From 14163f43c07bc8e82fd1c61634c651a1e91b4d4a Mon Sep 17 00:00:00 2001 From: SignpostMarv Date: Thu, 6 Sep 2012 10:40:37 +0100 Subject: [PATCH] adding utility method for getting SceneObjectPart from scene Signed-off-by: BlueWall --- OpenSim/Region/Framework/Scenes/Scene.cs | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index 500fae373e..a2d553d237 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs @@ -4624,6 +4624,18 @@ namespace OpenSim.Region.Framework.Scenes return m_sceneGraph.GetSceneObjectPart(fullID); } + /// + /// Attempt to get a prim via its UUID + /// + /// + /// + /// + public bool TryGetSceneObjectPart(UUID fullID, out SceneObjectPart sop) + { + sop = GetSceneObjectPart(fullID); + return sop != null; + } + /// /// Get a scene object group that contains the prim with the given local id ///