Пример #1
0
    public override void ApplyEffect(Ability ability, ICharacter target)
    {
        int effectValue = 0;

        effectValue = AbilityUtilities.EffectRoll(ability, this);

        statusEffect.SetupStatus(target, hitInfo, duration, AbilityUtilities.GetDamageBonus(this, ability.caster), dice);
        Debug.Log("Status effect to apply: " + statusEffect);
        target.ApplyEffect(this);
    }
Пример #2
0
    /// <summary>
    /// The effect
    /// </summary>
    /// <param name="ability"></param>
    /// <param name="target"></param>
    public virtual void ApplyEffect(Ability ability, ICharacter target)
    {
        int effectValue = 0;

        effectValue = AbilityUtilities.EffectRoll(ability, this);
        if (ability.rollInfo.wasCrit)
        {
            effectValue = effectValue * 2;
        }

        hitInfo = new EffectHitInfo(effectValue, ability.rollInfo, hitType);

        target.ApplyEffect(this);
    }
Пример #3
0
    public override void ApplyEffect(Ability ability, ICharacter target)
    {
        int modifier = AbilityUtilities.GetDamageBonus(this, ability.caster);

        //We want the duration to be based on the caster level
        duration = modifier + 1;
        modifier = Mathf.FloorToInt(modifier / 2);
        if (modifier < 1)
        {
            modifier = 1;
        }

        statusEffect.SetupStatus(target, duration, modifier);
        target.ApplyEffect(this);
    }