During a battle, the presence of destroyers affects when a firstStrike unit gets a sneak attack.
For example, a game has "Defending Subs Sneak Attack" and there is a firstStrike unit attacking another firstStrike unit. If there is a destroyer on defense, then the defending firstStrike gets a sneak attack before the attacker. If the destroyer is on offense, then the attacker gets the sneak attack. But if the destroyer isn't there, then both the attacker and defender can fire at each other.
My question is what to do if the destroyer is there at the start of the round but then gets killed during the AA phase? Imagine there is a unit that has an aaAttack and can hit a destroyer. It gets a lucky hit and the destroyer is sunk (since units hit by aa fire are removed from the battle after the aa phase).
Should the firstStrike units change their sneak attacks? If destroyer was a defender, should the defender firstStrike lose its sneak attack against the attacker firstStrike? And vice versa if the destroyer was an attacker?
Right now, the code sets the sneak attack of the firstStrike units at the beginning of the round. But that could be just because aa units originally couldn't hit destroyers. I don't think this scenario is possible in any of the classic rules.
The main reason I'm asking this is because I realized that the way I was refactoring the sub steps would cause the sneak attack of a FirstStrike unit to change in the middle of the round. And as I thought about the consequences, I wondered if this change is actually a good change.
Also, if the sneak attack can change, then the UI might have a problem. This is because the list of steps shown in the UI is set at the beginning of the round. If the destroyer does die during the aa phase, the list of steps may need to change.
(Also, I'm not exactly sure if this should be asked in this forum or in github)