- Concept
- Game Rules
- Running the game
- Creating the initial universe file
- Setup Instructions
- Contributor Guidelines
- Contact Information
- License
A massively multiplayer turn-based war game, loosely modelled on the gameplay of a PBM game sold in the 80s as Space Empires. This version has a new fleet system, new treasures, new treasure effects, and a more interactive combat system.
The game is turn-based. Players submit text files containing orders for their units, the server processes those orders, and when processing is complete returns a text report for each player containing the results.
To run a game you need is a private channel for players to submit files containing their orders, and a private channel back to each player for the reports on the outcome of each turn. These channels could be implemented as a REST interface, a Facebook plugin, a Twitter bot, email, or a custom web front end, email, or whichever combination of these is most convenient.
A player first gets a report of the current state of their empire, which traditionally starts as a single world with a ship factory.
TURN 1
W1<MING>(2,3,4,5) (ind=50 rms=13 rmp=10 pop=31)
... which means
- a world named "1" connected to 4 other worlds (worlds 2, 3, 4 and 5)
- owned by the empire of MING
- has the industrial production capacity (ind) of 50 ships per turn
- holds raw materials (rms) sufficient to build 13 ships
- producing 10 more raw materials (rmp) every turn
- with a population of 31 billion
The player reads the report and might submit these orders:
B12F1
B1F2
M1W3
...which means
- Build 12 ships onto a new fleet named F1.
- Build 1 ship onto a new fleet named F2.
- When the ships are ready, Move fleet 1 to World 3
- Leave the fleet F2 at home to defend the world.
If you played the classic game, you might notice that there were no fleets at the world before the first turn. In this game, players create fleets when required. A fleet containing zero ships is not possible. There are other changes to rules such as:
- the order of event processing
- fleet creation
- ship combat
- supply chains
The universe is of a set of worlds, connected via a galactic hyperspace network. Travel between worlds is only possible through the connections of this hyperspace network.
Sometimes the game consists of a grid of worlds, where each world is connected to four neighbors (which can be visualised as north, south, east and west)
Or the game might be a completely organic mess of interconnections and one-way links like this:
Worlds have a number of attributes:
World Attribute | Abbreviation | Game effect |
---|---|---|
Industry | IND | Each point of industry is capable of turning one unit of Raw Materials into one Ship per turn, as long as the Population is greater than zero. |
Raw Materials Stored | RMS | One unit of raw materials is enough to create one ship |
Raw Materials Produced | RMP | The number of new units of raw materials produced by the world per turn |
Population | POP | The number of billions of inhabitants. If this gets down to zero, Industry will no longer function, and the world becomes unowned. Population does NOT increase during the course of the game. π§ |
Owner | Every world will have zero or one owner. | |
World number | Every world will have a unique numerical identifier. |
All ships in the game are identical. Each ship may carry one unit of cargo, or no units of cargo. Every ship must belong to a fleet. A fleet may contain one or more of ships. Ships in a fleet move together as a unit, and share a single combat strategy.
Each turn has three phases.
-
Combat phase
- Fleets may be assigned combat strategies and targets.
- Combat is resolved according to the combat rules.
- Fleets with no ships after the combat phase are eliminated, and do not participate in remaining phases.
-
Bombardment phase
- If there are no enemy ships with DEFAULT or INTERDICTION strategy,
then surviving fleets
with bombardment orders (e.g.
AF99P
) destroy Industry or Population.
- If there are no enemy ships with DEFAULT or INTERDICTION strategy,
then surviving fleets
with bombardment orders (e.g.
-
Resolution phase
- Create new fleets
- Transfer ships between fleets
- Load and unload cargo and treasures
-
Movement phase
- Fleets move from one to three hyperspace jumps
- Fleets which loaded or unloaded cargo and treasure may not move in the same turn
- Ambushes occur in this phase
Each player will get a report of the status of their empire at the start of every turn.
The report will be in the
following format, but will also be delivered as a .dot
file and a json
file for processing by graphical clients.
W1<MING>(2,3,4,5) (ind=13 rms=22 rmp=10 pop=31)
The world named W1
is
-
<MING>
owned by the empire of Ming -
(2,3,4,5)
Ships can jump from here to worldsW2
,W3
,W4
andW5
-
ind=13
The world has 13 points of Industry. This means it can convert up to 13 units of raw materials into ships on each turn. -
rms=22
the world has 22 points of Raw Materials Stored. This means that it can build 13 ships, and still have 9 points of Raw Materials remaining. -
rmp=10
the world produced 10 points of Raw Materials Production every turn. This happens as the final act of the resolution phase, after construction is complete. To continue the example above, when the world has 9 points of Raw Materials remaining after building ships, at the start of the next turn the world will have 9+10=19 points of Raw Materials Stored. -
pop=31
the world has a Population of between 30 and 31 million. This number increases by 5%, rounded up, every turn. A world with 0 Population cannot produce raw materials, and cannot build ships.F2 10, I
This is a fleet, named F2
-
<MING>
It is also owned by the empire of Ming -
10
There are 10 ships in the fleet -
,I
At the start of the last turn, this fleet was employing the INTERDICTION strategy.F-2 20/5, TGT=POP
This is an enemy fleet, which we have given the name F-2
. We don't know the name that Bosco gave her fleet, so we
refer to it in all attack orders as F2
or F-2
. We can safely give an order AF2F2
which means "Command fleet F2
to attack F2
", and the command processor will understand that the target is the enemy fleet, not the friendly fleet
with the same name.
If you want to, you can issue the same order as AF2F-2
.
-
TGT=POP
Last turn, this enemy fleet bombarded the population of the world where it is located. -
20/5
There are 20 ships on the fleet, and the fleet is carrying 5 units of Raw Materials.F-3 20, <-W2
Bosco's fleet of 20 ships, which we have designated F-3
. It arrived from world W2
in the last turn.
F4 <MING> 5, X<BOSCO F-3>
F4
is a fleet we have just captured from Bosco. X<BOSCO F-3>
means we captured this ship from Bosco at the end of the
combat phase in the last turn. It used to be designated F-3
but we have given it a new name F4
.
F9 <MING> 30, TGT=F-3
F9
is a fleet which fired on F-3
during the combat phase.
F-7 <BOSCO> -> W2
This is a marker to say that the Bosco's fleet F-7
is no longer at this world, but left
for W2
at the end of the last turn. If we own world W2
or have ships at world W2
we will see a report showing the
fleet's arrival.
Ships may travel on the hyperspace link from one world to another with the M
order.
If you know the links between them, you can move a ship up to three jumps from its origin in a single turn. For example
the following order results in the ship arriving at W4
at the start of the next turn.
M2W2W3W4
Ships move in groups called Fleets.
A Fleet acts as a single unit, moving and attacking as one. You may split or join fleets during the Resolution phase.
A fleet cannot move on the same turn as it participates in combat, unless is only participates as a defender (See the table of fleet strategies for details). A fleet which has just been created cannot move on the same turn as it was constructed. A fleet involved in a transfer of ships, or which has loaded or unloaded cargo or treasure, cannot move on the same turn as the transfer.
One ship may carry one unit of Raw Materials. A Fleet containing even a single ship carrying cargo will be at a disadvantage during combat (see the section Combat).
A Ship may carry one or more Treasures. Treasures do not change the number of Combat Points, unless that is a specific Treasure Effect.
If a fleet is destroyed, any treasure it is carrying falls onto the world, but raw materials are destroyed.
A fleet has one attack point per ship, unless ANY ship is carrying cargo, in which case the fleet has one attack point for every two ships. A fleet has one defence point per ship. Fleets in ASSAULT mode double their Attack Points.
An attacking fleet causes casualties on a defending fleet, according to this table:
Ratio of attack points to Defence Points | Advantage |
---|---|
less than 1:1 | one casualty for every two Attack Points |
1:1 but not 3:1 | one casualty for every Attack Point |
3:1 or above | no casualties, and the defending fleet is captured at the end of the resolution phase |
Fleets attacking the same defending fleet combine their attack points to calculate ratios.
Combat is resolved simultaneously for both sides.
Fleets may bombard planets instead of attacking other ships. It takes 5 attack points to destroy one unit of population or industry. Ratios of attackers to defenders is not used in bombardment.
Ambush is an attack during the movement phase, with double attack points, against ships attempting to move past the world. Ambushed fleets do not fire back in the movement phase. Ambushed fleets will stop movement in the world where they are ambushed. See the movement phase orders for details, and the Strategy section for strategies which will prevent an ambush. A fleet may participate in multiple ambushes, one per fleet attempting to pass the world.
If an enemy world has no friendly fleets (not counting fleets in EVASION strategy), and their population or industry are bombarded (even with a single ship) then the world will be controlled by the attacking player at the end of the resolution phase. If it has just been captured, a world cannot participate in actions during the resolution phase.
A Fleet will have a Strategy. You can change a fleet's strategy, and the new strategy takes effect before the combat is resolved. The Strategies are:
- DEFAULT
- If not ordered to attack
- Double Defence Points
- Attack all fleets which attack it, with no limit on number of attacks
- If this fleet survives the turn, no enemy at the same world may
- transfer cargo,
- transfer treasure, or
- bombard a friendly world.
- If not ordered to attack
- SUPPLY
- You can't order a supply strategy, it's automatic when a fleet is given an "S" order. See "Resolution phase orders".
- Cannot participate in an ambush
- ASSAULT
- Double attack points
- Halve Defence Points
- Cannot capture fleets, or be captured.
- Cannot move away on the movement phase
- Cannot participate in an ambush
- PURSUIT:
- In the movement phase, the fleet will chase the fleet it fires upon, should it attempt to escape.
- EVASION
- Cannot attack (if the fleet attacks, strategy returns to DEFAULT)
- Double defence points
- Will not lose more than half of all ships in one turn
- Immune to capture
- Cannot participate in an ambush
- Cannot prevent the world from being captured
- INTERDICTION
- Same as EVASION but will automatically attack any fleet which is
- attacking a friendly world's population or industry
- transferring rm to/from an enemy world
- getting ships built on the world (will attack and destroy only ships built on the world, during resolution phase)
- May attack multiple times, once per enemy fleet performing the above actions!
- Same as EVASION but will automatically attack any fleet which is
An interdicting fleet is staying out of sight, but will fight any ship created on the interdicted enemy world. An interdicting fleet is limited in the amount of damage it can inflict on enemy fleets - only ships created in that turn can be destroyed. For example, a fleet of 10 ship can destroy 5 ships built on an enemy world a world creating 10 ships and transferring them to a fleet. Fleets attacked by interdicting fleets will automatically return the attack, with half the normal attack points.
Order | Description |
---|---|
F<fleetId>XA |
Set the fleet with the given fleet Id into ASSAULT mode. |
F<fleetId>XP |
Set the fleet with the given fleet Id into PURSUIT mode. |
F<fleetId>XE |
Set the fleet with the given fleet Id into EVASION mode |
F<fleetId>XI |
Set the fleet with the given fleet Id into INTERDICTION mode |
AF<fleetId>F<enemyFleetId> |
Attack the enemy fleet. Contributes all of the fleet's Attack Points to the destruction of ships on the enemy fleet. |
Order | Description |
---|---|
AF<fleetId>P |
Attack the enemy world's population. If any ships in Interdiction mode survive after fleet combat is resolved, they combine their Attack Points in a free attack against . |
AF<fleetId>I |
Bombard the enemy world's industry. If any ships in Interdiction mode survive after fleet combat is resolved, they combine their Attack Points in a free attack against . |
Order | Description | Interdictable |
---|---|---|
F<fleetId>L<count> |
Load <count> raw materials |
Yes |
F<fleetId>L(<treasureId>) |
Load the treasure with the id <treasureId> onto the fleet <fleetId> |
Yes |
F<fleetId>U<count> |
Drop <count> raw materials |
Yes |
F<fleetId>U(<treasureId>) |
Unload the treasure with the id <treasureId> from the fleet <fleetId> onto the world below |
Yes |
T<count>F<fleetId1>F<fleetId2> |
Transfer <count> ships from <fleetId1> to <fleetId2> |
No |
T(<treasureId>)F<fleetId1>F<fleetId2> |
Transfer the treasure with the id <treasureId> from fleet <fleetId1> to fleet <fleetId2> |
No |
B<count>F<fleetId1>W<worldId> |
Build <count> ships on world <worldId> and either create a new fleet called <fleetId1> or add the ships to an existing fleet called <fleetId> . Raw materials dumped on this world will be available for construction, and raw materials loaded off this world will not be available for construction, in the same turn. |
Yes |
S<fleetId1>W<worldId> |
Load all available raw materials into <fleetId1> . This fleet will move to the world <worldId> in the movement phase. The fleet will have the SUPPLY strategy. When the fleet arrives at the destination, it will unload all available raw materials at the destination world. In the movement phase, it will return to the source world, unless the source world does not have a reverse connection to the destination world. |
Yes |
Fleets with "Interdictable" orders an be attacked in the Resolution phase by any surviving enemy ships in INTERDICTION mode. Interactions between fleets and their worlds are all "interdictable".
Order | Description |
---|---|
M<fleetId>W<worldId> |
Move the fleet given by fleetId to the world worldId |
M<fleetId>W<worldId0>W<worldId1> |
Move the fleet given by fleetId to the world worldId0 , and from there to world worldId1 . Any fleets with DEFAULT or INTERDICTION strategy at worldId0 will ambush this fleet during the movement phase. |
M<fleetId>W<worldId0>W<worldId1>W<worldId2> |
Move the fleet given by fleetId to the world worldId0 , then moving to worldId1 and from there to world worldId2 . Any fleets with DEFAULT or INTERDICTION strategy at worldId0 or world1 will ambush this fleet during the movement phase. |
RF<fleetId1>F<fleetId2> |
Rename the fleet named fleetId1 as fleetId2 at the end of the movement phase. The fleet should still be referred to as fleetId1 in all orders in this turn, and referred to as fleetId2 at the start of the next turn |
Movement more than three worlds in one turn is impossible.
Not an exhaustive list of treasures, but these are the treasures with well-known effects. Other treasures are possible!
When a fleet carries this treasure and bombards a population (doesn't matter if friendly or enemy) the number of population killed is converted to ships on the fleet.
If carried by a fleet or stationed on a world, and a fleet carrying the Staff of the Vampire starts the combat phase on the same world, then the Staff of the Vampire, the fleet carrying the Staff of the Vampire, and the True Cross are all destroyed.
Will appear on unowned worlds. In the resolution round, a fleet carrying this treasure will lose half its ships, round up. A world carrying this treasure will lose half its population, round up. This treasure will transfer itself to the largest fleet at the current world, at the end of the resolution phase.
A world carrying this treasure will lose 1 industry in the resolution round. A fleet carrying this treasure will lose 1 ship in the resolution round. A fleet carrying both the Greater and Lesser of Two Evils will disappear into the pits of Hell after the resolution phase.
An enemy fleet at the same world as a fleet carrying the Magnus Morbus will lose 1 ship in the resolution phase.
A fleet carrying this treasure will treat fleets with the EVASION strategy as if they were following the DEFAULT strategy. This treasure is destroyed if the fleet carrying it is destroyed.
The game compiles to a command-line universe-processor.jar
file
which takes
- an
orders
file and - a
universe
file,
and outputs
- the new
universe
file, and - turn result reports for each player.
An orders
file is a set of orders supplied by players,
as a TOML file containing player ids and their orders:
[orders]
version = 1 # Orders files should always be version 1
player1 = "AF1F22 B23HF22 ..."
player2 = "B12HF2 T12F4F6 ..."
#...
How you create this file is up to you.
For example, in an old-style play-by-email system, the orders file might be assembled manually. In an online orders submission server, an orders file may be generated from orders in a database, or a firebase data store.
It's outside the scope of this project how you generate and deliver orders to the game processor.
# read the universe from universe-in.json
#
# read the player orders from orders.toml
#
# write the resulting universe to universe-out.json
#
# write the game reports to files named for each player as
# {player_name}_report.txt,
# {player_name}_report.dot and
# {player_name}_report.json
java \
-Din=universe-in.json \
-Dout=universe-out.json \
-Dorders=orders.toml \
-jar universe-processor.jar
Note: There is no random element to this game, except for the initial random placement of worlds, links, and players. Repeated processing of an orders file and a universe file is deterministic. Given the same universe and the same set of orders, the outcome will always be identical.
There is a separate executable for generating the starting random universe file:
java \
-Dplayers=5 \
-Dworlds=100 \
-Dout=universe.json \
-jar universe-generator.jar
This will also create the first report for each player.