[Bug] Fix Circular Dependency with BerryType (#1802)

* Fix Potential Circular Dependency with BerryType

* remove .js
This commit is contained in:
Benjamin Odom 2024-06-04 13:03:02 -05:00 committed by GitHub
parent 1c73b3b084
commit 6dbf99cc72
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 21 additions and 18 deletions

View File

@ -7,20 +7,7 @@ import { getStatusEffectHealText } from "./status-effect";
import * as Utils from "../utils";
import { DoubleBerryEffectAbAttr, ReduceBerryUseThresholdAbAttr, applyAbAttrs } from "./ability";
import i18next from "../plugins/i18n";
export enum BerryType {
SITRUS,
LUM,
ENIGMA,
LIECHI,
GANLON,
PETAYA,
APICOT,
SALAC,
LANSAT,
STARF,
LEPPA
}
import { BerryType } from "./enums/berry-type";
export function getBerryName(berryType: BerryType): string {
return i18next.t(`berry:${BerryType[berryType]}.name`);

View File

@ -0,0 +1,14 @@
export enum BerryType {
SITRUS,
LUM,
ENIGMA,
LIECHI,
GANLON,
PETAYA,
APICOT,
SALAC,
LANSAT,
STARF,
LEPPA
}

View File

@ -44,7 +44,7 @@ import { SpeciesFormChange, SpeciesFormChangeActiveTrigger, SpeciesFormChangeMov
import { TerrainType } from "../data/terrain";
import { TrainerSlot } from "../data/trainer-config";
import * as Overrides from "../overrides";
import { BerryType } from "../data/berry";
import { BerryType } from "../data/enums/berry-type";
import i18next from "../plugins/i18n";
import { speciesEggMoves } from "../data/egg-moves";
import { ModifierTier } from "../modifier/modifier-tier";

View File

@ -11,7 +11,8 @@ import { Type } from "../data/type";
import PartyUiHandler, { PokemonMoveSelectFilter, PokemonSelectFilter } from "../ui/party-ui-handler";
import * as Utils from "../utils";
import { TempBattleStat, getTempBattleStatBoosterItemName, getTempBattleStatName } from "../data/temp-battle-stat";
import { BerryType, getBerryEffectDescription, getBerryName } from "../data/berry";
import { getBerryEffectDescription, getBerryName } from "../data/berry";
import { BerryType } from "../data/enums/berry-type";
import { Unlockables } from "../system/unlockables";
import { StatusEffect, getStatusEffectDescriptor } from "../data/status-effect";
import { SpeciesFormKey } from "../data/pokemon-species";

View File

@ -12,7 +12,8 @@ import { FusionSpeciesFormEvolution, pokemonEvolutions, pokemonPrevolutions } fr
import { getPokemonMessage } from "../messages";
import * as Utils from "../utils";
import { TempBattleStat } from "../data/temp-battle-stat";
import { BerryType, getBerryEffectFunc, getBerryPredicate } from "../data/berry";
import { getBerryEffectFunc, getBerryPredicate } from "../data/berry";
import { BerryType } from "../data/enums/berry-type";
import { StatusEffect, getStatusEffectHealText } from "../data/status-effect";
import { achvs } from "../system/achv";
import { VoucherType } from "../system/voucher";

View File

@ -4,7 +4,7 @@ import { Biome } from "./data/enums/biome";
import { Moves } from "./data/enums/moves";
import { WeatherType } from "./data/weather";
import { Variant } from "./data/variant";
import { BerryType } from "./data/berry";
import { BerryType } from "./data/enums/berry-type";
import { TempBattleStat } from "./data/temp-battle-stat";
import { Nature } from "./data/nature";
import { Type } from "./data/type";