Automatically remove trapped players

Concise description:
Specifics:
This will improve the following aspects of the site:
- On maps where a player can be trapped and unable to play, being trapped removes the player from the game.
Specifics:
- If all of a player's remaining territories border nothing and can bombard nothing, then that player is immediately removed from the game. Exactly how the player is removed from the game depends on the game type.
- In a standard or terminator game, the player is eliminated. Remaining armies become neutral. Cards (if any, obviously not applying in a no cards game) go to the player who took the trapped player's last pre-trap territory; in a terminator game, that player also gets credit for the elimination.
- In an assassin game, the player is eliminated, and whoever had that player for a target wins. (Cards may be awarded and armies may go neutral as in standard or terminator games, if it is easier to code, but this is of little consequence since the game immediately ends.)
- There are two ways to handle team games, depending on which the community feels is better and which would be easier to code.
- OPTION 1: In a team game, any of the player's remaining teammates can take the player's turn, deploying that player's armies as desired. (Opponents must eliminate the player for real to stop this reinforcement, just as they do today.)
- OPTION 2: In a team game, the computer automatically deploys armies to the player's own territories on the player's turn, going for as even a distribution as possible.
- With either option, if an entire team is trapped, all players on that team are eliminated (by the player taking the last non-trapped territory, which may matter for cards) as per a standard game. (In triples or quadruples, this means immediate victory for the other side, unless and until Conquer Club supports games with 9 or more players.) Also, the player is marked as eliminated, the game does not count against a non-premium user's limit, appears in the user's "Eliminated" tab until the game ends (if the elimination did not trigger game end), et cetera.
- This only applies to maps such as San Francisco, where a player can be trapped in Alcatraz.
- This does not apply to maps such as Waterloo, where a player can be "trapped" in artillery but still able to bombard and otherwise affect territories beyond what the player controls. (In particular, this does not apply to Arms Race, since being "trapped" in half the map and being able to bombard the rest is part of the point.)
- While this is a particular problem with Battle for Iraq, where a player can be trapped in one quarter of the map (the US and Baathist loyalty boxes), there are at least three maps where this is known to come up, and there may be more. This suggestion is intended to fix this problem in general, for all current maps and in case it appears on other maps in the future. (There is at least one map idea, as of this writing, that is built around the concept of trapped territories.)
- At the moment, there do not appear to be any maps where a player can be trapped in territories that border or can bombard anything (short of controlling the entire map, at which point the game is won anyway). Therefore, "all remaining territories border nothing and can bombard nothing" seems to be a sufficient test, requiring no reworking of the maps where this occurs, and no foresight in future maps (unless future maps allow for someone to be trapped in territories that border one another, at which point this can be revised).
- This is intended to work automatically, without specific support from the XML. (Put another way, the XML already flags trapped territories, by the absence of anything they border or can bombard.)
- This is separate from the "Warn players before reinforcing to trapped territories" suggestion. Both suggestions are intended to improve the site, but they may have different strengths and weaknesses that need discussion, and they will probably affect slightly different areas of the site's code.
This will improve the following aspects of the site:
- Being trapped yet being forced to continue playing is no fun. This would recognize when a player is out of the game, and free the player to leave ratings and move on to other games.
- Currently, a trapped player has no reason not to drag a game on, waiting 23 hours and 59 minutes between moves when everyone else does their moves in much less time, to punish people for not actually eliminating the trapped player. There are no repercussions to this except possibly ratings hits, and players sympathetic to the trapped on (yet unable to eliminate the trapped one) might not even give bad ratings. This would eliminate the reason for such unpleasantness, making things more enjoyable for those still in the game as well.