From 09f6647aa37be99191263a20a98a5b992f62a3de Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Sat, 11 Feb 2012 17:48:49 +0000 Subject: [PATCH] scenepresence change! in standup() give avatar a physical actor after deciding the new position. This reduces a bit the odds of it being still coliding with object. --- OpenSim/Region/Framework/Scenes/ScenePresence.cs | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index c7c90dac3e..9100c29d69 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs @@ -1814,8 +1814,11 @@ namespace OpenSim.Region.Framework.Scenes // m_log.DebugFormat("[SCENE PRESENCE]: StandUp() for {0}", Name); SitGround = false; + +/* move this down so avatar gets physical in the new position and not where it is siting if (PhysicsActor == null) AddToPhysicalScene(false); + */ if (ParentID != 0) { @@ -1850,6 +1853,10 @@ namespace OpenSim.Region.Framework.Scenes ParentPosition = Vector3.Zero; ParentID = 0; + + if (PhysicsActor == null) + AddToPhysicalScene(false); + SendAvatarDataToAllAgents(); m_requestedSitTargetID = 0; @@ -1857,6 +1864,9 @@ namespace OpenSim.Region.Framework.Scenes part.ParentGroup.TriggerScriptChangedEvent(Changed.LINK); } + else if (PhysicsActor == null) + AddToPhysicalScene(false); + Animator.TrySetMovementAnimation("STAND"); }