Page 1 of 1

Sandbox Campaign : modding retreat ?

Posted: Sat Jan 10, 2026 3:07 pm
by Athos1660
How to make retreating possible say only 66% of the time (or less).
Cronos09 wrote: Fri Jan 09, 2026 9:36 am I think, if you add to the file CampaignTools.bsf in the corresponding condition || (FXRand(0,99) < 34) like this

Code: Select all

if (((army1Strength <= comparator) && (proportionFoot >= 33)) || (FXRand(0,99) < 34)) // Defender will set up defensive position.
then the retreating will occur with a probability of 66 percent.
Tested a few times.
First, a good thing : it doesn't break the game :)
So far I haven't seen any retreat. But hey ! the God of dice may be against me today...