aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Scenes
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Environment/Scenes')
-rw-r--r--OpenSim/Region/Environment/Scenes/AllNewSceneObjectGroup2.cs76
-rw-r--r--OpenSim/Region/Environment/Scenes/AllNewSceneObjectPart2.cs35
-rw-r--r--OpenSim/Region/Environment/Scenes/Scene.cs1
3 files changed, 107 insertions, 5 deletions
diff --git a/OpenSim/Region/Environment/Scenes/AllNewSceneObjectGroup2.cs b/OpenSim/Region/Environment/Scenes/AllNewSceneObjectGroup2.cs
index b0fe12a..9d9c97b 100644
--- a/OpenSim/Region/Environment/Scenes/AllNewSceneObjectGroup2.cs
+++ b/OpenSim/Region/Environment/Scenes/AllNewSceneObjectGroup2.cs
@@ -47,6 +47,14 @@ namespace OpenSim.Region.Environment.Scenes
47 /// <summary> 47 /// <summary>
48 /// 48 ///
49 /// </summary> 49 /// </summary>
50 public AllNewSceneObjectGroup2()
51 {
52
53 }
54
55 /// <summary>
56 ///
57 /// </summary>
50 public AllNewSceneObjectGroup2(Scene world, ulong regionHandle, LLUUID ownerID, uint localID, LLVector3 pos, PrimitiveBaseShape shape) 58 public AllNewSceneObjectGroup2(Scene world, ulong regionHandle, LLUUID ownerID, uint localID, LLVector3 pos, PrimitiveBaseShape shape)
51 { 59 {
52 m_regionHandle = regionHandle; 60 m_regionHandle = regionHandle;
@@ -62,7 +70,70 @@ namespace OpenSim.Region.Environment.Scenes
62 /// <summary> 70 /// <summary>
63 /// 71 ///
64 /// </summary> 72 /// </summary>
65 public void FlagGroupForFullUpdate() 73 /// <returns></returns>
74 public new AllNewSceneObjectGroup2 Copy()
75 {
76 AllNewSceneObjectGroup2 dupe = (AllNewSceneObjectGroup2) this.MemberwiseClone();
77 dupe.Pos = new LLVector3(Pos.X, Pos.Y, Pos.Z);
78 dupe.CopyRootPart(this.m_rootPart);
79
80 foreach (AllNewSceneObjectPart2 part in this.m_parts.Values)
81 {
82 if (part.UUID != this.m_rootPart.UUID)
83 {
84 dupe.CopyPart(part);
85 }
86 }
87 return dupe;
88 }
89
90 public void CopyRootPart(AllNewSceneObjectPart2 part)
91 {
92
93 }
94
95 public void CopyPart(AllNewSceneObjectPart2 part)
96 {
97
98 }
99
100 /// <summary>
101 ///
102 /// </summary>
103 public override void Update()
104 {
105 foreach (AllNewSceneObjectPart2 part in this.m_parts.Values)
106 {
107 part.SendScheduledUpdates();
108 }
109 }
110
111 /// <summary>
112 ///
113 /// </summary>
114 public void ScheduleGroupForFullUpdate()
115 {
116 foreach (AllNewSceneObjectPart2 part in this.m_parts.Values)
117 {
118 part.ScheduleFullUpdate();
119 }
120 }
121
122 /// <summary>
123 ///
124 /// </summary>
125 public void ScheduleGroupForTerseUpdate()
126 {
127 foreach (AllNewSceneObjectPart2 part in this.m_parts.Values)
128 {
129 part.ScheduleTerseUpdate();
130 }
131 }
132
133 /// <summary>
134 ///
135 /// </summary>
136 public void ScheduleGroupFullUpdate()
66 { 137 {
67 foreach (AllNewSceneObjectPart2 part in this.m_parts.Values) 138 foreach (AllNewSceneObjectPart2 part in this.m_parts.Values)
68 { 139 {
@@ -73,7 +144,7 @@ namespace OpenSim.Region.Environment.Scenes
73 /// <summary> 144 /// <summary>
74 /// 145 ///
75 /// </summary> 146 /// </summary>
76 public void FlagGroupForTerseUpdate() 147 public void SendGroupTerseUpdate()
77 { 148 {
78 foreach (AllNewSceneObjectPart2 part in this.m_parts.Values) 149 foreach (AllNewSceneObjectPart2 part in this.m_parts.Values)
79 { 150 {
@@ -177,6 +248,7 @@ namespace OpenSim.Region.Environment.Scenes
177 public void GrapMovement(LLVector3 offset, LLVector3 pos, IClientAPI remoteClient) 248 public void GrapMovement(LLVector3 offset, LLVector3 pos, IClientAPI remoteClient)
178 { 249 {
179 this.Pos = pos; 250 this.Pos = pos;
251 this.m_rootPart.SendTerseUpdateToALLClients();
180 } 252 }
181 253
182 /// <summary> 254 /// <summary>
diff --git a/OpenSim/Region/Environment/Scenes/AllNewSceneObjectPart2.cs b/OpenSim/Region/Environment/Scenes/AllNewSceneObjectPart2.cs
index b0303a3..813f2e1 100644
--- a/OpenSim/Region/Environment/Scenes/AllNewSceneObjectPart2.cs
+++ b/OpenSim/Region/Environment/Scenes/AllNewSceneObjectPart2.cs
@@ -253,6 +253,14 @@ namespace OpenSim.Region.Environment.Scenes
253 253
254 #region Constructors 254 #region Constructors
255 /// <summary> 255 /// <summary>
256 ///
257 /// </summary>
258 public AllNewSceneObjectPart2()
259 {
260
261 }
262
263 /// <summary>
256 /// Create a completely new SceneObjectPart (prim) 264 /// Create a completely new SceneObjectPart (prim)
257 /// </summary> 265 /// </summary>
258 /// <param name="regionHandle"></param> 266 /// <param name="regionHandle"></param>
@@ -315,6 +323,29 @@ namespace OpenSim.Region.Environment.Scenes
315 } 323 }
316 #endregion 324 #endregion
317 325
326 #region Copying
327 /// <summary>
328 ///
329 /// </summary>
330 /// <returns></returns>
331 public AllNewSceneObjectPart2 Copy(Scene scene)
332 {
333 AllNewSceneObjectPart2 dupe =(AllNewSceneObjectPart2) this.MemberwiseClone();
334 dupe.m_Shape = m_Shape.Copy();
335 dupe.m_regionHandle = m_regionHandle;
336 uint newLocalID = scene.PrimIDAllocate();
337 dupe.UUID = LLUUID.Random();
338 dupe.LocalID = newLocalID;
339 dupe.OffsetPosition = new LLVector3(OffsetPosition.X, OffsetPosition.Y, OffsetPosition.Z);
340 dupe.RotationOffset = new LLQuaternion(RotationOffset.X, RotationOffset.Y, RotationOffset.Z, RotationOffset.W);
341 dupe.Velocity = new LLVector3(0, 0, 0);
342 dupe.Acceleration = new LLVector3(0, 0, 0);
343 dupe.AngularVelocity = new LLVector3(0, 0, 0);
344 dupe.ObjectFlags = this.ObjectFlags;
345 return dupe;
346 }
347 #endregion
348
318 #region Update Scheduling 349 #region Update Scheduling
319 /// <summary> 350 /// <summary>
320 /// 351 ///
@@ -327,7 +358,7 @@ namespace OpenSim.Region.Environment.Scenes
327 /// <summary> 358 /// <summary>
328 /// 359 ///
329 /// </summary> 360 /// </summary>
330 private void ScheduleFullUpdate() 361 public void ScheduleFullUpdate()
331 { 362 {
332 m_updateFlag = 2; 363 m_updateFlag = 2;
333 } 364 }
@@ -335,7 +366,7 @@ namespace OpenSim.Region.Environment.Scenes
335 /// <summary> 366 /// <summary>
336 /// 367 ///
337 /// </summary> 368 /// </summary>
338 private void ScheduleTerseUpdate() 369 public void ScheduleTerseUpdate()
339 { 370 {
340 if (m_updateFlag < 1) 371 if (m_updateFlag < 1)
341 { 372 {
diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs
index f9fbe87..56e5a0a 100644
--- a/OpenSim/Region/Environment/Scenes/Scene.cs
+++ b/OpenSim/Region/Environment/Scenes/Scene.cs
@@ -582,7 +582,6 @@ namespace OpenSim.Region.Environment.Scenes
582 client.OnObjectName += PrimName; 582 client.OnObjectName += PrimName;
583 client.OnLinkObjects += LinkObjects; 583 client.OnLinkObjects += LinkObjects;
584 client.OnObjectDuplicate += DuplicateObject; 584 client.OnObjectDuplicate += DuplicateObject;
585 client.OnModifyTerrain += ModifyTerrain;
586 585
587 client.OnParcelPropertiesRequest += new ParcelPropertiesRequest(m_LandManager.handleParcelPropertiesRequest); 586 client.OnParcelPropertiesRequest += new ParcelPropertiesRequest(m_LandManager.handleParcelPropertiesRequest);
588 client.OnParcelDivideRequest += new ParcelDivideRequest(m_LandManager.handleParcelDivideRequest); 587 client.OnParcelDivideRequest += new ParcelDivideRequest(m_LandManager.handleParcelDivideRequest);