mirror of
https://github.com/opensim/opensim.git
synced 2026-08-08 02:05:34 +08:00
Plumb the path from the client to the extra physics params and back
This commit is contained in:
@@ -1408,7 +1408,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
/// <param name="SetPhantom"></param>
|
||||
/// <param name="remoteClient"></param>
|
||||
protected internal void UpdatePrimFlags(
|
||||
uint localID, bool UsePhysics, bool SetTemporary, bool SetPhantom, IClientAPI remoteClient)
|
||||
uint localID, bool UsePhysics, bool SetTemporary, bool SetPhantom, ExtraPhysicsData PhysData, IClientAPI remoteClient)
|
||||
{
|
||||
SceneObjectGroup group = GetGroupByPrim(localID);
|
||||
if (group != null)
|
||||
@@ -1416,7 +1416,28 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
if (m_parentScene.Permissions.CanEditObject(group.UUID, remoteClient.AgentId))
|
||||
{
|
||||
// VolumeDetect can't be set via UI and will always be off when a change is made there
|
||||
group.UpdatePrimFlags(localID, UsePhysics, SetTemporary, SetPhantom, false);
|
||||
// now only change volume dtc if phantom off
|
||||
|
||||
if (PhysData.PhysShapeType == PhysShapeType.invalid) // check for extraPhysics data
|
||||
{
|
||||
bool vdtc;
|
||||
if (SetPhantom) // if phantom keep volumedtc
|
||||
vdtc = group.RootPart.VolumeDetectActive;
|
||||
else // else turn it off
|
||||
vdtc = false;
|
||||
|
||||
group.UpdatePrimFlags(localID, UsePhysics, SetTemporary, SetPhantom, vdtc);
|
||||
}
|
||||
else
|
||||
{
|
||||
SceneObjectPart part = GetSceneObjectPart(localID);
|
||||
if (part != null)
|
||||
{
|
||||
part.UpdateExtraPhysics(PhysData);
|
||||
if (part.UpdatePhysRequired)
|
||||
remoteClient.SendPartPhysicsProprieties(part);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user