aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Scenes/InnerScene.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/InnerScene.cs')
-rw-r--r--OpenSim/Region/Environment/Scenes/InnerScene.cs117
1 files changed, 58 insertions, 59 deletions
diff --git a/OpenSim/Region/Environment/Scenes/InnerScene.cs b/OpenSim/Region/Environment/Scenes/InnerScene.cs
index 658478d..e61fb19 100644
--- a/OpenSim/Region/Environment/Scenes/InnerScene.cs
+++ b/OpenSim/Region/Environment/Scenes/InnerScene.cs
@@ -28,9 +28,8 @@
28using System; 28using System;
29using System.Collections.Generic; 29using System.Collections.Generic;
30using System.Reflection; 30using System.Reflection;
31using Axiom.Math; 31using OpenMetaverse;
32using libsecondlife; 32using OpenMetaverse.Packets;
33using libsecondlife.Packets;
34using log4net; 33using log4net;
35using OpenSim.Framework; 34using OpenSim.Framework;
36using OpenSim.Region.Environment.Types; 35using OpenSim.Region.Environment.Types;
@@ -53,11 +52,11 @@ namespace OpenSim.Region.Environment.Scenes
53 52
54 #region Fields 53 #region Fields
55 54
56 protected internal Dictionary<LLUUID, ScenePresence> ScenePresences = new Dictionary<LLUUID, ScenePresence>(); 55 protected internal Dictionary<UUID, ScenePresence> ScenePresences = new Dictionary<UUID, ScenePresence>();
57 // SceneObjects is not currently populated or used. 56 // SceneObjects is not currently populated or used.
58 //public Dictionary<LLUUID, SceneObjectGroup> SceneObjects; 57 //public Dictionary<UUID, SceneObjectGroup> SceneObjects;
59 protected internal Dictionary<LLUUID, EntityBase> Entities = new Dictionary<LLUUID, EntityBase>(); 58 protected internal Dictionary<UUID, EntityBase> Entities = new Dictionary<UUID, EntityBase>();
60 protected internal Dictionary<LLUUID, ScenePresence> RestorePresences = new Dictionary<LLUUID, ScenePresence>(); 59 protected internal Dictionary<UUID, ScenePresence> RestorePresences = new Dictionary<UUID, ScenePresence>();
61 60
62 protected internal BasicQuadTreeNode QuadTree; 61 protected internal BasicQuadTreeNode QuadTree;
63 62
@@ -276,7 +275,7 @@ namespace OpenSim.Region.Environment.Scenes
276 /// </summary> 275 /// </summary>
277 /// <param name="sceneObject"></param> 276 /// <param name="sceneObject"></param>
278 /// <returns>true if the object was deleted, false if there was no object to delete</returns> 277 /// <returns>true if the object was deleted, false if there was no object to delete</returns>
279 protected internal bool DeleteSceneObject(LLUUID uuid, bool resultOfObjectLinked) 278 protected internal bool DeleteSceneObject(UUID uuid, bool resultOfObjectLinked)
280 { 279 {
281 lock (Entities) 280 lock (Entities)
282 { 281 {
@@ -378,9 +377,9 @@ namespace OpenSim.Region.Environment.Scenes
378 } 377 }
379 } 378 }
380 379
381 protected internal void HandleUndo(IClientAPI remoteClient, LLUUID primId) 380 protected internal void HandleUndo(IClientAPI remoteClient, UUID primId)
382 { 381 {
383 if (primId != LLUUID.Zero) 382 if (primId != UUID.Zero)
384 { 383 {
385 SceneObjectPart part = m_parentScene.GetSceneObjectPart(primId); 384 SceneObjectPart part = m_parentScene.GetSceneObjectPart(primId);
386 if (part != null) 385 if (part != null)
@@ -389,7 +388,7 @@ namespace OpenSim.Region.Environment.Scenes
389 } 388 }
390 389
391 protected internal void HandleObjectGroupUpdate( 390 protected internal void HandleObjectGroupUpdate(
392 IClientAPI remoteClient, LLUUID GroupID, uint objectLocalID, LLUUID Garbage) 391 IClientAPI remoteClient, UUID GroupID, uint objectLocalID, UUID Garbage)
393 { 392 {
394 List<EntityBase> EntityList = GetEntities(); 393 List<EntityBase> EntityList = GetEntities();
395 394
@@ -417,17 +416,17 @@ namespace OpenSim.Region.Environment.Scenes
417 /// <param name="objectLocalID"></param> 416 /// <param name="objectLocalID"></param>
418 /// <param name="AttachmentPt"></param> 417 /// <param name="AttachmentPt"></param>
419 /// <param name="rot"></param> 418 /// <param name="rot"></param>
420 protected internal void AttachObject(IClientAPI remoteClient, uint objectLocalID, uint AttachmentPt, LLQuaternion rot) 419 protected internal void AttachObject(IClientAPI remoteClient, uint objectLocalID, uint AttachmentPt, Quaternion rot)
421 { 420 {
422 // Calls attach with a Zero position 421 // Calls attach with a Zero position
423 422
424 AttachObject(remoteClient, objectLocalID, AttachmentPt, rot, LLVector3.Zero); 423 AttachObject(remoteClient, objectLocalID, AttachmentPt, rot, Vector3.Zero);
425 } 424 }
426 425
427 public SceneObjectGroup RezSingleAttachment( 426 public SceneObjectGroup RezSingleAttachment(
428 IClientAPI remoteClient, LLUUID itemID, uint AttachmentPt,uint ItemFlags, uint NextOwnerMask) 427 IClientAPI remoteClient, UUID itemID, uint AttachmentPt,uint ItemFlags, uint NextOwnerMask)
429 { 428 {
430 SceneObjectGroup objatt = m_parentScene.RezObject(remoteClient, itemID, LLVector3.Zero, LLVector3.Zero, LLUUID.Zero, (byte)1, true, 429 SceneObjectGroup objatt = m_parentScene.RezObject(remoteClient, itemID, Vector3.Zero, Vector3.Zero, UUID.Zero, (byte)1, true,
431 (uint)(PermissionMask.Copy | PermissionMask.Move | PermissionMask.Modify | PermissionMask.Transfer), 430 (uint)(PermissionMask.Copy | PermissionMask.Move | PermissionMask.Modify | PermissionMask.Transfer),
432 (uint)(PermissionMask.Copy | PermissionMask.Move | PermissionMask.Modify | PermissionMask.Transfer), 431 (uint)(PermissionMask.Copy | PermissionMask.Move | PermissionMask.Modify | PermissionMask.Transfer),
433 (uint)(PermissionMask.Copy | PermissionMask.Move | PermissionMask.Modify | PermissionMask.Transfer), 432 (uint)(PermissionMask.Copy | PermissionMask.Move | PermissionMask.Modify | PermissionMask.Transfer),
@@ -435,17 +434,17 @@ namespace OpenSim.Region.Environment.Scenes
435 434
436 if (objatt != null) 435 if (objatt != null)
437 { 436 {
438 AttachObject(remoteClient,objatt.LocalId,AttachmentPt,new LLQuaternion(0,0,0,1),objatt.AbsolutePosition); 437 AttachObject(remoteClient, objatt.LocalId, AttachmentPt, Quaternion.Identity, objatt.AbsolutePosition);
439 objatt.ScheduleGroupForFullUpdate(); 438 objatt.ScheduleGroupForFullUpdate();
440 } 439 }
441 return objatt; 440 return objatt;
442 } 441 }
443 442
444 // What makes this method odd and unique is it tries to detach using an LLUUID.... Yay for standards. 443 // What makes this method odd and unique is it tries to detach using an UUID.... Yay for standards.
445 // To LocalId or LLUUID, *THAT* is the question. How now Brown LLUUID?? 444 // To LocalId or UUID, *THAT* is the question. How now Brown UUID??
446 public void DetachSingleAttachmentToInv(LLUUID itemID, IClientAPI remoteClient) 445 public void DetachSingleAttachmentToInv(UUID itemID, IClientAPI remoteClient)
447 { 446 {
448 if (itemID == LLUUID.Zero) // If this happened, someone made a mistake.... 447 if (itemID == UUID.Zero) // If this happened, someone made a mistake....
449 return; 448 return;
450 449
451 List<EntityBase> EntityList = GetEntities(); 450 List<EntityBase> EntityList = GetEntities();
@@ -467,7 +466,7 @@ namespace OpenSim.Region.Environment.Scenes
467 } 466 }
468 467
469 protected internal void AttachObject( 468 protected internal void AttachObject(
470 IClientAPI remoteClient, uint objectLocalID, uint AttachmentPt, LLQuaternion rot, LLVector3 attachPos) 469 IClientAPI remoteClient, uint objectLocalID, uint AttachmentPt, Quaternion rot, Vector3 attachPos)
471 { 470 {
472 List<EntityBase> EntityList = GetEntities(); 471 List<EntityBase> EntityList = GetEntities();
473 foreach (EntityBase obj in EntityList) 472 foreach (EntityBase obj in EntityList)
@@ -485,7 +484,7 @@ namespace OpenSim.Region.Environment.Scenes
485 if (AttachmentPt != 0 && AttachmentPt != (uint)group.GetAttachmentPoint()) 484 if (AttachmentPt != 0 && AttachmentPt != (uint)group.GetAttachmentPoint())
486 { 485 {
487 486
488 attachPos = LLVector3.Zero; 487 attachPos = Vector3.Zero;
489 } 488 }
490 489
491 // AttachmentPt 0 means the client chose to 'wear' the attachment. 490 // AttachmentPt 0 means the client chose to 'wear' the attachment.
@@ -503,16 +502,16 @@ namespace OpenSim.Region.Environment.Scenes
503 { 502 {
504 // Stick it on left hand with Zero Offset from the attachment point. 503 // Stick it on left hand with Zero Offset from the attachment point.
505 AttachmentPt = (uint)AttachmentPoint.LeftHand; 504 AttachmentPt = (uint)AttachmentPoint.LeftHand;
506 attachPos = LLVector3.Zero; 505 attachPos = Vector3.Zero;
507 } 506 }
508 m_log.Debug("[ATTACH]: Using attachpoint: " + AttachmentPt.ToString()); 507 m_log.Debug("[ATTACH]: Using attachpoint: " + AttachmentPt.ToString());
509 508
510 509
511 510
512 // Saves and gets assetID 511 // Saves and gets assetID
513 if (group.GetFromAssetID() == LLUUID.Zero) 512 if (group.GetFromAssetID() == UUID.Zero)
514 { 513 {
515 LLUUID newAssetID = m_parentScene.attachObjectAssetStore(remoteClient, group, remoteClient.AgentId); 514 UUID newAssetID = m_parentScene.attachObjectAssetStore(remoteClient, group, remoteClient.AgentId);
516 515
517 // sets assetID so client can show asset as 'attached' in inventory 516 // sets assetID so client can show asset as 'attached' in inventory
518 group.SetFromAssetID(newAssetID); 517 group.SetFromAssetID(newAssetID);
@@ -573,7 +572,7 @@ namespace OpenSim.Region.Environment.Scenes
573 /// <summary> 572 /// <summary>
574 /// Remove a presence from the scene 573 /// Remove a presence from the scene
575 /// </summary> 574 /// </summary>
576 protected internal void RemoveScenePresence(LLUUID agentID) 575 protected internal void RemoveScenePresence(UUID agentID)
577 { 576 {
578 lock (Entities) 577 lock (Entities)
579 { 578 {
@@ -696,7 +695,7 @@ namespace OpenSim.Region.Environment.Scenes
696 /// </summary> 695 /// </summary>
697 /// <param name="agentId"></param> 696 /// <param name="agentId"></param>
698 /// <returns>null if either the avatar wasn't in the scene, or they do not have a controlling client</returns> 697 /// <returns>null if either the avatar wasn't in the scene, or they do not have a controlling client</returns>
699 protected internal IClientAPI GetControllingClient(LLUUID agentId) 698 protected internal IClientAPI GetControllingClient(UUID agentId)
700 { 699 {
701 ScenePresence presence = GetScenePresence(agentId); 700 ScenePresence presence = GetScenePresence(agentId);
702 701
@@ -735,7 +734,7 @@ namespace OpenSim.Region.Environment.Scenes
735 /// </summary> 734 /// </summary>
736 /// <param name="avatarID"></param> 735 /// <param name="avatarID"></param>
737 /// <returns>null if the agent was not found</returns> 736 /// <returns>null if the agent was not found</returns>
738 protected internal ScenePresence GetScenePresence(LLUUID agentID) 737 protected internal ScenePresence GetScenePresence(UUID agentID)
739 { 738 {
740 ScenePresence sp; 739 ScenePresence sp;
741 ScenePresences.TryGetValue(agentID, out sp); 740 ScenePresences.TryGetValue(agentID, out sp);
@@ -768,7 +767,7 @@ namespace OpenSim.Region.Environment.Scenes
768 /// </summary> 767 /// </summary>
769 /// <param name="fullID"></param> 768 /// <param name="fullID"></param>
770 /// <returns>null if no scene object group containing that prim is found</returns> 769 /// <returns>null if no scene object group containing that prim is found</returns>
771 private SceneObjectGroup GetGroupByPrim(LLUUID fullID) 770 private SceneObjectGroup GetGroupByPrim(UUID fullID)
772 { 771 {
773 List<EntityBase> EntityList = GetEntities(); 772 List<EntityBase> EntityList = GetEntities();
774 773
@@ -828,7 +827,7 @@ namespace OpenSim.Region.Environment.Scenes
828 /// </summary> 827 /// </summary>
829 /// <param name="fullID"></param> 828 /// <param name="fullID"></param>
830 /// <returns>null if the part was not found</returns> 829 /// <returns>null if the part was not found</returns>
831 protected internal SceneObjectPart GetSceneObjectPart(LLUUID fullID) 830 protected internal SceneObjectPart GetSceneObjectPart(UUID fullID)
832 { 831 {
833 SceneObjectGroup group = GetGroupByPrim(fullID); 832 SceneObjectGroup group = GetGroupByPrim(fullID);
834 if (group != null) 833 if (group != null)
@@ -837,7 +836,7 @@ namespace OpenSim.Region.Environment.Scenes
837 return null; 836 return null;
838 } 837 }
839 838
840 protected internal bool TryGetAvatar(LLUUID avatarId, out ScenePresence avatar) 839 protected internal bool TryGetAvatar(UUID avatarId, out ScenePresence avatar)
841 { 840 {
842 ScenePresence presence; 841 ScenePresence presence;
843 if (ScenePresences.TryGetValue(avatarId, out presence)) 842 if (ScenePresences.TryGetValue(avatarId, out presence))
@@ -906,7 +905,7 @@ namespace OpenSim.Region.Environment.Scenes
906 if (ent is SceneObjectGroup) 905 if (ent is SceneObjectGroup)
907 { 906 {
908 SceneObjectGroup grp = (SceneObjectGroup)ent; 907 SceneObjectGroup grp = (SceneObjectGroup)ent;
909 if ((grp.RootPart.GetEffectiveObjectFlags() & (uint)LLObject.ObjectFlags.Scripted) != 0) 908 if ((grp.RootPart.GetEffectiveObjectFlags() & (uint)PrimFlags.Scripted) != 0)
910 { 909 {
911 if (grp.scriptScore >= 0.01) 910 if (grp.scriptScore >= 0.01)
912 { 911 {
@@ -938,13 +937,13 @@ namespace OpenSim.Region.Environment.Scenes
938 } 937 }
939 } 938 }
940 939
941 protected internal LLUUID ConvertLocalIDToFullID(uint localID) 940 protected internal UUID ConvertLocalIDToFullID(uint localID)
942 { 941 {
943 SceneObjectGroup group = GetGroupByPrim(localID); 942 SceneObjectGroup group = GetGroupByPrim(localID);
944 if (group != null) 943 if (group != null)
945 return group.GetPartsFullID(localID); 944 return group.GetPartsFullID(localID);
946 else 945 else
947 return LLUUID.Zero; 946 return UUID.Zero;
948 } 947 }
949 948
950 protected internal void ForEachClient(Action<IClientAPI> action) 949 protected internal void ForEachClient(Action<IClientAPI> action)
@@ -968,7 +967,7 @@ namespace OpenSim.Region.Environment.Scenes
968 /// <param name="localID"></param> 967 /// <param name="localID"></param>
969 /// <param name="scale"></param> 968 /// <param name="scale"></param>
970 /// <param name="remoteClient"></param> 969 /// <param name="remoteClient"></param>
971 protected internal void UpdatePrimScale(uint localID, LLVector3 scale, IClientAPI remoteClient) 970 protected internal void UpdatePrimScale(uint localID, Vector3 scale, IClientAPI remoteClient)
972 { 971 {
973 SceneObjectGroup group = GetGroupByPrim(localID); 972 SceneObjectGroup group = GetGroupByPrim(localID);
974 if (group != null) 973 if (group != null)
@@ -980,7 +979,7 @@ namespace OpenSim.Region.Environment.Scenes
980 } 979 }
981 } 980 }
982 981
983 protected internal void UpdatePrimGroupScale(uint localID, LLVector3 scale, IClientAPI remoteClient) 982 protected internal void UpdatePrimGroupScale(uint localID, Vector3 scale, IClientAPI remoteClient)
984 { 983 {
985 SceneObjectGroup group = GetGroupByPrim(localID); 984 SceneObjectGroup group = GetGroupByPrim(localID);
986 if (group != null) 985 if (group != null)
@@ -1001,7 +1000,7 @@ namespace OpenSim.Region.Environment.Scenes
1001 /// <param name="RequestFlags"></param> 1000 /// <param name="RequestFlags"></param>
1002 /// <param name="ObjectID"></param> 1001 /// <param name="ObjectID"></param>
1003 protected internal void RequestObjectPropertiesFamily( 1002 protected internal void RequestObjectPropertiesFamily(
1004 IClientAPI remoteClient, LLUUID AgentID, uint RequestFlags, LLUUID ObjectID) 1003 IClientAPI remoteClient, UUID AgentID, uint RequestFlags, UUID ObjectID)
1005 { 1004 {
1006 SceneObjectGroup group = GetGroupByPrim(ObjectID); 1005 SceneObjectGroup group = GetGroupByPrim(ObjectID);
1007 if (group != null) 1006 if (group != null)
@@ -1016,7 +1015,7 @@ namespace OpenSim.Region.Environment.Scenes
1016 /// <param name="localID"></param> 1015 /// <param name="localID"></param>
1017 /// <param name="rot"></param> 1016 /// <param name="rot"></param>
1018 /// <param name="remoteClient"></param> 1017 /// <param name="remoteClient"></param>
1019 protected internal void UpdatePrimSingleRotation(uint localID, LLQuaternion rot, IClientAPI remoteClient) 1018 protected internal void UpdatePrimSingleRotation(uint localID, Quaternion rot, IClientAPI remoteClient)
1020 { 1019 {
1021 SceneObjectGroup group = GetGroupByPrim(localID); 1020 SceneObjectGroup group = GetGroupByPrim(localID);
1022 if (group != null) 1021 if (group != null)
@@ -1034,7 +1033,7 @@ namespace OpenSim.Region.Environment.Scenes
1034 /// <param name="localID"></param> 1033 /// <param name="localID"></param>
1035 /// <param name="rot"></param> 1034 /// <param name="rot"></param>
1036 /// <param name="remoteClient"></param> 1035 /// <param name="remoteClient"></param>
1037 protected internal void UpdatePrimRotation(uint localID, LLQuaternion rot, IClientAPI remoteClient) 1036 protected internal void UpdatePrimRotation(uint localID, Quaternion rot, IClientAPI remoteClient)
1038 { 1037 {
1039 SceneObjectGroup group = GetGroupByPrim(localID); 1038 SceneObjectGroup group = GetGroupByPrim(localID);
1040 if (group != null) 1039 if (group != null)
@@ -1053,7 +1052,7 @@ namespace OpenSim.Region.Environment.Scenes
1053 /// <param name="pos"></param> 1052 /// <param name="pos"></param>
1054 /// <param name="rot"></param> 1053 /// <param name="rot"></param>
1055 /// <param name="remoteClient"></param> 1054 /// <param name="remoteClient"></param>
1056 protected internal void UpdatePrimRotation(uint localID, LLVector3 pos, LLQuaternion rot, IClientAPI remoteClient) 1055 protected internal void UpdatePrimRotation(uint localID, Vector3 pos, Quaternion rot, IClientAPI remoteClient)
1057 { 1056 {
1058 SceneObjectGroup group = GetGroupByPrim(localID); 1057 SceneObjectGroup group = GetGroupByPrim(localID);
1059 if (group != null) 1058 if (group != null)
@@ -1071,12 +1070,12 @@ namespace OpenSim.Region.Environment.Scenes
1071 /// <param name="localID"></param> 1070 /// <param name="localID"></param>
1072 /// <param name="pos"></param> 1071 /// <param name="pos"></param>
1073 /// <param name="remoteClient"></param> 1072 /// <param name="remoteClient"></param>
1074 protected internal void UpdatePrimSinglePosition(uint localID, LLVector3 pos, IClientAPI remoteClient) 1073 protected internal void UpdatePrimSinglePosition(uint localID, Vector3 pos, IClientAPI remoteClient)
1075 { 1074 {
1076 SceneObjectGroup group = GetGroupByPrim(localID); 1075 SceneObjectGroup group = GetGroupByPrim(localID);
1077 if (group != null) 1076 if (group != null)
1078 { 1077 {
1079 // LLVector3 oldPos = group.AbsolutePosition; 1078 // Vector3 oldPos = group.AbsolutePosition;
1080 if (!m_parentScene.ExternalChecks.ExternalChecksCanObjectEntry(group.UUID,pos) && !group.RootPart.IsAttachment) 1079 if (!m_parentScene.ExternalChecks.ExternalChecksCanObjectEntry(group.UUID,pos) && !group.RootPart.IsAttachment)
1081 { 1080 {
1082 group.SendGroupTerseUpdate(); 1081 group.SendGroupTerseUpdate();
@@ -1096,13 +1095,13 @@ namespace OpenSim.Region.Environment.Scenes
1096 /// <param name="localID"></param> 1095 /// <param name="localID"></param>
1097 /// <param name="pos"></param> 1096 /// <param name="pos"></param>
1098 /// <param name="remoteClient"></param> 1097 /// <param name="remoteClient"></param>
1099 protected internal void UpdatePrimPosition(uint localID, LLVector3 pos, IClientAPI remoteClient) 1098 protected internal void UpdatePrimPosition(uint localID, Vector3 pos, IClientAPI remoteClient)
1100 { 1099 {
1101 SceneObjectGroup group = GetGroupByPrim(localID); 1100 SceneObjectGroup group = GetGroupByPrim(localID);
1102 if (group != null) 1101 if (group != null)
1103 { 1102 {
1104 1103
1105 // LLVector3 oldPos = group.AbsolutePosition; 1104 // Vector3 oldPos = group.AbsolutePosition;
1106 if (group.RootPart.IsAttachment) 1105 if (group.RootPart.IsAttachment)
1107 { 1106 {
1108 group.UpdateGroupPosition(pos); 1107 group.UpdateGroupPosition(pos);
@@ -1166,7 +1165,7 @@ namespace OpenSim.Region.Environment.Scenes
1166 /// <param name="offset"></param> 1165 /// <param name="offset"></param>
1167 /// <param name="pos"></param> 1166 /// <param name="pos"></param>
1168 /// <param name="remoteClient"></param> 1167 /// <param name="remoteClient"></param>
1169 protected internal void MoveObject(LLUUID objectID, LLVector3 offset, LLVector3 pos, IClientAPI remoteClient) 1168 protected internal void MoveObject(UUID objectID, Vector3 offset, Vector3 pos, IClientAPI remoteClient)
1170 { 1169 {
1171 SceneObjectGroup group = GetGroupByPrim(objectID); 1170 SceneObjectGroup group = GetGroupByPrim(objectID);
1172 if (group != null) 1171 if (group != null)
@@ -1219,7 +1218,7 @@ namespace OpenSim.Region.Environment.Scenes
1219 } 1218 }
1220 } 1219 }
1221 1220
1222 protected internal void UpdateExtraParam(LLUUID agentID, uint primLocalID, ushort type, bool inUse, byte[] data) 1221 protected internal void UpdateExtraParam(UUID agentID, uint primLocalID, ushort type, bool inUse, byte[] data)
1223 { 1222 {
1224 SceneObjectGroup group = GetGroupByPrim(primLocalID); 1223 SceneObjectGroup group = GetGroupByPrim(primLocalID);
1225 1224
@@ -1237,7 +1236,7 @@ namespace OpenSim.Region.Environment.Scenes
1237 /// </summary> 1236 /// </summary>
1238 /// <param name="primLocalID"></param> 1237 /// <param name="primLocalID"></param>
1239 /// <param name="shapeBlock"></param> 1238 /// <param name="shapeBlock"></param>
1240 protected internal void UpdatePrimShape(LLUUID agentID, uint primLocalID, UpdateShapeArgs shapeBlock) 1239 protected internal void UpdatePrimShape(UUID agentID, uint primLocalID, UpdateShapeArgs shapeBlock)
1241 { 1240 {
1242 SceneObjectGroup group = GetGroupByPrim(primLocalID); 1241 SceneObjectGroup group = GetGroupByPrim(primLocalID);
1243 if (group != null) 1242 if (group != null)
@@ -1323,7 +1322,7 @@ namespace OpenSim.Region.Environment.Scenes
1323 1322
1324 // We need to explicitly resend the newly link prim's object properties since no other actions 1323 // We need to explicitly resend the newly link prim's object properties since no other actions
1325 // occur on link to invoke this elsewhere (such as object selection) 1324 // occur on link to invoke this elsewhere (such as object selection)
1326 parenPrim.RootPart.AddFlag(LLObject.ObjectFlags.CreateSelected); 1325 parenPrim.RootPart.AddFlag(PrimFlags.CreateSelected);
1327 parenPrim.TriggerScriptChangedEvent(Changed.LINK); 1326 parenPrim.TriggerScriptChangedEvent(Changed.LINK);
1328 if (client != null) 1327 if (client != null)
1329 parenPrim.GetProperties(client); 1328 parenPrim.GetProperties(client);
@@ -1478,8 +1477,8 @@ namespace OpenSim.Region.Environment.Scenes
1478 1477
1479 protected internal void MakeObjectSearchable(IClientAPI remoteClient, bool IncludeInSearch, uint localID) 1478 protected internal void MakeObjectSearchable(IClientAPI remoteClient, bool IncludeInSearch, uint localID)
1480 { 1479 {
1481 LLUUID user = remoteClient.AgentId; 1480 UUID user = remoteClient.AgentId;
1482 LLUUID objid = null; 1481 UUID objid = null;
1483 SceneObjectPart obj = null; 1482 SceneObjectPart obj = null;
1484 1483
1485 List<EntityBase> EntityList = GetEntities(); 1484 List<EntityBase> EntityList = GetEntities();
@@ -1487,7 +1486,7 @@ namespace OpenSim.Region.Environment.Scenes
1487 { 1486 {
1488 if (ent is SceneObjectGroup) 1487 if (ent is SceneObjectGroup)
1489 { 1488 {
1490 foreach (KeyValuePair<LLUUID, SceneObjectPart> subent in ((SceneObjectGroup)ent).Children) 1489 foreach (KeyValuePair<UUID, SceneObjectPart> subent in ((SceneObjectGroup)ent).Children)
1491 { 1490 {
1492 if (subent.Value.LocalId == localID) 1491 if (subent.Value.LocalId == localID)
1493 { 1492 {
@@ -1512,11 +1511,11 @@ namespace OpenSim.Region.Environment.Scenes
1512 1511
1513 if (IncludeInSearch && m_parentScene.ExternalChecks.ExternalChecksCanEditObject(objid, user)) 1512 if (IncludeInSearch && m_parentScene.ExternalChecks.ExternalChecksCanEditObject(objid, user))
1514 { 1513 {
1515 obj.ParentGroup.RootPart.AddFlag(LLObject.ObjectFlags.JointWheel); 1514 obj.ParentGroup.RootPart.AddFlag(PrimFlags.JointWheel);
1516 } 1515 }
1517 else if (!IncludeInSearch && m_parentScene.ExternalChecks.ExternalChecksCanMoveObject(objid,user)) 1516 else if (!IncludeInSearch && m_parentScene.ExternalChecks.ExternalChecksCanMoveObject(objid,user))
1518 { 1517 {
1519 obj.ParentGroup.RootPart.RemFlag(LLObject.ObjectFlags.JointWheel); 1518 obj.ParentGroup.RootPart.RemFlag(PrimFlags.JointWheel);
1520 } 1519 }
1521 } 1520 }
1522 1521
@@ -1526,12 +1525,12 @@ namespace OpenSim.Region.Environment.Scenes
1526 /// <param name="originalPrim"></param> 1525 /// <param name="originalPrim"></param>
1527 /// <param name="offset"></param> 1526 /// <param name="offset"></param>
1528 /// <param name="flags"></param> 1527 /// <param name="flags"></param>
1529 protected internal void DuplicateObject(uint originalPrim, LLVector3 offset, uint flags, LLUUID AgentID, LLUUID GroupID) 1528 protected internal void DuplicateObject(uint originalPrim, Vector3 offset, uint flags, UUID AgentID, UUID GroupID)
1530 { 1529 {
1531 //m_log.DebugFormat("[SCENE]: Duplication of object {0} at offset {1} requested by agent {2}", originalPrim, offset, AgentID); 1530 //m_log.DebugFormat("[SCENE]: Duplication of object {0} at offset {1} requested by agent {2}", originalPrim, offset, AgentID);
1532 1531
1533 // SceneObjectGroup dupe = DuplicateObject(originalPrim, offset, flags, AgentID, GroupID, Quaternion.Zero); 1532 // SceneObjectGroup dupe = DuplicateObject(originalPrim, offset, flags, AgentID, GroupID, Quaternion.Zero);
1534 DuplicateObject(originalPrim, offset, flags, AgentID, GroupID, Quaternion.Zero); 1533 DuplicateObject(originalPrim, offset, flags, AgentID, GroupID, Quaternion.Identity);
1535 } 1534 }
1536 /// <summary> 1535 /// <summary>
1537 /// Duplicate the given object. 1536 /// Duplicate the given object.
@@ -1539,7 +1538,7 @@ namespace OpenSim.Region.Environment.Scenes
1539 /// <param name="originalPrim"></param> 1538 /// <param name="originalPrim"></param>
1540 /// <param name="offset"></param> 1539 /// <param name="offset"></param>
1541 /// <param name="flags"></param> 1540 /// <param name="flags"></param>
1542 protected internal SceneObjectGroup DuplicateObject(uint originalPrim, LLVector3 offset, uint flags, LLUUID AgentID, LLUUID GroupID, Quaternion rot) 1541 protected internal SceneObjectGroup DuplicateObject(uint originalPrim, Vector3 offset, uint flags, UUID AgentID, UUID GroupID, Quaternion rot)
1543 { 1542 {
1544 //m_log.DebugFormat("[SCENE]: Duplication of object {0} at offset {1} requested by agent {2}", originalPrim, offset, AgentID); 1543 //m_log.DebugFormat("[SCENE]: Duplication of object {0} at offset {1} requested by agent {2}", originalPrim, offset, AgentID);
1545 1544
@@ -1580,9 +1579,9 @@ namespace OpenSim.Region.Environment.Scenes
1580 1579
1581 m_numPrim += copy.Children.Count; 1580 m_numPrim += copy.Children.Count;
1582 1581
1583 if (rot != Quaternion.Zero) 1582 if (rot != Quaternion.Identity)
1584 { 1583 {
1585 copy.UpdateGroupRotation(new LLQuaternion(rot.x, rot.y, rot.z, rot.w)); 1584 copy.UpdateGroupRotation(rot);
1586 } 1585 }
1587 1586
1588 copy.CreateScriptInstances(0, false); 1587 copy.CreateScriptInstances(0, false);
@@ -1610,7 +1609,7 @@ namespace OpenSim.Region.Environment.Scenes
1610 1609
1611 return 1610 return
1612 (float) 1611 (float)
1613 Math.Sqrt((v1.x - v2.x) * (v1.x - v2.x) + (v1.y - v2.y) * (v1.y - v2.y) + (v1.z - v2.z) * (v1.z - v2.z)); 1612 Math.Sqrt((v1.X - v2.X) * (v1.X - v2.X) + (v1.Y - v2.Y) * (v1.Y - v2.Y) + (v1.Z - v2.Z) * (v1.Z - v2.Z));
1614 } 1613 }
1615 1614
1616 #endregion 1615 #endregion