Harmonizing SP with Avination
parent
219ec7ef20
commit
2347593dac
|
@ -118,7 +118,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
/// TODO: For some reason, we effectively have a list both here and in Appearance. Need to work out if this is
|
/// TODO: For some reason, we effectively have a list both here and in Appearance. Need to work out if this is
|
||||||
/// necessary.
|
/// necessary.
|
||||||
/// </remarks>
|
/// </remarks>
|
||||||
protected List<SceneObjectGroup> m_attachments = new List<SceneObjectGroup>();
|
private List<SceneObjectGroup> m_attachments = new List<SceneObjectGroup>();
|
||||||
|
|
||||||
public Object AttachmentsSyncLock { get; private set; }
|
public Object AttachmentsSyncLock { get; private set; }
|
||||||
|
|
||||||
|
@ -550,8 +550,12 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Don't update while sitting
|
||||||
|
if (ParentID == 0)
|
||||||
|
{
|
||||||
m_pos = value;
|
m_pos = value;
|
||||||
ParentPosition = Vector3.Zero;
|
ParentPosition = Vector3.Zero;
|
||||||
|
}
|
||||||
|
|
||||||
//m_log.DebugFormat(
|
//m_log.DebugFormat(
|
||||||
// "[ENTITY BASE]: In {0} set AbsolutePosition of {1} to {2}",
|
// "[ENTITY BASE]: In {0} set AbsolutePosition of {1} to {2}",
|
||||||
|
@ -566,6 +570,13 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
public Vector3 OffsetPosition
|
public Vector3 OffsetPosition
|
||||||
{
|
{
|
||||||
get { return m_pos; }
|
get { return m_pos; }
|
||||||
|
set
|
||||||
|
{
|
||||||
|
// There is no offset position when not seated
|
||||||
|
if (ParentID == 0)
|
||||||
|
return;
|
||||||
|
m_pos = value;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -2740,8 +2751,10 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
if (IsChildAgent)
|
if (IsChildAgent)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
// We only do this if we have a physics actor or we're sitting on something
|
if (ParentID != 0)
|
||||||
if (ParentID == 0 && PhysicsActor != null || ParentID != 0)
|
return;
|
||||||
|
|
||||||
|
if (!IsInTransit)
|
||||||
{
|
{
|
||||||
Vector3 pos2 = AbsolutePosition;
|
Vector3 pos2 = AbsolutePosition;
|
||||||
Vector3 vel = Velocity;
|
Vector3 vel = Velocity;
|
||||||
|
@ -3100,16 +3113,15 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
catch { }
|
catch { }
|
||||||
|
|
||||||
// Attachment objects
|
// Attachment objects
|
||||||
lock (m_attachments)
|
List<SceneObjectGroup> attachments = GetAttachments();
|
||||||
{
|
if (attachments.Count > 0)
|
||||||
if (m_attachments.Count > 0)
|
|
||||||
{
|
{
|
||||||
cAgent.AttachmentObjects = new List<ISceneObject>();
|
cAgent.AttachmentObjects = new List<ISceneObject>();
|
||||||
cAgent.AttachmentObjectStates = new List<string>();
|
cAgent.AttachmentObjectStates = new List<string>();
|
||||||
// IScriptModule se = m_scene.RequestModuleInterface<IScriptModule>();
|
// IScriptModule se = m_scene.RequestModuleInterface<IScriptModule>();
|
||||||
InTransitScriptStates.Clear();
|
InTransitScriptStates.Clear();
|
||||||
|
|
||||||
foreach (SceneObjectGroup sog in m_attachments)
|
foreach (SceneObjectGroup sog in attachments)
|
||||||
{
|
{
|
||||||
// We need to make a copy and pass that copy
|
// We need to make a copy and pass that copy
|
||||||
// because of transfers withn the same sim
|
// because of transfers withn the same sim
|
||||||
|
@ -3126,7 +3138,6 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
private void CopyFrom(AgentData cAgent)
|
private void CopyFrom(AgentData cAgent)
|
||||||
{
|
{
|
||||||
|
@ -3530,6 +3541,8 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
/// <param name="eventName">The name of the event</param>
|
/// <param name="eventName">The name of the event</param>
|
||||||
/// <param name="args">The arguments for the event</param>
|
/// <param name="args">The arguments for the event</param>
|
||||||
public void SendScriptEventToAttachments(string eventName, Object[] args)
|
public void SendScriptEventToAttachments(string eventName, Object[] args)
|
||||||
|
{
|
||||||
|
Util.FireAndForget(delegate(object x)
|
||||||
{
|
{
|
||||||
if (m_scriptEngines.Length == 0)
|
if (m_scriptEngines.Length == 0)
|
||||||
return;
|
return;
|
||||||
|
@ -3551,6 +3564,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
internal void PushForce(Vector3 impulse)
|
internal void PushForce(Vector3 impulse)
|
||||||
|
|
Loading…
Reference in New Issue