aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
authorMelanie Thielker2010-09-06 03:59:48 +0200
committerMelanie2010-09-06 04:09:51 +0100
commit0246edc2eacd3690dae44ef11e99746764b672fd (patch)
treef602facdc4eb13170885e1feacd887993498bbe2 /OpenSim/Region
parentFix a handful of copypaste errors (diff)
downloadopensim-SC_OLD-0246edc2eacd3690dae44ef11e99746764b672fd.zip
opensim-SC_OLD-0246edc2eacd3690dae44ef11e99746764b672fd.tar.gz
opensim-SC_OLD-0246edc2eacd3690dae44ef11e99746764b672fd.tar.bz2
opensim-SC_OLD-0246edc2eacd3690dae44ef11e99746764b672fd.tar.xz
Reflect the ParcelPropertiesUpdateRequest into Scene.EventManager, because
modules need to see it (Search!) even if it comes in via CAPS
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs14
-rw-r--r--OpenSim/Region/Framework/Scenes/EventManager.cs26
2 files changed, 36 insertions, 4 deletions
diff --git a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs
index 268e2ee..da7a284 100644
--- a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs
+++ b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs
@@ -1103,7 +1103,11 @@ namespace OpenSim.Region.CoreModules.World.Land
1103 m_landList.TryGetValue(localID, out land); 1103 m_landList.TryGetValue(localID, out land);
1104 } 1104 }
1105 1105
1106 if (land != null) land.UpdateLandProperties(args, remote_client); 1106 if (land != null)
1107 {
1108 land.UpdateLandProperties(args, remote_client);
1109 m_scene.EventManager.TriggerOnParcelPropertiesUpdateRequest(args, localID, remote_client);
1110 }
1107 } 1111 }
1108 1112
1109 public void ClientOnParcelDivideRequest(int west, int south, int east, int north, IClientAPI remote_client) 1113 public void ClientOnParcelDivideRequest(int west, int south, int east, int north, IClientAPI remote_client)
@@ -1408,9 +1412,13 @@ namespace OpenSim.Region.CoreModules.World.Land
1408 m_landList.TryGetValue(parcelID, out land); 1412 m_landList.TryGetValue(parcelID, out land);
1409 } 1413 }
1410 1414
1411 if (land != null) { 1415 if (land != null)
1416 {
1412 land.UpdateLandProperties(land_update, client); 1417 land.UpdateLandProperties(land_update, client);
1413 } else { 1418 m_scene.EventManager.TriggerOnParcelPropertiesUpdateRequest(land_update, parcelID, client);
1419 }
1420 else
1421 {
1414 m_log.WarnFormat("[LAND] unable to find parcelID {0}", parcelID); 1422 m_log.WarnFormat("[LAND] unable to find parcelID {0}", parcelID);
1415 } 1423 }
1416 return LLSDHelpers.SerialiseLLSDReply(new LLSDEmpty()); 1424 return LLSDHelpers.SerialiseLLSDReply(new LLSDEmpty());
diff --git a/OpenSim/Region/Framework/Scenes/EventManager.cs b/OpenSim/Region/Framework/Scenes/EventManager.cs
index 0ae3146..7bcc4db 100644
--- a/OpenSim/Region/Framework/Scenes/EventManager.cs
+++ b/OpenSim/Region/Framework/Scenes/EventManager.cs
@@ -109,6 +109,8 @@ namespace OpenSim.Region.Framework.Scenes
109 109
110 public event OnSetRootAgentSceneDelegate OnSetRootAgentScene; 110 public event OnSetRootAgentSceneDelegate OnSetRootAgentScene;
111 111
112 public event ParcelPropertiesUpdateRequest OnParcelPropertiesUpdateRequest;
113
112 /// <summary> 114 /// <summary>
113 /// Fired when an object is touched/grabbed. 115 /// Fired when an object is touched/grabbed.
114 /// </summary> 116 /// </summary>
@@ -2104,5 +2106,27 @@ namespace OpenSim.Region.Framework.Scenes
2104 } 2106 }
2105 } 2107 }
2106 } 2108 }
2109
2110 public void TriggerOnParcelPropertiesUpdateRequest(LandUpdateArgs args,
2111 int local_id, IClientAPI remote_client)
2112 {
2113 ParcelPropertiesUpdateRequest handler = OnParcelPropertiesUpdateRequest;
2114 if (handler != null)
2115 {
2116 foreach (ParcelPropertiesUpdateRequest d in handler.GetInvocationList())
2117 {
2118 try
2119 {
2120 d(args, local_id, remote_client);
2121 }
2122 catch (Exception e)
2123 {
2124 m_log.ErrorFormat(
2125 "[EVENT MANAGER]: Delegate for TriggerOnSceneObjectPartCopy failed - continuing. {0} {1}",
2126 e.Message, e.StackTrace);
2127 }
2128 }
2129 }
2130 }
2107 } 2131 }
2108} \ No newline at end of file 2132}