Skip to content

Commit

Permalink
made max move names change based on ability
Browse files Browse the repository at this point in the history
  • Loading branch information
jbmagier committed Mar 28, 2021
1 parent 913c489 commit c47a3ab
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions calc/src/move.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,8 @@ export class Move implements State.Move {
const maxMoveName: string = getMaxMoveName(
data.type,
options.species,
!!(data.category === 'Status')
!!(data.category === 'Status'),
options.ability
);
const maxMove = gen.moves.get(toID(maxMoveName));
const maxPower = () => {
Expand Down Expand Up @@ -232,8 +233,9 @@ const ZMOVES_TYPING: {
Water: 'Hydro Vortex',
};

export function getMaxMoveName(moveType: I.TypeName, pokemonSpecies?: string, isStatus?: boolean) {
export function getMaxMoveName(moveType: I.TypeName, pokemonSpecies?: string, isStatus?: boolean, pokemonAbility?: string) {
if (isStatus) return 'Max Guard';
if (pokemonAbility === 'Normalize') return 'Max Strike';
if (moveType === 'Fire') {
if (pokemonSpecies === 'Charizard-Gmax') return 'G-Max Wildfire';
if (pokemonSpecies === 'Centiskorch-Gmax') return 'G-Max Centiferno';
Expand All @@ -243,6 +245,10 @@ export function getMaxMoveName(moveType: I.TypeName, pokemonSpecies?: string, is
if (pokemonSpecies === 'Eevee-Gmax') return 'G-Max Cuddle';
if (pokemonSpecies === 'Meowth-Gmax') return 'G-Max Gold Rush';
if (pokemonSpecies === 'Snorlax-Gmax') return 'G-Max Replenish';
if (pokemonAbility === 'Pixilate') return 'Max Starfall';
if (pokemonAbility === 'Aerilate') return 'Max Airstream';
if (pokemonAbility === 'Refrigerate') return 'Max Hailstorm';
if (pokemonAbility === 'Galvanize') return 'Max Lightning';
}
if (moveType === 'Fairy') {
if (pokemonSpecies === 'Alcremie-Gmax') return 'G-Max Finale';
Expand Down

0 comments on commit c47a3ab

Please sign in to comment.