aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Scenes
diff options
context:
space:
mode:
authorJeff Ames2008-05-28 03:44:49 +0000
committerJeff Ames2008-05-28 03:44:49 +0000
commit5752c1f5c2ee069e2ff5ffc0ff2f186d7454c5c4 (patch)
treeea980f49f1a6bb40ba037a87581a3d741c3d3c56 /OpenSim/Region/Environment/Scenes
parentThank you kindly, Melanie for a patch that: (diff)
downloadopensim-SC-5752c1f5c2ee069e2ff5ffc0ff2f186d7454c5c4.zip
opensim-SC-5752c1f5c2ee069e2ff5ffc0ff2f186d7454c5c4.tar.gz
opensim-SC-5752c1f5c2ee069e2ff5ffc0ff2f186d7454c5c4.tar.bz2
opensim-SC-5752c1f5c2ee069e2ff5ffc0ff2f186d7454c5c4.tar.xz
Formatting cleanup.
Diffstat (limited to 'OpenSim/Region/Environment/Scenes')
-rw-r--r--OpenSim/Region/Environment/Scenes/InnerScene.cs38
-rw-r--r--OpenSim/Region/Environment/Scenes/Scene.Inventory.cs10
-rw-r--r--OpenSim/Region/Environment/Scenes/Scene.PacketHandlers.cs6
-rw-r--r--OpenSim/Region/Environment/Scenes/Scene.cs12
-rw-r--r--OpenSim/Region/Environment/Scenes/SceneObjectPart.cs50
-rw-r--r--OpenSim/Region/Environment/Scenes/ScenePresence.cs4
6 files changed, 59 insertions, 61 deletions
diff --git a/OpenSim/Region/Environment/Scenes/InnerScene.cs b/OpenSim/Region/Environment/Scenes/InnerScene.cs
index 8541024..3e250da 100644
--- a/OpenSim/Region/Environment/Scenes/InnerScene.cs
+++ b/OpenSim/Region/Environment/Scenes/InnerScene.cs
@@ -196,7 +196,7 @@ namespace OpenSim.Region.Environment.Scenes
196 196
197 } 197 }
198 sceneObject.UpdateParentIDs(); 198 sceneObject.UpdateParentIDs();
199 199
200 AddSceneObject(sceneObject); 200 AddSceneObject(sceneObject);
201 } 201 }
202 202
@@ -215,14 +215,14 @@ namespace OpenSim.Region.Environment.Scenes
215 // QuadTree.AddSceneObject(sceneObject); 215 // QuadTree.AddSceneObject(sceneObject);
216 Entities.Add(sceneObject.UUID, sceneObject); 216 Entities.Add(sceneObject.UUID, sceneObject);
217 m_numPrim++; 217 m_numPrim++;
218 218
219 return true; 219 return true;
220 } 220 }
221 221
222 return false; 222 return false;
223 } 223 }
224 } 224 }
225 225
226 /// <summary> 226 /// <summary>
227 /// Delete an object from the scene 227 /// Delete an object from the scene
228 /// </summary> 228 /// </summary>
@@ -236,11 +236,11 @@ namespace OpenSim.Region.Environment.Scenes
236 { 236 {
237 Entities.Remove(uuid); 237 Entities.Remove(uuid);
238 m_numPrim--; 238 m_numPrim--;
239 239
240 return true; 240 return true;
241 } 241 }
242 } 242 }
243 243
244 return false; 244 return false;
245 } 245 }
246 246
@@ -313,7 +313,7 @@ namespace OpenSim.Region.Environment.Scenes
313 { 313 {
314 m_activeScripts += number; 314 m_activeScripts += number;
315 } 315 }
316 316
317 protected internal void DetachObject(uint objectLocalID, IClientAPI remoteClient) 317 protected internal void DetachObject(uint objectLocalID, IClientAPI remoteClient)
318 { 318 {
319 List<EntityBase> EntityList = GetEntities(); 319 List<EntityBase> EntityList = GetEntities();
@@ -340,9 +340,9 @@ namespace OpenSim.Region.Environment.Scenes
340 SceneObjectPart part = m_parentScene.GetSceneObjectPart(primId); 340 SceneObjectPart part = m_parentScene.GetSceneObjectPart(primId);
341 if (part != null) 341 if (part != null)
342 part.Undo(); 342 part.Undo();
343 } 343 }
344 } 344 }
345 345
346 protected internal void HandleObjectGroupUpdate( 346 protected internal void HandleObjectGroupUpdate(
347 IClientAPI remoteClient, LLUUID GroupID, uint objectLocalID, LLUUID Garbage) 347 IClientAPI remoteClient, LLUUID GroupID, uint objectLocalID, LLUUID Garbage)
348 { 348 {
@@ -360,12 +360,11 @@ namespace OpenSim.Region.Environment.Scenes
360 group.SetGroup(GroupID, remoteClient); 360 group.SetGroup(GroupID, remoteClient);
361 else 361 else
362 remoteClient.SendAgentAlertMessage("You don't have permission to set the group", false); 362 remoteClient.SendAgentAlertMessage("You don't have permission to set the group", false);
363
364 } 363 }
365 } 364 }
366 } 365 }
367 } 366 }
368 367
369 /// <summary> 368 /// <summary>
370 /// Event Handling routine for Attach Object 369 /// Event Handling routine for Attach Object
371 /// </summary> 370 /// </summary>
@@ -379,7 +378,7 @@ namespace OpenSim.Region.Environment.Scenes
379 378
380 AttachObject(remoteClient, objectLocalID, AttachmentPt, rot, LLVector3.Zero); 379 AttachObject(remoteClient, objectLocalID, AttachmentPt, rot, LLVector3.Zero);
381 } 380 }
382 381
383 protected internal void RezSingleAttachment( 382 protected internal void RezSingleAttachment(
384 IClientAPI remoteClient, LLUUID itemID, uint AttachmentPt,uint ItemFlags, uint NextOwnerMask) 383 IClientAPI remoteClient, LLUUID itemID, uint AttachmentPt,uint ItemFlags, uint NextOwnerMask)
385 { 384 {
@@ -492,7 +491,7 @@ namespace OpenSim.Region.Environment.Scenes
492 newAvatar.IsChildAgent = child; 491 newAvatar.IsChildAgent = child;
493 492
494 AddScenePresence(newAvatar); 493 AddScenePresence(newAvatar);
495 494
496 return newAvatar; 495 return newAvatar;
497 } 496 }
498 497
@@ -528,7 +527,7 @@ namespace OpenSim.Region.Environment.Scenes
528 ScenePresences[presence.UUID] = presence; 527 ScenePresences[presence.UUID] = presence;
529 } 528 }
530 } 529 }
531 530
532 /// <summary> 531 /// <summary>
533 /// Remove a presence from the scene 532 /// Remove a presence from the scene
534 /// </summary> 533 /// </summary>
@@ -545,9 +544,9 @@ namespace OpenSim.Region.Environment.Scenes
545 m_log.WarnFormat("[SCENE] Tried to remove non-existent scene presence with agent ID {0} from scene Entities list", agentID); 544 m_log.WarnFormat("[SCENE] Tried to remove non-existent scene presence with agent ID {0} from scene Entities list", agentID);
546 } 545 }
547 } 546 }
548 547
549 lock (ScenePresences) 548 lock (ScenePresences)
550 { 549 {
551 if (ScenePresences.Remove(agentID)) 550 if (ScenePresences.Remove(agentID))
552 { 551 {
553 //m_log.InfoFormat("[SCENE] Removed scene presence {0}", agentID); 552 //m_log.InfoFormat("[SCENE] Removed scene presence {0}", agentID);
@@ -556,7 +555,7 @@ namespace OpenSim.Region.Environment.Scenes
556 { 555 {
557 m_log.WarnFormat("[SCENE] Tried to remove non-existent scene presence with agent ID {0} from scene ScenePresences list", agentID); 556 m_log.WarnFormat("[SCENE] Tried to remove non-existent scene presence with agent ID {0} from scene ScenePresences list", agentID);
558 } 557 }
559 } 558 }
560 } 559 }
561 560
562 protected internal void SwapRootChildAgent(bool direction_RC_CR_T_F) 561 protected internal void SwapRootChildAgent(bool direction_RC_CR_T_F)
@@ -622,7 +621,7 @@ namespace OpenSim.Region.Environment.Scenes
622 m_scriptLPS = 0; 621 m_scriptLPS = 0;
623 return returnval; 622 return returnval;
624 } 623 }
625 624
626 #endregion 625 #endregion
627 626
628 #region Get Methods 627 #region Get Methods
@@ -863,7 +862,6 @@ namespace OpenSim.Region.Environment.Scenes
863 { 862 {
864 break; 863 break;
865 } 864 }
866
867 } 865 }
868 grp.scriptScore = 0; 866 grp.scriptScore = 0;
869 } 867 }
@@ -964,7 +962,7 @@ namespace OpenSim.Region.Environment.Scenes
964 } 962 }
965 } 963 }
966 } 964 }
967 965
968 protected internal void UpdatePrimGroupScale(uint localID, LLVector3 scale, IClientAPI remoteClient) 966 protected internal void UpdatePrimGroupScale(uint localID, LLVector3 scale, IClientAPI remoteClient)
969 { 967 {
970 SceneObjectGroup group = GetGroupByPrim(localID); 968 SceneObjectGroup group = GetGroupByPrim(localID);
diff --git a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs
index 5e7fd98..f5cb0b9 100644
--- a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs
+++ b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs
@@ -62,7 +62,7 @@ namespace OpenSim.Region.Environment.Scenes
62 public void AddUploadedInventoryItem(LLUUID agentID, InventoryItemBase item) 62 public void AddUploadedInventoryItem(LLUUID agentID, InventoryItemBase item)
63 { 63 {
64 IMoneyModule money=RequestModuleInterface<IMoneyModule>(); 64 IMoneyModule money=RequestModuleInterface<IMoneyModule>();
65 if(money != null) 65 if (money != null)
66 { 66 {
67 money.ApplyUploadCharge(agentID); 67 money.ApplyUploadCharge(agentID);
68 } 68 }
@@ -930,7 +930,7 @@ namespace OpenSim.Region.Environment.Scenes
930 if (part != null) 930 if (part != null)
931 { 931 {
932 TaskInventoryItem currentItem=part.GetInventoryItem(itemID); 932 TaskInventoryItem currentItem=part.GetInventoryItem(itemID);
933 if(currentItem == null) 933 if (currentItem == null)
934 { 934 {
935 LLUUID copyID = LLUUID.Random(); 935 LLUUID copyID = LLUUID.Random();
936 if (itemID != LLUUID.Zero) 936 if (itemID != LLUUID.Zero)
@@ -972,9 +972,9 @@ namespace OpenSim.Region.Environment.Scenes
972 } 972 }
973 else // Updating existing item with new perms etc 973 else // Updating existing item with new perms etc
974 { 974 {
975 TaskInventoryItem prevItem=part.GetInventoryItem(itemID); 975 TaskInventoryItem prevItem=part.GetInventoryItem(itemID);
976 itemInfo.AssetID = prevItem.AssetID; 976 itemInfo.AssetID = prevItem.AssetID;
977 if(part.UpdateInventoryItem(itemInfo)) 977 if (part.UpdateInventoryItem(itemInfo))
978 part.GetProperties(remoteClient); 978 part.GetProperties(remoteClient);
979 } 979 }
980 } 980 }
diff --git a/OpenSim/Region/Environment/Scenes/Scene.PacketHandlers.cs b/OpenSim/Region/Environment/Scenes/Scene.PacketHandlers.cs
index 41bd2d3..f5fe561 100644
--- a/OpenSim/Region/Environment/Scenes/Scene.PacketHandlers.cs
+++ b/OpenSim/Region/Environment/Scenes/Scene.PacketHandlers.cs
@@ -63,9 +63,9 @@ namespace OpenSim.Region.Environment.Scenes
63 63
64 if (broadcast) 64 if (broadcast)
65 EventManager.TriggerOnChatBroadcast(this, args); 65 EventManager.TriggerOnChatBroadcast(this, args);
66 else 66 else
67 EventManager.TriggerOnChatFromWorld(this, args); 67 EventManager.TriggerOnChatFromWorld(this, args);
68 68
69 } 69 }
70 /// <summary> 70 /// <summary>
71 /// 71 ///
@@ -293,7 +293,7 @@ namespace OpenSim.Region.Environment.Scenes
293 LLUUID itemID) 293 LLUUID itemID)
294 { 294 {
295 SceneObjectPart part=GetSceneObjectPart(objectID); 295 SceneObjectPart part=GetSceneObjectPart(objectID);
296 if(part == null) 296 if (part == null)
297 return; 297 return;
298 EventManager.TriggerScriptReset(part.LocalId, itemID); 298 EventManager.TriggerScriptReset(part.LocalId, itemID);
299 } 299 }
diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs
index c9f23af..1be0617 100644
--- a/OpenSim/Region/Environment/Scenes/Scene.cs
+++ b/OpenSim/Region/Environment/Scenes/Scene.cs
@@ -199,9 +199,9 @@ namespace OpenSim.Region.Environment.Scenes
199 /// <summary> 199 /// <summary>
200 /// The dictionary of all entities in this scene. The contents of this dictionary may be changed at any time. 200 /// The dictionary of all entities in this scene. The contents of this dictionary may be changed at any time.
201 /// If you wish to add or remove entities, please use the appropriate method for that entity rather than 201 /// If you wish to add or remove entities, please use the appropriate method for that entity rather than
202 /// editing this dictionary directly. 202 /// editing this dictionary directly.
203 /// 203 ///
204 /// If you want a list of entities where the list itself is guaranteed not to change, please use 204 /// If you want a list of entities where the list itself is guaranteed not to change, please use
205 /// GetEntities() 205 /// GetEntities()
206 /// </summary> 206 /// </summary>
207 public Dictionary<LLUUID, EntityBase> Entities 207 public Dictionary<LLUUID, EntityBase> Entities
@@ -565,19 +565,19 @@ namespace OpenSim.Region.Environment.Scenes
565 m_scripts_enabled = !ScriptEngine; 565 m_scripts_enabled = !ScriptEngine;
566 m_log.Info("[TOTEDD]: Here is the method to trigger disabling of the scripting engine"); 566 m_log.Info("[TOTEDD]: Here is the method to trigger disabling of the scripting engine");
567 } 567 }
568 568
569 if (m_physics_enabled != !PhysicsEngine) 569 if (m_physics_enabled != !PhysicsEngine)
570 { 570 {
571 m_physics_enabled = !PhysicsEngine; 571 m_physics_enabled = !PhysicsEngine;
572 } 572 }
573 } 573 }
574 574
575 public int GetInaccurateNeighborCount() 575 public int GetInaccurateNeighborCount()
576 { 576 {
577 lock (m_neighbours) 577 lock (m_neighbours)
578 return m_neighbours.Count; 578 return m_neighbours.Count;
579 } 579 }
580 580
581 // This is the method that shuts down the scene. 581 // This is the method that shuts down the scene.
582 public override void Close() 582 public override void Close()
583 { 583 {
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs b/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs
index a4ca33d..4610c99 100644
--- a/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs
+++ b/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs
@@ -2100,26 +2100,26 @@ namespace OpenSim.Region.Environment.Scenes
2100 /// <param name="pos"></param> 2100 /// <param name="pos"></param>
2101 public void UpdateOffSet(LLVector3 pos) 2101 public void UpdateOffSet(LLVector3 pos)
2102 { 2102 {
2103 if ((pos.X != OffsetPosition.X) || 2103 if ((pos.X != OffsetPosition.X) ||
2104 (pos.Y != OffsetPosition.Y) || 2104 (pos.Y != OffsetPosition.Y) ||
2105 (pos.Z != OffsetPosition.Z)) 2105 (pos.Z != OffsetPosition.Z))
2106 { 2106 {
2107 LLVector3 newPos = new LLVector3(pos.X, pos.Y, pos.Z); 2107 LLVector3 newPos = new LLVector3(pos.X, pos.Y, pos.Z);
2108 OffsetPosition = newPos; 2108 OffsetPosition = newPos;
2109 ScheduleTerseUpdate(); 2109 ScheduleTerseUpdate();
2110 } 2110 }
2111 } 2111 }
2112 2112
2113 public void UpdateGroupPosition(LLVector3 pos) 2113 public void UpdateGroupPosition(LLVector3 pos)
2114 { 2114 {
2115 if ((pos.X != GroupPosition.X) || 2115 if ((pos.X != GroupPosition.X) ||
2116 (pos.Y != GroupPosition.Y) || 2116 (pos.Y != GroupPosition.Y) ||
2117 (pos.Z != GroupPosition.Z)) 2117 (pos.Z != GroupPosition.Z))
2118 { 2118 {
2119 LLVector3 newPos = new LLVector3(pos.X, pos.Y, pos.Z); 2119 LLVector3 newPos = new LLVector3(pos.X, pos.Y, pos.Z);
2120 GroupPosition = newPos; 2120 GroupPosition = newPos;
2121 ScheduleTerseUpdate(); 2121 ScheduleTerseUpdate();
2122 } 2122 }
2123 } 2123 }
2124 2124
2125 #endregion 2125 #endregion
@@ -2128,15 +2128,15 @@ namespace OpenSim.Region.Environment.Scenes
2128 2128
2129 public void UpdateRotation(LLQuaternion rot) 2129 public void UpdateRotation(LLQuaternion rot)
2130 { 2130 {
2131 if ((rot.X != RotationOffset.X) || 2131 if ((rot.X != RotationOffset.X) ||
2132 (rot.Y != RotationOffset.Y) || 2132 (rot.Y != RotationOffset.Y) ||
2133 (rot.Z != RotationOffset.Z) || 2133 (rot.Z != RotationOffset.Z) ||
2134 (rot.W != RotationOffset.W)) 2134 (rot.W != RotationOffset.W))
2135 { 2135 {
2136 //StoreUndoState(); 2136 //StoreUndoState();
2137 RotationOffset = new LLQuaternion(rot.X, rot.Y, rot.Z, rot.W); 2137 RotationOffset = new LLQuaternion(rot.X, rot.Y, rot.Z, rot.W);
2138 ScheduleTerseUpdate(); 2138 ScheduleTerseUpdate();
2139 } 2139 }
2140 } 2140 }
2141 2141
2142 #endregion 2142 #endregion
diff --git a/OpenSim/Region/Environment/Scenes/ScenePresence.cs b/OpenSim/Region/Environment/Scenes/ScenePresence.cs
index 396d752..dfefe24 100644
--- a/OpenSim/Region/Environment/Scenes/ScenePresence.cs
+++ b/OpenSim/Region/Environment/Scenes/ScenePresence.cs
@@ -1407,9 +1407,9 @@ namespace OpenSim.Region.Environment.Scenes
1407 if (remoteAvatar == null) 1407 if (remoteAvatar == null)
1408 return; 1408 return;
1409 IClientAPI cl=remoteAvatar.ControllingClient; 1409 IClientAPI cl=remoteAvatar.ControllingClient;
1410 if(cl == null) 1410 if (cl == null)
1411 return; 1411 return;
1412 if(m_appearance.Texture == null) 1412 if (m_appearance.Texture == null)
1413 return; 1413 return;
1414 1414
1415 remoteAvatar.m_controllingClient.SendAvatarData(m_regionInfo.RegionHandle, m_firstname, m_lastname, m_uuid, 1415 remoteAvatar.m_controllingClient.SendAvatarData(m_regionInfo.RegionHandle, m_firstname, m_lastname, m_uuid,