Page 1 of 1

demo scripting

Posted: 08.08.2003, 21:28
by billybob884
Has the text string changed? I cant get it to work.

Posted: 08.08.2003, 22:14
by selden
"It works fine for me!" in Celestia v1.3.1pre9.

You'll have to provide a copy of what you've written.

Posted: 09.08.2003, 00:40
by billybob884
I even tried a simple little thing like:

Code: Select all

{
   print { text "Beginning tour...    Press the ESC key to cancel." }
}


doesn't work. I've got celestia pre 6, 768mb ram, geforce2, win me.

Posted: 09.08.2003, 06:13
by don
Howdy Mike,

You may want to take a look at Chris' demo.cel that comes with Celestia for some example code.

Here is how he begins his demo:

Code: Select all

   print { text "Beginning demo . . .\nPress ESC to end." origin "center" duration 2 }
   wait { duration 2.0 }

In Celestia's .CEL scripting, certain commands require one or more parameters to be used. With the print command, you need to tell it where to display the text and for how long. This is done via the origin and duration parameters.

Then, if you want the user to see the text, you need to code a wait command after the print command that has a duration equal to or greater than the duration specified in the print command -- just like Chris' lines above shows.

Hope this helps!

Posted: 09.08.2003, 23:49
by billybob884
it helps a little, but not enough. i played chris's demo and it works fine, but when i copied the print and wait code into mine (i put it right at the top) it still didnt show anything.

Posted: 10.08.2003, 02:06
by don
Mike,

If you post your script, or at least several commands before and after your print command, maybe we can help.

Posted: 10.08.2003, 07:43
by billybob884
Well, after a bit of tinkering, I got it to work. I just had to change every single text string before it would work, but it's fixed now.

Posted: 10.08.2003, 07:57
by don
Congratulations Mike! Glad to hear you got it to work.

If you're interested, I posted a "template" script over in the Celestia Scripting forum (http://ennui.shatters.net/forum/viewtopic.php?t=2961).