Added Scene.ConvertLocalIDToFullID() method.
parent
b3c6920328
commit
45fcbaae1b
|
@ -1023,5 +1023,23 @@ namespace OpenSim.Region.Environment.Scenes
|
|||
ScriptEngine.InitializeEngine(this);
|
||||
}
|
||||
#endregion
|
||||
|
||||
public LLUUID ConvertLocalIDToFullID(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).GetPartsFullID(localID);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -825,5 +825,15 @@ namespace OpenSim.Region.Environment.Scenes
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
public LLUUID GetPartsFullID(uint localID)
|
||||
{
|
||||
SceneObjectPart part = this.GetChildPrim(localID);
|
||||
if (part != null)
|
||||
{
|
||||
return part.UUID;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -300,7 +300,11 @@ namespace OpenSim.Region.Environment.Scenes
|
|||
dupe.Acceleration = new LLVector3(0, 0, 0);
|
||||
dupe.AngularVelocity = new LLVector3(0, 0, 0);
|
||||
dupe.ObjectFlags = this.ObjectFlags;
|
||||
//TODO copy extraparams data and anything else not currently copied
|
||||
|
||||
byte[] extraP = new byte[this.Shape.ExtraParams.Length];
|
||||
Array.Copy(this.Shape.ExtraParams, extraP, extraP.Length);
|
||||
dupe.Shape.ExtraParams = extraP;
|
||||
|
||||
return dupe;
|
||||
}
|
||||
#endregion
|
||||
|
|
|
@ -6,4 +6,18 @@
|
|||
<Key Name="inventoryType" Value="7" />
|
||||
<Key Name="fileName" Value="welcomeNote.dat" />
|
||||
</Section>
|
||||
<Section Name="texture1">
|
||||
<Key Name="assetID" Value="00000000-0000-2222-3333-000000000099" />
|
||||
<Key Name="name" Value="femface" />
|
||||
<Key Name="assetType" Value="0" />
|
||||
<Key Name="inventoryType" Value="0" />
|
||||
<Key Name="fileName" Value="femaleface.jp2" />
|
||||
</Section>
|
||||
<Section Name="test Object1">
|
||||
<Key Name="assetID" Value="00000000-0000-8877-5566-000000000001" />
|
||||
<Key Name="name" Value="test Object" />
|
||||
<Key Name="assetType" Value="6" />
|
||||
<Key Name="inventoryType" Value="6" />
|
||||
<Key Name="fileName" Value="testObject.dat" />
|
||||
</Section>
|
||||
</Nini>
|
Loading…
Reference in New Issue