Enforce physical prim max size on single prims.
Also convert a lock() to ReaderWriterLockSlim that i missed in the last commitavinationmerge
parent
9888f95068
commit
2e6dce434f
|
@ -2871,11 +2871,9 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
scale.Y = m_scene.m_maxNonphys;
|
scale.Y = m_scene.m_maxNonphys;
|
||||||
if (scale.Z > m_scene.m_maxNonphys)
|
if (scale.Z > m_scene.m_maxNonphys)
|
||||||
scale.Z = m_scene.m_maxNonphys;
|
scale.Z = m_scene.m_maxNonphys;
|
||||||
|
|
||||||
SceneObjectPart part = GetChildPart(localID);
|
SceneObjectPart part = GetChildPart(localID);
|
||||||
if (part != null)
|
if (part != null)
|
||||||
{
|
{
|
||||||
part.Resize(scale);
|
|
||||||
if (part.PhysActor != null)
|
if (part.PhysActor != null)
|
||||||
{
|
{
|
||||||
if (part.PhysActor.IsPhysical)
|
if (part.PhysActor.IsPhysical)
|
||||||
|
@ -2890,7 +2888,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
part.PhysActor.Size = scale;
|
part.PhysActor.Size = scale;
|
||||||
m_scene.PhysicsScene.AddPhysicsActorTaint(part.PhysActor);
|
m_scene.PhysicsScene.AddPhysicsActorTaint(part.PhysActor);
|
||||||
}
|
}
|
||||||
//if (part.UUID != m_rootPart.UUID)
|
part.Resize(scale);
|
||||||
|
|
||||||
HasGroupChanged = true;
|
HasGroupChanged = true;
|
||||||
ScheduleGroupForFullUpdate();
|
ScheduleGroupForFullUpdate();
|
||||||
|
@ -2931,8 +2929,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
float y = (scale.Y / part.Scale.Y);
|
float y = (scale.Y / part.Scale.Y);
|
||||||
float z = (scale.Z / part.Scale.Z);
|
float z = (scale.Z / part.Scale.Z);
|
||||||
|
|
||||||
lock (m_parts)
|
lockPartsForRead(true);
|
||||||
{
|
|
||||||
if (x > 1.0f || y > 1.0f || z > 1.0f)
|
if (x > 1.0f || y > 1.0f || z > 1.0f)
|
||||||
{
|
{
|
||||||
foreach (SceneObjectPart obPart in m_parts.Values)
|
foreach (SceneObjectPart obPart in m_parts.Values)
|
||||||
|
@ -3001,7 +2998,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
lockPartsForRead(false);
|
||||||
|
|
||||||
Vector3 prevScale = part.Scale;
|
Vector3 prevScale = part.Scale;
|
||||||
prevScale.X *= x;
|
prevScale.X *= x;
|
||||||
|
|
Loading…
Reference in New Issue