From cb6a0b9973c485082d3060bfd077bb2263c6ee0f Mon Sep 17 00:00:00 2001 From: Tempoanon <163687446+Tempo-anon@users.noreply.github.com> Date: Thu, 30 May 2024 17:25:53 -0400 Subject: [PATCH] Fix bug with variant rate (#1613) --- src/field/pokemon.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/field/pokemon.ts b/src/field/pokemon.ts index 37e8fcf9eca..c8aaeeaccfd 100644 --- a/src/field/pokemon.ts +++ b/src/field/pokemon.ts @@ -1268,8 +1268,8 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container { /** * Generates a variant * Has a 10% of returning 2 (epic variant) - * And a 20% of returning 1 (rare variant) - * Returns 0 (basic shiny) if there is no variant or 70% of the time otherwise + * And a 30% of returning 1 (rare variant) + * Returns 0 (basic shiny) if there is no variant or 60% of the time otherwise * @returns the shiny variant */ generateVariant(): Variant { @@ -1277,10 +1277,10 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container { return 0; } const rand = Utils.randSeedInt(10); - if (rand >= 3) { - return 0; // 7/10 + if (rand >= 4) { + return 0; // 6/10 } else if (rand >= 1) { - return 1; // 2/10 + return 1; // 3/10 } else { return 2; // 1/10 }