Animated LOOP
Moderator: Moderators
Animated LOOP
i know how to make a block go up and then go down again, with scripting, but how do i do it so that it does this in a continus loop?
Thanks
Thanks
Atomic wrote:
partloop:
wait 5 // what ever you want
$part time .001 // time from wayD to wayA
$part moveto $wayA
$part waitmove
$part show
$part time 10.6 // the time that would be used to go from wayA to wayB
$part moveto $wayB
$part waitmove
$part hide
$part time .001 // time from wayC to wayD
$part moveto $wayC
$part waitmove
$part time .001 // time from wayD to wayA
$part moveto $wayD
$part waitmove
goto partloop
end
"all the governments in the world are corrupt and in the hands of the Illuminati"
for sound of mind since this is an infinite loop do this
Code: Select all
partloop:
local.loopy = 1
while(local.loopy = 1)
{
wait 5 // what ever you want
$part time .001 // time from wayD to wayA
$part moveto $wayA
$part waitmove
$part show
$part time 10.6 // the time that would be used to go from wayA to wayB
$part moveto $wayB
$part waitmove
$part hide
$part time .001 // time from wayC to wayD
$part moveto $wayC
$part waitmove
$part time .001 // time from wayD to wayA
$part moveto $wayD
$part waitmove
}
end
(soz about this, i didn't mean to post) - forget this lol
Last edited by Dani on Sat Aug 21, 2004 11:34 am, edited 1 time in total.
yes
Yes it will make the game crash. It needs a wait line inside the loop to slow it down--like "wait 1" or "wait .5". Also, targetnames in the script should look like this, "$block", and you need to add this line after each of the lines that set the direction of movement.
$block waitmove
$block waitmove
- HDL_CinC_Dragon
- Brigadier General
- Posts: 574
- Joined: Mon Dec 22, 2003 8:32 pm
cant you just do this:
If you want it to wait before it goes back down:
If you want it to wait before going back up:
If you want it to wait before it goes back down:
Code: Select all
block_loop:
$block loopsound lighthouse_run // if you want sound
$block moveup 123 // or how ever much you want it to go up
$block waitmove
$block stoploopsound
wait 5 // or how ever long you want it to wait
$block loopsound lighthouse_run
$block movedown 123
$block waitmove
$block stoploopsound
goto block_loop
endCode: Select all
block_loop:
$block loopsound lighthouse_run // if you want sound
$block moveup 123 // or how ever much you want it to go up
$block movedown 123
$block waitmove
$block stoploopsound
wait 5 // or how ever long you want it to wait
goto block_loop
end-
Bjarne BZR
- Site Admin
- Posts: 3298
- Joined: Wed Feb 05, 2003 2:04 pm
- Location: Sweden
- Contact:



