aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Modules/ContentManagementSystem/CMModel.cs
diff options
context:
space:
mode:
authorTeravus Ovares2008-09-06 07:52:41 +0000
committerTeravus Ovares2008-09-06 07:52:41 +0000
commit7d89e122930be39e84a6d174548fa2d12ac0484a (patch)
treee5aa5752f988a9aba2a969f49e5e208985eda80c /OpenSim/Region/Environment/Modules/ContentManagementSystem/CMModel.cs
parent* minor: speculatively try a change to bamboo.build to see if this generates ... (diff)
downloadopensim-SC-7d89e122930be39e84a6d174548fa2d12ac0484a.zip
opensim-SC-7d89e122930be39e84a6d174548fa2d12ac0484a.tar.gz
opensim-SC-7d89e122930be39e84a6d174548fa2d12ac0484a.tar.bz2
opensim-SC-7d89e122930be39e84a6d174548fa2d12ac0484a.tar.xz
* This is the fabled LibOMV update with all of the libOMV types from JHurliman
* This is a HUGE OMG update and will definitely have unknown side effects.. so this is really only for the strong hearted at this point. Regular people should let the dust settle. * This has been tested to work with most basic functions. However.. make sure you back up 'everything' before using this. It's that big! * Essentially we're back at square 1 in the testing phase.. so lets identify things that broke.
Diffstat (limited to 'OpenSim/Region/Environment/Modules/ContentManagementSystem/CMModel.cs')
-rw-r--r--OpenSim/Region/Environment/Modules/ContentManagementSystem/CMModel.cs20
1 files changed, 9 insertions, 11 deletions
diff --git a/OpenSim/Region/Environment/Modules/ContentManagementSystem/CMModel.cs b/OpenSim/Region/Environment/Modules/ContentManagementSystem/CMModel.cs
index 92ae0d7..e1b4129 100644
--- a/OpenSim/Region/Environment/Modules/ContentManagementSystem/CMModel.cs
+++ b/OpenSim/Region/Environment/Modules/ContentManagementSystem/CMModel.cs
@@ -39,7 +39,7 @@ using System.Collections;
39using System.Collections.Generic; 39using System.Collections.Generic;
40using System.Diagnostics; 40using System.Diagnostics;
41 41
42using libsecondlife; 42using OpenMetaverse;
43 43
44using OpenSim; 44using OpenSim;
45using OpenSim.Framework; 45using OpenSim.Framework;
@@ -49,8 +49,6 @@ using OpenSim.Region.Physics.Manager;
49 49
50using log4net; 50using log4net;
51 51
52using Axiom.Math;
53
54namespace OpenSim.Region.Environment.Modules.ContentManagement 52namespace OpenSim.Region.Environment.Modules.ContentManagement
55{ 53{
56 public class CMModel 54 public class CMModel
@@ -133,14 +131,14 @@ namespace OpenSim.Region.Environment.Modules.ContentManagement
133 m_MetaEntityCollection.ClearAll(); 131 m_MetaEntityCollection.ClearAll();
134 } 132 }
135 133
136 public ContentManagementEntity FindMetaEntityAffectedByUndo(LLUUID uuid) 134 public ContentManagementEntity FindMetaEntityAffectedByUndo(UUID uuid)
137 { 135 {
138 ContentManagementEntity ent = GetMetaGroupByPrim(uuid); 136 ContentManagementEntity ent = GetMetaGroupByPrim(uuid);
139 return ent; 137 return ent;
140 } 138 }
141 139
142 //-------------------------------- HELPERS --------------------------------------------------------------------// 140 //-------------------------------- HELPERS --------------------------------------------------------------------//
143 public ContentManagementEntity GetMetaGroupByPrim(LLUUID uuid) 141 public ContentManagementEntity GetMetaGroupByPrim(UUID uuid)
144 { 142 {
145 foreach (Object ent in m_MetaEntityCollection.Entities.Values) 143 foreach (Object ent in m_MetaEntityCollection.Entities.Values)
146 { 144 {
@@ -194,7 +192,7 @@ namespace OpenSim.Region.Environment.Modules.ContentManagement
194 SceneObjectGroup temp = null; 192 SceneObjectGroup temp = null;
195 System.Collections.Hashtable deleteListUUIDs = new Hashtable(); 193 System.Collections.Hashtable deleteListUUIDs = new Hashtable();
196// Dictionary<LLUUID, EntityBase> SearchList = new Dictionary<LLUUID,EntityBase>(); 194// Dictionary<LLUUID, EntityBase> SearchList = new Dictionary<LLUUID,EntityBase>();
197 Dictionary<LLUUID, EntityBase> ReplacementList = new Dictionary<LLUUID,EntityBase>(); 195 Dictionary<UUID, EntityBase> ReplacementList = new Dictionary<UUID,EntityBase>();
198 int revision = m_database.GetMostRecentRevision(scene.RegionInfo.RegionID); 196 int revision = m_database.GetMostRecentRevision(scene.RegionInfo.RegionID);
199// EntityBase[] searchArray; 197// EntityBase[] searchArray;
200 198
@@ -255,14 +253,14 @@ namespace OpenSim.Region.Environment.Modules.ContentManagement
255 break; 253 break;
256 } 254 }
257 255
258 foreach(LLUUID uuid in deleteListUUIDs.Keys) 256 foreach(UUID uuid in deleteListUUIDs.Keys)
259 { 257 {
260 try 258 try
261 { 259 {
262 // I thought that the DeleteGroup() function would handle all of this, but it doesn't. I'm not sure WHAT it handles. 260 // I thought that the DeleteGroup() function would handle all of this, but it doesn't. I'm not sure WHAT it handles.
263 ((SceneObjectGroup)scene.Entities[uuid]).DetachFromBackup((SceneObjectGroup)scene.Entities[uuid]); 261 ((SceneObjectGroup)scene.Entities[uuid]).DetachFromBackup((SceneObjectGroup)scene.Entities[uuid]);
264 scene.PhysicsScene.RemovePrim(((SceneObjectGroup)scene.Entities[uuid]).RootPart.PhysActor); 262 scene.PhysicsScene.RemovePrim(((SceneObjectGroup)scene.Entities[uuid]).RootPart.PhysActor);
265 scene.SendKillObject(scene.Entities[uuid].LocalId); 263 scene.SendKiPrimitive(scene.Entities[uuid].LocalId);
266 scene.m_innerScene.DeleteSceneObject(uuid, false); 264 scene.m_innerScene.DeleteSceneObject(uuid, false);
267 ((SceneObjectGroup)scene.Entities[uuid]).DeleteGroup(); 265 ((SceneObjectGroup)scene.Entities[uuid]).DeleteGroup();
268 } 266 }
@@ -284,7 +282,7 @@ namespace OpenSim.Region.Environment.Modules.ContentManagement
284 if (!(ent is SceneObjectGroup)) 282 if (!(ent is SceneObjectGroup))
285 continue; 283 continue;
286 284
287 if ((((SceneObjectGroup)ent).RootPart.GetEffectiveObjectFlags() & (uint) LLObject.ObjectFlags.Phantom) == 0) 285 if ((((SceneObjectGroup)ent).RootPart.GetEffectiveObjectFlags() & (uint) PrimFlags.Phantom) == 0)
288 ((SceneObjectGroup)ent).ApplyPhysics(true); 286 ((SceneObjectGroup)ent).ApplyPhysics(true);
289 ((SceneObjectGroup)ent).AttachToBackup(); 287 ((SceneObjectGroup)ent).AttachToBackup();
290 ((SceneObjectGroup)ent).HasGroupChanged = true; // If not true, then attaching to backup does nothing because no change is detected. 288 ((SceneObjectGroup)ent).HasGroupChanged = true; // If not true, then attaching to backup does nothing because no change is detected.
@@ -346,7 +344,7 @@ namespace OpenSim.Region.Environment.Modules.ContentManagement
346 { 344 {
347 if (m_MetaEntityCollection.Auras.ContainsKey(part.UUID)) 345 if (m_MetaEntityCollection.Auras.ContainsKey(part.UUID))
348 { 346 {
349 ((AuraMetaEntity)m_MetaEntityCollection.Auras[part.UUID]).SetAura(new LLVector3(0,254,0), part.Scale); 347 ((AuraMetaEntity)m_MetaEntityCollection.Auras[part.UUID]).SetAura(new Vector3(0,254,0), part.Scale);
350 ((AuraMetaEntity)m_MetaEntityCollection.Auras[part.UUID]).RootPart.GroupPosition = part.GetWorldPosition(); 348 ((AuraMetaEntity)m_MetaEntityCollection.Auras[part.UUID]).RootPart.GroupPosition = part.GetWorldPosition();
351 auraList.Add((AuraMetaEntity)m_MetaEntityCollection.Auras[part.UUID]); 349 auraList.Add((AuraMetaEntity)m_MetaEntityCollection.Auras[part.UUID]);
352 } 350 }
@@ -356,4 +354,4 @@ namespace OpenSim.Region.Environment.Modules.ContentManagement
356 354
357 #endregion Public Methods 355 #endregion Public Methods
358 } 356 }
359} \ No newline at end of file 357}