Ejemplo n.º 1
0
        public static void Use(Combatant source, Combatant target)
        {
            PetrifyAbility ability = new PetrifyAbility(source, target);

            source.CurrentBattle.EnqueueAction(new AbilityEvent(ability, MODIFIERS, source, new Combatant[] { target }));
        }
Ejemplo n.º 2
0
        public static void Use(Combatant source, Combatant target)
        {
            PetrifyAbility ability = new PetrifyAbility(source, target);

            source.CurrentBattle.EnqueueAction(new AbilityEvent(ability, MODIFIERS, source, new Combatant[] { target }));
        }
Ejemplo n.º 3
0
        public void CheckTimers()
        {
            if (Sleep && V_Timer.ElapsedUnits - SleepTimeEnd >= SLEEP_DURATION)
            {
                CureSleep(this);
            }


            if (Poison && PoisonTime != null && V_Timer.ElapsedUnits - PoisonTime >= POISON_INTERVAL)
            {
                PoisonAbility.Use(Poisoner, this);
                PoisonTime = null;
            }

            if (SlowNumb && SlownumbTimeEnd != null && C_Timer.ElapsedUnits - SlownumbTimeEnd >= SLOWNUMB_DURATION)
            {
                PetrifyAbility.Use(Petrifier, this);
                SlownumbTimeEnd = null;
            }

            if (DeathSentence && DeathSentenceTimeEnd != null && C_Timer.ElapsedUnits - DeathSentenceTimeEnd >= DEATHSENTENCE_DURATION)
            {
                DeathAbility.Use(Sentencer, this);
                DeathSentenceTimeEnd = null;
            }


            if (Regen && V_Timer.ElapsedUnits - RegenTimeEnd >= REGEN_DURATION)
            {
                CureRegen(this);
            }
            else if (Regen && V_Timer.ElapsedUnits - RegenTimeInterval >= REGEN_INTERVAL)
            {
                AcceptDamage(Regenerator, MaxHP / -32);
                RegenTimeInterval = V_Timer.ElapsedUnits;
            }

            if (Seizure && V_Timer.ElapsedUnits - SeizureTimeEnd >= SEIZURE_DURATION)
            {
                CureSeizure(this);
            }
            else if (Seizure && V_Timer.ElapsedUnits - SeizureTimeInterval >= SEIZURE_INTERVAL)
            {
                AcceptDamage(Seizer, MaxHP / 32);
                SeizureTimeInterval = V_Timer.ElapsedUnits;
            }

            if (Barrier && V_Timer.ElapsedUnits - BarrierTimeEnd >= BARRIER_DURATION)
            {
                CureBarrier(this);
            }

            if (MBarrier && V_Timer.ElapsedUnits - MBarrierTimeEnd >= MBARRIER_DURATION)
            {
                CureMBarrier(this);
            }

            if (Shield && V_Timer.ElapsedUnits - ShieldTimeEnd >= SHIELD_DURATION)
            {
                CureShield(this);
            }

            if (Peerless && V_Timer.ElapsedUnits - PeerlessTimeEnd >= PEERLESS_DURATION)
            {
                CurePeerless(this);
            }

            if (Paralysed && V_Timer.ElapsedUnits - ParalyzedTimeEnd >= PARALYZED_DURATION)
            {
                CureParalyzed(this);
            }
        }