* Added a message for when the null reference exception occurs to make debugging easier. Without this, from the user's perspective.. they cannot move, fly or otherwise do anything physical and without a message on the console, it would be hard to tell that this is what is occurring.

prioritization
Teravus Ovares (Dan Olivares) 2009-10-16 03:40:44 -04:00
parent ac2f98b846
commit 1f28c6208b
1 changed files with 4 additions and 3 deletions

View File

@ -1109,12 +1109,13 @@ namespace OpenSim.Region.Physics.OdePlugin
try
{
vec = d.BodyGetPosition(Body);
//throw new NullReferenceException("foo!");
}
catch (NullReferenceException)
{
vec = new d.Vector3(Position.X, Position.Y, Position.Z);
base.RaiseOutOfBounds(_position);
vec = new d.Vector3(_position.X, _position.Y, _position.Z);
base.RaiseOutOfBounds(_position); // Tells ScenePresence that there's a problem!
m_log.WarnFormat("[ODEPLUGIN]: Avatar Null reference for Avatar: {0}", m_name);
}