Esempio n. 1
0
File: Monk.cs Progetto: n3rus/mooege
        public override IEnumerable<TickTimer> Run()
        {
            User.PlayEffectGroup(137644);

            AttackPayload attack = new AttackPayload(this);
            attack.AddTargets(GetEnemiesInRadius(User.Position, ScriptFormula(1)));
            attack.OnHit = (hit) =>
            {
                TickTimer waitBuffEnd = WaitSeconds(ScriptFormula(0));

                // add main effect buff only if blind debuff took effect
                if (AddBuff(hit.Target, new DebuffBlind(waitBuffEnd)))
                    AddBuff(hit.Target, new MainEffectBuff(waitBuffEnd));
            };

            attack.Apply();

            yield break;
        }
Esempio n. 2
0
        public override IEnumerable<TickTimer> Run()
        {
            UsePrimaryResource(45f);

            SpawnEffect(Wizard_Blizzard, TargetPosition);

            const int blizzard_duration = 3;

            for(int i = 0; i < blizzard_duration; ++i)
            {
                AttackPayload attack = new AttackPayload(this);
                attack.AddTargets(GetEnemiesInRadius(TargetPosition, 18));
                attack.AddWeaponDamage(0.65f, DamageType.Cold);
                attack.OnHit = (hit) =>
                {
                    AddBuff(hit.Target, new DebuffChilled(WaitSeconds(3f)));
                };
                attack.Apply();

                yield return WaitSeconds(1f);
            }
        }