Jump to content

Anim perms in gestures


You are about to reply to a thread that has been inactive for 489 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts


Hello

I bought some simple animations (wave, laugh, finger-guns), with the intention of triggering them while I'm chatting ('hi / lol / pew-pew').

I learned how to make gestures but the lack of Transfer Perms prevent me.
I dont understand permission restrictions.

If I had the time & skill & inclination I'd try to make some hud (with 100++ anims & expressions ), but surely there's a more fluent way of triggering my anims/emotions with keywords whilst socialising?


Someone had a similar issue in 2008
...they solved the issue with a magic bracelet, because of course they did.

Link to post
Share on other sites
7 hours ago, Rahscorch said:


Hello

I bought some simple animations (wave, laugh, finger-guns), with the intention of triggering them while I'm chatting ('hi / lol / pew-pew').

I learned how to make gestures but the lack of Transfer Perms prevent me.
I dont understand permission restrictions.

If I had the time & skill & inclination I'd try to make some hud (with 100++ anims & expressions ), but surely there's a more fluent way of triggering my anims/emotions with keywords whilst socialising?


Someone had a similar issue in 2008
...they solved the issue with a magic bracelet, because of course they did.

You can make a scripted avatar attachment that listens to you only, which triggers the animation you want based on keywords. 

Edit: this uses the listen event. The script should contain a permission request to play animations and only then start a to listen to you. Theisten event then shoukd contain filters to respond to you only, in a predefined channel if you so choose, and then a filter for the keywords you set up to play the correct animation(s) with optional sound and chat. I think a more indepth explanation can be asked in the scripting forum

Edited by OptimoMaximo
  • Like 2
Link to post
Share on other sites

Here's the basic logic for playing animations based on keywords in local chat messages:

default
{
    // When the script starts:
    state_entry()
    {
        // Request permissions to animate the owner.
        llRequestPermissions(llGetOwner(), PERMISSION_TRIGGER_ANIMATION);
    }

    // When a permission request is answered:
    run_time_permissions(integer permissions)
    {
        // If permissions were granted:
        if (permissions)
        {
            // Listen for the owner's messages in local chat.
            llListen(0, "", llGetOwner(), "");
        }
    }

    // When a message is heard:
    listen(integer channel, string name, key id, string message)
    {
        // Convert everything to lowercase so that case doesn't matter.
        message = llToLower(message);

        // Search for a keyword in the message.
        integer keyword = llSubStringIndex(message, "hi")

        // If the search didn't return an error, play an animation.
        if (keyword != -1)
        {
            llStartAnimation("wave");
        }

        // Search for another keyword in the message.
        keyword = llSubStringIndex(message, "lol")

        if (keyword != -1)
        {
            llStartAnimation("laugh");
        }
    }
}

It's not perfect as-is. If you just use llSubStringIndex to search for "lol" or "hi", the script will play an animation when you say "lollipop" or "hide". Checking for word-boundaries is slightly complicated, but not overwhelmingly difficult.

  • Thanks 1
Link to post
Share on other sites
You are about to reply to a thread that has been inactive for 489 days.

Please take a moment to consider if this thread is worth bumping.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...