OsForceOtherSit

From OpenSimulator

(Difference between revisions)
Jump to: navigation, search
m (Adding an example with target)
 
(5 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 
{{osslfunc
 
{{osslfunc
|function_syntax=void osForceOtherSit(key avatar)
+
|function_syntax= osForceOtherSit(key avatar)
  
void osForceOtherSit(key avatar, string target)
+
osForceOtherSit(key avatar, key target)
 
|csharp_syntax=
 
|csharp_syntax=
 
|description=Forces a sit of targeted avatar onto prim.
 
|description=Forces a sit of targeted avatar onto prim.
  
* avatar - The UUID of the avatar to which to attach.  Nothing happens if this is not a UUID.
+
* avatar - The key of the avatar to which to attach.  Nothing happens if this is not a UUID.
* target - The UUID of another prim to sit avatar on. Nothing happens if this is not a UUID of prim in region.
+
* target - The key of another prim to sit avatar on. Nothing happens if this is not a UUID of prim in region.
  
 
In OpenSimulator 0.8.0.1.
 
In OpenSimulator 0.8.0.1.
|threat_level=VeryHigh.
+
|threat_level=VeryHigh
 +
|permissions=false
 +
|delay=0
 
|ossl_example=<source lang="lsl">
 
|ossl_example=<source lang="lsl">
 
+
//
//Simple example for osForceOtherSit
+
// Simple example for osForceOtherSit
 +
//
  
 
default
 
default
Line 19: Line 22:
 
     state_entry()
 
     state_entry()
 
     {
 
     {
         llSitTarget(<0.0, 0.0, 1.0>, ZERO_ROTATION); //The vector's components must not all be set to 0 for effect to take place.
+
         llSay(PUBLIC_CHANNEL, "Touch to see osForceOtherSit in action.");
 +
 
 +
        // The vector's components must not all be set to 0 for effect to take place.
 +
        llSitTarget(<0.0, 0.0, 1.0>, ZERO_ROTATION);
 
     }
 
     }
   
+
 
    touch_start(integer num)
+
    touch_start(integer number)
 
     {
 
     {
      osForceOtherSit(llDetectedKey(0));
+
        osForceOtherSit(llDetectedKey(0));
 
     }
 
     }
 
}
 
}
 +
</source>
 +
<source lang="lsl">
 +
//
 +
// Simple example for osForceOtherSit with target
 +
//
  
 +
key target = "<PRIM_UUID>";
 +
 +
default
 +
{
 +
    state_entry()
 +
    {
 +
        llSay(PUBLIC_CHANNEL, "Touch to see osForceOtherSit with target in action.");
 +
 +
        // The vector's components must not all be set to 0 for effect to take place.
 +
        llSitTarget(<0.0, 0.0, 1.0>, ZERO_ROTATION);
 +
    }
 +
 +
    touch_start(integer number)
 +
    {
 +
        osForceOtherSit(llDetectedKey(0), target);
 +
    }
 +
}
 
</source>
 
</source>
|additional_info=
+
|additional_info=This function was added in 0.8.1-post-fixes
 
}}
 
}}

Latest revision as of 16:05, 23 November 2020

osForceOtherSit(key avatar)

osForceOtherSit(key avatar, key target)

Forces a sit of targeted avatar onto prim.
  • avatar - The key of the avatar to which to attach. Nothing happens if this is not a UUID.
  • target - The key of another prim to sit avatar on. Nothing happens if this is not a UUID of prim in region.

In OpenSimulator 0.8.0.1.

Threat Level VeryHigh
Permissions Use of this function is always disabled by default
Extra Delay 0 seconds
Example(s)
// 
// Simple example for osForceOtherSit
// 
 
default
{
    state_entry()
    {
        llSay(PUBLIC_CHANNEL, "Touch to see osForceOtherSit in action.");
 
        // The vector's components must not all be set to 0 for effect to take place.
        llSitTarget(<0.0, 0.0, 1.0>, ZERO_ROTATION);
    }
 
    touch_start(integer number)
    {
        osForceOtherSit(llDetectedKey(0));
    }
}
//
// Simple example for osForceOtherSit with target
//
 
key target = "<PRIM_UUID>";
 
default
{
    state_entry()
    {
        llSay(PUBLIC_CHANNEL, "Touch to see osForceOtherSit with target in action.");
 
        // The vector's components must not all be set to 0 for effect to take place.
        llSitTarget(<0.0, 0.0, 1.0>, ZERO_ROTATION);
    }
 
    touch_start(integer number)
    {
        osForceOtherSit(llDetectedKey(0), target);
    }
}
Notes
This function was added in 0.8.1-post-fixes
Personal tools
General
About This Wiki