diff options
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs | 42 |
1 files changed, 27 insertions, 15 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs index 6807e1b..6b4cc0d 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs | |||
@@ -386,6 +386,13 @@ namespace OpenSim.Region.Framework.Scenes | |||
386 | #region Constructors | 386 | #region Constructors |
387 | 387 | ||
388 | /// <summary> | 388 | /// <summary> |
389 | /// Constructor | ||
390 | /// </summary> | ||
391 | public SceneObjectGroup() | ||
392 | { | ||
393 | } | ||
394 | |||
395 | /// <summary> | ||
389 | /// This constructor creates a SceneObjectGroup using a pre-existing SceneObjectPart. | 396 | /// This constructor creates a SceneObjectGroup using a pre-existing SceneObjectPart. |
390 | /// The original SceneObjectPart will be used rather than a copy, preserving | 397 | /// The original SceneObjectPart will be used rather than a copy, preserving |
391 | /// its existing localID and UUID. | 398 | /// its existing localID and UUID. |
@@ -2974,8 +2981,9 @@ namespace OpenSim.Region.Framework.Scenes | |||
2974 | /// | 2981 | /// |
2975 | /// </summary> | 2982 | /// </summary> |
2976 | /// <param name="rot"></param> | 2983 | /// <param name="rot"></param> |
2977 | public void UpdateGroupRotation(Quaternion rot) | 2984 | public void UpdateGroupRotationR(Quaternion rot) |
2978 | { | 2985 | { |
2986 | |||
2979 | m_rootPart.UpdateRotation(rot); | 2987 | m_rootPart.UpdateRotation(rot); |
2980 | if (m_rootPart.PhysActor != null) | 2988 | if (m_rootPart.PhysActor != null) |
2981 | { | 2989 | { |
@@ -2992,7 +3000,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
2992 | /// </summary> | 3000 | /// </summary> |
2993 | /// <param name="pos"></param> | 3001 | /// <param name="pos"></param> |
2994 | /// <param name="rot"></param> | 3002 | /// <param name="rot"></param> |
2995 | public void UpdateGroupRotation(Vector3 pos, Quaternion rot) | 3003 | public void UpdateGroupRotationPR(Vector3 pos, Quaternion rot) |
2996 | { | 3004 | { |
2997 | m_rootPart.UpdateRotation(rot); | 3005 | m_rootPart.UpdateRotation(rot); |
2998 | if (m_rootPart.PhysActor != null) | 3006 | if (m_rootPart.PhysActor != null) |
@@ -3100,22 +3108,26 @@ namespace OpenSim.Region.Framework.Scenes | |||
3100 | int yaxis = 4; | 3108 | int yaxis = 4; |
3101 | int zaxis = 8; | 3109 | int zaxis = 8; |
3102 | 3110 | ||
3103 | setX = ((axis & xaxis) != 0) ? true : false; | 3111 | if (m_rootPart != null) |
3104 | setY = ((axis & yaxis) != 0) ? true : false; | 3112 | { |
3105 | setZ = ((axis & zaxis) != 0) ? true : false; | 3113 | setX = ((axis & xaxis) != 0) ? true : false; |
3114 | setY = ((axis & yaxis) != 0) ? true : false; | ||
3115 | setZ = ((axis & zaxis) != 0) ? true : false; | ||
3106 | 3116 | ||
3107 | float setval = (rotate10 > 0) ? 1f : 0f; | 3117 | float setval = (rotate10 > 0) ? 1f : 0f; |
3108 | 3118 | ||
3109 | if (setX) | 3119 | if (setX) |
3110 | m_rootPart.RotationAxis.X = setval; | 3120 | m_rootPart.RotationAxis.X = setval; |
3111 | if (setY) | 3121 | if (setY) |
3112 | m_rootPart.RotationAxis.Y = setval; | 3122 | m_rootPart.RotationAxis.Y = setval; |
3113 | if (setZ) | 3123 | if (setZ) |
3114 | m_rootPart.RotationAxis.Z = setval; | 3124 | m_rootPart.RotationAxis.Z = setval; |
3125 | |||
3126 | if (setX || setY || setZ) | ||
3127 | { | ||
3128 | m_rootPart.SetPhysicsAxisRotation(); | ||
3129 | } | ||
3115 | 3130 | ||
3116 | if (setX || setY || setZ) | ||
3117 | { | ||
3118 | m_rootPart.SetPhysicsAxisRotation(); | ||
3119 | } | 3131 | } |
3120 | } | 3132 | } |
3121 | 3133 | ||