mirror of
https://github.com/opensim/opensim.git
synced 2026-08-07 17:55:48 +08:00
Merge branch 'master' into careminster
Conflicts: OpenSim/Framework/ChildAgentDataUpdate.cs OpenSim/Region/Framework/Scenes/ScenePresence.cs
This commit is contained in:
@@ -45,6 +45,11 @@ namespace OpenSim.Region.Framework.Scenes.Animation
|
||||
private OpenSim.Framework.Animation m_defaultAnimation = new OpenSim.Framework.Animation();
|
||||
private List<OpenSim.Framework.Animation> m_animations = new List<OpenSim.Framework.Animation>();
|
||||
|
||||
public OpenSim.Framework.Animation DefaultAnimation
|
||||
{
|
||||
get { return m_defaultAnimation; }
|
||||
}
|
||||
|
||||
public OpenSim.Framework.Animation ImplicitDefaultAnimation
|
||||
{
|
||||
get { return m_implicitDefaultAnimation; }
|
||||
@@ -126,6 +131,12 @@ namespace OpenSim.Region.Framework.Scenes.Animation
|
||||
return false;
|
||||
}
|
||||
|
||||
// Called from serialization only
|
||||
public void SetImplicitDefaultAnimation(UUID animID, int sequenceNum, UUID objectID)
|
||||
{
|
||||
m_implicitDefaultAnimation = new OpenSim.Framework.Animation(animID, sequenceNum, objectID);
|
||||
}
|
||||
|
||||
protected bool ResetDefaultAnimation()
|
||||
{
|
||||
return TrySetDefaultAnimation("STAND", 1, UUID.Zero);
|
||||
|
||||
@@ -1748,15 +1748,19 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
|
||||
private void CheckAtTargets()
|
||||
{
|
||||
List<SceneObjectGroup> objs = new List<SceneObjectGroup>();
|
||||
List<SceneObjectGroup> objs = null;
|
||||
|
||||
lock (m_groupsWithTargets)
|
||||
{
|
||||
foreach (SceneObjectGroup grp in m_groupsWithTargets.Values)
|
||||
objs.Add(grp);
|
||||
if (m_groupsWithTargets.Count != 0)
|
||||
objs = new List<SceneObjectGroup>(m_groupsWithTargets.Values);
|
||||
}
|
||||
|
||||
foreach (SceneObjectGroup entry in objs)
|
||||
entry.checkAtTargets();
|
||||
if (objs != null)
|
||||
{
|
||||
foreach (SceneObjectGroup entry in objs)
|
||||
entry.checkAtTargets();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -3276,7 +3276,8 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
cAgent.Anims = Animator.Animations.ToArray();
|
||||
}
|
||||
catch { }
|
||||
cAgent.DefaultAnim = Animator.Animations.ImplicitDefaultAnimation;
|
||||
cAgent.DefaultAnim = Animator.Animations.DefaultAnimation;
|
||||
cAgent.AnimState = Animator.Animations.ImplicitDefaultAnimation;
|
||||
|
||||
if (Scene.AttachmentsModule != null)
|
||||
Scene.AttachmentsModule.CopyAttachments(this, cAgent);
|
||||
@@ -3353,6 +3354,8 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
Animator.Animations.FromArray(cAgent.Anims);
|
||||
if (cAgent.DefaultAnim != null)
|
||||
Animator.Animations.SetDefaultAnimation(cAgent.DefaultAnim.AnimID, cAgent.DefaultAnim.SequenceNum, UUID.Zero);
|
||||
if (cAgent.AnimState != null)
|
||||
Animator.Animations.SetImplicitDefaultAnimation(cAgent.AnimState.AnimID, cAgent.AnimState.SequenceNum, UUID.Zero);
|
||||
|
||||
if (Scene.AttachmentsModule != null)
|
||||
Scene.AttachmentsModule.CopyAttachments(cAgent, this);
|
||||
|
||||
Reference in New Issue
Block a user