Advertisement
Edie_Shoreland

Simple Idle Stand Bot AO

Sep 20th, 2018
148
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // Ideal for Mannequin-Style Bots (Should work with any SL Bot Services
  2. // or Bot/Text Viewers.)
  3.  
  4. // This script is designed to activate lifelike AO stand animations while
  5. // your bot is waiting for the command to be "seated" on posestands or any
  6. // objects with built in animations.
  7.  
  8. // Revised to pick a stand animation at random.  Place this script and your
  9. // stand-only (idle) animations in a prim and attach the prim to your bot's
  10. // avatar.
  11.  
  12.  
  13. default
  14. {
  15.     attach(key id)
  16.     {
  17.         if ( id ) llRequestPermissions(id , PERMISSION_OVERRIDE_ANIMATIONS);
  18.         else if ( llGetPermissions() & PERMISSION_OVERRIDE_ANIMATIONS ) llResetAnimationOverride("ALL");
  19.     }
  20.     run_time_permissions(integer perms)
  21.     {
  22.         if ( perms & PERMISSION_OVERRIDE_ANIMATIONS )
  23.         {
  24.             integer standz = llGetInventoryNumber(INVENTORY_ANIMATION);    
  25.             string idle = llGetInventoryName(INVENTORY_ANIMATION, (integer)llFrand(standz));
  26.             llSetAnimationOverride("Standing",idle);
  27.         }
  28.     }
  29. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement