mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2024-11-30 02:36:11 +00:00
Update src/test/utils/overridesHelper.ts
Co-authored-by: flx-sta <50131232+flx-sta@users.noreply.github.com>
This commit is contained in:
parent
6a697b193e
commit
f80901f7b9
@ -20,7 +20,7 @@ export class OverridesHelper {
|
||||
* @param percentage the encounter chance in %
|
||||
* @returns spy instance
|
||||
*/
|
||||
mysteryEncounterChance(percentage: number): MockInstance {
|
||||
mysteryEncounterChance(percentage: number) {
|
||||
const maxRate: number = 256; // 100%
|
||||
const rate = maxRate * (percentage / 100);
|
||||
const spy = vi.spyOn(Overrides, "MYSTERY_ENCOUNTER_RATE_OVERRIDE", "get").mockReturnValue(rate);
|
||||
|
Loading…
Reference in New Issue
Block a user