From fd2c99f184fa192d316222f90ef76ec8b9726ada Mon Sep 17 00:00:00 2001 From: John Hurliman Date: Thu, 29 Oct 2009 02:10:48 -0700 Subject: Fixing NullReferenceException regression in the previous commit --- OpenSim/Region/Framework/Scenes/ScenePresence.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'OpenSim/Region/Framework/Scenes/ScenePresence.cs') diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 91044be..7420134 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs @@ -2367,7 +2367,7 @@ namespace OpenSim.Region.Framework.Scenes if (m_isChildAgent == false) { - Vector3 velocity = m_physicsActor.Velocity; + Vector3 velocity = (m_physicsActor != null) ? m_physicsActor.Velocity : Vector3.Zero; // Throw away duplicate or insignificant updates if (!m_bodyRot.ApproxEquals(m_lastRotation, ROTATION_TOLERANCE) || -- cgit v1.1