Some work on cleanly removing Regions.
parent
7f8a69f181
commit
297cc7ef4f
|
@ -439,6 +439,7 @@ namespace OpenSim.Framework
|
|||
void SetDebug(int newDebug);
|
||||
void InPacket(Packet NewPack);
|
||||
void Close();
|
||||
void Stop();
|
||||
event ViewerEffectEventHandler OnViewerEffect;
|
||||
event Action<IClientAPI> OnLogout;
|
||||
event Action<IClientAPI> OnConnectionClosed;
|
||||
|
|
|
@ -435,10 +435,6 @@ namespace OpenSim
|
|||
}
|
||||
}
|
||||
|
||||
protected void ConnectToRemoteGridServer()
|
||||
{
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
/// <summary>
|
||||
|
|
|
@ -158,6 +158,16 @@ namespace OpenSim.Region.ClientStack
|
|||
ClientThread.Abort();
|
||||
}
|
||||
|
||||
public void Stop()
|
||||
{
|
||||
clientPingTimer.Stop();
|
||||
|
||||
libsecondlife.Packets.DisableSimulatorPacket disable = new libsecondlife.Packets.DisableSimulatorPacket();
|
||||
OutPacket(disable);
|
||||
|
||||
ClientThread.Abort();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
# region Packet Handling
|
||||
|
|
|
@ -241,11 +241,26 @@ namespace OpenSim.Region.Environment.Scenes
|
|||
#region Startup / Close Methods
|
||||
public override void Close()
|
||||
{
|
||||
ForEachScenePresence(delegate(ScenePresence avatar)
|
||||
{
|
||||
avatar.ControllingClient.Stop();
|
||||
});
|
||||
|
||||
m_heartbeatTimer.Close();
|
||||
m_innerScene.Close();
|
||||
m_sceneGridService.Close();
|
||||
|
||||
foreach (IRegionModule module in this.Modules.Values)
|
||||
{
|
||||
if (!module.IsSharedModule)
|
||||
{
|
||||
module.Close();
|
||||
}
|
||||
}
|
||||
Modules.Clear();
|
||||
|
||||
base.Close();
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
|
@ -179,6 +179,35 @@ namespace OpenSim.Region.Environment.Scenes
|
|||
}
|
||||
}
|
||||
|
||||
public bool TryGetScene(string regionName, out Scene scene)
|
||||
{
|
||||
foreach (Scene mscene in m_localScenes)
|
||||
{
|
||||
if (String.Compare(mscene.RegionInfo.RegionName, regionName, true) == 0)
|
||||
{
|
||||
scene = mscene;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
scene = null;
|
||||
return false;
|
||||
}
|
||||
|
||||
public bool TryGetScene(LLUUID regionID, out Scene scene)
|
||||
{
|
||||
foreach (Scene mscene in m_localScenes)
|
||||
{
|
||||
if (mscene.RegionInfo.RegionID == regionID)
|
||||
{
|
||||
scene = mscene;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
scene = null;
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
public void SetDebugPacketOnCurrentScene(LogBase log, int newDebug)
|
||||
{
|
||||
ForEachCurrentScene(delegate(Scene scene)
|
||||
|
|
|
@ -1197,6 +1197,7 @@ namespace OpenSim.Region.Environment.Scenes
|
|||
{
|
||||
m_wearables[wearableId] = wearable;
|
||||
SendOwnWearables();
|
||||
|
||||
}
|
||||
|
||||
private void SendOwnWearables()
|
||||
|
|
|
@ -427,6 +427,11 @@ namespace SimpleApp
|
|||
{
|
||||
}
|
||||
|
||||
public void Stop()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
private uint m_circuitCode;
|
||||
|
||||
public uint CircuitCode
|
||||
|
|
Loading…
Reference in New Issue