fBaseXtensions.Game.Hero.Skills.Skill.Activation C# (CSharp) Method

Activation() private method

private Activation ( ) : bool
return bool
        internal virtual bool Activation()
        {
            if (Power != SNOPower.Barbarian_Whirlwind && Power != SNOPower.DemonHunter_Strafe)
            {
                UsePower();
                FunkyGame.Navigation.lastChangedZigZag = DateTime.Today;
                FunkyGame.Navigation.vPositionLastZigZagCheck = Vector3.Zero;
            }
            else
            {
                // Special code to prevent whirlwind double-spam, this helps save fury
                bool bUseThisLoop = Power != FunkyGame.Hero.Class.LastUsedAbility.Power;
                if (!bUseThisLoop)
                {
                    //powerLastSnoPowerUsed = SNOPower.None;
                    if (LastUsedMilliseconds >= 200)
                        bUseThisLoop = true;
                }
                if (bUseThisLoop)
                {
                    UsePower();
                }
            }

            if (SuccessUsed.HasValue && SuccessUsed.Value)
            {
                _failureToUseCounter = 0;
                OnSuccessfullyUsed();

            }
            else
            {
                _lastFailureDateTime = DateTime.Now;
                _failureToUseCounter++;
                PowerCacheLookup.dictAbilityLastFailed[Power] = DateTime.Now;
            }

            ActivationFinished = true;
            return true;
        }