From b916d5b112990bac8b412fa8ddb83be87b25e02c Mon Sep 17 00:00:00 2001 From: MW Date: Tue, 27 Nov 2007 15:44:39 +0000 Subject: Fixed bug, where the clients in a region weren't told to kill a user's avatar when that user teleported to a different region. --- OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs') diff --git a/OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs b/OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs index 0355a1b..9a83710 100644 --- a/OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs +++ b/OpenSim/Region/Environment/Scenes/SceneCommunicationService.cs @@ -10,6 +10,8 @@ using OpenSim.Framework.Communications; namespace OpenSim.Region.Environment.Scenes { + public delegate void KillObjectDelegate(uint localID); + public class SceneCommunicationService //one instance per region { protected CommunicationsManager m_commsProvider; @@ -22,8 +24,11 @@ namespace OpenSim.Region.Environment.Scenes public event CloseAgentConnection OnCloseAgentConnection; public event PrimCrossing OnPrimCrossingIntoRegion; public event RegionUp OnRegionUp; + + public KillObjectDelegate KillObject; public string _debugRegionName = ""; + public string debugRegionName { get { return _debugRegionName; } @@ -276,6 +281,10 @@ namespace OpenSim.Region.Environment.Scenes string capsPath = Util.GetCapsURL(avatar.ControllingClient.AgentId); avatar.ControllingClient.SendRegionTeleport(regionHandle, 13, reg.ExternalEndPoint, 4, (1 << 4), capsPath); avatar.MakeChildAgent(); + if (KillObject != null) + { + KillObject(avatar.LocalId); + } uint newRegionX = (uint)(regionHandle >> 40); uint newRegionY = (((uint)(regionHandle)) >> 8); uint oldRegionX = (uint)(m_regionInfo.RegionHandle >> 40); -- cgit v1.1