From 73e64c65970e91f10dc4683171145264835e5080 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Wed, 30 Jan 2019 12:27:03 +0000 Subject: [PATCH] mantis 6702: fix collisions lldetectedlinknumber also on Yengine --- OpenSim/Region/Framework/Scenes/SceneObjectPart.cs | 13 +++++++++---- OpenSim/Region/ScriptEngine/XEngine/EventManager.cs | 1 - OpenSim/Region/ScriptEngine/YEngine/XMREvents.cs | 8 +------- 3 files changed, 10 insertions(+), 12 deletions(-) diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs index 6d0854b04e..8a3ff71a89 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs @@ -2670,7 +2670,10 @@ namespace OpenSim.Region.Framework.Scenes detobj.velVector = obj.Velocity; detobj.colliderType = 0; detobj.groupUUID = obj.GroupID; - detobj.linkNumber = LinkNum; + if (VolumeDetectActive) + detobj.linkNumber = 0; + else + detobj.linkNumber = LinkNum; return detobj; } @@ -2689,7 +2692,10 @@ namespace OpenSim.Region.Framework.Scenes else if(detobj.velVector != Vector3.Zero) detobj.colliderType |= 0x2; //active detobj.groupUUID = av.ControllingClient.ActiveGroupId; - detobj.linkNumber = LinkNum; + if (VolumeDetectActive) + detobj.linkNumber = 0; + else + detobj.linkNumber = LinkNum; return detobj; } @@ -2705,8 +2711,7 @@ namespace OpenSim.Region.Framework.Scenes detobj.velVector = Vector3.Zero; detobj.colliderType = 0; detobj.groupUUID = UUID.Zero; - detobj.linkNumber = LinkNum; // pass my link number not sure needed.. but no harm - + detobj.linkNumber = LinkNum; return detobj; } diff --git a/OpenSim/Region/ScriptEngine/XEngine/EventManager.cs b/OpenSim/Region/ScriptEngine/XEngine/EventManager.cs index 55a77bce0f..b7fc161e61 100644 --- a/OpenSim/Region/ScriptEngine/XEngine/EventManager.cs +++ b/OpenSim/Region/ScriptEngine/XEngine/EventManager.cs @@ -245,7 +245,6 @@ namespace OpenSim.Region.ScriptEngine.XEngine DetectParams d = new DetectParams(); d.Key =detobj.keyUUID; d.Populate(myScriptEngine.World, detobj); - d.LinkNum = detobj.linkNumber; // do it here since currently linknum is collided part det.Add(d); } diff --git a/OpenSim/Region/ScriptEngine/YEngine/XMREvents.cs b/OpenSim/Region/ScriptEngine/YEngine/XMREvents.cs index b4e92b9d1c..5a8b2a39aa 100644 --- a/OpenSim/Region/ScriptEngine/YEngine/XMREvents.cs +++ b/OpenSim/Region/ScriptEngine/YEngine/XMREvents.cs @@ -231,13 +231,7 @@ namespace OpenSim.Region.ScriptEngine.Yengine det[i++] = d; d.Key = detobj.keyUUID; - d.Populate(this.World); - - /* not done by XEngine... - d.Position = detobj.posVector; - d.Rotation = detobj.rotQuat; - d.Velocity = detobj.velVector; - ... */ + d.Populate(World, detobj); } this.PostObjectEvent(localID, new EventParams(