Page 1 of 1
Siege of Cav bug
Posted: Sun Jun 23, 2024 1:30 am
by BrianSchick
Here, the Spanish are sieging Tunis, containing a Tunisian corps with one Cav.
Accept the siege of Tunis, and if it resolves, the Tunisians lose 1 point.
Before pressing OK for the spanish, the Tunisian corps has the cav point and is allocated 1 loss to resolve.
After pressing OK for the Spanish, the Tunisian corps no longer has the cav point, but still has 1 loss to resolve. Tunis cannot resolve the loss, and the game hangs.
I've attaced the .sav file and the .sav.dat file.
Re: Siege of Cav bug
Posted: Sun Jun 23, 2024 12:24 pm
by pzgndr
Good catch! I'll figure out why a single cav siege loss isn't working and fix it for the next hotfix. In the meantime, here's your save with the Tunisia garrison removed so you can continue, if you haven't already. Thanks!
Re: Siege of Cav bug
Posted: Mon Jun 24, 2024 6:03 pm
by pzgndr
The issue with the siege of Tunis is that the city surrendered but the code did not change the defender casualties to be taken from 1 to 0. Thus, when the city surrendered and the corps taken prisoner, it was zeroed out. This is now fixed.
The other thing that threw me off and I didn't notice until I got into the code, you either had Turkey as human controlled or perhaps a previous glitch changed Turkey to human control. I was trying to troubleshoot an AI issue when it wasn't. So, I fixed the issue for both human and AI defender. I don't like how it looks since it kicks you out of the combat screen without showing a final result, but it works and the game log reports what happened. I might circle back to work on this some more later, or perhaps not. I want to move on.
.

- Tunisia Siege.jpg (1020.01 KiB) Viewed 339 times
Re: Siege of Cav bug
Posted: Thu Jun 27, 2024 4:31 pm
by pzgndr
Alright, I did circle back on the whole siege combat processing and cleaned up a few things. I first ran a simple test case for a "normal" siege and tracked how it went, soup to nuts. Then I reviewed your siege of Tunis, both for human Turkey defender and AI Turkey defender, and verified evrything worked normally. The battle screen works correctly now and the game log is mostly accurate. For some reason, the initial Turkey defender factors are 0 and the Spanish attacker battle log is missing (R1: Spain Lost: ). If this is the worst of the glitch, we can live with it. I'm sticking a fork in it now. LOL
.

- Siege Bug.jpg (234.08 KiB) Viewed 325 times