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
 

Re: Can someone tell me why this isnt moving by 1 stud?

Previous Thread :: Next Thread 
harryvince2000 is not online. harryvince2000
Joined: 22 Jun 2008
Total Posts: 4324
25 Aug 2011 08:42 PM
Please.
---created by harryvince2000
while true do

p = game.Workspace.Wedge3

for i = 1, 30, 1 do
p.CFrame = p.CFrame+Vector3.new(i, 0, 0)
wait(0.5)



end
p.Position = Vector3.new(-240, 8.2, 0.5)
end
Report Abuse
earth100 is not online. earth100
Joined: 13 Dec 2007
Total Posts: 2088
25 Aug 2011 08:46 PM
You increase distance by i.

As the for loop continues, the i value will increase from 1, to 2 making the distance that the part moves increase accordingly

Change i to 1

Also instead of

p.Position = Vector3.new(#,#,#)

I suggest putting this at the start of the code
startCF = p.CFrame

and replacing p.Position = Vect....
with p.CFrame = startCF
Report Abuse
harryvince2000 is not online. harryvince2000
Joined: 22 Jun 2008
Total Posts: 4324
25 Aug 2011 08:47 PM
kk thanks!
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