Attempt fixing issue with form-specific moves in learnset not being used
This commit is contained in:
1 parent
97bc8ae9e6
commit
b94215e3f6
2 files changed
+13
-3
No files matched your search
@@ -24,6 +24,15 @@ export function getPokemonSpecies(species: Species): PokemonSpecies {
|
||||
return allSpecies[species - 1];
|
||||
}
|
||||
|
||||
export function getPokemonSpeciesForm(species: Species, formIndex: integer): PokemonSpeciesForm {
|
||||
let retSpecies: PokemonSpecies = species >= 2000
|
||||
? allSpecies.find(s => s.speciesId === species)
|
||||
: allSpecies[species - 1];
|
||||
if (formIndex < retSpecies.forms?.length)
|
||||
return retSpecies.forms[formIndex];
|
||||
return retSpecies;
|
||||
}
|
||||
|
||||
export function getFusedSpeciesName(speciesAName: string, speciesBName: string): string {
|
||||
const fragAPattern = /([a-z]{2}.*?[aeiou(?:y$)\-\']+)(.*?)$/i;
|
||||
const fragBPattern = /([a-z]{2}.*?[aeiou(?:y$)\-\'])(.*?)$/i;
|
||||
|
||||
Reference in new issue
Block a user