aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/CoreModules/Avatar/Chat/ChatModule.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/CoreModules/Avatar/Chat/ChatModule.cs')
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Chat/ChatModule.cs7
1 files changed, 5 insertions, 2 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Chat/ChatModule.cs b/OpenSim/Region/CoreModules/Avatar/Chat/ChatModule.cs
index 10122e6..a9d2de0 100644
--- a/OpenSim/Region/CoreModules/Avatar/Chat/ChatModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Chat/ChatModule.cs
@@ -274,17 +274,20 @@ namespace OpenSim.Region.CoreModules.Avatar.Chat
274 string fromName = c.From; 274 string fromName = c.From;
275 275
276 UUID fromID = UUID.Zero; 276 UUID fromID = UUID.Zero;
277 UUID ownerID = UUID.Zero;
277 ChatSourceType sourceType = ChatSourceType.Object; 278 ChatSourceType sourceType = ChatSourceType.Object;
278 if (null != c.Sender) 279 if (null != c.Sender)
279 { 280 {
280 ScenePresence avatar = (c.Scene as Scene).GetScenePresence(c.Sender.AgentId); 281 ScenePresence avatar = (c.Scene as Scene).GetScenePresence(c.Sender.AgentId);
281 fromID = c.Sender.AgentId; 282 fromID = c.Sender.AgentId;
282 fromName = avatar.Name; 283 fromName = avatar.Name;
284 ownerID = c.Sender.AgentId;
283 sourceType = ChatSourceType.Agent; 285 sourceType = ChatSourceType.Agent;
284 } 286 }
285 else if (c.SenderUUID != UUID.Zero) 287 else if (c.SenderUUID != UUID.Zero)
286 { 288 {
287 fromID = c.SenderUUID; 289 fromID = c.SenderUUID;
290 ownerID = ((SceneObjectPart)c.SenderObject).OwnerID;
288 } 291 }
289 292
290 // m_log.DebugFormat("[CHAT] Broadcast: fromID {0} fromName {1}, cType {2}, sType {3}", fromID, fromName, cType, sourceType); 293 // m_log.DebugFormat("[CHAT] Broadcast: fromID {0} fromName {1}, cType {2}, sType {3}", fromID, fromName, cType, sourceType);
@@ -302,7 +305,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Chat
302 return; 305 return;
303 306
304 client.SendChatMessage( 307 client.SendChatMessage(
305 c.Message, (byte)cType, CenterOfRegion, fromName, fromID, fromID, 308 c.Message, (byte)cType, CenterOfRegion, fromName, fromID, ownerID,
306 (byte)sourceType, (byte)ChatAudibleLevel.Fully); 309 (byte)sourceType, (byte)ChatAudibleLevel.Fully);
307 310
308 receiverIDs.Add(client.AgentId); 311 receiverIDs.Add(client.AgentId);