Thread:TsuchiNoKao/@comment-26544499-20201101011936

I recently mentioned what happened to me with Chinu being taken by the Shimazu brothers but not leaving my roster. In summary, what happened was: I have a guess for what has caused this, does this sound plausible to you?
 * In the KTM route, I was playing around with average troops sizes and that Chinu was in my army with 1 troop.
 * According to their end of turn screen, I'm fairly confident that Shimazu had 59 commanders.
 * At the start of my turns, I usually just got the "the prison is full, please tell Rance" event.
 * I unexpectedly got the Shimazu defection event. It is not the first time that I've had it on this run, but it's the first time that I've seen it take priority over the prison event.
 * The defection event reports that Chinu has left
 * After checking my roster, I found that she had not left.
 * I think, but do not know or even know how to find out, that the end of turn screen for each faction does not count commanders that are in their army but are "reserved", i.e. those with gs[ii][loop].配備 == true (do you know how to check this?). From past work, I know that in the KTM route, Shimazu Toshihisa starts at true and is never set to have gs[ii][loop].配備 = false.
 * My suspicion is that in this case, the Shimazu family had 59 unreserved commanders and 1 reserved commander (Toshihisa) and that their end of turn screen was only reporting the 59.
 * Pictured here is the code for the defections in the KTM route. My suspicion is that キャラ数 is returning 59 whereas 勢力空き番号 sees that slots 1-59 are filled with normal commanders and that the 60th slot is filled by the reserved Toshihisa, meaning that there is no room for a new commander, causing 0 to be returned and the event to play without Chinu being taken.

How does that all sound? It's way past my bedtime and this isn't my usual code. Mind carefully checking all of that over? Notably, it doesn't explain the prison event failing to take priority over the defection - I didn't think that was possible.  