Ejemplo n.º 1
0
    public override void OnEnemyClick(Enemy clickedEnemy)
    {
        if (_currentEnemy != clickedEnemy)
        {
            _currentEnemy = clickedEnemy;
            User.Instance.CurrentHero.CritChance -= _stackCount * CritChanceIncreasePerStack;
            _stackCount = 0;
        }

        if (_stackCount < MaxStacks)
        {
            _stackCount++;
            User.Instance.CurrentHero.CritChance += CritChanceIncreasePerStack;
        }

        var isEnemyAMonster    = _currentEnemy is Monster;
        var isEnemyInThreshold = _currentEnemy.CurrentHealth <= ExecuteThreshold * _currentEnemy.Health;

        if (isEnemyAMonster && isEnemyInThreshold && _stackCount == MaxStacks)
        {
            CombatHelper.DealDamageToEnemy(_currentEnemy, _currentEnemy.CurrentHealth, DamageType.Magic);
        }

        base.OnEnemyClick(clickedEnemy);
    }
Ejemplo n.º 2
0
    public override void OnEnemyClick(Enemy clickedEnemy)
    {
        if (clickedEnemy is Monster monster)
        {
            CombatHelper.DealDamageToEnemy(clickedEnemy, (int)Math.Ceiling(monster.Health * DamageDealtPercentage), DamageType.Magic);
        }

        base.OnEnemyClick(clickedEnemy);
    }
Ejemplo n.º 3
0
    public override void OnEnemyClick(Enemy clickedEnemy)
    {
        if (clickedEnemy is Monster monster)
        {
            CombatHelper.DealDamageToEnemy(monster, monster.CurrentHealth, DamageType.Magic);
        }

        base.OnEnemyClick(clickedEnemy);
    }
Ejemplo n.º 4
0
    public override void OnEnemyClick(Enemy clickedEnemy)
    {
        if (_currentEnemy != clickedEnemy)
        {
            _spineCount   = 0;
            _currentEnemy = clickedEnemy;
        }

        CombatHelper.DealDamageToEnemy(clickedEnemy, DamagePerSpine * _spineCount, DamageType.Magic);
        _spineCount++;

        base.OnEnemyClick(clickedEnemy);
    }
Ejemplo n.º 5
0
    public override void OnEnemyClick(Enemy clickedEnemy)
    {
        if (!_isNextClickEmpowered)
        {
            _isNextClickEmpowered = true;
            return;
        }

        _isNextClickEmpowered = false;

        CombatHelper.DealDamageToEnemy(clickedEnemy, DamageDealt, DamageType.Magic);

        base.OnEnemyClick(clickedEnemy);
    }
Ejemplo n.º 6
0
    public override void OnEnemyClick(Enemy clickedEnemy)
    {
        _clickTimes.Add(DateTime.Now);

        if (_clickTimes.Count == ClicksRequired)
        {
            var requiredTimeSpan = TimeSpan.FromMilliseconds(TimeFrame);
            var actualTimeSpan   = _clickTimes.Last() - _clickTimes.First();

            if (actualTimeSpan <= requiredTimeSpan)
            {
                CombatHelper.DealDamageToEnemy(clickedEnemy, DamageDealt, DamageType.Magic);
            }

            _clickTimes.Clear();
        }

        base.OnEnemyClick(clickedEnemy);
    }
Ejemplo n.º 7
0
    public override void OnEnemyClick(Enemy clickedEnemy)
    {
        if (_currentEnemy != clickedEnemy)
        {
            _currentEnemy = clickedEnemy;
            _clickCount   = 0;
        }

        _clickCount++;

        if (_clickCount == ClickThreshold)
        {
            var damageDealt = _currentEnemy is Monster ? (int)Math.Ceiling(_currentEnemy.Health * DamageAgainstMonsters) : (int)Math.Ceiling(_currentEnemy.Health * DamageAgainstBosses);
            CombatHelper.DealDamageToEnemy(_currentEnemy, damageDealt, DamageType.Magic);

            _clickCount = 0;
        }

        base.OnEnemyClick(clickedEnemy);
    }
Ejemplo n.º 8
0
    public override void OnEnemyClick(Enemy clickedEnemy)
    {
        var bonusDamageDealt = (int)Math.Ceiling(User.Instance.CurrentHero.ClickDamage * ClickDamagePercentageAsBonusDamage * User.Instance.CurrentHero.CritDamage);

        CombatHelper.DealDamageToEnemy(clickedEnemy, bonusDamageDealt, DamageType.Magic);
    }