aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Scenes
diff options
context:
space:
mode:
authorJustin Clarke Casey2008-05-24 22:45:13 +0000
committerJustin Clarke Casey2008-05-24 22:45:13 +0000
commitf3067ce6f9f2ea992f0e601ab120f3a1ff89cf94 (patch)
tree0ec2ccf815cba335f42b9a64f6a9cc18b0c78230 /OpenSim/Region/Environment/Scenes
parent* Refactor: Renaming various *Entity*() methods to *Object*() methods on the ... (diff)
downloadopensim-SC-f3067ce6f9f2ea992f0e601ab120f3a1ff89cf94.zip
opensim-SC-f3067ce6f9f2ea992f0e601ab120f3a1ff89cf94.tar.gz
opensim-SC-f3067ce6f9f2ea992f0e601ab120f3a1ff89cf94.tar.bz2
opensim-SC-f3067ce6f9f2ea992f0e601ab120f3a1ff89cf94.tar.xz
* Refactor: Change previous commits Object methods to SceneObject methods instead, on the basis that this is less likely to cause confusion with c#'s base object type
Diffstat (limited to 'OpenSim/Region/Environment/Scenes')
-rw-r--r--OpenSim/Region/Environment/Scenes/InnerScene.cs11
-rw-r--r--OpenSim/Region/Environment/Scenes/Scene.Inventory.cs4
-rw-r--r--OpenSim/Region/Environment/Scenes/Scene.cs16
-rw-r--r--OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs2
-rw-r--r--OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs4
5 files changed, 19 insertions, 18 deletions
diff --git a/OpenSim/Region/Environment/Scenes/InnerScene.cs b/OpenSim/Region/Environment/Scenes/InnerScene.cs
index 4088746..4885d6d 100644
--- a/OpenSim/Region/Environment/Scenes/InnerScene.cs
+++ b/OpenSim/Region/Environment/Scenes/InnerScene.cs
@@ -186,7 +186,7 @@ namespace OpenSim.Region.Environment.Scenes
186 /// Add an object into the scene that has come from storage 186 /// Add an object into the scene that has come from storage
187 /// </summary> 187 /// </summary>
188 /// <param name="sceneObject"></param> 188 /// <param name="sceneObject"></param>
189 public void AddObjectFromStorage(SceneObjectGroup sceneObject) 189 public void AddSceneObjectFromStorage(SceneObjectGroup sceneObject)
190 { 190 {
191 sceneObject.RegionHandle = m_regInfo.RegionHandle; 191 sceneObject.RegionHandle = m_regInfo.RegionHandle;
192 sceneObject.SetScene(m_parentScene); 192 sceneObject.SetScene(m_parentScene);
@@ -197,18 +197,18 @@ namespace OpenSim.Region.Environment.Scenes
197 } 197 }
198 sceneObject.UpdateParentIDs(); 198 sceneObject.UpdateParentIDs();
199 199
200 AddObject(sceneObject); 200 AddSceneObject(sceneObject);
201 } 201 }
202 202
203 /// <summary> 203 /// <summary>
204 /// Add an object to the scene. 204 /// Add an object to the scene.
205 /// </summary> 205 /// </summary>
206 /// <param name="sceneObject"></param> 206 /// <param name="sceneObject"></param>
207 public void AddObject(SceneObjectGroup sceneObject) 207 public void AddSceneObject(SceneObjectGroup sceneObject)
208 { 208 {
209 if (!Entities.ContainsKey(sceneObject.UUID)) 209 if (!Entities.ContainsKey(sceneObject.UUID))
210 { 210 {
211 // QuadTree.AddObject(sceneObject); 211 // QuadTree.AddSceneObject(sceneObject);
212 lock (Entities) 212 lock (Entities)
213 { 213 {
214 Entities.Add(sceneObject.UUID, sceneObject); 214 Entities.Add(sceneObject.UUID, sceneObject);
@@ -299,7 +299,7 @@ namespace OpenSim.Region.Environment.Scenes
299 { 299 {
300 if (m_parentScene.ExternalChecks.ExternalChecksCanDeleteObject(((SceneObjectGroup)obj).UUID, avatar_deleter)) 300 if (m_parentScene.ExternalChecks.ExternalChecksCanDeleteObject(((SceneObjectGroup)obj).UUID, avatar_deleter))
301 { 301 {
302 m_parentScene.RemoveObject((SceneObjectGroup)obj); 302 m_parentScene.RemoveSceneObject((SceneObjectGroup)obj);
303 m_numPrim--; 303 m_numPrim--;
304 } 304 }
305 return; 305 return;
@@ -307,6 +307,7 @@ namespace OpenSim.Region.Environment.Scenes
307 } 307 }
308 } 308 }
309 } 309 }
310
310 public void DetachObject(uint objectLocalID, IClientAPI remoteClient) 311 public void DetachObject(uint objectLocalID, IClientAPI remoteClient)
311 { 312 {
312 List<EntityBase> EntityList = GetEntities(); 313 List<EntityBase> EntityList = GetEntities();
diff --git a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs
index 81ab733..816b01d 100644
--- a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs
+++ b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs
@@ -1502,7 +1502,7 @@ namespace OpenSim.Region.Environment.Scenes
1502 1502
1503 group.ResetIDs(); 1503 group.ResetIDs();
1504 1504
1505 AddObject(group); 1505 AddSceneObject(group);
1506 1506
1507 // if attachment we set it's asset id so object updates can reflect that 1507 // if attachment we set it's asset id so object updates can reflect that
1508 // if not, we set it's position in world. 1508 // if not, we set it's position in world.
@@ -1614,7 +1614,7 @@ namespace OpenSim.Region.Environment.Scenes
1614 } 1614 }
1615 group.ResetIDs(); 1615 group.ResetIDs();
1616 1616
1617 AddObject(group); 1617 AddSceneObject(group);
1618 1618
1619 // Set the startup parameter for on_rez event and llGetStartParameter() function 1619 // Set the startup parameter for on_rez event and llGetStartParameter() function
1620 group.StartParameter = param; 1620 group.StartParameter = param;
diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs
index 5912c51..e3f219f 100644
--- a/OpenSim/Region/Environment/Scenes/Scene.cs
+++ b/OpenSim/Region/Environment/Scenes/Scene.cs
@@ -1163,7 +1163,7 @@ namespace OpenSim.Region.Environment.Scenes
1163 List<SceneObjectGroup> PrimsFromDB = m_storageManager.DataStore.LoadObjects(regionID); 1163 List<SceneObjectGroup> PrimsFromDB = m_storageManager.DataStore.LoadObjects(regionID);
1164 foreach (SceneObjectGroup group in PrimsFromDB) 1164 foreach (SceneObjectGroup group in PrimsFromDB)
1165 { 1165 {
1166 AddObjectFromStorage(group); 1166 AddSceneObjectFromStorage(group);
1167 SceneObjectPart rootPart = group.GetChildPart(group.UUID); 1167 SceneObjectPart rootPart = group.GetChildPart(group.UUID);
1168 rootPart.ObjectFlags &= ~(uint)LLObject.ObjectFlags.Scripted; 1168 rootPart.ObjectFlags &= ~(uint)LLObject.ObjectFlags.Scripted;
1169 rootPart.TrimPermissions(); 1169 rootPart.TrimPermissions();
@@ -1290,7 +1290,7 @@ namespace OpenSim.Region.Environment.Scenes
1290 { 1290 {
1291 SceneObjectGroup sceneOb = 1291 SceneObjectGroup sceneOb =
1292 new SceneObjectGroup(this, m_regionHandle, ownerID, PrimIDAllocate(), pos, rot, shape); 1292 new SceneObjectGroup(this, m_regionHandle, ownerID, PrimIDAllocate(), pos, rot, shape);
1293 AddObject(sceneOb); 1293 AddSceneObject(sceneOb);
1294 SceneObjectPart rootPart = sceneOb.GetChildPart(sceneOb.UUID); 1294 SceneObjectPart rootPart = sceneOb.GetChildPart(sceneOb.UUID);
1295 // if grass or tree, make phantom 1295 // if grass or tree, make phantom
1296 //rootPart.TrimPermissions(); 1296 //rootPart.TrimPermissions();
@@ -1328,25 +1328,25 @@ namespace OpenSim.Region.Environment.Scenes
1328 /// Add an object into the scene that has come from storage 1328 /// Add an object into the scene that has come from storage
1329 /// </summary> 1329 /// </summary>
1330 /// <param name="sceneObject"></param> 1330 /// <param name="sceneObject"></param>
1331 public void AddObjectFromStorage(SceneObjectGroup sceneObject) 1331 public void AddSceneObjectFromStorage(SceneObjectGroup sceneObject)
1332 { 1332 {
1333 m_innerScene.AddObjectFromStorage(sceneObject); 1333 m_innerScene.AddSceneObjectFromStorage(sceneObject);
1334 } 1334 }
1335 1335
1336 /// <summary> 1336 /// <summary>
1337 /// Add an object to the scene 1337 /// Add an object to the scene
1338 /// </summary> 1338 /// </summary>
1339 /// <param name="sceneObject"></param> 1339 /// <param name="sceneObject"></param>
1340 public void AddObject(SceneObjectGroup sceneObject) 1340 public void AddSceneObject(SceneObjectGroup sceneObject)
1341 { 1341 {
1342 m_innerScene.AddObject(sceneObject); 1342 m_innerScene.AddSceneObject(sceneObject);
1343 } 1343 }
1344 1344
1345 /// <summary> 1345 /// <summary>
1346 /// Remove an object from the scene 1346 /// Remove an object from the scene
1347 /// </summary> 1347 /// </summary>
1348 /// <param name="sceneObject"></param> 1348 /// <param name="sceneObject"></param>
1349 public void RemoveObject(SceneObjectGroup sceneObject) 1349 public void RemoveSceneObject(SceneObjectGroup sceneObject)
1350 { 1350 {
1351 if (Entities.ContainsKey(sceneObject.UUID)) 1351 if (Entities.ContainsKey(sceneObject.UUID))
1352 { 1352 {
@@ -3164,7 +3164,7 @@ namespace OpenSim.Region.Environment.Scenes
3164 3164
3165 lock (Entities) 3165 lock (Entities)
3166 { 3166 {
3167 RemoveObject(group); 3167 RemoveSceneObject(group);
3168 } 3168 }
3169 group.DeleteParts(); 3169 group.DeleteParts();
3170 3170
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs
index 935253f..f4e1ef4 100644
--- a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs
+++ b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs
@@ -1841,7 +1841,7 @@ namespace OpenSim.Region.Environment.Scenes
1841 1841
1842 SceneObjectGroup objectGroup = new SceneObjectGroup(m_scene, m_regionHandle, linkPart); 1842 SceneObjectGroup objectGroup = new SceneObjectGroup(m_scene, m_regionHandle, linkPart);
1843 1843
1844 m_scene.AddObject(objectGroup); 1844 m_scene.AddSceneObject(objectGroup);
1845 1845
1846 ScheduleGroupForFullUpdate(); 1846 ScheduleGroupForFullUpdate();
1847 } 1847 }
diff --git a/OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs b/OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs
index 13483bb..742996e 100644
--- a/OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs
+++ b/OpenSim/Region/Environment/Scenes/SceneXmlLoader.cs
@@ -72,7 +72,7 @@ namespace OpenSim.Region.Environment.Scenes
72 //if we want this to be a import method then we need new uuids for the object to avoid any clashes 72 //if we want this to be a import method then we need new uuids for the object to avoid any clashes
73 //obj.RegenerateFullIDs(); 73 //obj.RegenerateFullIDs();
74 74
75 m_innerScene.AddObject(obj); 75 m_innerScene.AddSceneObject(obj);
76 76
77 SceneObjectPart rootPart = obj.GetChildPart(obj.UUID); 77 SceneObjectPart rootPart = obj.GetChildPart(obj.UUID);
78 // Apply loadOffsets for load/import and move combinations 78 // Apply loadOffsets for load/import and move combinations
@@ -184,7 +184,7 @@ namespace OpenSim.Region.Environment.Scenes
184 SceneObjectGroup obj = new SceneObjectGroup(xmlData); 184 SceneObjectGroup obj = new SceneObjectGroup(xmlData);
185 LLVector3 receivedVelocity = obj.RootPart.Velocity; 185 LLVector3 receivedVelocity = obj.RootPart.Velocity;
186 //System.Console.WriteLine(obj.RootPart.Velocity.ToString()); 186 //System.Console.WriteLine(obj.RootPart.Velocity.ToString());
187 m_innerScene.AddObjectFromStorage(obj); 187 m_innerScene.AddSceneObjectFromStorage(obj);
188 188
189 SceneObjectPart rootPart = obj.GetChildPart(obj.UUID); 189 SceneObjectPart rootPart = obj.GetChildPart(obj.UUID);
190 bool UsePhysics = (((rootPart.GetEffectiveObjectFlags() & (uint) LLObject.ObjectFlags.Physics) > 0) && 190 bool UsePhysics = (((rootPart.GetEffectiveObjectFlags() & (uint) LLObject.ObjectFlags.Physics) > 0) &&