Now diagnosing a strange behavior where upon TP agents are temporarily placed in very large coordinates, then snap back.

Extra checks in preparation for dropping obsolete data in agent transfers.
cpu-performance
Diva Canto 2013-07-21 12:44:46 -07:00
parent 9801d0d4c8
commit 5e5aa5fba7
2 changed files with 6 additions and 5 deletions

View File

@ -634,17 +634,17 @@ namespace OpenSim.Framework
// The code to unpack textures, visuals, wearables and attachments
// should be removed; packed appearance contains the full appearance
// This is retained for backward compatibility only
if (args["texture_entry"] != null)
if (args.ContainsKey("texture_entry") && args["texture_entry"] != null)
{
byte[] rawtextures = args["texture_entry"].AsBinary();
Primitive.TextureEntry textures = new Primitive.TextureEntry(rawtextures,0,rawtextures.Length);
Appearance.SetTextureEntries(textures);
}
if (args["visual_params"] != null)
if (args.ContainsKey("visual_params") && args["visual_params"] != null)
Appearance.SetVisualParams(args["visual_params"].AsBinary());
if ((args["wearables"] != null) && (args["wearables"]).Type == OSDType.Array)
if (args.ContainsKey("wearables") && (args["wearables"] != null) && (args["wearables"]).Type == OSDType.Array)
{
OSDArray wears = (OSDArray)(args["wearables"]);
for (int i = 0; i < wears.Count / 2; i++)
@ -654,7 +654,7 @@ namespace OpenSim.Framework
}
}
if ((args["attachments"] != null) && (args["attachments"]).Type == OSDType.Array)
if (args.ContainsKey("attachments") && (args["attachments"] != null) && (args["attachments"]).Type == OSDType.Array)
{
OSDArray attachs = (OSDArray)(args["attachments"]);
foreach (OSD o in attachs)

View File

@ -3370,7 +3370,8 @@ namespace OpenSim.Region.Framework.Scenes
// "[SCENE PRESENCE]: Set callback for {0} in {1} to {2} in CopyFrom()",
// Name, m_scene.RegionInfo.RegionName, m_callbackURI);
m_pos = cAgent.Position;
//m_pos = cAgent.Position;
AbsolutePosition = cAgent.Position;
m_velocity = cAgent.Velocity;
CameraPosition = cAgent.Center;
CameraAtAxis = cAgent.AtAxis;