diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs index 45bda635c0..62eb54709b 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.cs @@ -1165,5 +1165,22 @@ namespace OpenSim.Region.Environment.Scenes } return LLUUID.Zero; } + + public SceneObjectPart GetSceneObjectPart(uint localID) + { + bool hasPrim = false; + foreach (EntityBase ent in Entities.Values) + { + if (ent is SceneObjectGroup) + { + hasPrim = ((SceneObjectGroup)ent).HasChildPrim(localID); + if (hasPrim != false) + { + return ((SceneObjectGroup)ent).GetChildPart(localID); + } + } + } + return null; + } } }