aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Framework/General/Interfaces/IClientAPI.cs4
-rw-r--r--OpenSim/Framework/General/NullClientAPI.cs6
-rw-r--r--OpenSim/Region/ClientStack/ClientView.API.cs7
-rw-r--r--OpenSim/Region/Environment/Scenes/Primitive.cs9
-rw-r--r--OpenSim/Region/Examples/SimpleApp/CpuCounterObject.cs2
-rw-r--r--OpenSim/Region/Examples/SimpleApp/MyNpcCharacter.cs19
6 files changed, 29 insertions, 18 deletions
diff --git a/OpenSim/Framework/General/Interfaces/IClientAPI.cs b/OpenSim/Framework/General/Interfaces/IClientAPI.cs
index 858126b..abde0ab 100644
--- a/OpenSim/Framework/General/Interfaces/IClientAPI.cs
+++ b/OpenSim/Framework/General/Interfaces/IClientAPI.cs
@@ -182,8 +182,8 @@ namespace OpenSim.Framework.Interfaces
182 void SendAvatarTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, LLVector3 position, LLVector3 velocity); 182 void SendAvatarTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, LLVector3 position, LLVector3 velocity);
183 183
184 void AttachObject(uint localID, LLQuaternion rotation, byte attachPoint); 184 void AttachObject(uint localID, LLQuaternion rotation, byte attachPoint);
185 void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, LLQuaternion rotation, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID); 185 void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, LLQuaternion rotation, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID, byte[] particleSystem);
186 void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID); 186 void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID, byte[] particleSystem);
187 void SendPrimTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, LLVector3 position, LLQuaternion rotation); 187 void SendPrimTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, LLVector3 position, LLQuaternion rotation);
188 188
189 void SendInventoryFolderDetails(LLUUID ownerID, LLUUID folderID, List<InventoryItemBase> items); 189 void SendInventoryFolderDetails(LLUUID ownerID, LLUUID folderID, List<InventoryItemBase> items);
diff --git a/OpenSim/Framework/General/NullClientAPI.cs b/OpenSim/Framework/General/NullClientAPI.cs
index a5539ef..f753d05 100644
--- a/OpenSim/Framework/General/NullClientAPI.cs
+++ b/OpenSim/Framework/General/NullClientAPI.cs
@@ -118,10 +118,8 @@ namespace OpenSim.Framework
118 public virtual void SendAvatarTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, LLVector3 position, LLVector3 velocity){} 118 public virtual void SendAvatarTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, LLVector3 position, LLVector3 velocity){}
119 119
120 public virtual void AttachObject(uint localID, LLQuaternion rotation, byte attachPoint){} 120 public virtual void AttachObject(uint localID, LLQuaternion rotation, byte attachPoint){}
121 public virtual void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimData primData, LLVector3 pos, LLQuaternion rotation, LLUUID textureID, uint flags){} 121 public virtual void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, LLQuaternion rotation, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID, byte[] particleSystem){}
122 public virtual void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimData primData, LLVector3 pos, LLUUID textureID, uint flags){} 122 public virtual void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID, byte[] particleSystem){}
123 public virtual void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, LLQuaternion rotation, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID){}
124 public virtual void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID){}
125 public virtual void SendPrimTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, LLVector3 position, LLQuaternion rotation){} 123 public virtual void SendPrimTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, LLVector3 position, LLQuaternion rotation){}
126 124
127 public virtual void SendInventoryFolderDetails(LLUUID ownerID, LLUUID folderID, List<InventoryItemBase> items){} 125 public virtual void SendInventoryFolderDetails(LLUUID ownerID, LLUUID folderID, List<InventoryItemBase> items){}
diff --git a/OpenSim/Region/ClientStack/ClientView.API.cs b/OpenSim/Region/ClientStack/ClientView.API.cs
index 440f583..73b3887 100644
--- a/OpenSim/Region/ClientStack/ClientView.API.cs
+++ b/OpenSim/Region/ClientStack/ClientView.API.cs
@@ -719,9 +719,8 @@ namespace OpenSim.Region.ClientStack
719 719
720 this.OutPacket(attach); 720 this.OutPacket(attach);
721 } 721 }
722
723 722
724 public void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, LLQuaternion rotation, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID) 723 public void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, LLQuaternion rotation, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID, byte[] particleSystem)
725 { 724 {
726 ObjectUpdatePacket outPacket = new ObjectUpdatePacket(); 725 ObjectUpdatePacket outPacket = new ObjectUpdatePacket();
727 outPacket.RegionData.RegionHandle = regionHandle; 726 outPacket.RegionData.RegionHandle = regionHandle;
@@ -733,6 +732,7 @@ namespace OpenSim.Region.ClientStack
733 outPacket.ObjectData[0].OwnerID = ownerID; 732 outPacket.ObjectData[0].OwnerID = ownerID;
734 outPacket.ObjectData[0].Text = Helpers.StringToField( text ); 733 outPacket.ObjectData[0].Text = Helpers.StringToField( text );
735 outPacket.ObjectData[0].ParentID = parentID; 734 outPacket.ObjectData[0].ParentID = parentID;
735 outPacket.ObjectData[0].PSBlock = particleSystem;
736 byte[] pb = pos.GetBytes(); 736 byte[] pb = pos.GetBytes();
737 Array.Copy(pb, 0, outPacket.ObjectData[0].ObjectData, 0, pb.Length); 737 Array.Copy(pb, 0, outPacket.ObjectData[0].ObjectData, 0, pb.Length);
738 byte[] rot = rotation.GetBytes(); 738 byte[] rot = rotation.GetBytes();
@@ -740,7 +740,7 @@ namespace OpenSim.Region.ClientStack
740 OutPacket(outPacket); 740 OutPacket(outPacket);
741 } 741 }
742 742
743 public void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID) 743 public void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID, byte[] particleSystem)
744 { 744 {
745 ObjectUpdatePacket outPacket = new ObjectUpdatePacket(); 745 ObjectUpdatePacket outPacket = new ObjectUpdatePacket();
746 outPacket.RegionData.RegionHandle = regionHandle; 746 outPacket.RegionData.RegionHandle = regionHandle;
@@ -752,6 +752,7 @@ namespace OpenSim.Region.ClientStack
752 outPacket.ObjectData[0].OwnerID = ownerID; 752 outPacket.ObjectData[0].OwnerID = ownerID;
753 outPacket.ObjectData[0].Text = Helpers.StringToField( text ); 753 outPacket.ObjectData[0].Text = Helpers.StringToField( text );
754 outPacket.ObjectData[0].ParentID = parentID; 754 outPacket.ObjectData[0].ParentID = parentID;
755 outPacket.ObjectData[0].PSBlock = particleSystem;
755 byte[] pb = pos.GetBytes(); 756 byte[] pb = pos.GetBytes();
756 Array.Copy(pb, 0, outPacket.ObjectData[0].ObjectData, 0, pb.Length); 757 Array.Copy(pb, 0, outPacket.ObjectData[0].ObjectData, 0, pb.Length);
757 758
diff --git a/OpenSim/Region/Environment/Scenes/Primitive.cs b/OpenSim/Region/Environment/Scenes/Primitive.cs
index bca8e0c..7484393 100644
--- a/OpenSim/Region/Environment/Scenes/Primitive.cs
+++ b/OpenSim/Region/Environment/Scenes/Primitive.cs
@@ -38,6 +38,7 @@ namespace OpenSim.Region.Environment.Scenes
38 public uint BaseMask = FULL_MASK_PERMISSIONS; 38 public uint BaseMask = FULL_MASK_PERMISSIONS;
39 39
40 private PrimitiveBaseShape m_Shape; 40 private PrimitiveBaseShape m_Shape;
41 private byte[] m_particleSystem = new byte[0];
41 42
42 public SceneObject m_RootParent; 43 public SceneObject m_RootParent;
43 public bool m_isRootPrim; 44 public bool m_isRootPrim;
@@ -620,6 +621,12 @@ namespace OpenSim.Region.Environment.Scenes
620 621
621 #endregion 622 #endregion
622 623
624 public void AddNewParticleSystem(libsecondlife.Primitive.ParticleSystem pSystem)
625 {
626 this.m_particleSystem = pSystem.GetBytes();
627 ScheduleFullUpdate();
628 }
629
623 #region Client Update Methods 630 #region Client Update Methods
624 631
625 /// <summary> 632 /// <summary>
@@ -653,7 +660,7 @@ namespace OpenSim.Region.Environment.Scenes
653 lRot = new LLQuaternion(Rotation.x, Rotation.y, Rotation.z, Rotation.w); 660 lRot = new LLQuaternion(Rotation.x, Rotation.y, Rotation.z, Rotation.w);
654 661
655 remoteClient.SendPrimitiveToClient(m_regionHandle, 64096, LocalId, m_Shape, lPos, lRot, m_flags, m_uuid, 662 remoteClient.SendPrimitiveToClient(m_regionHandle, 64096, LocalId, m_Shape, lPos, lRot, m_flags, m_uuid,
656 OwnerID, m_text, ParentID); 663 OwnerID, m_text, ParentID, this.m_particleSystem);
657 } 664 }
658 665
659 /// <summary> 666 /// <summary>
diff --git a/OpenSim/Region/Examples/SimpleApp/CpuCounterObject.cs b/OpenSim/Region/Examples/SimpleApp/CpuCounterObject.cs
index 26ecf01..e6505b4 100644
--- a/OpenSim/Region/Examples/SimpleApp/CpuCounterObject.cs
+++ b/OpenSim/Region/Examples/SimpleApp/CpuCounterObject.cs
@@ -19,7 +19,7 @@ namespace SimpleApp
19 String objectName = "Processor"; 19 String objectName = "Processor";
20 String counterName = "% Processor Time"; 20 String counterName = "% Processor Time";
21 String instanceName = "_Total"; 21 String instanceName = "_Total";
22 22
23 m_counter = new PerformanceCounter(objectName, counterName, instanceName); 23 m_counter = new PerformanceCounter(objectName, counterName, instanceName);
24 } 24 }
25 25
diff --git a/OpenSim/Region/Examples/SimpleApp/MyNpcCharacter.cs b/OpenSim/Region/Examples/SimpleApp/MyNpcCharacter.cs
index 308dea7..8274912 100644
--- a/OpenSim/Region/Examples/SimpleApp/MyNpcCharacter.cs
+++ b/OpenSim/Region/Examples/SimpleApp/MyNpcCharacter.cs
@@ -132,10 +132,9 @@ namespace SimpleApp
132 public virtual void SendAvatarTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, LLVector3 position, LLVector3 velocity) { } 132 public virtual void SendAvatarTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, LLVector3 position, LLVector3 velocity) { }
133 133
134 public virtual void AttachObject(uint localID, LLQuaternion rotation, byte attachPoint) { } 134 public virtual void AttachObject(uint localID, LLQuaternion rotation, byte attachPoint) { }
135 public virtual void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimData primData, LLVector3 pos, LLQuaternion rotation, LLUUID textureID, uint flags) { } 135
136 public virtual void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimData primData, LLVector3 pos, LLUUID textureID, uint flags) { } 136 public virtual void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, LLQuaternion rotation, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID, byte[] particleSystem) { }
137 public virtual void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, LLQuaternion rotation, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID) { } 137 public virtual void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID, byte[] particleSystem) { }
138 public virtual void SendPrimitiveToClient(ulong regionHandle, ushort timeDilation, uint localID, PrimitiveBaseShape primShape, LLVector3 pos, uint flags, LLUUID objectID, LLUUID ownerID, string text, uint parentID) { }
139 public virtual void SendPrimTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, LLVector3 position, LLQuaternion rotation) { } 138 public virtual void SendPrimTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, LLVector3 position, LLQuaternion rotation) { }
140 139
141 public virtual void SendInventoryFolderDetails(LLUUID ownerID, LLUUID folderID, List<InventoryItemBase> items) { } 140 public virtual void SendInventoryFolderDetails(LLUUID ownerID, LLUUID folderID, List<InventoryItemBase> items) { }
@@ -152,8 +151,10 @@ namespace SimpleApp
152 { 151 {
153 Encoding enc = Encoding.ASCII; 152 Encoding enc = Encoding.ASCII;
154 153
155 this.OnAgentUpdate(this, movementFlag, bodyDirection); 154 if (this.OnAgentUpdate != null)
156 155 {
156 this.OnAgentUpdate(this, movementFlag, bodyDirection);
157 }
157 if (this.flyState == 0) 158 if (this.flyState == 0)
158 { 159 {
159 movementFlag = (uint)MainAvatar.ControlFlags.AGENT_CONTROL_FLY | (uint)MainAvatar.ControlFlags.AGENT_CONTROL_UP_NEG; 160 movementFlag = (uint)MainAvatar.ControlFlags.AGENT_CONTROL_FLY | (uint)MainAvatar.ControlFlags.AGENT_CONTROL_UP_NEG;
@@ -172,8 +173,12 @@ namespace SimpleApp
172 173
173 if (count >= 40) 174 if (count >= 40)
174 { 175 {
175 this.OnChatFromViewer(enc.GetBytes("Kind of quiet around here, isn't it! \0"), 2, new LLVector3(128, 128, 26), this.FirstName + " " + this.LastName, this.AgentId); 176 if (OnChatFromViewer != null)
177 {
178 this.OnChatFromViewer(enc.GetBytes("Kind of quiet around here, isn't it! \0"), 2, new LLVector3(128, 128, 26), this.FirstName + " " + this.LastName, this.AgentId);
179 }
176 count = -1; 180 count = -1;
181
177 } 182 }
178 183
179 count++; 184 count++;