diff --git a/Programs/Simian/Extensions/SceneManager.cs b/Programs/Simian/Extensions/SceneManager.cs index 05277d08..4bac3009 100644 --- a/Programs/Simian/Extensions/SceneManager.cs +++ b/Programs/Simian/Extensions/SceneManager.cs @@ -9,8 +9,6 @@ namespace Simian public class SceneManager : ISimianExtension { Simian server; - Dictionary sceneObjects = new Dictionary(); - Dictionary sceneAvatars = new Dictionary(); int currentLocalID = 0; int currentWearablesSerialNum = 0; ulong regionHandle; @@ -48,8 +46,8 @@ namespace Simian avatar.Scale = new Vector3(1f, 1f, 3f); // Add this agent to the scene graph - lock (sceneAvatars) - sceneAvatars[avatar.ID] = avatar; + lock (server.SceneAvatars) + server.SceneAvatars[avatar.ID] = avatar; AgentMovementCompletePacket complete = new AgentMovementCompletePacket(); complete.AgentData.AgentID = agent.AgentID; @@ -68,7 +66,7 @@ namespace Simian AgentUpdatePacket update = (AgentUpdatePacket)packet; Avatar avatar; - if (sceneAvatars.TryGetValue(agent.AgentID, out avatar)) + if (server.SceneAvatars.TryGetValue(agent.AgentID, out avatar)) { SendFullUpdate(agent, avatar, update.AgentData.State, update.AgentData.Flags); } diff --git a/Programs/Simian/Simian.cs b/Programs/Simian/Simian.cs index 467d9b30..73bfab8a 100644 --- a/Programs/Simian/Simian.cs +++ b/Programs/Simian/Simian.cs @@ -15,7 +15,9 @@ namespace Simian { public HttpServer HttpServer; public UDPServer UDPServer; - + public Dictionary SceneObjects = new Dictionary(); + public Dictionary SceneAvatars = new Dictionary(); + Dictionary unassociatedAgents; int currentCircuitCode; int tcpPort;