Add flag for immediate hatching eggs (#1424)

* Add flag for immediate hatching eggs

* Change time to hatch based on flag in Overrides
This commit is contained in:
hayuna 2024-05-27 12:49:49 +02:00 committed by GitHub
parent 35cb04fae1
commit 4c443e7760
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 1 deletions

View File

@ -32,6 +32,7 @@ export const STARTING_BIOME_OVERRIDE: Biome = Biome.TOWN;
export const ARENA_TINT_OVERRIDE: TimeOfDay = null;
// Multiplies XP gained by this value including 0. Set to null to ignore the override
export const XP_MULTIPLIER_OVERRIDE: number = null;
export const IMMEDIATE_HATCH_EGGS_OVERRIDE: boolean = false;
// default 1000
export const STARTING_MONEY_OVERRIDE: integer = 0;
export const POKEBALL_OVERRIDE: { active: boolean, pokeballs: PokeballCounts } = {

View File

@ -5008,7 +5008,7 @@ export class EggLapsePhase extends Phase {
super.start();
const eggsToHatch: Egg[] = this.scene.gameData.eggs.filter((egg: Egg) => {
return --egg.hatchWaves < 1;
return Overrides.IMMEDIATE_HATCH_EGGS_OVERRIDE ? true : --egg.hatchWaves < 1;
});
if (eggsToHatch.length) {