Well so what I am trying to do is that the brick will rise with Vector3.new. But why won't this actually work?
01 | while true do |
02 | local part = script.Parent |
03 | for i = 25 , 1 do |
04 | part.Position = part.Position + Vector 3. new( 0 , 1 , 0 ) |
05 | wait( 0.5 ) |
06 | end |
07 | wait( 0.9 ) |
08 | for i 2 = 25 , 1 do |
09 | part.Position = part.Position + Vector 3. new( 0 , - 1 , 0 ) |
10 | wait( 0.5 ) |
11 | end |
12 | wait( 0.9 ) |
13 | end |
Thanks for service!
By the way, there are no errors in the output.
I am guessing you want it to rise 25 times?
when you use for loops you make the i = 1 and then put a comma, and say how many times you want it to repeat, then what it does. each time it repeats it adds the i by one until it reaches the max times you set it as.
so:
01 | while wait( 0.9 ) do |
02 | local part = script.Parent |
03 | for i = 1 , 25 do |
04 | part.Position = part.Position + Vector 3. new( 0 , 1 , 0 ) |
05 | wait( 0.5 ) |
06 | end |
07 | wait( 0.9 ) |
08 | for i = 1 , 25 do |
09 | part.Position = part.Position - Vector 3. new( 0 , 1 , 0 ) |
10 | wait( 0.5 ) |
11 | end |
12 | end |