From 25ae59b9ebf71d39d2ff5237b791f2599f4fa082 Mon Sep 17 00:00:00 2001 From: Robert Adams Date: Wed, 2 Oct 2013 16:57:02 -0700 Subject: varregion: remove scattered use of Constants.RegionSize by having routines reference RegionInfo.RegionWorldLoc?. --- OpenSim/Region/CoreModules/Avatar/Chat/ChatModule.cs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'OpenSim/Region/CoreModules/Avatar/Chat/ChatModule.cs') diff --git a/OpenSim/Region/CoreModules/Avatar/Chat/ChatModule.cs b/OpenSim/Region/CoreModules/Avatar/Chat/ChatModule.cs index 4616170..7bc5e51 100644 --- a/OpenSim/Region/CoreModules/Avatar/Chat/ChatModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Chat/ChatModule.cs @@ -180,8 +180,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Chat string message = c.Message; Scene scene = (Scene)c.Scene; Vector3 fromPos = c.Position; - Vector3 regionPos = new Vector3(scene.RegionInfo.LegacyRegionLocX * Constants.RegionSize, - scene.RegionInfo.LegacyRegionLocY * Constants.RegionSize, 0); + Vector3 regionPos = new Vector3(scene.RegionInfo.RegionWorldLocX, scene.RegionInfo.RegionWorldLocY, 0); if (c.Channel == DEBUG_CHANNEL) c.Type = ChatTypeEnum.DebugChannel; @@ -333,8 +332,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Chat { Vector3 fromRegionPos = fromPos + regionPos; Vector3 toRegionPos = presence.AbsolutePosition + - new Vector3(presence.Scene.RegionInfo.LegacyRegionLocX * Constants.RegionSize, - presence.Scene.RegionInfo.LegacyRegionLocY * Constants.RegionSize, 0); + new Vector3(presence.Scene.RegionInfo.RegionWorldLocX, presence.Scene.RegionInfo.RegionWorldLocY, 0); int dis = (int)Util.GetDistanceTo(toRegionPos, fromRegionPos); -- cgit v1.1