Merge branch 'ubitwork' of ssh://3dhosting.de/var/git/careminster into ubitwork
commit
a99026691b
|
@ -401,30 +401,51 @@ namespace OpenSim.Region.CoreModules.World.Land
|
||||||
|
|
||||||
public void SendLandUpdate(ScenePresence avatar, bool force)
|
public void SendLandUpdate(ScenePresence avatar, bool force)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
/* stop sendind same data twice
|
||||||
|
ILandObject over = GetLandObject((int)Math.Min(((int)Constants.RegionSize - 1), Math.Max(0, Math.Round(avatar.AbsolutePosition.X))),
|
||||||
|
(int)Math.Min(((int)Constants.RegionSize - 1), Math.Max(0, Math.Round(avatar.AbsolutePosition.Y))));
|
||||||
|
|
||||||
|
if (over != null)
|
||||||
|
{
|
||||||
|
|
||||||
|
if (force)
|
||||||
|
{
|
||||||
|
if (!avatar.IsChildAgent)
|
||||||
|
{
|
||||||
|
over.SendLandUpdateToClient(avatar.ControllingClient);
|
||||||
|
m_scene.EventManager.TriggerAvatarEnteringNewParcel(avatar, over.LandData.LocalID,
|
||||||
|
m_scene.RegionInfo.RegionID);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (avatar.currentParcelUUID != over.LandData.GlobalID)
|
||||||
|
{
|
||||||
|
if (!avatar.IsChildAgent)
|
||||||
|
{
|
||||||
|
over.SendLandUpdateToClient(avatar.ControllingClient);
|
||||||
|
avatar.currentParcelUUID = over.LandData.GlobalID;
|
||||||
|
m_scene.EventManager.TriggerAvatarEnteringNewParcel(avatar, over.LandData.LocalID,
|
||||||
|
m_scene.RegionInfo.RegionID);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
if (avatar.IsChildAgent)
|
||||||
|
return;
|
||||||
|
|
||||||
ILandObject over = GetLandObject((int)Math.Min(((int)Constants.RegionSize - 1), Math.Max(0, Math.Round(avatar.AbsolutePosition.X))),
|
ILandObject over = GetLandObject((int)Math.Min(((int)Constants.RegionSize - 1), Math.Max(0, Math.Round(avatar.AbsolutePosition.X))),
|
||||||
(int)Math.Min(((int)Constants.RegionSize - 1), Math.Max(0, Math.Round(avatar.AbsolutePosition.Y))));
|
(int)Math.Min(((int)Constants.RegionSize - 1), Math.Max(0, Math.Round(avatar.AbsolutePosition.Y))));
|
||||||
|
|
||||||
if (over != null)
|
if (over != null)
|
||||||
{
|
{
|
||||||
if (force)
|
bool NotsameID = (avatar.currentParcelUUID != over.LandData.GlobalID);
|
||||||
|
if (force || NotsameID)
|
||||||
{
|
{
|
||||||
if (!avatar.IsChildAgent)
|
over.SendLandUpdateToClient(avatar.ControllingClient);
|
||||||
{
|
if (NotsameID)
|
||||||
over.SendLandUpdateToClient(avatar.ControllingClient);
|
|
||||||
m_scene.EventManager.TriggerAvatarEnteringNewParcel(avatar, over.LandData.LocalID,
|
|
||||||
m_scene.RegionInfo.RegionID);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (avatar.currentParcelUUID != over.LandData.GlobalID)
|
|
||||||
{
|
|
||||||
if (!avatar.IsChildAgent)
|
|
||||||
{
|
|
||||||
over.SendLandUpdateToClient(avatar.ControllingClient);
|
|
||||||
avatar.currentParcelUUID = over.LandData.GlobalID;
|
avatar.currentParcelUUID = over.LandData.GlobalID;
|
||||||
m_scene.EventManager.TriggerAvatarEnteringNewParcel(avatar, over.LandData.LocalID,
|
m_scene.EventManager.TriggerAvatarEnteringNewParcel(avatar, over.LandData.LocalID,
|
||||||
m_scene.RegionInfo.RegionID);
|
m_scene.RegionInfo.RegionID);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -2890,9 +2890,11 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
{
|
{
|
||||||
EventManager.TriggerOnClientLogin(client);
|
EventManager.TriggerOnClientLogin(client);
|
||||||
// Send initial parcel data
|
// Send initial parcel data
|
||||||
|
/* this is done on TriggerOnNewClient by landmanegement respective event handler
|
||||||
Vector3 pos = sp.AbsolutePosition;
|
Vector3 pos = sp.AbsolutePosition;
|
||||||
ILandObject land = LandChannel.GetLandObject(pos.X, pos.Y);
|
ILandObject land = LandChannel.GetLandObject(pos.X, pos.Y);
|
||||||
land.SendLandUpdateToClient(client);
|
land.SendLandUpdateToClient(client);
|
||||||
|
*/
|
||||||
}
|
}
|
||||||
|
|
||||||
return sp;
|
return sp;
|
||||||
|
|
|
@ -1315,13 +1315,15 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
// Create child agents in neighbouring regions
|
// Create child agents in neighbouring regions
|
||||||
if (openChildAgents && !IsChildAgent)
|
if (openChildAgents && !IsChildAgent)
|
||||||
{
|
{
|
||||||
|
|
||||||
IEntityTransferModule m_agentTransfer = m_scene.RequestModuleInterface<IEntityTransferModule>();
|
IEntityTransferModule m_agentTransfer = m_scene.RequestModuleInterface<IEntityTransferModule>();
|
||||||
if (m_agentTransfer != null)
|
if (m_agentTransfer != null)
|
||||||
Util.FireAndForget(delegate { m_agentTransfer.EnableChildAgents(this); });
|
m_agentTransfer.EnableChildAgents(this);
|
||||||
|
|
||||||
IFriendsModule friendsModule = m_scene.RequestModuleInterface<IFriendsModule>();
|
IFriendsModule friendsModule = m_scene.RequestModuleInterface<IFriendsModule>();
|
||||||
if (friendsModule != null)
|
if (friendsModule != null)
|
||||||
friendsModule.SendFriendsOnlineIfNeeded(ControllingClient);
|
friendsModule.SendFriendsOnlineIfNeeded(ControllingClient);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// m_log.DebugFormat(
|
// m_log.DebugFormat(
|
||||||
|
|
|
@ -129,7 +129,7 @@ namespace OpenSim.Services.Connectors
|
||||||
string ret = serverUri.Uri.AbsoluteUri;
|
string ret = serverUri.Uri.AbsoluteUri;
|
||||||
if (ret.EndsWith("/"))
|
if (ret.EndsWith("/"))
|
||||||
ret = ret.Substring(0, ret.Length - 1);
|
ret = ret.Substring(0, ret.Length - 1);
|
||||||
return serverUri.Uri.AbsoluteUri;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected void retryCheck(object source, ElapsedEventArgs e)
|
protected void retryCheck(object source, ElapsedEventArgs e)
|
||||||
|
|
Loading…
Reference in New Issue