Page 1 of 1

looping .cel scripts with .celx

Posted: 26.09.2004, 09:25
by Guest
hey guys, i wrote a .cel script and i'd like it to loop.

i found this in the boards but i get an error:

Code: Select all

while true do
  celscript = celestia:createcelscript( [[
..cel script here..
  ]] )
  while celscript:tick() do end
end


when i try and run he script i get a fatal error dialog saying "timeout: script hasn't returned control to celestia (forgot to call wait()?)"

any ideas? i'm on a windows 2k system running celestia 1.3.2

thanks!

Posted: 26.09.2004, 09:39
by Guest
hey guys, i figured it out myself!

Code: Select all

while true do
  celscript = celestia:createcelscript( [[
..cel script here..
  ]] )
  while celscript:tick() do [b]wait(0)[/b] end
end


:o