aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/OpenSim.Region/Scenes/Primitive.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/OpenSim.Region/Scenes/Primitive.cs')
-rw-r--r--OpenSim/OpenSim.Region/Scenes/Primitive.cs45
1 files changed, 43 insertions, 2 deletions
diff --git a/OpenSim/OpenSim.Region/Scenes/Primitive.cs b/OpenSim/OpenSim.Region/Scenes/Primitive.cs
index 62f401c..b0bfd1e 100644
--- a/OpenSim/OpenSim.Region/Scenes/Primitive.cs
+++ b/OpenSim/OpenSim.Region/Scenes/Primitive.cs
@@ -47,6 +47,7 @@ namespace OpenSim.Region.Scenes
47 private const uint FULL_MASK_PERMISSIONS = 2147483647; 47 private const uint FULL_MASK_PERMISSIONS = 2147483647;
48 private bool physicsEnabled = false; 48 private bool physicsEnabled = false;
49 private byte updateFlag = 0; 49 private byte updateFlag = 0;
50 private uint flags = 32 + 65536 + 131072 + 256 + 4 + 8 + 2048 + 524288 + 268435456 + 128;
50 51
51 private Dictionary<LLUUID, InventoryItem> inventoryItems; 52 private Dictionary<LLUUID, InventoryItem> inventoryItems;
52 53
@@ -411,7 +412,7 @@ namespace OpenSim.Region.Scenes
411 lPos = this.Pos; 412 lPos = this.Pos;
412 } 413 }
413 414
414 remoteClient.SendPrimitiveToClient(this.m_regionHandle, 64096, this.LocalId, this.primData, lPos, new LLUUID("00000000-0000-0000-9999-000000000005")); 415 remoteClient.SendPrimitiveToClient(this.m_regionHandle, 64096, this.LocalId, this.primData, lPos, new LLUUID("00000000-0000-0000-9999-000000000005"), this.flags);
415 } 416 }
416 417
417 /// <summary> 418 /// <summary>
@@ -434,7 +435,7 @@ namespace OpenSim.Region.Scenes
434 { 435 {
435 LLVector3 lPos; 436 LLVector3 lPos;
436 Axiom.MathLib.Quaternion lRot; 437 Axiom.MathLib.Quaternion lRot;
437 if (this._physActor != null && this.physicsEnabled) 438 if (this._physActor != null && this.physicsEnabled) //is this needed ? doesn't the property fields do this for us?
438 { 439 {
439 PhysicsVector pPos = this._physActor.Position; 440 PhysicsVector pPos = this._physActor.Position;
440 lPos = new LLVector3(pPos.X, pPos.Y, pPos.Z); 441 lPos = new LLVector3(pPos.X, pPos.Y, pPos.Z);
@@ -445,6 +446,8 @@ namespace OpenSim.Region.Scenes
445 lPos = this.Pos; 446 lPos = this.Pos;
446 lRot = this.rotation; 447 lRot = this.rotation;
447 } 448 }
449 LLQuaternion mRot = new LLQuaternion(lRot.x, lRot.y, lRot.z, lRot.w);
450 RemoteClient.SendPrimTerseUpdate(this.m_regionHandle, 64096, this.LocalId, lPos, mRot);
448 } 451 }
449 452
450 /// <summary> 453 /// <summary>
@@ -534,6 +537,44 @@ namespace OpenSim.Region.Scenes
534 { 537 {
535 538
536 } 539 }
540
541 public void GrapMovement(LLVector3 offset, LLVector3 pos, IClientAPI remoteClient)
542 {
543 Console.WriteLine("moving prim to new location " + pos.X + " , " + pos.Y + " , " + pos.Z);
544 this.Pos = pos;
545 this.SendTerseUpdateToALLClients();
546 }
547
548 public void GetProperites(IClientAPI client)
549 {
550 //needs changing
551 ObjectPropertiesPacket proper = new ObjectPropertiesPacket();
552 proper.ObjectData = new ObjectPropertiesPacket.ObjectDataBlock[1];
553 proper.ObjectData[0] = new ObjectPropertiesPacket.ObjectDataBlock();
554 proper.ObjectData[0].ItemID = LLUUID.Zero;
555 proper.ObjectData[0].CreationDate = (ulong)primData.CreationDate;
556 proper.ObjectData[0].CreatorID = primData.OwnerID;
557 proper.ObjectData[0].FolderID = LLUUID.Zero;
558 proper.ObjectData[0].FromTaskID = LLUUID.Zero;
559 proper.ObjectData[0].GroupID = LLUUID.Zero;
560 proper.ObjectData[0].InventorySerial = 0;
561 proper.ObjectData[0].LastOwnerID = LLUUID.Zero;
562 proper.ObjectData[0].ObjectID = this.uuid;
563 proper.ObjectData[0].OwnerID = primData.OwnerID;
564 proper.ObjectData[0].TouchName = new byte[0];
565 proper.ObjectData[0].TextureID = new byte[0];
566 proper.ObjectData[0].SitName = new byte[0];
567 proper.ObjectData[0].Name = new byte[0];
568 proper.ObjectData[0].Description = new byte[0];
569 proper.ObjectData[0].OwnerMask = primData.OwnerMask;
570 proper.ObjectData[0].NextOwnerMask = primData.NextOwnerMask;
571 proper.ObjectData[0].GroupMask = primData.GroupMask;
572 proper.ObjectData[0].EveryoneMask = primData.EveryoneMask;
573 proper.ObjectData[0].BaseMask = primData.BaseMask;
574
575 client.OutPacket(proper);
576
577 }
537 578
538 #endregion 579 #endregion
539 580