generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: If I wanted to cframe a model do I have to...

Previous Thread :: Next Thread 
EarthKingIV is not online. EarthKingIV
Joined: 02 Apr 2011
Total Posts: 2376
17 Apr 2017 08:05 PM
make a line of code for each part
(i tried get children with a primary part but it didn't work idk if I was doing it wrong or what)
Report Abuse
Wowgnomes is online. Wowgnomes
Joined: 27 Sep 2009
Total Posts: 26255
17 Apr 2017 08:07 PM
Set primary part, this can be done with scripting or just setting it as if you were setting transparency using explorer + property viewer


SetPrimaryPartCFrame(cframe)
Report Abuse
EarthKingIV is not online. EarthKingIV
Joined: 02 Apr 2011
Total Posts: 2376
17 Apr 2017 08:11 PM
ok so this is what I made, the numbers are from the primary part's position, can you go through this and tell me what I did wrong

script.Parent.Touched:connect(function()

if workspace.mainBlock.lead.Transparency==0 then
--main block is the name of the model

for i=4883.806,4822.806,-3 do
mainBlock=workspace.mainBlock
for _,part in pairs(mainBlock:GetChildren()) do
part.CFrame=CFrame.new(-208.735, i, 66.133) --the numbers are the pp's position
wait(.1)
end



end
end
end)
Report Abuse
Disillusions is not online. Disillusions
Joined: 10 Jul 2011
Total Posts: 6365
17 Apr 2017 08:12 PM
model:SetPrimaryPartCFrame(Cframe)


Report Abuse
Wowgnomes is online. Wowgnomes
Joined: 27 Sep 2009
Total Posts: 26255
17 Apr 2017 08:13 PM
just use set primary part cframe like i said in first post. it moves the whole model
Report Abuse
EarthKingIV is not online. EarthKingIV
Joined: 02 Apr 2011
Total Posts: 2376
17 Apr 2017 08:15 PM
that's what wiki said to, and it's not help at all bc idk where to put it D':
Report Abuse
EarthKingIV is not online. EarthKingIV
Joined: 02 Apr 2011
Total Posts: 2376
17 Apr 2017 08:19 PM
i put it under where I defined the variable and changed model to the name of the variable and output says missing argument
Report Abuse
EarthKingIV is not online. EarthKingIV
Joined: 02 Apr 2011
Total Posts: 2376
17 Apr 2017 08:23 PM
anyoneeeeeeeeeeee
Report Abuse
Wowgnomes is online. Wowgnomes
Joined: 27 Sep 2009
Total Posts: 26255
17 Apr 2017 08:23 PM
Noob not listening to me because wiki says different? Ok don't. Have fun with inefficient code
Report Abuse
EarthKingIV is not online. EarthKingIV
Joined: 02 Apr 2011
Total Posts: 2376
17 Apr 2017 08:25 PM
what are you talking about I am listening to you, i'm saying wiki said the same thing but didn't explain where to put it and how to use it, if you just give me a line of code without explaining it i'm not gonna know what to do with it...
Report Abuse
EarthKingIV is not online. EarthKingIV
Joined: 02 Apr 2011
Total Posts: 2376
17 Apr 2017 08:26 PM
and you can't set the primary part to cframe in properties unless i'm doing it wrong
Report Abuse
Wowgnomes is online. Wowgnomes
Joined: 27 Sep 2009
Total Posts: 26255
17 Apr 2017 08:29 PM
Model:SetPrimaryPartCFrame(cframedesired)
What don't you understand about it
Report Abuse
EarthKingIV is not online. EarthKingIV
Joined: 02 Apr 2011
Total Posts: 2376
17 Apr 2017 08:31 PM
where do i put it in the script
Report Abuse
Wowgnomes is online. Wowgnomes
Joined: 27 Sep 2009
Total Posts: 26255
17 Apr 2017 08:33 PM
It is the same as if you were doing part.CFrame = cframe
Just format is different bc it is for a model
Report Abuse
Wunder_Wulfe is online. Wunder_Wulfe
Joined: 13 Sep 2016
Total Posts: 8356
17 Apr 2017 08:58 PM
it moves the primary part of the model to that cframe and brings all other descendants with it
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image