aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorMW2007-11-30 12:10:12 +0000
committerMW2007-11-30 12:10:12 +0000
commitc1d66a85646eeae9011265bdf26157ccbaed2421 (patch)
treef09b200dc54c991d6e77f2c8c56f60893992d6a5
parent* Refactored away permissions and physics flag duplications (diff)
downloadopensim-SC_OLD-c1d66a85646eeae9011265bdf26157ccbaed2421.zip
opensim-SC_OLD-c1d66a85646eeae9011265bdf26157ccbaed2421.tar.gz
opensim-SC_OLD-c1d66a85646eeae9011265bdf26157ccbaed2421.tar.bz2
opensim-SC_OLD-c1d66a85646eeae9011265bdf26157ccbaed2421.tar.xz
small change to OnSceneGroupMove event (in SceneEvents.cs)
-rw-r--r--OpenSim/Region/Environment/Scenes/SceneEvents.cs7
-rw-r--r--OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs17
2 files changed, 14 insertions, 10 deletions
diff --git a/OpenSim/Region/Environment/Scenes/SceneEvents.cs b/OpenSim/Region/Environment/Scenes/SceneEvents.cs
index 0986654..e058745 100644
--- a/OpenSim/Region/Environment/Scenes/SceneEvents.cs
+++ b/OpenSim/Region/Environment/Scenes/SceneEvents.cs
@@ -88,7 +88,7 @@ namespace OpenSim.Region.Environment.Scenes
88 88
89 public event RemoveScript OnRemoveScript; 89 public event RemoveScript OnRemoveScript;
90 90
91 public delegate void SceneGroupMoved(LLUUID groupID, LLVector3 delta); 91 public delegate bool SceneGroupMoved(LLUUID groupID, LLVector3 delta);
92 92
93 public event SceneGroupMoved OnSceneGroupMove; 93 public event SceneGroupMoved OnSceneGroupMove;
94 94
@@ -194,12 +194,13 @@ namespace OpenSim.Region.Environment.Scenes
194 } 194 }
195 } 195 }
196 196
197 public void TriggerGroupMove(LLUUID groupID, LLVector3 delta) 197 public bool TriggerGroupMove(LLUUID groupID, LLVector3 delta)
198 { 198 {
199 if (OnSceneGroupMove != null) 199 if (OnSceneGroupMove != null)
200 { 200 {
201 OnSceneGroupMove(groupID, delta); 201 return OnSceneGroupMove(groupID, delta);
202 } 202 }
203 return true;
203 } 204 }
204 205
205 public void TriggerGroupGrab(LLUUID groupID, LLVector3 offset, LLUUID userID) 206 public void TriggerGroupGrab(LLUUID groupID, LLVector3 offset, LLUUID userID)
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs
index 1b55a49..8038a83 100644
--- a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs
+++ b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs
@@ -972,9 +972,11 @@ namespace OpenSim.Region.Environment.Scenes
972 /// <param name="remoteClient"></param> 972 /// <param name="remoteClient"></param>
973 public void GrabMovement(LLVector3 offset, LLVector3 pos, IClientAPI remoteClient) 973 public void GrabMovement(LLVector3 offset, LLVector3 pos, IClientAPI remoteClient)
974 { 974 {
975 AbsolutePosition = pos; 975 if (m_scene.EventManager.TriggerGroupMove(UUID, pos))
976 m_rootPart.SendTerseUpdateToAllClients(); 976 {
977 m_scene.EventManager.TriggerGroupMove(UUID, pos); 977 AbsolutePosition = pos;
978 m_rootPart.SendTerseUpdateToAllClients();
979 }
978 } 980 }
979 981
980 /// <summary> 982 /// <summary>
@@ -1263,10 +1265,11 @@ namespace OpenSim.Region.Environment.Scenes
1263 /// <param name="pos"></param> 1265 /// <param name="pos"></param>
1264 public void UpdateGroupPosition(LLVector3 pos) 1266 public void UpdateGroupPosition(LLVector3 pos)
1265 { 1267 {
1266 AbsolutePosition = pos; 1268 if (m_scene.EventManager.TriggerGroupMove(UUID, pos))
1267 ScheduleGroupForTerseUpdate(); 1269 {
1268 1270 AbsolutePosition = pos;
1269 m_scene.EventManager.TriggerGroupMove(UUID, pos); 1271 ScheduleGroupForTerseUpdate();
1272 }
1270 } 1273 }
1271 1274
1272 /// <summary> 1275 /// <summary>