aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorMelanie2012-01-07 12:06:21 +0100
committerMelanie2012-01-07 12:06:21 +0100
commitefe51fd5cba9bf3ed1cd37f71f8af888dbf0a386 (patch)
treedf9184456626907bbe3ac489db7840069d2416b7
parentForce the group tag of NPCs to "- NPC -" unless the name is completely blank. (diff)
downloadopensim-SC_OLD-efe51fd5cba9bf3ed1cd37f71f8af888dbf0a386.zip
opensim-SC_OLD-efe51fd5cba9bf3ed1cd37f71f8af888dbf0a386.tar.gz
opensim-SC_OLD-efe51fd5cba9bf3ed1cd37f71f8af888dbf0a386.tar.bz2
opensim-SC_OLD-efe51fd5cba9bf3ed1cd37f71f8af888dbf0a386.tar.xz
Don't try to save a NPCs attachment states on NPC delete
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs8
1 files changed, 8 insertions, 0 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
index eca9c3b..83beff4 100644
--- a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
@@ -468,6 +468,14 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
468 /// <param name="grp"></param> 468 /// <param name="grp"></param>
469 private void UpdateKnownItem(IScenePresence sp, SceneObjectGroup grp) 469 private void UpdateKnownItem(IScenePresence sp, SceneObjectGroup grp)
470 { 470 {
471 // Saving attachments for NPCs messes them up for the real owner!
472 INPCModule module = m_scene.RequestModuleInterface<INPCModule>();
473 if (module != null)
474 {
475 if (module.IsNPC(sp.UUID, m_scene))
476 return;
477 }
478
471 if (grp.HasGroupChanged || grp.ContainsScripts()) 479 if (grp.HasGroupChanged || grp.ContainsScripts())
472 { 480 {
473 m_log.DebugFormat( 481 m_log.DebugFormat(