From 13cb6ef6ef8618f56e4c7a7609bee97ab5fea25a Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Tue, 9 Sep 2014 23:30:31 +0100 Subject: remove the check animState == anim for same reasons --- .../Shared/Api/Implementation/LSL_Api.cs | 26 +++++++++------------- 1 file changed, 10 insertions(+), 16 deletions(-) (limited to 'OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs') diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index caf9fca..b00dbbf 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs @@ -13525,25 +13525,19 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api return; UUID animID; - if (animState == anim) + + animID = ScriptUtils.GetAssetIdFromItemName(m_host, anim, (int)AssetType.Animation); + + if (animID == UUID.Zero) { - animID = UUID.Zero; + String animupper = ((string)anim).ToUpperInvariant(); + DefaultAvatarAnimations.AnimsUUID.TryGetValue(animupper, out animID); } - else - { - animID = ScriptUtils.GetAssetIdFromItemName(m_host, anim, (int)AssetType.Animation); - - if (animID == UUID.Zero) - { - String animupper = ((string)anim).ToUpperInvariant(); - DefaultAvatarAnimations.AnimsUUID.TryGetValue(animupper, out animID); - } - if (animID == UUID.Zero) - { - llShout(ScriptBaseClass.DEBUG_CHANNEL, "Animation not found"); - return; - } + if (animID == UUID.Zero) + { + llShout(ScriptBaseClass.DEBUG_CHANNEL, "Animation not found"); + return; } presence.SetAnimationOverride(state, animID); -- cgit v1.1