Skip to content
lsl.devlsl.devLSL Dev

LlSetAngularVelocity

Looking for the current API? Open the llSetAngularVelocity reference →

Wiki description

Applies rotational velocity to object.
It does the same job as llApplyRotationalImpulse but doesn't depend of the mass of object .

Examples


Instances :
one regular cube with mass M , and gravity 0 ( to disable the gravity) ; the object is homogenous and with only one prim so, its center of mass is its center of the object and its physical axis of rotation are its local axis :
<ul>
<li>LlSetAngularVelocity(<0,0,1>, TRUE ) => starts to rotate around its Z local axis with a start value of omega = 1 radian /second , and slows down over time until it won't rotate </li>
<li>llApplyRotationalImpulse(<0,0,1>, TRUE ) => starts to rotate around its Z local axis with a start value of omega = 1/M radian /second , and slows down over time until it won't rotate</li>
<li>llTargetOmega(<0.0,0.0,1.0>, 1.0, 1.0) => if the object is physical , starts to rotate around its Z local axis with a start value of omega = 1 radian / second . It won t slow down over time </li>
</ul>

See also: functions

History

Date of Release 10/08/2011

Shared wiki helpers

The original page also injects shared parameter notes, caveats or issue information through these helpers. Their conditional MediaWiki logic is not reproduced here; inspect the preserved helper source for additional material.

Template:LSL Function/force

Original shared helper source (conditional wiki logic is not evaluated)
{{LSL Injection Test}}{{#if:

{{#if:{{{local|}}}|
{{#ifeq:{{{local|}}}|*||

<!-- non-zero=* -->

{{#ifeq:{{{1|}}}|torque|

{{LSL_Function/boolean|{{{local|}}}|if=*
|th=uses the local axis
|td=uses the [[Viewer coordinate frames#Local|local axis]]
|fh=uses the region axis
|fd=uses the region [[Viewer coordinate frames#Region|region axis]]
|bool=*}}

|

{{LSL_Function/boolean|{{{local|}}}|if=*
|th={{{1|}}} is treated as a local directional vector
|td={{LSLP|{{{1|}}}}} is treated as a [[Viewer coordinate frames#Local|local]] directional vector
|fh={{{1|}}} is treated as a region directional vector
|fd={{LSLP|{{{1|}}}}} is treated as a [[Viewer coordinate frames#Region|region]] directional vector
|bool=*}}

}}

}}
}}


}}

Template:LSL Function/physical

Original shared helper source (conditional wiki logic is not evaluated)
{{LSL Injection Test}}{{#if:

{{#vardefine:caveats|{{#var:caveats}}
*Only works in {{#if:{{{avatar|}}}|attachments and}} [[STATUS_PHYSICS|physics-enabled]] objects.}}

}}<noinclude>
{| {{Prettytable}}
|- {{Hl2}}
! #var
! value
|-
{{VarPair|caveats}}
|}
</noinclude>
Original wiki source

Some wiki templates and tables need their original context. View this article on the Second Life Wiki. Technical wording and examples are retained from the source; historical guidance may differ from current behavior.