Merge https://github.com/opensim/opensim into mantis5110
Conflicts: OpenSim/Region/Framework/Scenes/Scene.csviewer-2-initial-appearance
commit
562147475c
|
@ -117,7 +117,7 @@ namespace OpenSim.ApplicationPlugins.RemoteController
|
||||||
|
|
||||||
m_application = openSim;
|
m_application = openSim;
|
||||||
string bind_ip_address = m_config.GetString("bind_ip_address", "0.0.0.0");
|
string bind_ip_address = m_config.GetString("bind_ip_address", "0.0.0.0");
|
||||||
IPAddress ipaddr = IPAddress.Parse( bind_ip_address );
|
IPAddress ipaddr = IPAddress.Parse(bind_ip_address);
|
||||||
m_httpServer = MainServer.GetHttpServer((uint)port,ipaddr);
|
m_httpServer = MainServer.GetHttpServer((uint)port,ipaddr);
|
||||||
|
|
||||||
Dictionary<string, XmlRpcMethod> availableMethods = new Dictionary<string, XmlRpcMethod>();
|
Dictionary<string, XmlRpcMethod> availableMethods = new Dictionary<string, XmlRpcMethod>();
|
||||||
|
|
|
@ -177,7 +177,7 @@ namespace OpenSim.Framework
|
||||||
m_owner = appearance.Owner;
|
m_owner = appearance.Owner;
|
||||||
|
|
||||||
m_wearables = new AvatarWearable[AvatarWearable.MAX_WEARABLES];
|
m_wearables = new AvatarWearable[AvatarWearable.MAX_WEARABLES];
|
||||||
for (int i = 0 ; i < AvatarWearable.MAX_WEARABLES ; i++ )
|
for (int i = 0; i < AvatarWearable.MAX_WEARABLES; i++)
|
||||||
m_wearables[i] = new AvatarWearable();
|
m_wearables[i] = new AvatarWearable();
|
||||||
if (copyWearables && (appearance.Wearables != null))
|
if (copyWearables && (appearance.Wearables != null))
|
||||||
{
|
{
|
||||||
|
@ -204,9 +204,9 @@ namespace OpenSim.Framework
|
||||||
|
|
||||||
public void GetAssetsFrom(AvatarAppearance app)
|
public void GetAssetsFrom(AvatarAppearance app)
|
||||||
{
|
{
|
||||||
for (int i = 0 ; i < AvatarWearable.MAX_WEARABLES ; i++ )
|
for (int i = 0; i < AvatarWearable.MAX_WEARABLES; i++)
|
||||||
{
|
{
|
||||||
for (int j = 0 ; j < m_wearables[i].Count ; j++)
|
for (int j = 0; j < m_wearables[i].Count; j++)
|
||||||
{
|
{
|
||||||
UUID itemID = m_wearables[i][j].ItemID;
|
UUID itemID = m_wearables[i][j].ItemID;
|
||||||
UUID assetID = app.Wearables[i].GetAsset(itemID);
|
UUID assetID = app.Wearables[i].GetAsset(itemID);
|
||||||
|
@ -220,7 +220,7 @@ namespace OpenSim.Framework
|
||||||
public void ClearWearables()
|
public void ClearWearables()
|
||||||
{
|
{
|
||||||
m_wearables = new AvatarWearable[AvatarWearable.MAX_WEARABLES];
|
m_wearables = new AvatarWearable[AvatarWearable.MAX_WEARABLES];
|
||||||
for (int i = 0 ; i < AvatarWearable.MAX_WEARABLES ; i++ )
|
for (int i = 0; i < AvatarWearable.MAX_WEARABLES; i++)
|
||||||
m_wearables[i] = new AvatarWearable();
|
m_wearables[i] = new AvatarWearable();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -347,11 +347,10 @@ namespace OpenSim.Framework
|
||||||
// m_log.WarnFormat("[AVATARAPPEARANCE] set wearable {0} --> {1}:{2}",wearableId,wearable.ItemID,wearable.AssetID);
|
// m_log.WarnFormat("[AVATARAPPEARANCE] set wearable {0} --> {1}:{2}",wearableId,wearable.ItemID,wearable.AssetID);
|
||||||
// DEBUG OFF
|
// DEBUG OFF
|
||||||
m_wearables[wearableId].Clear();
|
m_wearables[wearableId].Clear();
|
||||||
for (int i = 0 ; i < wearable.Count ; i++)
|
for (int i = 0; i < wearable.Count; i++)
|
||||||
m_wearables[wearableId].Add(wearable[i].ItemID, wearable[i].AssetID);
|
m_wearables[wearableId].Add(wearable[i].ItemID, wearable[i].AssetID);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// DEBUG ON
|
// DEBUG ON
|
||||||
public override String ToString()
|
public override String ToString()
|
||||||
{
|
{
|
||||||
|
@ -365,7 +364,7 @@ namespace OpenSim.Framework
|
||||||
|
|
||||||
foreach (AvatarWearable awear in m_wearables)
|
foreach (AvatarWearable awear in m_wearables)
|
||||||
{
|
{
|
||||||
for ( int i = 0 ; i < awear.Count ; i++ )
|
for (int i = 0; i < awear.Count; i++)
|
||||||
s += String.Format("Wearable: item={0}, asset={1}\n",awear[i].ItemID,awear[i].AssetID);
|
s += String.Format("Wearable: item={0}, asset={1}\n",awear[i].ItemID,awear[i].AssetID);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -64,7 +64,7 @@ namespace OpenSim.Framework
|
||||||
|
|
||||||
m_Servers[port] = new BaseHttpServer(port);
|
m_Servers[port] = new BaseHttpServer(port);
|
||||||
|
|
||||||
if (ipaddr != null )
|
if (ipaddr != null)
|
||||||
m_Servers[port].ListenIPAddress = ipaddr;
|
m_Servers[port].ListenIPAddress = ipaddr;
|
||||||
|
|
||||||
m_log.InfoFormat("[MAIN HTTP SERVER]: Starting main http server on port {0}", port);
|
m_log.InfoFormat("[MAIN HTTP SERVER]: Starting main http server on port {0}", port);
|
||||||
|
|
|
@ -651,8 +651,9 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
// Make sure that we see any exception caused by the asynchronous operation.
|
// Make sure that we see any exception caused by the asynchronous operation.
|
||||||
m_log.Error(
|
m_log.ErrorFormat(
|
||||||
string.Format("[LLCLIENTVIEW]: Caught exception while processing {0}", packetObject.Pack), e);
|
"[LLCLIENTVIEW]: Caught exception while processing {0} for {1}, {2} {3}",
|
||||||
|
packetObject.Pack, Name, e.Message, e.StackTrace);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -178,13 +178,17 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
|
||||||
UUID itemID = UUID.Zero;
|
UUID itemID = UUID.Zero;
|
||||||
if (sp != null)
|
if (sp != null)
|
||||||
{
|
{
|
||||||
foreach (SceneObjectGroup grp in sp.GetAttachments(AttachmentPt))
|
foreach (SceneObjectGroup grp in sp.Attachments)
|
||||||
|
{
|
||||||
|
if (grp.GetAttachmentPoint() == (byte)AttachmentPt)
|
||||||
{
|
{
|
||||||
itemID = grp.GetFromItemID();
|
itemID = grp.GetFromItemID();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
if (itemID != UUID.Zero)
|
if (itemID != UUID.Zero)
|
||||||
DetachSingleAttachmentToInv(itemID, remoteClient);
|
DetachSingleAttachmentToInv(itemID, remoteClient);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if (group.GetFromItemID() == UUID.Zero)
|
if (group.GetFromItemID() == UUID.Zero)
|
||||||
{
|
{
|
||||||
|
|
|
@ -139,7 +139,6 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
return cached;
|
return cached;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Set appearance data (textureentry and slider settings) received from the client
|
/// Set appearance data (textureentry and slider settings) received from the client
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -221,7 +220,7 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
|
|
||||||
public void QueueAppearanceSend(UUID agentid)
|
public void QueueAppearanceSend(UUID agentid)
|
||||||
{
|
{
|
||||||
// m_log.WarnFormat("[AVATAR FACTORY MODULE]: Queue appearance send for {0}",agentid);
|
// m_log.WarnFormat("[AVATAR FACTORY MODULE]: Queue appearance send for {0}", agentid);
|
||||||
|
|
||||||
// 100 nanoseconds (ticks) we should wait
|
// 100 nanoseconds (ticks) we should wait
|
||||||
long timestamp = DateTime.Now.Ticks + Convert.ToInt64(m_sendtime * 10000000);
|
long timestamp = DateTime.Now.Ticks + Convert.ToInt64(m_sendtime * 10000000);
|
||||||
|
@ -234,7 +233,7 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
|
|
||||||
public void QueueAppearanceSave(UUID agentid)
|
public void QueueAppearanceSave(UUID agentid)
|
||||||
{
|
{
|
||||||
// m_log.WarnFormat("[AVATAR FACTORY MODULE]: Queue appearance save for {0}",agentid);
|
// m_log.WarnFormat("[AVATAR FACTORY MODULE]: Queue appearance save for {0}", agentid);
|
||||||
|
|
||||||
// 100 nanoseconds (ticks) we should wait
|
// 100 nanoseconds (ticks) we should wait
|
||||||
long timestamp = DateTime.Now.Ticks + Convert.ToInt64(m_savetime * 10000000);
|
long timestamp = DateTime.Now.Ticks + Convert.ToInt64(m_savetime * 10000000);
|
||||||
|
@ -262,7 +261,7 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
|
|
||||||
// Send the appearance back to the avatar
|
// Send the appearance back to the avatar
|
||||||
// AvatarAppearance avp = sp.Appearance;
|
// AvatarAppearance avp = sp.Appearance;
|
||||||
// sp.ControllingClient.SendAppearance(avp.Owner,avp.VisualParams,avp.Texture.GetBytes());
|
// sp.ControllingClient.SendAppearance(avp.Owner, avp.VisualParams, avp.Texture.GetBytes());
|
||||||
|
|
||||||
/*
|
/*
|
||||||
// this needs to be fixed, the flag should be on scene presence not the region module
|
// this needs to be fixed, the flag should be on scene presence not the region module
|
||||||
|
@ -293,8 +292,8 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
|
|
||||||
lock (m_sendqueue)
|
lock (m_sendqueue)
|
||||||
{
|
{
|
||||||
Dictionary<UUID,long> sends = new Dictionary<UUID,long>(m_sendqueue);
|
Dictionary<UUID, long> sends = new Dictionary<UUID, long>(m_sendqueue);
|
||||||
foreach (KeyValuePair<UUID,long> kvp in sends)
|
foreach (KeyValuePair<UUID, long> kvp in sends)
|
||||||
{
|
{
|
||||||
if (kvp.Value < now)
|
if (kvp.Value < now)
|
||||||
{
|
{
|
||||||
|
@ -306,8 +305,8 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
|
|
||||||
lock (m_savequeue)
|
lock (m_savequeue)
|
||||||
{
|
{
|
||||||
Dictionary<UUID,long> saves = new Dictionary<UUID,long>(m_savequeue);
|
Dictionary<UUID, long> saves = new Dictionary<UUID, long>(m_savequeue);
|
||||||
foreach (KeyValuePair<UUID,long> kvp in saves)
|
foreach (KeyValuePair<UUID, long> kvp in saves)
|
||||||
{
|
{
|
||||||
if (kvp.Value < now)
|
if (kvp.Value < now)
|
||||||
{
|
{
|
||||||
|
@ -337,7 +336,7 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
|
|
||||||
// m_log.WarnFormat("[AVATAR FACTORY MODULE]: Received request for wearables of {0}", client.AgentId);
|
// m_log.WarnFormat("[AVATAR FACTORY MODULE]: Received request for wearables of {0}", client.AgentId);
|
||||||
|
|
||||||
client.SendWearables(sp.Appearance.Wearables,sp.Appearance.Serial++);
|
client.SendWearables(sp.Appearance.Wearables, sp.Appearance.Serial++);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -354,14 +353,14 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// m_log.WarnFormat("[AVATAR FACTORY MODULE]: AvatarIsWearing called for {0}",client.AgentId);
|
// m_log.WarnFormat("[AVATAR FACTORY MODULE]: AvatarIsWearing called for {0}", client.AgentId);
|
||||||
|
|
||||||
AvatarAppearance avatAppearance = new AvatarAppearance(sp.Appearance, false);
|
AvatarAppearance avatAppearance = new AvatarAppearance(sp.Appearance, false);
|
||||||
|
|
||||||
foreach (AvatarWearingArgs.Wearable wear in e.NowWearing)
|
foreach (AvatarWearingArgs.Wearable wear in e.NowWearing)
|
||||||
{
|
{
|
||||||
if (wear.Type < AvatarWearable.MAX_WEARABLES)
|
if (wear.Type < AvatarWearable.MAX_WEARABLES)
|
||||||
avatAppearance.Wearables[wear.Type].Add(wear.ItemID,UUID.Zero);
|
avatAppearance.Wearables[wear.Type].Add(wear.ItemID, UUID.Zero);
|
||||||
}
|
}
|
||||||
|
|
||||||
avatAppearance.GetAssetsFrom(sp.Appearance);
|
avatAppearance.GetAssetsFrom(sp.Appearance);
|
||||||
|
@ -381,7 +380,7 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
{
|
{
|
||||||
for (int i = 0; i < AvatarWearable.MAX_WEARABLES; i++)
|
for (int i = 0; i < AvatarWearable.MAX_WEARABLES; i++)
|
||||||
{
|
{
|
||||||
for (int j = 0 ; j < appearance.Wearables[j].Count ; j ++ )
|
for (int j = 0; j < appearance.Wearables[j].Count; j++)
|
||||||
{
|
{
|
||||||
if (appearance.Wearables[i][j].ItemID == UUID.Zero)
|
if (appearance.Wearables[i][j].ItemID == UUID.Zero)
|
||||||
continue;
|
continue;
|
||||||
|
|
|
@ -435,6 +435,8 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
|
||||||
// Now let's make it officially a child agent
|
// Now let's make it officially a child agent
|
||||||
sp.MakeChildAgent();
|
sp.MakeChildAgent();
|
||||||
|
|
||||||
|
sp.Scene.CleanDroppedAttachments();
|
||||||
|
|
||||||
// Finally, let's close this previously-known-as-root agent, when the jump is outside the view zone
|
// Finally, let's close this previously-known-as-root agent, when the jump is outside the view zone
|
||||||
|
|
||||||
if (NeedsClosing(oldRegionX, newRegionX, oldRegionY, newRegionY, reg))
|
if (NeedsClosing(oldRegionX, newRegionX, oldRegionY, newRegionY, reg))
|
||||||
|
|
|
@ -1098,12 +1098,14 @@ namespace OpenSim.Region.CoreModules.World.Estate
|
||||||
if (m_scene.RegionInfo.RegionSettings.AllowLandJoinDivide)
|
if (m_scene.RegionInfo.RegionSettings.AllowLandJoinDivide)
|
||||||
flags |= RegionFlags.AllowParcelChanges;
|
flags |= RegionFlags.AllowParcelChanges;
|
||||||
if (m_scene.RegionInfo.RegionSettings.BlockShowInSearch)
|
if (m_scene.RegionInfo.RegionSettings.BlockShowInSearch)
|
||||||
flags |= (RegionFlags)(1 << 29);
|
flags |= RegionFlags.BlockParcelSearch;
|
||||||
|
|
||||||
if (m_scene.RegionInfo.RegionSettings.FixedSun)
|
if (m_scene.RegionInfo.RegionSettings.FixedSun)
|
||||||
flags |= RegionFlags.SunFixed;
|
flags |= RegionFlags.SunFixed;
|
||||||
if (m_scene.RegionInfo.RegionSettings.Sandbox)
|
if (m_scene.RegionInfo.RegionSettings.Sandbox)
|
||||||
flags |= RegionFlags.Sandbox;
|
flags |= RegionFlags.Sandbox;
|
||||||
|
if (m_scene.RegionInfo.EstateSettings.AllowVoice)
|
||||||
|
flags |= RegionFlags.AllowVoice;
|
||||||
|
|
||||||
// Fudge these to always on, so the menu options activate
|
// Fudge these to always on, so the menu options activate
|
||||||
//
|
//
|
||||||
|
|
|
@ -88,7 +88,8 @@ namespace OpenSim.Region.CoreModules.World.Land
|
||||||
|
|
||||||
// caches ExtendedLandData
|
// caches ExtendedLandData
|
||||||
private Cache parcelInfoCache;
|
private Cache parcelInfoCache;
|
||||||
private Vector3? forcedPosition = null;
|
private Dictionary<UUID, Vector3> forcedPosition =
|
||||||
|
new Dictionary<UUID, Vector3>();
|
||||||
|
|
||||||
#region INonSharedRegionModule Members
|
#region INonSharedRegionModule Members
|
||||||
|
|
||||||
|
@ -177,7 +178,7 @@ namespace OpenSim.Region.CoreModules.World.Land
|
||||||
void ClientOnPreAgentUpdate(IClientAPI remoteClient, AgentUpdateArgs agentData)
|
void ClientOnPreAgentUpdate(IClientAPI remoteClient, AgentUpdateArgs agentData)
|
||||||
{
|
{
|
||||||
//If we are forcing a position for them to go
|
//If we are forcing a position for them to go
|
||||||
if (forcedPosition != null)
|
if (forcedPosition.ContainsKey(remoteClient.AgentId))
|
||||||
{
|
{
|
||||||
ScenePresence clientAvatar = m_scene.GetScenePresence(remoteClient.AgentId);
|
ScenePresence clientAvatar = m_scene.GetScenePresence(remoteClient.AgentId);
|
||||||
|
|
||||||
|
@ -187,23 +188,23 @@ namespace OpenSim.Region.CoreModules.World.Land
|
||||||
|
|
||||||
|
|
||||||
//Make sure we stop if they get about to the right place to prevent yoyo and prevents getting stuck on banlines
|
//Make sure we stop if they get about to the right place to prevent yoyo and prevents getting stuck on banlines
|
||||||
if (Vector3.Distance(clientAvatar.AbsolutePosition, forcedPosition.Value) < .2)
|
if (Vector3.Distance(clientAvatar.AbsolutePosition, forcedPosition[remoteClient.AgentId]) < .2)
|
||||||
{
|
{
|
||||||
Debug.WriteLine(string.Format("Stopping force position because {0} is close enough to position {1}", forcedPosition.Value, clientAvatar.AbsolutePosition));
|
Debug.WriteLine(string.Format("Stopping force position because {0} is close enough to position {1}", forcedPosition[remoteClient.AgentId], clientAvatar.AbsolutePosition));
|
||||||
forcedPosition = null;
|
forcedPosition.Remove(remoteClient.AgentId);
|
||||||
}
|
}
|
||||||
//if we are far away, teleport
|
//if we are far away, teleport
|
||||||
else if (Vector3.Distance(clientAvatar.AbsolutePosition, forcedPosition.Value) > 3)
|
else if (Vector3.Distance(clientAvatar.AbsolutePosition, forcedPosition[remoteClient.AgentId]) > 3)
|
||||||
{
|
{
|
||||||
Debug.WriteLine(string.Format("Teleporting out because {0} is too far from avatar position {1}", forcedPosition.Value, clientAvatar.AbsolutePosition));
|
Debug.WriteLine(string.Format("Teleporting out because {0} is too far from avatar position {1}", forcedPosition[remoteClient.AgentId], clientAvatar.AbsolutePosition));
|
||||||
clientAvatar.Teleport(forcedPosition.Value);
|
clientAvatar.Teleport(forcedPosition[remoteClient.AgentId]);
|
||||||
forcedPosition = null;
|
forcedPosition.Remove(remoteClient.AgentId);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
//Forces them toward the forced position we want if they aren't there yet
|
//Forces them toward the forced position we want if they aren't there yet
|
||||||
agentData.UseClientAgentPosition = true;
|
agentData.UseClientAgentPosition = true;
|
||||||
agentData.ClientAgentPosition = forcedPosition.Value;
|
agentData.ClientAgentPosition = forcedPosition[remoteClient.AgentId];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -326,7 +327,7 @@ namespace OpenSim.Region.CoreModules.World.Land
|
||||||
if (m_scene.Permissions.IsGod(avatar.UUID)) return;
|
if (m_scene.Permissions.IsGod(avatar.UUID)) return;
|
||||||
if (position.HasValue)
|
if (position.HasValue)
|
||||||
{
|
{
|
||||||
forcedPosition = position;
|
forcedPosition[avatar.ControllingClient.AgentId] = (Vector3)position;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -457,7 +458,7 @@ namespace OpenSim.Region.CoreModules.World.Land
|
||||||
parcel.IsBannedFromLand(clientAvatar.UUID))
|
parcel.IsBannedFromLand(clientAvatar.UUID))
|
||||||
{
|
{
|
||||||
//once we've sent the message once, keep going toward the target until we are done
|
//once we've sent the message once, keep going toward the target until we are done
|
||||||
if (forcedPosition == null)
|
if (forcedPosition.ContainsKey(clientAvatar.ControllingClient.AgentId))
|
||||||
{
|
{
|
||||||
SendYouAreBannedNotice(clientAvatar);
|
SendYouAreBannedNotice(clientAvatar);
|
||||||
ForceAvatarToPosition(clientAvatar, m_scene.GetNearestAllowedPosition(clientAvatar));
|
ForceAvatarToPosition(clientAvatar, m_scene.GetNearestAllowedPosition(clientAvatar));
|
||||||
|
@ -466,7 +467,7 @@ namespace OpenSim.Region.CoreModules.World.Land
|
||||||
else if (parcel.IsRestrictedFromLand(clientAvatar.UUID))
|
else if (parcel.IsRestrictedFromLand(clientAvatar.UUID))
|
||||||
{
|
{
|
||||||
//once we've sent the message once, keep going toward the target until we are done
|
//once we've sent the message once, keep going toward the target until we are done
|
||||||
if (forcedPosition == null)
|
if (forcedPosition.ContainsKey(clientAvatar.ControllingClient.AgentId))
|
||||||
{
|
{
|
||||||
SendYouAreRestrictedNotice(clientAvatar);
|
SendYouAreRestrictedNotice(clientAvatar);
|
||||||
ForceAvatarToPosition(clientAvatar, m_scene.GetNearestAllowedPosition(clientAvatar));
|
ForceAvatarToPosition(clientAvatar, m_scene.GetNearestAllowedPosition(clientAvatar));
|
||||||
|
@ -475,7 +476,7 @@ namespace OpenSim.Region.CoreModules.World.Land
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
//when we are finally in a safe place, lets release the forced position lock
|
//when we are finally in a safe place, lets release the forced position lock
|
||||||
forcedPosition = null;
|
forcedPosition.Remove(clientAvatar.ControllingClient.AgentId);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -97,7 +97,6 @@ namespace OpenSim.Region.CoreModules.World.Sound
|
||||||
else
|
else
|
||||||
gain = (float)((double)gain * ((radius - dis) / radius));
|
gain = (float)((double)gain * ((radius - dis) / radius));
|
||||||
|
|
||||||
m_log.DebugFormat("Play sound, gain {0}", gain);
|
|
||||||
sp.ControllingClient.SendPlayAttachedSound(soundID, objectID, ownerID, (float)gain, flags);
|
sp.ControllingClient.SendPlayAttachedSound(soundID, objectID, ownerID, (float)gain, flags);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -174,6 +174,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
private bool m_firstHeartbeat = true;
|
private bool m_firstHeartbeat = true;
|
||||||
|
|
||||||
private object m_deleting_scene_object = new object();
|
private object m_deleting_scene_object = new object();
|
||||||
|
private object m_cleaningAttachments = new object();
|
||||||
|
|
||||||
private UpdatePrioritizationSchemes m_priorityScheme = UpdatePrioritizationSchemes.Time;
|
private UpdatePrioritizationSchemes m_priorityScheme = UpdatePrioritizationSchemes.Time;
|
||||||
private bool m_reprioritizationEnabled = true;
|
private bool m_reprioritizationEnabled = true;
|
||||||
|
@ -3162,6 +3163,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
}
|
}
|
||||||
|
|
||||||
m_eventManager.TriggerOnRemovePresence(agentID);
|
m_eventManager.TriggerOnRemovePresence(agentID);
|
||||||
|
|
||||||
ForEachClient(
|
ForEachClient(
|
||||||
delegate(IClientAPI client)
|
delegate(IClientAPI client)
|
||||||
{
|
{
|
||||||
|
@ -3194,6 +3196,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
}
|
}
|
||||||
|
|
||||||
m_authenticateHandler.RemoveCircuit(avatar.ControllingClient.CircuitCode);
|
m_authenticateHandler.RemoveCircuit(avatar.ControllingClient.CircuitCode);
|
||||||
|
CleanDroppedAttachments();
|
||||||
//m_log.InfoFormat("[SCENE] Memory pre GC {0}", System.GC.GetTotalMemory(false));
|
//m_log.InfoFormat("[SCENE] Memory pre GC {0}", System.GC.GetTotalMemory(false));
|
||||||
//m_log.InfoFormat("[SCENE] Memory post GC {0}", System.GC.GetTotalMemory(true));
|
//m_log.InfoFormat("[SCENE] Memory post GC {0}", System.GC.GetTotalMemory(true));
|
||||||
}
|
}
|
||||||
|
@ -3408,6 +3411,8 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
|
|
||||||
if (vialogin)
|
if (vialogin)
|
||||||
{
|
{
|
||||||
|
CleanDroppedAttachments();
|
||||||
|
|
||||||
if (TestBorderCross(agent.startpos, Cardinals.E))
|
if (TestBorderCross(agent.startpos, Cardinals.E))
|
||||||
{
|
{
|
||||||
Border crossedBorder = GetCrossedBorder(agent.startpos, Cardinals.E);
|
Border crossedBorder = GetCrossedBorder(agent.startpos, Cardinals.E);
|
||||||
|
@ -3756,7 +3761,13 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
|
|
||||||
// We have to wait until the viewer contacts this region after receiving EAC.
|
// We have to wait until the viewer contacts this region after receiving EAC.
|
||||||
// That calls AddNewClient, which finally creates the ScenePresence
|
// That calls AddNewClient, which finally creates the ScenePresence
|
||||||
m_log.Debug("ICADU -> pre wait");
|
ILandObject nearestParcel = GetNearestAllowedParcel(cAgentData.AgentID, Constants.RegionSize / 2, Constants.RegionSize / 2);
|
||||||
|
if (nearestParcel == null)
|
||||||
|
{
|
||||||
|
m_log.DebugFormat("[SCENE]: Denying root agent entry to {0}: no allowed parcel", cAgentData.AgentID);
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
ScenePresence childAgentUpdate = WaitGetScenePresence(cAgentData.AgentID);
|
ScenePresence childAgentUpdate = WaitGetScenePresence(cAgentData.AgentID);
|
||||||
m_log.Debug("ICADU -> post wait");
|
m_log.Debug("ICADU -> post wait");
|
||||||
if (childAgentUpdate != null)
|
if (childAgentUpdate != null)
|
||||||
|
@ -4738,7 +4749,6 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
Vector3 nearestRegionEdgePoint = GetNearestRegionEdgePosition(avatar);
|
Vector3 nearestRegionEdgePoint = GetNearestRegionEdgePosition(avatar);
|
||||||
//Debug.WriteLine("They are really in a place they don't belong, sending them to: " + nearestRegionEdgePoint.ToString());
|
//Debug.WriteLine("They are really in a place they don't belong, sending them to: " + nearestRegionEdgePoint.ToString());
|
||||||
return nearestRegionEdgePoint;
|
return nearestRegionEdgePoint;
|
||||||
return null;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private Vector3 GetParcelCenterAtGround(ILandObject parcel)
|
private Vector3 GetParcelCenterAtGround(ILandObject parcel)
|
||||||
|
@ -4987,5 +4997,40 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
throw new Exception(error);
|
throw new Exception(error);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void CleanDroppedAttachments()
|
||||||
|
{
|
||||||
|
List<SceneObjectGroup> objectsToDelete =
|
||||||
|
new List<SceneObjectGroup>();
|
||||||
|
|
||||||
|
lock (m_cleaningAttachments)
|
||||||
|
{
|
||||||
|
ForEachSOG(delegate (SceneObjectGroup grp)
|
||||||
|
{
|
||||||
|
if (grp.RootPart.Shape.PCode == 0 && grp.RootPart.Shape.State != 0 && (!objectsToDelete.Contains(grp)))
|
||||||
|
{
|
||||||
|
UUID agentID = grp.OwnerID;
|
||||||
|
if (agentID == UUID.Zero)
|
||||||
|
{
|
||||||
|
objectsToDelete.Add(grp);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
ScenePresence sp = GetScenePresence(agentID);
|
||||||
|
if (sp == null)
|
||||||
|
{
|
||||||
|
objectsToDelete.Add(grp);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach (SceneObjectGroup grp in objectsToDelete)
|
||||||
|
{
|
||||||
|
m_log.InfoFormat("[SCENE]: Deleting dropped attachment {0} of user {1}", grp.UUID, grp.OwnerID);
|
||||||
|
DeleteSceneObject(grp, true);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -9882,6 +9882,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
|
||||||
case "4":
|
case "4":
|
||||||
ret = ret + new LSL_List(land.Area);
|
ret = ret + new LSL_List(land.Area);
|
||||||
break;
|
break;
|
||||||
|
case "5":
|
||||||
|
ret = ret + new LSL_List(land.GlobalID);
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
ret = ret + new LSL_List(0);
|
ret = ret + new LSL_List(0);
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -507,6 +507,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase
|
||||||
public const int PARCEL_DETAILS_OWNER = 2;
|
public const int PARCEL_DETAILS_OWNER = 2;
|
||||||
public const int PARCEL_DETAILS_GROUP = 3;
|
public const int PARCEL_DETAILS_GROUP = 3;
|
||||||
public const int PARCEL_DETAILS_AREA = 4;
|
public const int PARCEL_DETAILS_AREA = 4;
|
||||||
|
public const int PARCEL_DETAILS_ID = 5;
|
||||||
|
|
||||||
// constants for llSetClickAction
|
// constants for llSetClickAction
|
||||||
public const int CLICK_ACTION_NONE = 0;
|
public const int CLICK_ACTION_NONE = 0;
|
||||||
|
|
|
@ -4,6 +4,9 @@
|
||||||
StorageProvider = "OpenSim.Data.SQLiteLegacy.dll"
|
StorageProvider = "OpenSim.Data.SQLiteLegacy.dll"
|
||||||
ConnectionString = "URI=file:OpenSim.db,version=3,UseUTF16Encoding=True"
|
ConnectionString = "URI=file:OpenSim.db,version=3,UseUTF16Encoding=True"
|
||||||
|
|
||||||
|
[AssetService]
|
||||||
|
ConnectionString = "URI=file:Asset.db,version=3"
|
||||||
|
|
||||||
[AvatarService]
|
[AvatarService]
|
||||||
ConnectionString = "URI=file:avatars.db,version=3"
|
ConnectionString = "URI=file:avatars.db,version=3"
|
||||||
|
|
||||||
|
|
|
@ -4,6 +4,9 @@
|
||||||
StorageProvider = "OpenSim.Data.SQLite.dll"
|
StorageProvider = "OpenSim.Data.SQLite.dll"
|
||||||
ConnectionString = "URI=file:OpenSim.db,version=3,UseUTF16Encoding=True"
|
ConnectionString = "URI=file:OpenSim.db,version=3,UseUTF16Encoding=True"
|
||||||
|
|
||||||
|
[AssetService]
|
||||||
|
ConnectionString = "URI=file:Asset.db,version=3"
|
||||||
|
|
||||||
[InventoryService]
|
[InventoryService]
|
||||||
;ConnectionString = "URI=file:inventory.db,version=3"
|
;ConnectionString = "URI=file:inventory.db,version=3"
|
||||||
; if you have a legacy inventory store use the connection string below
|
; if you have a legacy inventory store use the connection string below
|
||||||
|
|
|
@ -2155,7 +2155,7 @@
|
||||||
<Reference name="OpenSim.Region.Framework"/>
|
<Reference name="OpenSim.Region.Framework"/>
|
||||||
<Reference name="OpenMetaverseTypes" path="../../../bin/"/>
|
<Reference name="OpenMetaverseTypes" path="../../../bin/"/>
|
||||||
<Reference name="OpenMetaverse" path="../../../bin/"/>
|
<Reference name="OpenMetaverse" path="../../../bin/"/>
|
||||||
<Reference name="Mono.Data.SqliteClient"/>
|
<Reference name="Mono.Data.SqliteClient" path="../../../bin/"/>
|
||||||
<Reference name="Mono.Addins" path="../../../bin/"/>
|
<Reference name="Mono.Addins" path="../../../bin/"/>
|
||||||
<Reference name="log4net" path="../../../bin/"/>
|
<Reference name="log4net" path="../../../bin/"/>
|
||||||
|
|
||||||
|
@ -2503,7 +2503,7 @@
|
||||||
<Reference name="OpenSim.Framework.Servers.HttpServer"/>
|
<Reference name="OpenSim.Framework.Servers.HttpServer"/>
|
||||||
<Reference name="OpenSim.Framework.Statistics"/>
|
<Reference name="OpenSim.Framework.Statistics"/>
|
||||||
<Reference name="OpenSim.Region.Physics.Manager"/>
|
<Reference name="OpenSim.Region.Physics.Manager"/>
|
||||||
<Reference name="Mono.Data.SqliteClient"/>
|
<Reference name="Mono.Data.SqliteClient" path="../../../bin/"/>
|
||||||
<Reference name="Mono.Addins"/>
|
<Reference name="Mono.Addins"/>
|
||||||
|
|
||||||
<!-- For scripting in funny languages by default -->
|
<!-- For scripting in funny languages by default -->
|
||||||
|
|
Loading…
Reference in New Issue