32767 = 2^15-1. Adding 1, we get 1 in the highest bit, which will be interpreted as a minus for 16-bit signed numbers.
In the last battle, in the last best attempt, I took 39764 skeleton warriors, BUT in the save they are divided, and after saving, another heroine gives 7000 skeletons, and Erdian attacks Lea de Vuz. Overflow does not occur during normal actions, but when reading the save or changing turns, you may get a negative number, so you need to remember this and take precautions. Here, in principle, 32 thousand skeletons are enough, it’s just that the more there are, the easier it is to win.
overall walkthrough of 2000+ (!!!) MONTHS.
(Василь Симоненко. Люди – прекрасні)