aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorubit2012-06-05 06:55:15 +0200
committerubit2012-06-05 06:55:15 +0200
commitb5a908033cfb8293b8c7ee63cf2268b4c9dcf2ff (patch)
treef1084f0517e5dccf4db1116de7774e018cdc0d9f
parentMerge branch 'ubitwork' of ssh://3dhosting.de/var/git/careminster into ubitwork (diff)
parentfix the real cause of double velocity (diff)
downloadopensim-SC-b5a908033cfb8293b8c7ee63cf2268b4c9dcf2ff.zip
opensim-SC-b5a908033cfb8293b8c7ee63cf2268b4c9dcf2ff.tar.gz
opensim-SC-b5a908033cfb8293b8c7ee63cf2268b4c9dcf2ff.tar.bz2
opensim-SC-b5a908033cfb8293b8c7ee63cf2268b4c9dcf2ff.tar.xz
Merge branch 'ubitwork' of ssh://3dhosting.de/var/git/careminster into ubitwork
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneGraph.cs1
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs8
2 files changed, 4 insertions, 5 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneGraph.cs b/OpenSim/Region/Framework/Scenes/SceneGraph.cs
index 0d178c3..b7466be 100644
--- a/OpenSim/Region/Framework/Scenes/SceneGraph.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneGraph.cs
@@ -352,7 +352,6 @@ namespace OpenSim.Region.Framework.Scenes
352 if (pa != null && pa.IsPhysical && vel != Vector3.Zero) 352 if (pa != null && pa.IsPhysical && vel != Vector3.Zero)
353 { 353 {
354 sceneObject.RootPart.ApplyImpulse((vel * sceneObject.GetMass()), false); 354 sceneObject.RootPart.ApplyImpulse((vel * sceneObject.GetMass()), false);
355 sceneObject.Velocity = vel;
356 } 355 }
357 356
358 return true; 357 return true;
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index e825b74..d83b05d 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -3079,9 +3079,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
3079 // need the magnitude later 3079 // need the magnitude later
3080 // float velmag = (float)Util.GetMagnitude(llvel); 3080 // float velmag = (float)Util.GetMagnitude(llvel);
3081 3081
3082 // rez with zero velocity so we can apply it here after resume scripts etc 3082 SceneObjectGroup new_group = World.RezObject(m_host, inv.Value, llpos, Rot2Quaternion(rot), llvel, param);
3083// SceneObjectGroup new_group = World.RezObject(m_host, inv.Value, llpos, Rot2Quaternion(rot), llvel, param);
3084 SceneObjectGroup new_group = World.RezObject(m_host, inv.Value, llpos, Rot2Quaternion(rot), Vector3.Zero, param);
3085 3083
3086 // If either of these are null, then there was an unknown error. 3084 // If either of these are null, then there was an unknown error.
3087 if (new_group == null) 3085 if (new_group == null)
@@ -3104,7 +3102,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
3104 3102
3105 if (pa != null && pa.IsPhysical && llvel != Vector3.Zero) 3103 if (pa != null && pa.IsPhysical && llvel != Vector3.Zero)
3106 { 3104 {
3107 llApplyImpulse(new LSL_Vector(llvel.X * groupmass, llvel.Y * groupmass, llvel.Z * groupmass), 0); 3105 // recoil
3106 llvel *= -groupmass;
3107 llApplyImpulse(new LSL_Vector(llvel.X, llvel.Y,llvel.Z), 0);
3108 } 3108 }
3109 // Variable script delay? (see (http://wiki.secondlife.com/wiki/LSL_Delay) 3109 // Variable script delay? (see (http://wiki.secondlife.com/wiki/LSL_Delay)
3110 return; 3110 return;