mirror of
https://github.com/chase-manning/pokemon-js.git
synced 2025-10-09 06:00:19 +00:00
🐛 fix encounter frequency
This commit is contained in:
parent
4b883dfc9e
commit
e0c2495713
1 changed files with 1 additions and 1 deletions
|
@ -8,7 +8,7 @@ import { PokemonEncounterType } from "../state/state-types";
|
||||||
import getPokemonEncounter from "../app/pokemon-encounter-helper";
|
import getPokemonEncounter from "../app/pokemon-encounter-helper";
|
||||||
|
|
||||||
const shouldEncounter = (rate: number) => {
|
const shouldEncounter = (rate: number) => {
|
||||||
const random = Math.random() * 100;
|
const random = Math.random() * 255;
|
||||||
return random < rate;
|
return random < rate;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue