aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework
diff options
context:
space:
mode:
authorRobert Adams2015-03-28 07:50:04 -0700
committerRobert Adams2015-03-28 07:50:04 -0700
commit08c72a8dc1e54114559521a6c2952905ecf6f105 (patch)
treecdc1f379109500504516755fcd3d4e9c6c4e3218 /OpenSim/Framework
parentvarregion: refactor use of 'double heightmap[,]' into references to new class... (diff)
downloadopensim-SC_OLD-08c72a8dc1e54114559521a6c2952905ecf6f105.zip
opensim-SC_OLD-08c72a8dc1e54114559521a6c2952905ecf6f105.tar.gz
opensim-SC_OLD-08c72a8dc1e54114559521a6c2952905ecf6f105.tar.bz2
opensim-SC_OLD-08c72a8dc1e54114559521a6c2952905ecf6f105.tar.xz
varregion: remove use of Constants.RegionSize is various places.
More use of the Util routines for conversion of region handles into addresses.
Diffstat (limited to '')
-rw-r--r--OpenSim/Framework/RegionInfo.cs1
-rw-r--r--OpenSim/Framework/UserProfileData.cs12
2 files changed, 9 insertions, 4 deletions
diff --git a/OpenSim/Framework/RegionInfo.cs b/OpenSim/Framework/RegionInfo.cs
index 90188d2..019fffc 100644
--- a/OpenSim/Framework/RegionInfo.cs
+++ b/OpenSim/Framework/RegionInfo.cs
@@ -825,6 +825,7 @@ namespace OpenSim.Framework
825 825
826 if (DataStore != String.Empty) 826 if (DataStore != String.Empty)
827 config.Set("Datastore", DataStore); 827 config.Set("Datastore", DataStore);
828
828 if (RegionSizeX != Constants.RegionSize || RegionSizeY != Constants.RegionSize) 829 if (RegionSizeX != Constants.RegionSize || RegionSizeY != Constants.RegionSize)
829 { 830 {
830 config.Set("SizeX", RegionSizeX); 831 config.Set("SizeX", RegionSizeX);
diff --git a/OpenSim/Framework/UserProfileData.cs b/OpenSim/Framework/UserProfileData.cs
index 9bac739..f7069a5 100644
--- a/OpenSim/Framework/UserProfileData.cs
+++ b/OpenSim/Framework/UserProfileData.cs
@@ -161,14 +161,18 @@ namespace OpenSim.Framework
161 { 161 {
162 get 162 get
163 { 163 {
164 return Utils.UIntsToLong( 164 return Util.RegionWorldLocToHandle(Util.RegionToWorldLoc(m_homeRegionX), Util.RegionToWorldLoc(m_homeRegionY));
165 m_homeRegionX * (uint)Constants.RegionSize, m_homeRegionY * (uint)Constants.RegionSize); 165 // return Utils.UIntsToLong( m_homeRegionX * (uint)Constants.RegionSize, m_homeRegionY * (uint)Constants.RegionSize);
166 } 166 }
167 167
168 set 168 set
169 { 169 {
170 m_homeRegionX = (uint) (value >> 40); 170 uint regionWorldLocX, regionWorldLocY;
171 m_homeRegionY = (((uint) (value)) >> 8); 171 Util.RegionHandleToWorldLoc(value, out regionWorldLocX, out regionWorldLocY);
172 m_homeRegionX = Util.WorldToRegionLoc(regionWorldLocX);
173 m_homeRegionY = Util.WorldToRegionLoc(regionWorldLocY);
174 // m_homeRegionX = (uint) (value >> 40);
175 // m_homeRegionY = (((uint) (value)) >> 8);
172 } 176 }
173 } 177 }
174 178