当前位置: 首页>>代码示例>>C#>>正文


C# Aurora.ScriptEngine.AuroraDotNetEngine.LSL_Types.list.GetLSLFloatItem方法代码示例

本文整理汇总了C#中Aurora.ScriptEngine.AuroraDotNetEngine.LSL_Types.list.GetLSLFloatItem方法的典型用法代码示例。如果您正苦于以下问题:C# Aurora.ScriptEngine.AuroraDotNetEngine.LSL_Types.list.GetLSLFloatItem方法的具体用法?C# Aurora.ScriptEngine.AuroraDotNetEngine.LSL_Types.list.GetLSLFloatItem怎么用?C# Aurora.ScriptEngine.AuroraDotNetEngine.LSL_Types.list.GetLSLFloatItem使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Aurora.ScriptEngine.AuroraDotNetEngine.LSL_Types.list的用法示例。


在下文中一共展示了Aurora.ScriptEngine.AuroraDotNetEngine.LSL_Types.list.GetLSLFloatItem方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: SetPrimParams


//.........这里部分代码省略.........
                    }

                }

                else if (code == (int)ScriptBaseClass.PRIM_TYPE)
                {
                    if (remain < 3)
                        return;

                    if (part is SceneObjectPart) { }
                    else
                        return;

                    code = (int)rules.GetLSLIntegerItem(idx++);

                    remain = rules.Length - idx;
                    float hollow;
                    LSL_Vector twist;
                    LSL_Vector taper_b;
                    LSL_Vector topshear;
                    float revolutions;
                    float radiusoffset;
                    float skew;
                    LSL_Vector holesize;
                    LSL_Vector profilecut;

                    if (code == (int)ScriptBaseClass.PRIM_TYPE_BOX)
                    {
                        if (remain < 6)
                            return;

                        face = (int)rules.GetLSLIntegerItem(idx++);
                        v = rules.GetVector3Item(idx++); // cut
                        hollow = (float)rules.GetLSLFloatItem(idx++);
                        twist = rules.GetVector3Item(idx++);
                        taper_b = rules.GetVector3Item(idx++);
                        topshear = rules.GetVector3Item(idx++);

                        (part as SceneObjectPart).Shape.PathCurve = (byte)Extrusion.Straight;
                        SetPrimitiveShapeParams((part as SceneObjectPart), face, v, hollow, twist, taper_b, topshear, 1);

                    }

                    else if (code == (int)ScriptBaseClass.PRIM_TYPE_CYLINDER)
                    {
                        if (remain < 6)
                            return;

                        face = (int)rules.GetLSLIntegerItem(idx++); // holeshape
                        v = rules.GetVector3Item(idx++); // cut
                        hollow = (float)rules.GetLSLFloatItem(idx++);
                        twist = rules.GetVector3Item(idx++);
                        taper_b = rules.GetVector3Item(idx++);
                        topshear = rules.GetVector3Item(idx++);
                        (part as SceneObjectPart).Shape.ProfileShape = ProfileShape.Circle;
                        (part as SceneObjectPart).Shape.PathCurve = (byte)Extrusion.Straight;
                        SetPrimitiveShapeParams((part as SceneObjectPart), face, v, hollow, twist, taper_b, topshear, 0);

                    }

                    else if (code == (int)ScriptBaseClass.PRIM_TYPE_PRISM)
                    {
                        if (remain < 6)
                            return;

                        face = (int)rules.GetLSLIntegerItem(idx++); // holeshape
开发者ID:mugginsm,项目名称:Aurora-Sim,代码行数:67,代码来源:LSL_Api.cs

示例2: aaSetEnv

 public void aaSetEnv(LSL_String name, LSL_List value)
 {
     if (name == ScriptBaseClass.ENABLE_GRAVITY)
     {
         LSL_Integer enabled = value.GetLSLIntegerItem(0);
         float[] grav = m_host.ParentEntity.Scene.PhysicsScene.GetGravityForce();
         m_host.ParentEntity.Scene.PhysicsScene.SetGravityForce(enabled == 1, grav[0], grav[1], grav[2]);
     }
     else if (name == ScriptBaseClass.GRAVITY_FORCE_X)
     {
         LSL_Float f = value.GetLSLFloatItem(0);
         float[] grav = m_host.ParentEntity.Scene.PhysicsScene.GetGravityForce();
         m_host.ParentEntity.Scene.PhysicsScene.SetGravityForce(true, (float) f.value, grav[1], grav[2]);
     }
     else if (name == ScriptBaseClass.GRAVITY_FORCE_Y)
     {
         LSL_Float f = value.GetLSLFloatItem(0);
         float[] grav = m_host.ParentEntity.Scene.PhysicsScene.GetGravityForce();
         m_host.ParentEntity.Scene.PhysicsScene.SetGravityForce(true, grav[0], (float) f.value, grav[2]);
     }
     else if (name == ScriptBaseClass.GRAVITY_FORCE_Z)
     {
         LSL_Float f = value.GetLSLFloatItem(0);
         float[] grav = m_host.ParentEntity.Scene.PhysicsScene.GetGravityForce();
         m_host.ParentEntity.Scene.PhysicsScene.SetGravityForce(true, grav[0], grav[1], (float) f.value);
     }
     else if (name == ScriptBaseClass.ADD_GRAVITY_POINT)
     {
         LSL_Vector pos = value.GetVector3Item(0);
         LSL_Float gravForce = value.GetLSLFloatItem(1);
         LSL_Float radius = value.GetLSLFloatItem(2);
         LSL_Integer ident = value.GetLSLIntegerItem(3);
         float[] grav = m_host.ParentEntity.Scene.PhysicsScene.GetGravityForce();
         m_host.ParentEntity.Scene.PhysicsScene.AddGravityPoint(false,
                                                                new Vector3((float) pos.x, (float) pos.y,
                                                                            (float) pos.z),
                                                                0, 0, 0, (float) gravForce.value,
                                                                (float) radius.value, ident.value);
     }
     else if (name == ScriptBaseClass.ADD_GRAVITY_FORCE)
     {
         LSL_Vector pos = value.GetVector3Item(0);
         LSL_Float xForce = value.GetLSLFloatItem(1);
         LSL_Float yForce = value.GetLSLFloatItem(2);
         LSL_Float zForce = value.GetLSLFloatItem(3);
         LSL_Float radius = value.GetLSLFloatItem(4);
         LSL_Integer ident = value.GetLSLIntegerItem(5);
         float[] grav = m_host.ParentEntity.Scene.PhysicsScene.GetGravityForce();
         m_host.ParentEntity.Scene.PhysicsScene.AddGravityPoint(true,
                                                                new Vector3((float) pos.x, (float) pos.y,
                                                                            (float) pos.z),
                                                                (float) xForce, (float) yForce, (float) zForce, 0,
                                                                (float) radius.value, ident.value);
     }
     else if (name == ScriptBaseClass.START_TIME_REVERSAL_SAVING)
     {
         IPhysicsStateModule physicsState = World.RequestModuleInterface<IPhysicsStateModule>();
         if (physicsState != null)
             physicsState.StartSavingPhysicsTimeReversalStates();
     }
     else if (name == ScriptBaseClass.STOP_TIME_REVERSAL_SAVING)
     {
         IPhysicsStateModule physicsState = World.RequestModuleInterface<IPhysicsStateModule>();
         if (physicsState != null)
             physicsState.StopSavingPhysicsTimeReversalStates();
     }
     else if (name == ScriptBaseClass.START_TIME_REVERSAL)
     {
         IPhysicsStateModule physicsState = World.RequestModuleInterface<IPhysicsStateModule>();
         if (physicsState != null)
             physicsState.StartPhysicsTimeReversal();
     }
     else if (name == ScriptBaseClass.STOP_TIME_REVERSAL)
     {
         IPhysicsStateModule physicsState = World.RequestModuleInterface<IPhysicsStateModule>();
         if (physicsState != null)
             physicsState.StopPhysicsTimeReversal();
     }
 }
开发者ID:savino1976,项目名称:Aurora-Sim,代码行数:79,代码来源:AA_API.cs

示例3: SetPrimParams


//.........这里部分代码省略.........
                }

                else if (code == (int) ScriptBaseClass.PRIM_TYPE)
                {
                    if (remain < 3)
                        return;

                    if (part is ISceneChildEntity)
                    {
                    }
                    else
                        return;

                    code = rules.GetLSLIntegerItem(idx++);

                    remain = rules.Length - idx;
                    float hollow;
                    LSL_Vector twist;
                    LSL_Vector taper_b;
                    LSL_Vector topshear;
                    float revolutions;
                    float radiusoffset;
                    float skew;
                    LSL_Vector holesize;
                    LSL_Vector profilecut;

                    if (code == (int) ScriptBaseClass.PRIM_TYPE_BOX)
                    {
                        if (remain < 6)
                            return;

                        face = rules.GetLSLIntegerItem(idx++);
                        v = rules.GetVector3Item(idx++); // cut
                        hollow = (float) rules.GetLSLFloatItem(idx++);
                        twist = rules.GetVector3Item(idx++);
                        taper_b = rules.GetVector3Item(idx++);
                        topshear = rules.GetVector3Item(idx++);

                        (part as ISceneChildEntity).Shape.PathCurve = (byte) Extrusion.Straight;
                        SetPrimitiveShapeParams((part as ISceneChildEntity), face, v, hollow, twist, taper_b, topshear,
                                                1);
                    }

                    else if (code == (int) ScriptBaseClass.PRIM_TYPE_CYLINDER)
                    {
                        if (remain < 6)
                            return;

                        face = rules.GetLSLIntegerItem(idx++); // holeshape
                        v = rules.GetVector3Item(idx++); // cut
                        hollow = (float) rules.GetLSLFloatItem(idx++);
                        twist = rules.GetVector3Item(idx++);
                        taper_b = rules.GetVector3Item(idx++);
                        topshear = rules.GetVector3Item(idx++);
                        (part as ISceneChildEntity).Shape.ProfileShape = ProfileShape.Circle;
                        (part as ISceneChildEntity).Shape.PathCurve = (byte) Extrusion.Straight;
                        SetPrimitiveShapeParams((part as ISceneChildEntity), face, v, hollow, twist, taper_b, topshear,
                                                0);
                    }

                    else if (code == (int) ScriptBaseClass.PRIM_TYPE_PRISM)
                    {
                        if (remain < 6)
                            return;

                        face = rules.GetLSLIntegerItem(idx++); // holeshape
开发者ID:velus,项目名称:Async-Sim-Testing,代码行数:67,代码来源:LSL_Api.cs

示例4: SetParticleSystem

        private void SetParticleSystem(SceneObjectPart part, LSL_List rules)
        {
            if (rules.Length == 0)
            {
                part.RemoveParticleSystem();
                part.ParentGroup.HasGroupChanged = true;
            }
            else
            {
                Primitive.ParticleSystem prules = getNewParticleSystemWithSLDefaultValues();
                LSL_Vector tempv = new LSL_Vector();

                float tempf = 0;

                for (int i = 0; i < rules.Length; i += 2)
                {
                    LSL_Integer rule = rules.GetLSLIntegerItem(i);
                    if (rule == (int)ScriptBaseClass.PSYS_PART_FLAGS)
                    {
                        prules.PartDataFlags = (Primitive.ParticleSystem.ParticleDataFlags)(uint)rules.GetLSLIntegerItem(i + 1);
                    }

                    else if (rule == (int)ScriptBaseClass.PSYS_PART_START_COLOR)
                    {
                        tempv = rules.GetVector3Item(i + 1);
                        prules.PartStartColor.R = (float)tempv.x;
                        prules.PartStartColor.G = (float)tempv.y;
                        prules.PartStartColor.B = (float)tempv.z;
                    }

                    else if (rule == (int)ScriptBaseClass.PSYS_PART_START_ALPHA)
                    {
                        tempf = (float)rules.GetLSLFloatItem(i + 1);
                        prules.PartStartColor.A = tempf;
                    }

                    else if (rule == (int)ScriptBaseClass.PSYS_PART_END_COLOR)
                    {
                        tempv = rules.GetVector3Item(i + 1);
                        prules.PartEndColor.R = (float)tempv.x;
                        prules.PartEndColor.G = (float)tempv.y;
                        prules.PartEndColor.B = (float)tempv.z;
                    }

                    else if (rule == (int)ScriptBaseClass.PSYS_PART_END_ALPHA)
                    {
                        tempf = (float)rules.GetLSLFloatItem(i + 1);
                        prules.PartEndColor.A = tempf;
                    }

                    else if (rule == (int)ScriptBaseClass.PSYS_PART_START_SCALE)
                    {
                        tempv = rules.GetVector3Item(i + 1);
                        prules.PartStartScaleX = (float)tempv.x;
                        prules.PartStartScaleY = (float)tempv.y;
                    }

                    else if (rule == (int)ScriptBaseClass.PSYS_PART_END_SCALE)
                    {
                        tempv = rules.GetVector3Item(i + 1);
                        prules.PartEndScaleX = (float)tempv.x;
                        prules.PartEndScaleY = (float)tempv.y;
                    }

                    else if (rule == (int)ScriptBaseClass.PSYS_PART_MAX_AGE)
                    {
                        tempf = (float)rules.GetLSLFloatItem(i + 1);
                        prules.PartMaxAge = tempf;
                    }

                    else if (rule == (int)ScriptBaseClass.PSYS_SRC_ACCEL)
                    {
                        tempv = rules.GetVector3Item(i + 1);
                        prules.PartAcceleration.X = (float)tempv.x;
                        prules.PartAcceleration.Y = (float)tempv.y;
                        prules.PartAcceleration.Z = (float)tempv.z;
                    }

                    else if (rule == (int)ScriptBaseClass.PSYS_SRC_PATTERN)
                    {
                        int tmpi = (int)rules.GetLSLIntegerItem(i + 1);
                        prules.Pattern = (Primitive.ParticleSystem.SourcePattern)tmpi;
                    }

                    // PSYS_SRC_INNERANGLE and PSYS_SRC_ANGLE_BEGIN use the same variables. The
                    // PSYS_SRC_OUTERANGLE and PSYS_SRC_ANGLE_END also use the same variable. The
                    // client tells the difference between the two by looking at the 0x02 bit in
                    // the PartFlags variable.
                    else if (rule == (int)ScriptBaseClass.PSYS_SRC_INNERANGLE)
                    {
                        tempf = (float)rules.GetLSLFloatItem(i + 1);
                        prules.InnerAngle = (float)tempf;
                        prules.PartFlags &= 0xFFFFFFFD; // Make sure new angle format is off.
                    }

                    else if (rule == (int)ScriptBaseClass.PSYS_SRC_OUTERANGLE)
                    {
                        tempf = (float)rules.GetLSLFloatItem(i + 1);
                        prules.OuterAngle = (float)tempf;
                        prules.PartFlags &= 0xFFFFFFFD; // Make sure new angle format is off.
//.........这里部分代码省略.........
开发者ID:mugginsm,项目名称:Aurora-Sim,代码行数:101,代码来源:LSL_Api.cs

示例5: llPursue

 public void llPursue(LSL_String target, LSL_List options)
 {
     IBotManager botManager = World.RequestModuleInterface<IBotManager>();
     if (botManager != null)
     {
         float fuzz = 2;
         Vector3 offset = Vector3.Zero;
         bool requireLOS = false;
         bool intercept = false; //Not implemented
         for (int i = 0; i < options.Length; i += 2)
         {
             LSL_Types.LSLInteger opt = options.GetLSLIntegerItem(i);
             if (opt == ScriptBaseClass.PURSUIT_FUZZ_FACTOR)
                 fuzz = (float) options.GetLSLFloatItem(i + 1).value;
             if (opt == ScriptBaseClass.PURSUIT_OFFSET)
                 offset = options.GetVector3Item(i + 1).ToVector3();
             if (opt == ScriptBaseClass.REQUIRE_LINE_OF_SIGHT)
                 requireLOS = options.GetLSLIntegerItem(i + 1) == 1;
             if (opt == ScriptBaseClass.PURSUIT_INTERCEPT)
                 intercept = options.GetLSLIntegerItem(i + 1) == 1;
         }
         botManager.FollowAvatar(m_host.ParentEntity.UUID, target.m_string, fuzz, fuzz, requireLOS, offset,
                                 m_host.ParentEntity.OwnerID);
     }
 }
开发者ID:velus,项目名称:Async-Sim-Testing,代码行数:25,代码来源:LSL_Api.cs

示例6: llUpdateCharacter

 public void llUpdateCharacter(LSL_List options)
 {
     IBotManager botManager = World.RequestModuleInterface<IBotManager>();
     if (botManager != null)
     {
         IBotController controller = botManager.GetCharacterManager(m_host.ParentEntity.UUID);
         for (int i = 0; i < options.Length; i += 2)
         {
             LSL_Types.LSLInteger opt = options.GetLSLIntegerItem(i);
             LSL_Types.LSLFloat value = options.GetLSLFloatItem(i + 1);
             if (opt == ScriptBaseClass.CHARACTER_DESIRED_SPEED)
                 controller.SetSpeedModifier((float) value.value);
             else if (opt == ScriptBaseClass.CHARACTER_RADIUS)
             {
             }
             else if (opt == ScriptBaseClass.CHARACTER_LENGTH)
             {
             }
             else if (opt == ScriptBaseClass.CHARACTER_ORIENTATION)
             {
             }
             else if (opt == ScriptBaseClass.TRAVERSAL_TYPE)
             {
             }
             else if (opt == ScriptBaseClass.CHARACTER_TYPE)
             {
             }
             else if (opt == ScriptBaseClass.CHARACTER_AVOIDANCE_MODE)
             {
             }
             else if (opt == ScriptBaseClass.CHARACTER_MAX_ACCEL)
             {
             }
             else if (opt == ScriptBaseClass.CHARACTER_MAX_DECEL)
             {
             }
             else if (opt == ScriptBaseClass.CHARACTER_MAX_ANGULAR_SPEED)
             {
             }
             else if (opt == ScriptBaseClass.CHARACTER_MAX_ANGULAR_ACCEL)
             {
             }
             else if (opt == ScriptBaseClass.CHARACTER_TURN_SPEED_MULTIPLIER)
             {
             }
         }
     }
 }
开发者ID:velus,项目名称:Async-Sim-Testing,代码行数:48,代码来源:LSL_Api.cs

示例7: llSetKeyframedMotion

 public void llSetKeyframedMotion(LSL_List keyframes, LSL_List options)
 {
     if (!ScriptProtection.CheckThreatLevel(ThreatLevel.None, "LSL", m_host, "LSL", m_itemID)) return;
     if (!m_host.IsRoot)
     {
         ShoutError("Must be used in the root object!");
         return;
     }
     KeyframeAnimation.Data dataType = KeyframeAnimation.Data.Both;
     KeyframeAnimation.Modes currentMode = KeyframeAnimation.Modes.Forward;
     for (int i = 0; i < options.Length; i += 2)
     {
         LSL_Integer option = options.GetLSLIntegerItem(i);
         LSL_Integer value = options.GetLSLIntegerItem(i + 1);
         if (option == ScriptBaseClass.KFM_COMMAND)
         {
             m_host.ParentEntity.AddKeyframedMotion(null, (KeyframeAnimation.Commands) value.value);
             break; //Its supposed to be the only option in the list
         }
         if (option == ScriptBaseClass.KFM_MODE)
         {
             currentMode = (KeyframeAnimation.Modes) value.value;
         }
         else if (option == ScriptBaseClass.KFM_DATA)
         {
             dataType = (KeyframeAnimation.Data) value.value;
         }
     }
     List<Vector3> positions = new List<Vector3>();
     List<Quaternion> rotations = new List<Quaternion>();
     List<float> times = new List<float>();
     for (int i = 0; i < keyframes.Length; i += (dataType == KeyframeAnimation.Data.Both ? 3 : 2))
     {
         if (dataType == KeyframeAnimation.Data.Both ||
             dataType == KeyframeAnimation.Data.Translation)
         {
             LSL_Vector pos = keyframes.GetVector3Item(i);
             positions.Add(pos.ToVector3());
         }
         if (dataType == KeyframeAnimation.Data.Both ||
             dataType == KeyframeAnimation.Data.Rotation)
         {
             LSL_Rotation rot = keyframes.GetQuaternionItem(i + (dataType == KeyframeAnimation.Data.Both ? 1 : 0));
             Quaternion quat = rot.ToQuaternion();
             quat.Normalize();
             rotations.Add(quat);
         }
         LSL_Float time = keyframes.GetLSLFloatItem(i + (dataType == KeyframeAnimation.Data.Both ? 2 : 1));
         times.Add((float)time);
     }
     KeyframeAnimation animation = new KeyframeAnimation
                                       {
                                           CurrentMode = currentMode,
                                           PositionList = positions.ToArray(),
                                           RotationList = rotations.ToArray(),
                                           TimeList = times.ToArray(),
                                           CurrentAnimationPosition = 0,
                                           InitialPosition = m_host.AbsolutePosition,
                                           InitialRotation = m_host.GetRotationOffset()
                                       };
     m_host.ParentEntity.AddKeyframedMotion(animation, KeyframeAnimation.Commands.Play);
 }
开发者ID:KSLcom,项目名称:Aurora-Sim,代码行数:62,代码来源:LSL_Api.cs

示例8: aaSetEnv

 public void aaSetEnv(LSL_String name, LSL_List value)
 {
     if (!ScriptProtection.CheckThreatLevel(ThreatLevel.VeryHigh, "aaSetEnv", m_host, "AA", m_itemID))
         return;
     if (!World.Permissions.IsGod(m_host.OwnerID))
     {
         LSLError("You do not have god permissions.");
         return;
     }
     if (name == ScriptBaseClass.ENABLE_GRAVITY)
     {
         LSL_Integer enabled = value.GetLSLIntegerItem(0);
         float[] grav = m_host.ParentEntity.Scene.PhysicsScene.GetGravityForce();
         m_host.ParentEntity.Scene.PhysicsScene.SetGravityForce(enabled == 1, grav[0], grav[1], grav[2]);
     }
     else if (name == ScriptBaseClass.GRAVITY_FORCE_X)
     {
         LSL_Float f = value.GetLSLFloatItem(0);
         float[] grav = m_host.ParentEntity.Scene.PhysicsScene.GetGravityForce();
         m_host.ParentEntity.Scene.PhysicsScene.SetGravityForce(true, (float)f.value, grav[1], grav[2]);
     }
     else if (name == ScriptBaseClass.GRAVITY_FORCE_Y)
     {
         LSL_Float f = value.GetLSLFloatItem(0);
         float[] grav = m_host.ParentEntity.Scene.PhysicsScene.GetGravityForce();
         m_host.ParentEntity.Scene.PhysicsScene.SetGravityForce(true, grav[0], (float)f.value, grav[2]);
     }
     else if (name == ScriptBaseClass.GRAVITY_FORCE_Z)
     {
         LSL_Float f = value.GetLSLFloatItem(0);
         float[] grav = m_host.ParentEntity.Scene.PhysicsScene.GetGravityForce();
         m_host.ParentEntity.Scene.PhysicsScene.SetGravityForce(true, grav[0], grav[1], (float)f.value);
     }
     else if (name == ScriptBaseClass.ADD_GRAVITY_POINT)
     {
         LSL_Vector pos = value.GetVector3Item(0);
         LSL_Float gravForce = value.GetLSLFloatItem(1);
         LSL_Float radius = value.GetLSLFloatItem(2);
         LSL_Integer ident = value.GetLSLIntegerItem(3);
         m_host.ParentEntity.Scene.PhysicsScene.AddGravityPoint(false,
                                                                new Vector3((float)pos.x, (float)pos.y,
                                                                            (float)pos.z),
                                                                0, 0, 0, (float)gravForce.value,
                                                                (float)radius.value, ident.value);
     }
     else if (name == ScriptBaseClass.ADD_GRAVITY_FORCE)
     {
         LSL_Vector pos = value.GetVector3Item(0);
         LSL_Float xForce = value.GetLSLFloatItem(1);
         LSL_Float yForce = value.GetLSLFloatItem(2);
         LSL_Float zForce = value.GetLSLFloatItem(3);
         LSL_Float radius = value.GetLSLFloatItem(4);
         LSL_Integer ident = value.GetLSLIntegerItem(5);
         m_host.ParentEntity.Scene.PhysicsScene.AddGravityPoint(true,
                                                                new Vector3((float)pos.x, (float)pos.y,
                                                                            (float)pos.z),
                                                                (float)xForce, (float)yForce, (float)zForce, 0,
                                                                (float)radius.value, ident.value);
     }
     else if (name == ScriptBaseClass.START_TIME_REVERSAL_SAVING)
     {
         IPhysicsStateModule physicsState = World.RequestModuleInterface<IPhysicsStateModule>();
         if (physicsState != null)
             physicsState.StartSavingPhysicsTimeReversalStates();
     }
     else if (name == ScriptBaseClass.STOP_TIME_REVERSAL_SAVING)
     {
         IPhysicsStateModule physicsState = World.RequestModuleInterface<IPhysicsStateModule>();
         if (physicsState != null)
             physicsState.StopSavingPhysicsTimeReversalStates();
     }
     else if (name == ScriptBaseClass.START_TIME_REVERSAL)
     {
         IPhysicsStateModule physicsState = World.RequestModuleInterface<IPhysicsStateModule>();
         if (physicsState != null)
             physicsState.StartPhysicsTimeReversal();
     }
     else if (name == ScriptBaseClass.STOP_TIME_REVERSAL)
     {
         IPhysicsStateModule physicsState = World.RequestModuleInterface<IPhysicsStateModule>();
         if (physicsState != null)
             physicsState.StopPhysicsTimeReversal();
     }
 }
开发者ID:nathanmarck,项目名称:Aurora-Sim,代码行数:84,代码来源:AA_API.cs

示例9: ConvertLSLToWindlight


//.........这里部分代码省略.........
                        }
                    case ScriptBaseClass.WL_SKY_GLOW:
                        {
                            LSL_Rotation rot = list.GetQuaternionItem(i + 1);
                            skyData.glow = rot.ToVector4();
                            break;
                        }
                    case ScriptBaseClass.WL_SKY_HAZE_DENSITY:
                        {
                            LSL_Rotation rot = list.GetQuaternionItem(i + 1);
                            skyData.haze_density = rot.ToVector4();
                            break;
                        }
                    case ScriptBaseClass.WL_SKY_HAZE_HORIZON:
                        {
                            LSL_Rotation rot = list.GetQuaternionItem(i + 1);
                            skyData.haze_horizon = rot.ToVector4();
                            break;
                        }
                    case ScriptBaseClass.WL_SKY_LIGHT_NORMALS:
                        {
                            LSL_Rotation rot = list.GetQuaternionItem(i + 1);
                            skyData.lightnorm = rot.ToVector4();
                            break;
                        }
                    case ScriptBaseClass.WL_SKY_MAX_ALTITUDE:
                        {
                            LSL_Rotation rot = list.GetQuaternionItem(i + 1);
                            skyData.max_y = rot.ToVector4();
                            break;
                        }
                    case ScriptBaseClass.WL_SKY_STAR_BRIGHTNESS:
                        {
                            LSL_Float f = list.GetLSLFloatItem(i + 1);
                            skyData.star_brightness = (float)f.value;
                            break;
                        }
                    case ScriptBaseClass.WL_SKY_SUNLIGHT_COLOR:
                        {
                            LSL_Rotation rot = list.GetQuaternionItem(i + 1);
                            skyData.sunlight_color = rot.ToVector4();
                            break;
                        }
                    case ScriptBaseClass.WL_WATER_BIG_WAVE_DIRECTION:
                        {
                            var rot = list.GetVector3Item(i + 1);
                            cycle.Water.wave1Dir = new Vector2((float)rot.x.value, (float)rot.y.value);
                            break;
                        }
                    case ScriptBaseClass.WL_WATER_BLUR_MULTIPLIER:
                        {
                            var f = list.GetLSLFloatItem(i + 1);
                            cycle.Water.blurMultiplier = (float)f.value;
                            break;
                        }
                    case ScriptBaseClass.WL_WATER_FOG_COLOR:
                        {
                            LSL_Rotation rot = list.GetQuaternionItem(i + 1);
                            cycle.Water.waterFogColor = rot.ToVector4();
                            break;
                        }
                    case ScriptBaseClass.WL_WATER_FOG_DENSITY:
                        {
                            var f = list.GetLSLFloatItem(i + 1);
                            cycle.Water.waterFogDensity = (float)f.value;
                            break;
开发者ID:nathanmarck,项目名称:Aurora-Sim,代码行数:67,代码来源:AA_API.cs


注:本文中的Aurora.ScriptEngine.AuroraDotNetEngine.LSL_Types.list.GetLSLFloatItem方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。