Could somebody tell me what to write to make a brick move when ordered? I'm a newbie at scripting...
COMMUNITY QUESTION
How to make a brick move with a script?
3 answers
for i = 1,10 do
Workspace.Part.Position = Workspace.Part.Position + Vector3.new(i,0,0)
wait(0.5)
end
This will move it 10 studs on the x axis.
Correction:
for i = 1,20 do
script.Parent.Position = vector3.new(i, 0, 0)
wait(0.5)
end
This is an easier way, paste it into the brick. Or you can do this to have it run by it not being in the script.
for i,20 do
game.Workspace.BRICKNAME.Position = vector3.new(i, 0, 0)
wait(0.5)
end
You should of checked the wiki
This discussion is preserved as it was. New answers, comments, and votes are closed.
