mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 00:46:02 +08:00
change to llTargetOmega. If gain == 0 make viewer stop and reset rotation. NOT AS SL (but as its spec) - MAY DEPEND ON VIEWER. as before on physical only works on rootprim, ignored on child ones
This commit is contained in:
@@ -4229,11 +4229,14 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
|
||||
|
||||
protected void TargetOmega(SceneObjectPart part, LSL_Vector axis, double spinrate, double gain)
|
||||
{
|
||||
PhysicsActor pa = part.PhysActor;
|
||||
if ( ( pa == null || !pa.IsPhysical ) && gain == 0.0d )
|
||||
spinrate = 0.0d;
|
||||
part.UpdateAngularVelocity(axis * spinrate);
|
||||
}
|
||||
if(gain == 0)
|
||||
{
|
||||
part.UpdateAngularVelocity(Vector3.Zero);
|
||||
part.ScheduleFullAnimUpdate();
|
||||
}
|
||||
else
|
||||
part.UpdateAngularVelocity(axis * spinrate);
|
||||
}
|
||||
|
||||
public LSL_Integer llGetStartParameter()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user