Fix flee odds being incorrect
All checks were successful
Build / Build (push) Successful in 57s

This commit is contained in:
2025-11-08 10:32:29 +01:00
parent 90eaeb1a72
commit fa05cdd773
3 changed files with 35 additions and 2 deletions

View File

@@ -162,10 +162,14 @@ public static class TurnRunner
}
if (!battle.Library.MiscLibrary.CanFlee(battle, fleeChoice))
{
battle.EventHook.Invoke(new FleeEvent(user, false));
return;
}
var userSide = battle.Sides[battleData.SideIndex];
userSide.MarkAsFled();
battle.EventHook.Invoke(new FleeEvent(user, true));
battle.ValidateBattleState();
}