aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorMelanie Thielker2008-07-31 10:58:15 +0000
committerMelanie Thielker2008-07-31 10:58:15 +0000
commitb3e19359d972fde84f4397ed831e876741ca4c5f (patch)
tree189d0c27d8e7a31b658442ea4f043c83fdf06779
parentThank you, sacha magne, for a patch that implements (diff)
downloadopensim-SC_OLD-b3e19359d972fde84f4397ed831e876741ca4c5f.zip
opensim-SC_OLD-b3e19359d972fde84f4397ed831e876741ca4c5f.tar.gz
opensim-SC_OLD-b3e19359d972fde84f4397ed831e876741ca4c5f.tar.bz2
opensim-SC_OLD-b3e19359d972fde84f4397ed831e876741ca4c5f.tar.xz
Thank you, sacha magne, for a patch that prevents sim chat from
being heard across whole grids. Fixes Mantis #1855
-rw-r--r--OpenSim/Region/Environment/Modules/Avatar/Chat/ChatModule.cs5
1 files changed, 4 insertions, 1 deletions
diff --git a/OpenSim/Region/Environment/Modules/Avatar/Chat/ChatModule.cs b/OpenSim/Region/Environment/Modules/Avatar/Chat/ChatModule.cs
index 0e397d6..f98633f 100644
--- a/OpenSim/Region/Environment/Modules/Avatar/Chat/ChatModule.cs
+++ b/OpenSim/Region/Environment/Modules/Avatar/Chat/ChatModule.cs
@@ -222,7 +222,10 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Chat
222 if (presence.IsChildAgent) return; 222 if (presence.IsChildAgent) return;
223 223
224 LLVector3 fromRegionPos = fromPos + regionPos; 224 LLVector3 fromRegionPos = fromPos + regionPos;
225 LLVector3 toRegionPos = presence.AbsolutePosition + regionPos; 225 LLVector3 toRegionPos = presence.AbsolutePosition +
226 new LLVector3(presence.Scene.RegionInfo.RegionLocX * Constants.RegionSize,
227 presence.Scene.RegionInfo.RegionLocY * Constants.RegionSize, 0);
228
226 int dis = Math.Abs((int) Util.GetDistanceTo(toRegionPos, fromRegionPos)); 229 int dis = Math.Abs((int) Util.GetDistanceTo(toRegionPos, fromRegionPos));
227 230
228 if (type == ChatTypeEnum.Whisper && dis > m_whisperdistance || 231 if (type == ChatTypeEnum.Whisper && dis > m_whisperdistance ||