mirror of
https://github.com/opensim/opensim.git
synced 2026-08-07 17:55:48 +08:00
== UUID.Zero is slow
This commit is contained in:
@@ -182,7 +182,7 @@ namespace OpenSim.Region.Framework.Scenes.Animation
|
||||
{
|
||||
lock (m_animations)
|
||||
{
|
||||
int j = m_defaultAnimation.AnimID == UUID.Zero ? 0 : 1;
|
||||
int j = m_defaultAnimation.AnimID.IsZero() ? 0 : 1;
|
||||
|
||||
int defaultSize = m_animations.Count + j;
|
||||
animIDs = new UUID[defaultSize];
|
||||
|
||||
@@ -55,7 +55,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
private Dictionary<string, UUID> m_overrides = new Dictionary<string, UUID>();
|
||||
public void SetOverride(string state, UUID animID)
|
||||
{
|
||||
if (animID == UUID.Zero)
|
||||
if (animID.IsZero())
|
||||
{
|
||||
if (state == "ALL")
|
||||
m_overrides.Clear();
|
||||
|
||||
@@ -108,7 +108,7 @@ namespace OpenSim.Region.Framework.Scenes.Animation
|
||||
return;
|
||||
|
||||
UUID animID = DefaultAvatarAnimations.GetDefaultAnimation(name);
|
||||
if (animID == UUID.Zero)
|
||||
if (animID.IsZero())
|
||||
return;
|
||||
|
||||
// m_log.DebugFormat("[SCENE PRESENCE ANIMATOR]: Adding animation {0} {1} for {2}", animID, name, m_scenePresence.Name);
|
||||
@@ -164,7 +164,7 @@ namespace OpenSim.Region.Framework.Scenes.Animation
|
||||
return;
|
||||
|
||||
UUID animID = DefaultAvatarAnimations.GetDefaultAnimation(name);
|
||||
if (animID == UUID.Zero)
|
||||
if (animID.IsZero())
|
||||
return;
|
||||
|
||||
RemoveAnimation(animID, true);
|
||||
@@ -213,7 +213,7 @@ namespace OpenSim.Region.Framework.Scenes.Animation
|
||||
if (anim == "SITGROUND")
|
||||
{
|
||||
UUID defsit = DefaultAvatarAnimations.AnimsUUIDbyName["SIT_GROUND_CONSTRAINED"];
|
||||
if (defsit == UUID.Zero)
|
||||
if (defsit.IsZero())
|
||||
return false;
|
||||
m_animations.SetDefaultAnimation(defsit, m_scenePresence.ControllingClient.NextAnimationSequenceNumber, m_scenePresence.UUID);
|
||||
aoSitGndAnim = overridenAnim;
|
||||
|
||||
Reference in New Issue
Block a user