Пример #1
0
 internal void Debut()
 {
     if (Action == PokemonAction.Debuting)
     {
         Tile.Debut();
         if (!(OnboardPokemon.HasCondition(Cs.Substitute) || AbilityE(As.OVERCOAT)))
         {
             EHTs.Debut(this);
         }
         if (!PTs.CheckFaint(this))
         {
             if (ItemE(Is.BLUE_ORB) && PTs.CanChangeForm(this, Ps.KYOGRE, 1) || ItemE(Is.RED_ORB) && PTs.CanChangeForm(this, Ps.GROUNDON, 1))
             {
                 PTs.ChangeForm(this, 1, true, Ls.Primal);
             }
             if (OnboardPokemon.Ability != As.FLOWER_GIFT && OnboardPokemon.Ability != As.FORECAST)
             {
                 AbilityAttach.Execute(this);
             }
             if (!ITs.AirBalloon(this))
             {
                 ITs.Attach(this);
             }
         }
         Action = PokemonAction.Done;
     }
 }
Пример #2
0
        internal static void RecoverAfterMoldBreaker(PokemonProxy pm)
        {
            int id = pm.Ability;

            if (id == As.LIMBER || id == As.OBLIVIOUS || id == As.IMMUNITY || id == As.INSOMNIA || id == As.OWN_TEMPO || id == As.MAGMA_ARMOR || id == As.WATER_VEIL || id == As.VITAL_SPIRIT)
            {
                AbilityAttach.Execute(pm);
            }
        }
Пример #3
0
 public static void WeatherChanged(Controller c)
 {
     foreach (var pm in c.OnboardPokemons)
         if (pm.OnboardPokemon.HasCondition(Cs.ObserveWeather))
         {
             var ab = pm.Ability;
             if (ab == As.FORECAST || ab == As.FLOWER_GIFT) AbilityAttach.Execute(pm);
         }
 }
Пример #4
0
 public static void ChangeForm(this PokemonProxy pm, int form, bool forever = false, string log = "FormChange")
 {
     pm.OnboardPokemon.ChangeForm(pm.OnboardPokemon.Form.Species.GetForm(form));
     if (forever)
     {
         pm.Pokemon.Form = pm.OnboardPokemon.Form;
     }
     pm.Controller.ReportBuilder.ChangeForm(pm, forever);
     if (log != null)
     {
         ShowLogPm(pm, log);
     }
     AbilityAttach.Execute(pm);
 }
Пример #5
0
 public static void ChangeAbility(this PokemonProxy pm, int ab)
 {
     AbilityDetach.Execute(pm);
     pm.OnboardPokemon.Ability = ab;
     AbilityAttach.Execute(pm);
 }