-
Notifications
You must be signed in to change notification settings - Fork 2
Game Overview
The central class is Server, which represents a single game server. A Server can be used for more than one simultaneous Game. (This is a major change from Colossus.) Only one Server runs on a single TCP port or in a single Python process.
When a Client connects to a Server, it gets back a list of existing Games and Users connected to the server, with high-level summary data about each current Game. Anteroom displays this information. Each User needs a unique player name and a matching password. (For now these are added by hand to a text file; we can do something more elaborate later.)
Any user can use the NewGame dialog to set up a new Game. Attributes that can be attached to a game include a unique name, time formed, minimum and maximum number of players, and a time limit for players to join before the game starts. (Later we might add things like settings for optional rules, whether AIs are welcome, minimum karma to play, passwords for private games, etc.)
Other clients can join games, as players or spectators, by selecting them in Anteroom. When a user chooses to join a game, his client should receive the full stream of events so far for that game. (Not just a dump of the current state. The full event stream is more expensive, but allows full undo / redo / rewind/ fast-forward, and allows one code path instead of two.)
Once a game starts (either by the maximum number of players having joined, or at least the minimum number of players having joined plus the time limit being hit or the forming player saying to start), only new spectators can join, not new players. (But we should eventually allow spectators or AIs to take over for players who drop.)
When a game starts, towers are rolled for, then players pick colors in ascending order of tower number. When all colors have been assigned, the starting 8-high legions are placed in their towers, and the first player is given priority to start his turn.
On the first turn, each player must split his 8-high legion into 2 4-high legions, each with one lord. (On future turns, legions can be split voluntarily, as long as each remaining legion has at least 2 creatures.) Then movement is rolled and he has to move at least one of his legions. If he moves onto an enemy legion then the engagement must be resolved. Finally, any legions that moved to a hex where their creatures can recruit can muster a reinforcement, unless they already contain 7 creatures.
During the engagement phase, the defender first gets a chance to flee, unless his legion contains a lord. If the defender does not flee then either player can concede, or they can negotiate a settlement (involving at least one legion being eliminated), or they can fight. The winner, if any, gets points for the value of the loser, or half-points if it fled.
When legions fight, the defender enters his creatures onto the battle map first, then the attacker enters. Any creatures in contact exchange attacks and counter-attacks. Rangestrikers can rangestrike enemies, without risking counter-attack. The attacker can summon an angel or archangel (once per turn, if he has one in an un-engaged legion) on the first turn after he kills an opposing creature, or after the battle. The defender can recruit a reinforcement at the start of battle turn 4. The battle continues until at least one side is completely destroyed, or until 7 turns are over and the attacker takes a time loss. Except in the case of a time loss, the winner earns points for the defeated legion.
Every 100 points, a player gets to acquire an angel (if the scoring legion has room). Every 500 points, the player can take an archangel instead. A player’s Titan also gains a point of power every 100 points.
When a Titan dies, his player is out and the player who killed his titan gets half-points for his remaining legions. Note that such half-points do not count for angels or archangels. The last player with a surviving titan wins; if the last two players eliminate each other’s titans in the same battle turn then it’s a draw.