Fix issue with mega/gmax and female sprites

pull/16/head
Flashfyre 2024-02-24 21:38:18 -05:00
parent d72dd93212
commit b48c7ca76d
1 changed files with 2 additions and 1 deletions

View File

@ -150,7 +150,8 @@ export abstract class PokemonSpeciesForm {
formIndex = this.formIndex;
const formSpriteKey = this.getFormSpriteKey(formIndex);
return `${shiny ? 'shiny__' : ''}${this.genderDiffs && female ? 'female__' : ''}${this.speciesId}${formSpriteKey ? `-${formSpriteKey}` : ''}`;
const showGenderDiffs = this.genderDiffs && female && ![ SpeciesFormKey.MEGA, SpeciesFormKey.GIGANTAMAX ].find(k => formSpriteKey === k);
return `${shiny ? 'shiny__' : ''}${showGenderDiffs ? 'female__' : ''}${this.speciesId}${formSpriteKey ? `-${formSpriteKey}` : ''}`;
}
getSpriteKey(female: boolean, formIndex?: integer, shiny?: boolean): string {