Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

stoping animations, on standing, when there are more then one scripte linked together

Kurt Zidane
Just Human
Join date: 1 Apr 2004
Posts: 636
09-26-2004 12:49
nm my test script was flawed, and the real problem was some where else in the code. lol Thanks for the post.
Strife Onizuka
Moonchild
Join date: 3 Mar 2004
Posts: 5,887
09-26-2004 13:08
in the future put code in [ code ] tags please; it's almost unreadable (and use white space for indents)

CODE

key userID = NULL_KEY;

default
{
state_entry()
{
llSitTarget( <0.0,0.0,0.001>, ZERO_ROTATION );
}

touch_start(integer total_number)
{

}

changed(integer change)
{
if ( change & CHANGED_LINK )
{
key id = llAvatarOnSitTarget();
if ( userID == NULL_KEY && id != NULL_KEY)
{
llSay(0, "sit detected - requesting permissions" );
llRequestPermissions(id, PERMISSION_TRIGGER_ANIMATION);
}
else if ( userID != NULL_KEY && id == NULL_KEY )
{
llSay( 0, "user has stood" );
llStopAnimation ( "atlas" );
llResetScript();
}
}
}

run_time_permissions(integer perm)
{
if(perm & PERMISSION_TRIGGER_ANIMATION)
{
llSay( 0, "permissions granted" );
llStopAnimation( "sit" );
llStartAnimation( "atlas" );
userID = llGetPermissionsKey();
}
}
}
_____________________
Truth is a river that is always splitting up into arms that reunite. Islanded between the arms, the inhabitants argue for a lifetime as to which is the main river.
- Cyril Connolly

Without the political will to find common ground, the continual friction of tactic and counter tactic, only creates suspicion and hatred and vengeance, and perpetuates the cycle of violence.
- James Nachtwey
Samhain Broom
Registered User
Join date: 1 Aug 2004
Posts: 298
09-27-2004 09:46
Strife,

Which tag button above here do you use to put your code in? Is it "vB Code" with the radio button set to "Enhanced mode"?
_____________________
rm -rf /bin/ladden #beware of geeks bearing grifts
Samhain Broom
Registered User
Join date: 1 Aug 2004
Posts: 298
09-27-2004 09:56
NM Strife,

I discovered the tag with the trusty "help" tag there. So next time I'll try it!
_____________________
rm -rf /bin/ladden #beware of geeks bearing grifts