Merge branch 'master' into careminster
Conflicts: OpenSim/Region/OptionalModules/World/NPC/NPCModule.csavinationmerge
commit
def65cd94a
|
@ -296,6 +296,10 @@ namespace OpenSim.Framework.Console
|
||||||
matches[0].Groups["Category"].Value);
|
matches[0].Groups["Category"].Value);
|
||||||
System.Console.Write("]:");
|
System.Console.Write("]:");
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
outText = outText.Trim();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (level == "error")
|
if (level == "error")
|
||||||
|
|
|
@ -189,7 +189,9 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.ErrorFormat("[ATTACHMENTS MODULE]: Unable to rez attachment: {0}{1}", e.Message, e.StackTrace);
|
UUID agentId = (sp.ControllingClient == null) ? (UUID)null : sp.ControllingClient.AgentId;
|
||||||
|
m_log.ErrorFormat("[ATTACHMENTS MODULE]: Unable to rez attachment with itemID {0}, assetID {1}, point {2} for {3}: {4}\n{5}",
|
||||||
|
attach.ItemID, attach.AssetID, p, agentId, e.Message, e.StackTrace);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -440,7 +442,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
|
||||||
lock (sp.AttachmentsSyncLock)
|
lock (sp.AttachmentsSyncLock)
|
||||||
{
|
{
|
||||||
// Save avatar attachment information
|
// Save avatar attachment information
|
||||||
m_log.Debug("[ATTACHMENTS MODULE]: Detaching from UserID: " + sp.UUID + ", ItemID: " + itemID);
|
// m_log.Debug("[ATTACHMENTS MODULE]: Detaching from UserID: " + sp.UUID + ", ItemID: " + itemID);
|
||||||
|
|
||||||
bool changed = sp.Appearance.DetachAttachment(itemID);
|
bool changed = sp.Appearance.DetachAttachment(itemID);
|
||||||
if (changed && m_scene.AvatarFactory != null)
|
if (changed && m_scene.AvatarFactory != null)
|
||||||
|
@ -520,9 +522,9 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
|
||||||
|
|
||||||
if (grp.HasGroupChanged || (saveAllScripted && grp.ContainsScripts()))
|
if (grp.HasGroupChanged || (saveAllScripted && grp.ContainsScripts()))
|
||||||
{
|
{
|
||||||
m_log.DebugFormat(
|
// m_log.DebugFormat(
|
||||||
"[ATTACHMENTS MODULE]: Updating asset for attachment {0}, attachpoint {1}",
|
// "[ATTACHMENTS MODULE]: Updating asset for attachment {0}, attachpoint {1}",
|
||||||
grp.UUID, grp.AttachmentPoint);
|
// grp.UUID, grp.AttachmentPoint);
|
||||||
|
|
||||||
string sceneObjectXml = SceneObjectSerializer.ToOriginalXmlFormat(grp);
|
string sceneObjectXml = SceneObjectSerializer.ToOriginalXmlFormat(grp);
|
||||||
|
|
||||||
|
@ -553,12 +555,12 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
|
||||||
}
|
}
|
||||||
grp.HasGroupChanged = false; // Prevent it being saved over and over
|
grp.HasGroupChanged = false; // Prevent it being saved over and over
|
||||||
}
|
}
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
m_log.DebugFormat(
|
// m_log.DebugFormat(
|
||||||
"[ATTACHMENTS MODULE]: Don't need to update asset for unchanged attachment {0}, attachpoint {1}",
|
// "[ATTACHMENTS MODULE]: Don't need to update asset for unchanged attachment {0}, attachpoint {1}",
|
||||||
grp.UUID, grp.AttachmentPoint);
|
// grp.UUID, grp.AttachmentPoint);
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -946,13 +948,12 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
|
||||||
// Calls attach with a Zero position
|
// Calls attach with a Zero position
|
||||||
if (AttachObject(sp, part.ParentGroup, AttachmentPt, false))
|
if (AttachObject(sp, part.ParentGroup, AttachmentPt, false))
|
||||||
{
|
{
|
||||||
m_scene.EventManager.TriggerOnAttach(objectLocalID, part.ParentGroup.FromItemID, remoteClient.AgentId);
|
// m_log.Debug(
|
||||||
|
// "[ATTACHMENTS MODULE]: Saving avatar attachment. AgentID: " + remoteClient.AgentId
|
||||||
|
// + ", AttachmentPoint: " + AttachmentPt);
|
||||||
|
|
||||||
// Save avatar attachment information
|
// Save avatar attachment information
|
||||||
m_log.Debug(
|
m_scene.EventManager.TriggerOnAttach(objectLocalID, part.ParentGroup.FromItemID, remoteClient.AgentId);
|
||||||
"[ATTACHMENTS MODULE]: Saving avatar attachment. AgentID: " + remoteClient.AgentId
|
|
||||||
+ ", AttachmentPoint: " + AttachmentPt);
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
|
|
|
@ -158,7 +158,7 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
// Process the baked texture array
|
// Process the baked texture array
|
||||||
if (textureEntry != null)
|
if (textureEntry != null)
|
||||||
{
|
{
|
||||||
m_log.InfoFormat("[AVFACTORY]: Received texture update for {0} {1}", sp.Name, sp.UUID);
|
// m_log.DebugFormat("[AVFACTORY]: Received texture update for {0} {1}", sp.Name, sp.UUID);
|
||||||
|
|
||||||
// WriteBakedTexturesReport(sp, m_log.DebugFormat);
|
// WriteBakedTexturesReport(sp, m_log.DebugFormat);
|
||||||
|
|
||||||
|
@ -208,7 +208,8 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
ScenePresence sp = m_scene.GetScenePresence(agentId);
|
ScenePresence sp = m_scene.GetScenePresence(agentId);
|
||||||
if (sp == null)
|
if (sp == null)
|
||||||
{
|
{
|
||||||
m_log.WarnFormat("[AVFACTORY]: Agent {0} no longer in the scene", agentId);
|
// This is expected if the user has gone away.
|
||||||
|
// m_log.DebugFormat("[AVFACTORY]: Agent {0} no longer in the scene", agentId);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -248,10 +249,10 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
|
|
||||||
if (bakedTextureFace == null)
|
if (bakedTextureFace == null)
|
||||||
{
|
{
|
||||||
m_log.WarnFormat(
|
// This can happen legitimately, since some baked textures might not exist
|
||||||
"[AV FACTORY]: No texture ID set for {0} for {1} in {2} not found when trying to save permanently",
|
//m_log.WarnFormat(
|
||||||
bakeType, sp.Name, m_scene.RegionInfo.RegionName);
|
// "[AV FACTORY]: No texture ID set for {0} for {1} in {2} not found when trying to save permanently",
|
||||||
|
// bakeType, sp.Name, m_scene.RegionInfo.RegionName);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -337,7 +338,7 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
m_log.DebugFormat("[AVFACTORY]: Completed texture check for {0} {1}", sp.Name, sp.UUID);
|
// m_log.DebugFormat("[AVFACTORY]: Completed texture check for {0} {1}", sp.Name, sp.UUID);
|
||||||
|
|
||||||
// If we only found default textures, then the appearance is not cached
|
// If we only found default textures, then the appearance is not cached
|
||||||
return (defonly ? false : true);
|
return (defonly ? false : true);
|
||||||
|
@ -417,7 +418,8 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
// acd.AgentID, i, acd.Appearance.Texture.FaceTextures[i]);
|
// acd.AgentID, i, acd.Appearance.Texture.FaceTextures[i]);
|
||||||
|
|
||||||
int ftIndex = (int)AppearanceManager.BakeTypeToAgentTextureIndex(bakeType);
|
int ftIndex = (int)AppearanceManager.BakeTypeToAgentTextureIndex(bakeType);
|
||||||
bakedTextures[bakeType] = faceTextures[ftIndex];
|
Primitive.TextureEntryFace texture = faceTextures[ftIndex]; // this will be null if there's no such baked texture
|
||||||
|
bakedTextures[bakeType] = texture;
|
||||||
}
|
}
|
||||||
|
|
||||||
return bakedTextures;
|
return bakedTextures;
|
||||||
|
@ -482,7 +484,8 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory
|
||||||
ScenePresence sp = m_scene.GetScenePresence(agentid);
|
ScenePresence sp = m_scene.GetScenePresence(agentid);
|
||||||
if (sp == null)
|
if (sp == null)
|
||||||
{
|
{
|
||||||
m_log.WarnFormat("[AVFACTORY]: Agent {0} no longer in the scene", agentid);
|
// This is expected if the user has gone away.
|
||||||
|
// m_log.DebugFormat("[AVFACTORY]: Agent {0} no longer in the scene", agentid);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -172,13 +172,17 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
|
||||||
// Reset animations; the viewer does that in teleports.
|
// Reset animations; the viewer does that in teleports.
|
||||||
sp.Animator.ResetAnimations();
|
sp.Animator.ResetAnimations();
|
||||||
|
|
||||||
|
string destinationRegionName = "(not found)";
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (regionHandle == sp.Scene.RegionInfo.RegionHandle)
|
if (regionHandle == sp.Scene.RegionInfo.RegionHandle)
|
||||||
{
|
{
|
||||||
|
destinationRegionName = sp.Scene.RegionInfo.RegionName;
|
||||||
|
|
||||||
m_log.DebugFormat(
|
m_log.DebugFormat(
|
||||||
"[ENTITY TRANSFER MODULE]: RequestTeleportToLocation {0} within {1}",
|
"[ENTITY TRANSFER MODULE]: RequestTeleportToLocation for {0} to {1} within existing region {2}",
|
||||||
position, sp.Scene.RegionInfo.RegionName);
|
sp.Name, position, destinationRegionName);
|
||||||
|
|
||||||
// Teleport within the same region
|
// Teleport within the same region
|
||||||
if (IsOutsideRegion(sp.Scene, position) || position.Z < 0)
|
if (IsOutsideRegion(sp.Scene, position) || position.Z < 0)
|
||||||
|
@ -188,6 +192,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
|
||||||
m_log.WarnFormat(
|
m_log.WarnFormat(
|
||||||
"[ENTITY TRANSFER MODULE]: RequestTeleportToLocation() was given an illegal position of {0} for avatar {1}, {2}. Substituting {3}",
|
"[ENTITY TRANSFER MODULE]: RequestTeleportToLocation() was given an illegal position of {0} for avatar {1}, {2}. Substituting {3}",
|
||||||
position, sp.Name, sp.UUID, emergencyPos);
|
position, sp.Name, sp.UUID, emergencyPos);
|
||||||
|
|
||||||
position = emergencyPos;
|
position = emergencyPos;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -234,6 +239,8 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
destinationRegionName = finalDestination.RegionName;
|
||||||
|
|
||||||
// check if HyperGrid teleport is allowed, based on user level
|
// check if HyperGrid teleport is allowed, based on user level
|
||||||
int flags = m_aScene.GridService.GetRegionFlags(sp.Scene.RegionInfo.ScopeID, reg.RegionID);
|
int flags = m_aScene.GridService.GetRegionFlags(sp.Scene.RegionInfo.ScopeID, reg.RegionID);
|
||||||
|
|
||||||
|
@ -308,7 +315,11 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
m_log.WarnFormat("[ENTITY TRANSFER MODULE]: Exception on teleport: {0} {1}", e.Message, e.StackTrace);
|
m_log.ErrorFormat(
|
||||||
|
"[ENTITY TRANSFER MODULE]: Exception on teleport of {0} from {1}@{2} to {3}@{4}: {5}{6}",
|
||||||
|
sp.Name, sp.AbsolutePosition, sp.Scene.RegionInfo.RegionName, position, destinationRegionName,
|
||||||
|
e.Message, e.StackTrace);
|
||||||
|
|
||||||
sp.ControllingClient.SendTeleportFailed("Internal error");
|
sp.ControllingClient.SendTeleportFailed("Internal error");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -155,18 +155,10 @@ namespace OpenSim.Region.OptionalModules.World.NPC
|
||||||
ScenePresence sp;
|
ScenePresence sp;
|
||||||
if (scene.TryGetScenePresence(npcAvatar.AgentId, out sp))
|
if (scene.TryGetScenePresence(npcAvatar.AgentId, out sp))
|
||||||
{
|
{
|
||||||
m_log.DebugFormat(
|
|
||||||
"[NPC MODULE]: Successfully retrieved scene presence for NPC {0} {1}", sp.Name, sp.UUID);
|
|
||||||
|
|
||||||
sp.CompleteMovement(npcAvatar, false);
|
sp.CompleteMovement(npcAvatar, false);
|
||||||
m_avatars.Add(npcAvatar.AgentId, npcAvatar);
|
m_avatars.Add(npcAvatar.AgentId, npcAvatar);
|
||||||
|
m_log.DebugFormat("[NPC MODULE]: Created NPC {0} {1}", npcAvatar.AgentId, sp.Name);
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
m_log.WarnFormat("[NPC MODULE]: Could not find scene presence for NPC {0} {1}", sp.Name, sp.UUID);
|
|
||||||
npcAvatar.AgentId = UUID.Zero;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
ev.Set();
|
ev.Set();
|
||||||
});
|
});
|
||||||
|
@ -308,7 +300,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC
|
||||||
scene.RemoveClient(agentID, false);
|
scene.RemoveClient(agentID, false);
|
||||||
m_avatars.Remove(agentID);
|
m_avatars.Remove(agentID);
|
||||||
|
|
||||||
// m_log.DebugFormat("[NPC MODULE]: Removed {0} {1}", agentID, av.Name);
|
m_log.DebugFormat("[NPC MODULE]: Removed NPC {0} {1}", agentID, av.Name);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1902,9 +1902,11 @@ namespace OpenSim.Region.ScriptEngine.XEngine
|
||||||
// if there already exists a file at that location, it may be locked.
|
// if there already exists a file at that location, it may be locked.
|
||||||
m_log.ErrorFormat("[XEngine]: File {0} already exists! {1}", path, ex.Message);
|
m_log.ErrorFormat("[XEngine]: File {0} already exists! {1}", path, ex.Message);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
string textpath = path + ".text";
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
using (FileStream fs = File.Create(path + ".text"))
|
using (FileStream fs = File.Create(textpath))
|
||||||
{
|
{
|
||||||
using (StreamWriter sw = new StreamWriter(fs))
|
using (StreamWriter sw = new StreamWriter(fs))
|
||||||
{
|
{
|
||||||
|
@ -1917,7 +1919,7 @@ namespace OpenSim.Region.ScriptEngine.XEngine
|
||||||
catch (IOException ex)
|
catch (IOException ex)
|
||||||
{
|
{
|
||||||
// if there already exists a file at that location, it may be locked.
|
// if there already exists a file at that location, it may be locked.
|
||||||
m_log.ErrorFormat("[XEngine]: File {0} already exists! {1}", path, ex.Message);
|
m_log.ErrorFormat("[XEngine]: File {0} already exists! {1}", textpath, ex.Message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1966,7 +1968,7 @@ namespace OpenSim.Region.ScriptEngine.XEngine
|
||||||
catch (IOException ex)
|
catch (IOException ex)
|
||||||
{
|
{
|
||||||
// if there already exists a file at that location, it may be locked.
|
// if there already exists a file at that location, it may be locked.
|
||||||
m_log.ErrorFormat("[XEngine]: File {0} already exists! {1}", statepath, ex.Message);
|
m_log.ErrorFormat("[XEngine]: File {0} already exists! {1}", mappath, ex.Message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -117,7 +117,10 @@ namespace OpenSim.Server.Base
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
if (!(e is System.MissingMethodException))
|
if (!(e is System.MissingMethodException))
|
||||||
m_log.ErrorFormat("Error loading plugin from {0}, exception {1}", dllName, e.InnerException);
|
{
|
||||||
|
m_log.ErrorFormat("Error loading plugin {0} from {1}. Exception: {2}",
|
||||||
|
interfaceName, dllName, e.InnerException == null ? e.Message : e.InnerException.Message);
|
||||||
|
}
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -357,21 +357,26 @@ namespace OpenSim.Services.LLLoginService
|
||||||
{
|
{
|
||||||
TimeZoneInfo gridTimeZone;
|
TimeZoneInfo gridTimeZone;
|
||||||
|
|
||||||
try
|
// Disabled for now pending making timezone a config value, which can at some point have a default of
|
||||||
{
|
// a ; separated list of possible timezones.
|
||||||
// First try to fetch DST from Pacific Standard Time, because this is
|
// The problem here is that US/Pacific (or even the Olsen America/Los_Angeles) is not universal across
|
||||||
// the one expected by the viewer. "US/Pacific" is the string to search
|
// windows, mac and various distributions of linux, introducing another element of consistency.
|
||||||
// on linux and mac, and should work also on Windows (to confirm)
|
// The server operator needs to be able to control this setting
|
||||||
gridTimeZone = TimeZoneInfo.FindSystemTimeZoneById("US/Pacific");
|
// try
|
||||||
}
|
// {
|
||||||
catch (Exception e)
|
// // First try to fetch DST from Pacific Standard Time, because this is
|
||||||
{
|
// // the one expected by the viewer. "US/Pacific" is the string to search
|
||||||
m_log.WarnFormat(
|
// // on linux and mac, and should work also on Windows (to confirm)
|
||||||
"[TIMEZONE]: {0} Falling back to system time. System time should be set to Pacific Standard Time to provide the expected time",
|
// gridTimeZone = TimeZoneInfo.FindSystemTimeZoneById("US/Pacific");
|
||||||
e.Message);
|
// }
|
||||||
|
// catch (Exception e)
|
||||||
|
// {
|
||||||
|
// m_log.WarnFormat(
|
||||||
|
// "[TIMEZONE]: {0} Falling back to system time. System time should be set to Pacific Standard Time to provide the expected time",
|
||||||
|
// e.Message);
|
||||||
|
|
||||||
gridTimeZone = TimeZoneInfo.Local;
|
gridTimeZone = TimeZoneInfo.Local;
|
||||||
}
|
// }
|
||||||
|
|
||||||
DST = gridTimeZone.IsDaylightSavingTime(DateTime.Now) ? "Y" : "N";
|
DST = gridTimeZone.IsDaylightSavingTime(DateTime.Now) ? "Y" : "N";
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue