Jump to content
Sign in to follow this  
Wandering Soulstar

Automatic Sit Animation

Recommended Posts

Hi All,

I'd like to set the animation (pose) of an AV when they sit on a prim, without the requesting of permissions. This must be possible as most any chair I have does not ask for this, yet I cannot seem to see in the Wiki how this is accomplished. Any help?

 

Thanks in advance,

Wanda

Share this post


Link to post
Share on other sites
11 minutes ago, Wandering Soulstar said:

Hi All,

I'd like to set the animation (pose) of an AV when they sit on a prim, without the requesting of permissions. This must be possible as most any chair I have does not ask for this, yet I cannot seem to see in the Wiki how this is accomplished. Any help?

 

Thanks in advance,

Wanda

Try the opensource AVsitter system.  https://avsitter.github.io/avsitter2_home.html

 

Share this post


Link to post
Share on other sites

Ahhh ... so the following:

    changed(integer change)
    {
        //see if we have someone sitting ...
        if (change & CHANGED_LINK)
        {
            //code check to see if seated AV and get their link
            //...

            //get their key
            key user = llGetLinkKey(userLink);

            //call permissions .. will not trigger an ask to the iser
            llRequestPermissions(user, PERMISSION_TRIGGER_ANIMATION);
            //continue in run_time_permissions event
        }
    }

    run_time_permissions(integer permissions)
    {
        if (perm & PERMISSION_TRIGGER_ANIMATION)
        {
            //code to set sit animation
        } 
    }

 

Thanks for the clarification @Qie Niangao

  • Like 1

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...