diff options
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/Scene.cs')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/Scene.cs | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs index cd81384..d1f6038 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.cs | |||
@@ -546,6 +546,28 @@ namespace OpenSim.Region.Environment.Scenes | |||
546 | { | 546 | { |
547 | eventManager.TriggerOnRemovePresence(agentID); | 547 | eventManager.TriggerOnRemovePresence(agentID); |
548 | 548 | ||
549 | ScenePresence avatar = this.RequestAvatar(agentID); | ||
550 | |||
551 | m_clientManager.ForEachClient( | ||
552 | delegate(IClientAPI client) | ||
553 | { | ||
554 | client.SendKillObject(avatar.RegionHandle, avatar.LocalId); | ||
555 | }); | ||
556 | |||
557 | lock (Avatars) { | ||
558 | if (Avatars.ContainsKey(agentID)) { | ||
559 | Avatars.Remove(agentID); | ||
560 | } | ||
561 | } | ||
562 | lock (Entities) { | ||
563 | if (Entities.ContainsKey(agentID)) { | ||
564 | Entities.Remove(agentID); | ||
565 | } | ||
566 | } | ||
567 | // TODO: Add the removal from physics ? | ||
568 | |||
569 | |||
570 | |||
549 | return; | 571 | return; |
550 | } | 572 | } |
551 | #endregion | 573 | #endregion |