diff options
Diffstat (limited to 'OpenSim/Region/ClientStack/ClientView.API.cs')
-rw-r--r-- | OpenSim/Region/ClientStack/ClientView.API.cs | 28 |
1 files changed, 15 insertions, 13 deletions
diff --git a/OpenSim/Region/ClientStack/ClientView.API.cs b/OpenSim/Region/ClientStack/ClientView.API.cs index beb83af..428fb77 100644 --- a/OpenSim/Region/ClientStack/ClientView.API.cs +++ b/OpenSim/Region/ClientStack/ClientView.API.cs | |||
@@ -268,29 +268,27 @@ namespace OpenSim.Region.ClientStack | |||
268 | /// <remarks>TODO</remarks> | 268 | /// <remarks>TODO</remarks> |
269 | /// <param name="message"></param> | 269 | /// <param name="message"></param> |
270 | /// <param name="target"></param> | 270 | /// <param name="target"></param> |
271 | public void SendInstantMessage(string message, LLUUID target, string fromName) | 271 | public void SendInstantMessage(LLUUID fromAgent, LLUUID fromAgentSession, string message, LLUUID toAgent, LLUUID imSessionID, string fromName, byte dialog, uint timeStamp) |
272 | { | 272 | { |
273 | if (message != "typing") | 273 | |
274 | { | ||
275 | Encoding enc = Encoding.ASCII; | 274 | Encoding enc = Encoding.ASCII; |
276 | ImprovedInstantMessagePacket msg = new ImprovedInstantMessagePacket(); | 275 | ImprovedInstantMessagePacket msg = new ImprovedInstantMessagePacket(); |
277 | msg.AgentData.AgentID = this.AgentID; | 276 | msg.AgentData.AgentID = fromAgent; |
278 | msg.AgentData.SessionID = this.SessionID; | 277 | msg.AgentData.SessionID = fromAgentSession; |
279 | msg.MessageBlock.FromAgentName = enc.GetBytes(fromName + " \0"); | 278 | msg.MessageBlock.FromAgentName = enc.GetBytes(fromName + " \0"); |
280 | msg.MessageBlock.Dialog = 0; | 279 | msg.MessageBlock.Dialog = dialog; |
281 | msg.MessageBlock.FromGroup = false; | 280 | msg.MessageBlock.FromGroup = false; |
282 | msg.MessageBlock.ID = target.Combine(this.SecureSessionID); | 281 | msg.MessageBlock.ID = imSessionID; |
283 | msg.MessageBlock.Offline = 0; | 282 | msg.MessageBlock.Offline = 0; |
284 | msg.MessageBlock.ParentEstateID = 0; | 283 | msg.MessageBlock.ParentEstateID = 0; |
285 | msg.MessageBlock.Position = new LLVector3(); | 284 | msg.MessageBlock.Position = new LLVector3(); |
286 | msg.MessageBlock.RegionID = new LLUUID(); | 285 | msg.MessageBlock.RegionID = LLUUID.Random(); |
287 | msg.MessageBlock.Timestamp = 0; | 286 | msg.MessageBlock.Timestamp = timeStamp; |
288 | msg.MessageBlock.ToAgentID = target; | 287 | msg.MessageBlock.ToAgentID = toAgent; |
289 | msg.MessageBlock.Message = enc.GetBytes(message + "\0"); | 288 | msg.MessageBlock.Message = enc.GetBytes(message + "\0"); |
290 | msg.MessageBlock.BinaryBucket = new byte[0]; | 289 | msg.MessageBlock.BinaryBucket = new byte[0]; |
291 | 290 | ||
292 | this.OutPacket(msg); | 291 | this.OutPacket(msg); |
293 | } | ||
294 | } | 292 | } |
295 | 293 | ||
296 | /// <summary> | 294 | /// <summary> |
@@ -927,7 +925,7 @@ namespace OpenSim.Region.ClientStack | |||
927 | { | 925 | { |
928 | ObjectUpdatePacket outPacket = new ObjectUpdatePacket(); | 926 | ObjectUpdatePacket outPacket = new ObjectUpdatePacket(); |
929 | outPacket.RegionData.RegionHandle = regionHandle; | 927 | outPacket.RegionData.RegionHandle = regionHandle; |
930 | outPacket.RegionData.TimeDilation = timeDilation; | 928 | outPacket.RegionData.TimeDilation = timeDilation; |
931 | outPacket.ObjectData = new ObjectUpdatePacket.ObjectDataBlock[1]; | 929 | outPacket.ObjectData = new ObjectUpdatePacket.ObjectDataBlock[1]; |
932 | 930 | ||
933 | outPacket.ObjectData[0] = this.CreatePrimUpdateBlock(primShape, flags); | 931 | outPacket.ObjectData[0] = this.CreatePrimUpdateBlock(primShape, flags); |
@@ -938,6 +936,9 @@ namespace OpenSim.Region.ClientStack | |||
938 | outPacket.ObjectData[0].Text = Helpers.StringToField(text); | 936 | outPacket.ObjectData[0].Text = Helpers.StringToField(text); |
939 | outPacket.ObjectData[0].ParentID = parentID; | 937 | outPacket.ObjectData[0].ParentID = parentID; |
940 | outPacket.ObjectData[0].PSBlock = particleSystem; | 938 | outPacket.ObjectData[0].PSBlock = particleSystem; |
939 | outPacket.ObjectData[0].ClickAction = 0; | ||
940 | //outPacket.ObjectData[0].Flags = 0; | ||
941 | outPacket.ObjectData[0].Radius = 20; | ||
941 | 942 | ||
942 | byte[] pb = pos.GetBytes(); | 943 | byte[] pb = pos.GetBytes(); |
943 | Array.Copy(pb, 0, outPacket.ObjectData[0].ObjectData, 0, pb.Length); | 944 | Array.Copy(pb, 0, outPacket.ObjectData[0].ObjectData, 0, pb.Length); |
@@ -1045,6 +1046,7 @@ namespace OpenSim.Region.ClientStack | |||
1045 | bytes[i++] = (byte)((ac >> 8) % 256); | 1046 | bytes[i++] = (byte)((ac >> 8) % 256); |
1046 | 1047 | ||
1047 | dat.Data = bytes; | 1048 | dat.Data = bytes; |
1049 | |||
1048 | return (dat); | 1050 | return (dat); |
1049 | } | 1051 | } |
1050 | 1052 | ||
@@ -1196,7 +1198,7 @@ namespace OpenSim.Region.ClientStack | |||
1196 | ObjectUpdatePacket.ObjectDataBlock objdata = new ObjectUpdatePacket.ObjectDataBlock(); // new libsecondlife.Packets.ObjectUpdatePacket.ObjectDataBlock(data1, ref i); | 1198 | ObjectUpdatePacket.ObjectDataBlock objdata = new ObjectUpdatePacket.ObjectDataBlock(); // new libsecondlife.Packets.ObjectUpdatePacket.ObjectDataBlock(data1, ref i); |
1197 | 1199 | ||
1198 | SetDefaultAvatarPacketValues(ref objdata); | 1200 | SetDefaultAvatarPacketValues(ref objdata); |
1199 | objdata.UpdateFlags = 61 + (9 << 8) + (130 << 16) + (16 << 24); | 1201 | objdata.UpdateFlags = 61 + (9 << 8) + (130 << 16) + (16 << 24); |
1200 | objdata.PathCurve = 16; | 1202 | objdata.PathCurve = 16; |
1201 | objdata.ProfileCurve = 1; | 1203 | objdata.ProfileCurve = 1; |
1202 | objdata.PathScaleX = 100; | 1204 | objdata.PathScaleX = 100; |