diff options
Diffstat (limited to 'OpenSim/Services/Interfaces/IGridService.cs')
-rw-r--r-- | OpenSim/Services/Interfaces/IGridService.cs | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/OpenSim/Services/Interfaces/IGridService.cs b/OpenSim/Services/Interfaces/IGridService.cs index 19ea0fe..1119e48 100644 --- a/OpenSim/Services/Interfaces/IGridService.cs +++ b/OpenSim/Services/Interfaces/IGridService.cs | |||
@@ -179,14 +179,14 @@ namespace OpenSim.Services.Interfaces | |||
179 | protected IPEndPoint m_internalEndPoint; | 179 | protected IPEndPoint m_internalEndPoint; |
180 | 180 | ||
181 | /// <summary> | 181 | /// <summary> |
182 | /// The co-ordinate of this region. | 182 | /// The co-ordinate of this region in region units. |
183 | /// </summary> | 183 | /// </summary> |
184 | public int RegionCoordX { get { return RegionLocX / (int)Constants.RegionSize; } } | 184 | public int RegionCoordX { get { return (int)Util.WorldToRegionLoc((uint)RegionLocX); } } |
185 | 185 | ||
186 | /// <summary> | 186 | /// <summary> |
187 | /// The co-ordinate of this region | 187 | /// The co-ordinate of this region in region units |
188 | /// </summary> | 188 | /// </summary> |
189 | public int RegionCoordY { get { return RegionLocY / (int)Constants.RegionSize; } } | 189 | public int RegionCoordY { get { return (int)Util.WorldToRegionLoc((uint)RegionLocY); } } |
190 | 190 | ||
191 | /// <summary> | 191 | /// <summary> |
192 | /// The location of this region in meters. | 192 | /// The location of this region in meters. |
@@ -265,8 +265,8 @@ namespace OpenSim.Services.Interfaces | |||
265 | 265 | ||
266 | public GridRegion(uint xcell, uint ycell) | 266 | public GridRegion(uint xcell, uint ycell) |
267 | { | 267 | { |
268 | m_regionLocX = (int)(xcell * Constants.RegionSize); | 268 | m_regionLocX = (int)Util.RegionToWorldLoc(xcell); |
269 | m_regionLocY = (int)(ycell * Constants.RegionSize); | 269 | m_regionLocY = (int)Util.RegionToWorldLoc(ycell); |
270 | RegionSizeX = (int)Constants.RegionSize; | 270 | RegionSizeX = (int)Constants.RegionSize; |
271 | RegionSizeY = (int)Constants.RegionSize; | 271 | RegionSizeY = (int)Constants.RegionSize; |
272 | } | 272 | } |
@@ -274,8 +274,8 @@ namespace OpenSim.Services.Interfaces | |||
274 | public GridRegion(RegionInfo ConvertFrom) | 274 | public GridRegion(RegionInfo ConvertFrom) |
275 | { | 275 | { |
276 | m_regionName = ConvertFrom.RegionName; | 276 | m_regionName = ConvertFrom.RegionName; |
277 | m_regionLocX = (int)(ConvertFrom.RegionLocX * Constants.RegionSize); | 277 | m_regionLocX = (int)(ConvertFrom.WorldLocX); |
278 | m_regionLocY = (int)(ConvertFrom.RegionLocY * Constants.RegionSize); | 278 | m_regionLocY = (int)(ConvertFrom.WorldLocY); |
279 | RegionSizeX = (int)ConvertFrom.RegionSizeX; | 279 | RegionSizeX = (int)ConvertFrom.RegionSizeX; |
280 | RegionSizeY = (int)ConvertFrom.RegionSizeY; | 280 | RegionSizeY = (int)ConvertFrom.RegionSizeY; |
281 | m_internalEndPoint = ConvertFrom.InternalEndPoint; | 281 | m_internalEndPoint = ConvertFrom.InternalEndPoint; |