Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Help with script

Tony Tigereye
Registered User
Join date: 4 Sep 2003
Posts: 165
10-01-2003 22:22
Is there a forum to post questions about scripting? I am having a problem with a couple of scripts and could really use some other eyes on the code to help me figure out what I am doing wrong.

Just in case this is the right forum for that sort of thing...

Script Foo does this:
llSay(1,"Spin_Start";);

Script Bar does this:
state_entry
{
llListen(1,"","","";);
}

listen(...)
{
if (message == "Spin_Start";)
{
llSay(0,"Start Spinning";);
llTargetOmega(...);
}
}


This code is supposed to make the Bar object spin when it hears "Spin_Start" on channel 1, but it doesn't spin. It prints the "Start Spinning" message, but it doesn't spin. When I move the llTargetOmega() call to the state_entry block, the same object spins just fine.

Any help appreciated.
Kats Kothari
Disturbingly Cute
Join date: 14 Aug 2003
Posts: 556
10-01-2003 22:35
Yes there is a specific forum for scripts. If you can't see it, that means that you are not completely logged in and at the bottom of the page there should be the space for you to write in your name and your password. ;)
Garoad Kuroda
Prophet of Muppetry
Join date: 5 Sep 2003
Posts: 2,989
10-02-2003 00:48
Psst... to use targetOmega the object has to be physical.

Better ask on the scripting forum though. Look into llSetRot() and using a timer I guess if it can't be physical. But it's more complicated.

*sneaks back to scripting forum*