Example #1
0
        public void Tick(NWCreature oCaster, NWObject oTarget, int currentTick, int effectiveLevel, string data)
        {
            Random random = new Random();
            int    amount = random.Next(3, 7);

            oCaster.AssignCommand(() =>
            {
                Effect damage = _.EffectDamage(amount);
                _.ApplyEffectToObject(NWScript.DURATION_TYPE_INSTANT, damage, oTarget.Object);
            });

            Effect decreaseAC = _.EffectACDecrease(2);

            oCaster.AssignCommand(() =>
            {
                _.ApplyEffectToObject(NWScript.DURATION_TYPE_TEMPORARY, decreaseAC, oTarget.Object, 1.0f);
            });

            _.ApplyEffectToObject(NWScript.DURATION_TYPE_INSTANT, _.EffectVisualEffect(NWScript.VFX_IMP_ACID_S), oTarget.Object);
        }
Example #2
0
        public void Tick(NWCreature oCaster, NWObject oTarget)
        {
            Random random = new Random();
            int    amount = random.Next(3, 7);

            oCaster.AssignCommand(() =>
            {
                Effect damage = _.EffectDamage(amount);
                _.ApplyEffectToObject(DURATION_TYPE_INSTANT, damage, oTarget.Object);
            });

            Effect decreaseAC = _.EffectACDecrease(2);

            oCaster.AssignCommand(() =>
            {
                _.ApplyEffectToObject(DURATION_TYPE_TEMPORARY, decreaseAC, oTarget.Object, 6.1f);
            });

            _.ApplyEffectToObject(DURATION_TYPE_INSTANT, _.EffectVisualEffect(VFX_IMP_ACID_S), oTarget.Object);
        }
Example #3
0
        public void OnImpact(NWPlayer player, NWObject target, int perkLevel)
        {
            int   damage   = 0;
            float duration = 0.0f;

            switch (perkLevel)
            {
            case 1:
                damage   = _random.D4(1);
                duration = 6;
                break;

            case 2:
                damage   = _random.D4(2);
                duration = 6;
                break;

            case 3:
                damage   = _random.D4(2);
                duration = 9;
                break;

            case 4:
                damage   = _random.D8(2);
                duration = 9;
                break;

            case 5:
                damage   = _random.D8(2);
                duration = 12;
                break;

            case 6:
                damage   = _random.D6(3);
                duration = 15;
                break;

            case 7:
                damage   = _random.D8(3);
                duration = 15;
                break;

            case 8:
                damage   = _random.D8(3);
                duration = 18;
                break;

            case 9:
                damage   = _random.D8(4);
                duration = 18;
                break;

            case 10:
                damage   = _random.D8(4);
                duration = 21;
                break;
            }

            _.ApplyEffectToObject(DURATION_TYPE_INSTANT, _.EffectDamage(damage, DAMAGE_TYPE_SLASHING), target);
            _.ApplyEffectToObject(DURATION_TYPE_TEMPORARY, _.EffectACDecrease(3), target, duration);
            _.ApplyEffectToObject(DURATION_TYPE_INSTANT, _.EffectVisualEffect(VFX_IMP_HEAD_EVIL), target);

            player.SendMessage("Your target's armor has been breached.");
        }