From b738b50cd609b9a71d2780e31edfbd1143c1dee1 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 61b04ba86a..7512bd08e7 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs @@ -4579,6 +4579,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 ///