Exemplo n.º 1
0
        public override async Task <bool> Invoke(double manaPercentFloor = 10)
        {
            if (Self.Self.Mana.Percent > manaPercentFloor.EvaluateAsPercentage())
            {
                return(false);
            }

            var didMageInvoke = false;

            if (_mageInvokeOrb != null)
            {
                didMageInvoke = await SpellCommands.CastAetheredSpell(Self, _mageInvokeOrb, _mageInvokeStatus);
            }

            if (didMageInvoke)
            {
                InvokeStatus.ResetStatusCooldown();
                return(true);
            }

            var didInvoke = await SpellCommands.CastAetheredSpell(Self, InvokeSpell, InvokeStatus, true);

            if (didInvoke)
            {
                _mageInvokeStatus?.ResetStatusCooldown();
            }

            return(didInvoke);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Casts the Whirlwind attack spell on the target in front of the caster.
        /// </summary>
        /// <param name="minimumVitaPercent">Vita percent threshold below which the spell
        /// will not be cast.</param>
        /// <returns>True if the spell was cast; false otherwise.</returns>
        public async Task <bool> Whirlwind(double minimumVitaPercent = 80)
        {
            if (Self.Self.Vita.Percent < minimumVitaPercent.EvaluateAsPercentage())
            {
                return(false);
            }

            return(await SpellCommands.CastAetheredSpell(Self, _whirlwindSpell, _whirlwindStatus));
        }
Exemplo n.º 3
0
        /// <summary>
        /// Casts the Desperate Attack attack spell on the target in front of the caster.
        /// </summary>
        /// <param name="minimumVitaPercent">Vita percent threshold below which the spell
        /// will not be cast.</param>
        /// <returns>True if the spell was cast; false otherwise.</returns>
        public async Task <bool> DesperateAttack(double minimumVitaPercent = 80)
        {
            if (Self.Self.Vita.Percent < minimumVitaPercent.EvaluateAsPercentage())
            {
                return(false);
            }

            return(await SpellCommands.CastAetheredSpell(Self, _desperateAttackSpell, _desperateAttackStatus));
        }
Exemplo n.º 4
0
        /// <summary>
        /// Casts the Sul Slash attack spell on the target in front of the caster.
        /// </summary>
        /// <param name="minimumVitaPercent">Vita percent threshold below which the spell
        /// will not be cast.</param>
        /// <returns>True if the spell was cast; false otherwise.</returns>
        public async Task <bool> SulSlash(double minimumVitaPercent = 80)
        {
            if (Self.Self.Vita.Percent < minimumVitaPercent.EvaluateAsPercentage())
            {
                return(false);
            }

            return(await SpellCommands.CastAetheredSpell(Self, _sulSlashOrb, _sulSlashStatus));
        }
Exemplo n.º 5
0
        /// <summary>
        /// Casts the Invoke spell to restore mana at the cost of vita but only if current
        /// mana is less than the specified threshold. Set threshold to 100 to always Invoke
        /// as soon as possible.
        /// </summary>
        /// <param name="manaPercentFloor">The mana percent threshold below which the spell
        /// is eligible to be cast.</param>
        /// <returns>True if the spell was cast; false otherwise.</returns>
        public virtual async Task <bool> Invoke(double manaPercentFloor = 10)
        {
            if (Self.Self.Mana.Percent > manaPercentFloor.EvaluateAsPercentage())
            {
                return(false);
            }

            return(await SpellCommands.CastAetheredSpell(Self, InvokeSpell, InvokeStatus, true));
        }
Exemplo n.º 6
0
        /// <summary>
        /// Casts a Rage/Cunning buff. Does not include Furies.
        /// </summary>
        /// <returns>True if the spell was cast; false otherwise.</returns>
        public async Task <bool> Rage()
        {
            if (_rageSpell == null)
            {
                return(false);
            }

            return(await SpellCommands.CastAetheredSpell(Self, _rageSpell, _rageStatus));
        }
Exemplo n.º 7
0
        /// <summary>
        /// Casts a Fury buff. Does not include Rage/Cunning.
        /// </summary>
        /// <returns>True if the spell was cast; false otherwise.</returns>
        public async Task <bool> Fury()
        {
            if (RageSpell != null)
            {
                return(false);
            }

            return(await SpellCommands.CastAetheredSpell(Self, _furySpell, _furyStatus));
        }
Exemplo n.º 8
0
 /// <summary>
 /// Casts the Harden Body buff on the caster.
 /// </summary>
 /// <returns>True if the spell was cast; false otherwise.</returns>
 public async Task <bool> HardenBody()
 {
     return(await SpellCommands.CastAetheredSpell(Self, _hardenBodySpell, _hardenBodyStatus));
 }
Exemplo n.º 9
0
 /// <summary>
 /// Casts the Shadow Figure buff on the caster.
 /// </summary>
 /// <returns>True if the spell was cast; false otherwise.</returns>
 public async Task <bool> ShadowFigure()
 {
     return(await SpellCommands.CastAetheredSpell(Self, _shadowFigureSpell, _shadowFigureStatus));
 }
Exemplo n.º 10
0
 /// <summary>
 /// Casts the Might buff on the caster.
 /// </summary>
 /// <returns>True if the spell was cast; false otherwise.</returns>
 public async Task <bool> Might()
 {
     return(await SpellCommands.CastAetheredSpell(Self, _mightSpell, _mightStatus));
 }
Exemplo n.º 11
0
 /// <summary>
 /// Casts the Potency buff on the caster.
 /// </summary>
 /// <returns>True if the spell was cast; false otherwise.</returns>
 public async Task <bool> Potence()
 {
     return(await SpellCommands.CastAetheredSpell(Self, _potenceSpell, _potenceStatus));
 }
Exemplo n.º 12
0
 /// <summary>
 /// Casts the Flank buff on the caster.
 /// </summary>
 /// <returns>True if the spell was cast; false otherwise.</returns>
 public async Task <bool> Flank()
 {
     return(await SpellCommands.CastAetheredSpell(Self, _flankSpell, _flankStatus));
 }
Exemplo n.º 13
0
 /// <summary>
 /// Casts the Blessing buff on the caster.
 /// </summary>
 /// <returns>True if the spell was cast; false otherwise.</returns>
 public async Task <bool> Blessing()
 {
     return(await SpellCommands.CastAetheredSpell(Self, _blessingSpell, _blessingStatus));
 }
Exemplo n.º 14
0
 /// <summary>
 /// Casts the Backstab buff on the caster.
 /// </summary>
 /// <returns>True if the spell was cast; false otherwise.</returns>
 public async Task <bool> Backstab()
 {
     return(await SpellCommands.CastAetheredSpell(Self, _backstabSpell, _backstabStatus));
 }
Exemplo n.º 15
0
 /// <summary>
 /// Reveals any NPC ambushes hidden on the screen.
 /// </summary>
 /// <returns>True if the spell was cast; false otherwise.</returns>
 public async Task <bool> SpotTraps()
 {
     return(await SpellCommands.CastAetheredSpell(Self, _spotTrapsSpell, _spotTrapsStatus));
 }