diff options
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/SceneManager.cs')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/SceneManager.cs | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/OpenSim/Region/Environment/Scenes/SceneManager.cs b/OpenSim/Region/Environment/Scenes/SceneManager.cs index 75e2a41..da553bc 100644 --- a/OpenSim/Region/Environment/Scenes/SceneManager.cs +++ b/OpenSim/Region/Environment/Scenes/SceneManager.cs | |||
@@ -179,6 +179,35 @@ namespace OpenSim.Region.Environment.Scenes | |||
179 | } | 179 | } |
180 | } | 180 | } |
181 | 181 | ||
182 | public bool TryGetScene(string regionName, out Scene scene) | ||
183 | { | ||
184 | foreach (Scene mscene in m_localScenes) | ||
185 | { | ||
186 | if (String.Compare(mscene.RegionInfo.RegionName, regionName, true) == 0) | ||
187 | { | ||
188 | scene = mscene; | ||
189 | return true; | ||
190 | } | ||
191 | } | ||
192 | scene = null; | ||
193 | return false; | ||
194 | } | ||
195 | |||
196 | public bool TryGetScene(LLUUID regionID, out Scene scene) | ||
197 | { | ||
198 | foreach (Scene mscene in m_localScenes) | ||
199 | { | ||
200 | if (mscene.RegionInfo.RegionID == regionID) | ||
201 | { | ||
202 | scene = mscene; | ||
203 | return true; | ||
204 | } | ||
205 | } | ||
206 | scene = null; | ||
207 | return false; | ||
208 | } | ||
209 | |||
210 | |||
182 | public void SetDebugPacketOnCurrentScene(LogBase log, int newDebug) | 211 | public void SetDebugPacketOnCurrentScene(LogBase log, int newDebug) |
183 | { | 212 | { |
184 | ForEachCurrentScene(delegate(Scene scene) | 213 | ForEachCurrentScene(delegate(Scene scene) |