mirror of
https://github.com/opensim/opensim.git
synced 2026-05-15 03:15:41 +08:00
Added Scene.GetSceneObjectPart(uint localID)
This commit is contained in:
@@ -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;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user