From Second Life Wiki
|LSL Portal||Functions | Events | Types | Operators | Constants | Flow Control | Script Library | Categorized Library | Tutorials|
- Returns an accurate facing for Avatars seated or in mouselook, but only a rough direction otherwise when called from an attached prim.
- This function incorrectly (but usefully) returns the avatars region rotation when called in an attachment, use the following instead:
// if called only from the root llGetLocalRot(); // if called from in a linked object llList2Rot( llGetLinkPrimitiveParams( LINK_ROOT, [PRIM_ROT_LOCAL] ), 0 ); // this alternative works correctly in all scenarios llList2Rot( llGetLinkPrimitiveParams( !!llGetLinkNumber(), [PRIM_ROT_LOCAL] ), 0 );
In an attached object, returns region rotation of avatar NOT of the object's root prim. See special cases of rotation.
This related article at the LSL Wiki is able to bring enlightenment.wasn't helpful for you? Maybe the