diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Data/Null/NullRegionData.cs | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/OpenSim/Data/Null/NullRegionData.cs b/OpenSim/Data/Null/NullRegionData.cs index d596698..f276d10 100644 --- a/OpenSim/Data/Null/NullRegionData.cs +++ b/OpenSim/Data/Null/NullRegionData.cs | |||
@@ -164,30 +164,29 @@ namespace OpenSim.Data.Null | |||
164 | 164 | ||
165 | public List<RegionData> GetDefaultRegions(UUID scopeID) | 165 | public List<RegionData> GetDefaultRegions(UUID scopeID) |
166 | { | 166 | { |
167 | if (Instance != this) | 167 | return Get((int)RegionFlags.DefaultRegion, scopeID); |
168 | return Instance.GetDefaultRegions(scopeID); | 168 | } |
169 | |||
170 | List<RegionData> ret = new List<RegionData>(); | ||
171 | 169 | ||
172 | foreach (RegionData r in m_regionData.Values) | 170 | public List<RegionData> GetFallbackRegions(UUID scopeID, int x, int y) |
173 | { | 171 | { |
174 | if ((Convert.ToInt32(r.Data["flags"]) & 1) != 0) | 172 | return Get((int)RegionFlags.FallbackRegion, scopeID); |
175 | ret.Add(r); | 173 | } |
176 | } | ||
177 | 174 | ||
178 | return ret; | 175 | public List<RegionData> GetHyperlinks(UUID scopeID) |
176 | { | ||
177 | return Get((int)RegionFlags.Hyperlink, scopeID); | ||
179 | } | 178 | } |
180 | 179 | ||
181 | public List<RegionData> GetFallbackRegions(UUID scopeID, int x, int y) | 180 | private List<RegionData> Get(int regionFlags, UUID scopeID) |
182 | { | 181 | { |
183 | if (Instance != this) | 182 | if (Instance != this) |
184 | return Instance.GetFallbackRegions(scopeID, x, y); | 183 | return Instance.Get(regionFlags, scopeID); |
185 | 184 | ||
186 | List<RegionData> ret = new List<RegionData>(); | 185 | List<RegionData> ret = new List<RegionData>(); |
187 | 186 | ||
188 | foreach (RegionData r in m_regionData.Values) | 187 | foreach (RegionData r in m_regionData.Values) |
189 | { | 188 | { |
190 | if ((Convert.ToInt32(r.Data["flags"]) & 2) != 0) | 189 | if ((Convert.ToInt32(r.Data["flags"]) & regionFlags) != 0) |
191 | ret.Add(r); | 190 | ret.Add(r); |
192 | } | 191 | } |
193 | 192 | ||