Rework option select and add game stats

This commit is contained in:
Flashfyre committed 2024-01-11 12:26:32 -05:00
1 parent 13aa20630d
commit fcf1c4f574
14 files changed
+585 -169

No files matched your search

+16 -1
View File
@@ -346,10 +346,25 @@ export default class EggGachaUiHandler extends MessageUiHandler {
for (let tier of tiers) {
const egg = new Egg(Utils.randInt(EGG_SEED, EGG_SEED * tier), this.gachaCursor, getEggTierDefaultHatchWaves(tier), timestamp);
if (egg.isManaphyEgg())
if (egg.isManaphyEgg()) {
this.scene.gameData.gameStats.manaphyEggsPulled++;
egg.hatchWaves = getEggTierDefaultHatchWaves(ModifierTier.ULTRA);
} else {
switch (tier) {
case ModifierTier.GREAT:
this.scene.gameData.gameStats.rareEggsPulled++;
break;
case ModifierTier.ULTRA:
this.scene.gameData.gameStats.epicEggsPulled++;
break;
case ModifierTier.MASTER:
this.scene.gameData.gameStats.legendaryEggsPulled++;
break;
}
}
eggs.push(egg);
this.scene.gameData.eggs.push(egg);
this.scene.gameData.gameStats.eggsPulled++;
}
this.scene.gameData.saveSystem().then(success => {