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 » Scripting Helpers
Home Search
 

I need help getting this script to work

Previous Thread :: Next Thread 
AprilFirst is not online. AprilFirst
Joined: 19 Jul 2012
Total Posts: 186
18 Aug 2012 03:40 PM
Basicly i just want it to look like a basic rocket lift off, click a button, the engine lights and it flys up, im new the CFrame so im not so sure how it works

function onClicked(clicked)
Fire = Instance.new("Fire")
Fire.Parent = script.Parent.Parent.Rocket.Light
Fire.Heat = 20
Fire.Size = 15

wait(2)
Rocket = script.Parent.Parent.Rocket

for i = 1, 50 do
Rocket.CFrame = Rocket.CFrame - Vector3.new(0, 1, 0)
wait()
end
end

script.Parent.ClickDetector.MouseClick:connect(onClicked)

Output says "13:38:04 - CFrame is not a valid member of Model"
Report Abuse
xXTheRobotXx is not online. xXTheRobotXx
Joined: 05 May 2012
Total Posts: 13343
18 Aug 2012 03:56 PM
game.Workspace.Rocket.CFrame = CFrame.new(0,1,0)
Report Abuse
18cwatford is not online. 18cwatford
Joined: 08 Oct 2009
Total Posts: 5410
18 Aug 2012 03:57 PM
A model does not have a CFrame OR Position value.
Report Abuse
AprilFirst is not online. AprilFirst
Joined: 19 Jul 2012
Total Posts: 186
18 Aug 2012 04:00 PM
@18, then how would you move a model?
Report Abuse
18cwatford is not online. 18cwatford
Joined: 08 Oct 2009
Total Posts: 5410
18 Aug 2012 04:01 PM
Taking all the parts in it and moving them.
Report Abuse
xXTheRobotXx is not online. xXTheRobotXx
Joined: 05 May 2012
Total Posts: 13343
18 Aug 2012 04:02 PM
Oh, forgot it was a model
Report Abuse
18cwatford is not online. 18cwatford
Joined: 08 Oct 2009
Total Posts: 5410
18 Aug 2012 04:03 PM
@Robot and he wanted it to go down one stud, not move all the way to CFrame.new(0, 1, 0)
Report Abuse
xXTheRobotXx is not online. xXTheRobotXx
Joined: 05 May 2012
Total Posts: 13343
18 Aug 2012 04:03 PM
You could put all the bricks in the model in a table, then move that entire table.
Report Abuse
18cwatford is not online. 18cwatford
Joined: 08 Oct 2009
Total Posts: 5410
18 Aug 2012 04:05 PM
@Robot well that would be a for loop after using a function to get all the parts and return a table.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • 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