Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Question on getting perm for animation

Kermit Rutkowski
Registered User
Join date: 5 Feb 2008
Posts: 8
08-01-2008 14:39
I am modifying a vehicle script. The base animation is sit, but once the vehicle starts to move, I want to change the animation. Currently the codes start with:

llRequestPermissions(agent, PERMISSION_TRIGGER_ANIMATION | PERMISSION_TAKE_CONTROLS);

and is followed by:

run_time_permissions(integer perm)

The animation is the standard sit when the vehicle starts.

What I would like to do is to change the driver animation at a later time when conditions change. Can I change the animation by a simple llStartAnimaion or do I need to check perm with llGetPermissions first and then set the animation?

I hope my question is clear.
Hewee Zetkin
Registered User
Join date: 20 Jul 2006
Posts: 2,702
08-01-2008 14:47
You should be able to simply use llStartAnimation() and llStopAnimation() if the script has received permissions already and not lost them (it'll basically lose the permissions only if you reset the script, request a different set of permissions, or request permissions from a different avatar after the initial request). Also llReleaseControls() may revoke some (PERMISSION_TAKE_CONTROLS) or all permissions, though IIRC it shows up in the script as still having the permission even though you don't get the control event again until you take controls once more (after maybe requesting the permission again).
Kermit Rutkowski
Registered User
Join date: 5 Feb 2008
Posts: 8
Thank you
08-01-2008 15:19
From: Hewee Zetkin
You should be able to simply use llStartAnimation() and llStopAnimation() if the script has received permissions already and not lost them (it'll basically lose the permissions only if you reset the script, request a different set of permissions, or request permissions from a different avatar after the initial request). Also llReleaseControls() may revoke some (PERMISSION_TAKE_CONTROLS) or all permissions, though IIRC it shows up in the script as still having the permission even though you don't get the control event again until you take controls once more (after maybe requesting the permission again).


Thank you so much for the very clear answer to my question!
Kermit Rutkowski
Registered User
Join date: 5 Feb 2008
Posts: 8
08-04-2008 19:11
From: Kermit Rutkowski
I am modifying a vehicle script. The base animation is sit, but once the vehicle starts to move, I want to change the animation. Currently the codes start with:

llRequestPermissions(agent, PERMISSION_TRIGGER_ANIMATION | PERMISSION_TAKE_CONTROLS);

and is followed by:

run_time_permissions(integer perm)

The animation is the standard sit when the vehicle starts.

What I would like to do is to change the driver animation at a later time when conditions change. Can I change the animation by a simple llStartAnimaion or do I need to check perm with llGetPermissions first and then set the animation?

I hope my question is clear.


Sorry to post this question again. I have everything working well with the simple lines above. Subsequent animation changes are done with a simple llStartAnimation command and worked well if the vehicle stays in the same sim. The problem is if the vehicle moves across a sim border to a different sim, I get an error message- "llStartAnimation: Script trying to trigger animations but agent not found."

This seems to happen only for a particular sim crossing and not at some other crossing. Any advice on this?