Pax Galaxia
by Diodor Bitan
Technical Manual
compiled by Jonathan
in this manual:
(scroll down to to see the sections)
Game Mechanics
Cheats
Hosting Help
Commands
Editor Tips
When moving your fleet to a neighboring star, approximately one-tenth will move per tick.
When attacking another star, some of your troops will be damaged, while some will be completely destroyed. More ships get damaged / destroyed as time goes on.
If you attack another star and succeed in capturing it, the defending player's damaged ships will be dispersed into neighboring systems that that player is in control of (if possible). When this retreat occurs, some of the damaged ships will be destroyed. Approximately half of the damaged ships will be immediately repaired and become active again. If the defending player has no neighboring stars, the attacker will get control of his ships.
When attacking ordinary stars, a 1.5 to 1 ratio in active ships is needed. 2 to 1 is preferable. A 4 to 1 ratio is needed when attacking a defense (red) star.
Defense stars (red) make your defense twice as effective. (Attacking from an attack star (green) cancels this out.) Blue stars will move twice as many ships per tick. Yellow stars produce new ships at roughly double the rate of other stars. Violet stars repair ships at double the rate of other stars. (However, if a violet star is under attack, they will repair ships at the same rate as other stars do when not under attack.)
Any star (except a violet star) which is under attack will repair ships at one-fifth of the rate they usually do when not under attack.
There are several cheat codes that can be used in the single-player mode. Note that the game will not allow you to save high-scores for games in which you have cheated.
Ctrl + 1 : Adds 100 ships to a random star under your control.
Ctrl + S : Allows you to switch sides with one of your opponents.
Ctrl + K : Destroys the opponent of your choice.
Ctrl + J : Merges the empires of your choice.
To host a public game, you must open the port 8591 (UDP). Unfortunately, every router has a different way of doing this, so specialized help cannot be given. However, there are some basic steps to follow.
Find the IP of your router. This usually starts with 192.168.x.x or 10.0.0.x. Common ones are http://192.168.0.1 , http://192.168.2.1 , and http://10.0.0.1 . You can usually find this information in your router manual.
After opening your web browser and putting your router IP in the address bar, it will probably ask for a username and password. The person who set this router up should know what it is, ask them if you don't know. Otherwise, it's probably the default password. Look for this in your router manual.
Once logged in, look for a page that says "Port Forwarding" or "Application Rules" or "Advanced" or something like that. You should get to a page where you can add a port to be forwarded. Use 8591 as the port number and UDP as the protocol, if asked. If asked for a name, type Pax Galaxia. When it asks for the IP to forward to, you should put the local IP of your computer. This will look like your router IP, but the last digit should be different. For example, my router IP is 10.0.0.1 and my local computer IP is 10.0.0.4. You can probably find this info out in your Network preferences. (Mac users: Go to the Network pane of Sys. Prefs. It should tell you your IP.)
Click Save Settings, and wait a few seconds. You should now be able to host.
A software firewall may also be blocking your connection. If you have ZoneAlarm, for example, set it to allow all incoming connections to Pax Galaxia (allow to act as a server).
Server-only commands
$kick [color]
Kicks the player out of the game.
$ban [color] (perma) (range)
Kicks the player out of the game and rejects his attempts to reconnect. perma: The restriction persists after exiting the game and cannot be removed. range: Bans the 256 IP addresses closest to that of the player - useful to ban players on dialup connections that have different but similar IP addresses.
$unban (last) / (all)
last: Allows the last banned player to reconnect. all: Allows all banned players to reconnect.
$antidote
Turn the dot animations on and off. Use it if you want to host an efficient auto server that doesn't waste CPU cycles.
$join / $quit
The server player joins / leaves the game, but the game continues. [Same as button.]
$say [Hello World]
Sends all the player a "Hello World" server message.
$tell [color] [Hello World]
Sends the player a private "Hello World" server message.
$ai (easy) / (hard)
Changes the computer difficulty.
$load [risk]
Tries to load a map named 'risk'. It will search for it in the standard maps, fan-made maps, and edited maps. However, you could specify the location by typing $load standard/time, $load fan/time, or $load custom/time, where "time" is the map name. This is useful if you have several maps with the same name
$random map [galaxy]
Generates a random level. If used with no parameters ($random), the map size and number of players depend on the amount of people on the server. The map [mapname] uses the specified map and randomly places players on it.
$random stars [50] players [5] bases [3] force [10]
Creates a random level with 50 stars and deploys 5 players each having 3 starting stars each having an initial force of 10 ships. (Any of these four options can be omitted. Note that map [mapname] can be used in conjunction with the players [#], bases [x], and force [x] options.)
$time [on] / [off] / [#]
Turns the time setting on or off. If time is set to on, a further command must be issued: $time [x]. After [x] number of ticks with the time setting enabled, the game will end, with the player who controls the most stars winning.
$auto (on) / (off)
The server enters / leaves the automatic mode, which restarts the game automatically when a player wins a map.
$auto command [load risk]
Stores a command, in this case a map loading command, which will be executed upon the end of the current game (if the auto mode has been turned on using $auto on). Any number of commands can be used, each executing after the end of the current game. (ex. if $auto command load risk and then $auto command load time were typed in successively, the map 'time' would load upon the end of the map 'risk'.)
$auto id [x] display
Displays the [x] auto command (if existing). If "$auto display" is used without any "id [x]", it will display the number of auto commands currently loaded into the server.
$auto id [x] delete
Deletes the auto command at [x], if existing. $auto delete all could also be used to delete all auto commands.
$auto id 2 command load one
Replaces the existing second command with a new command (in this case the new command loads the map named one)
$auto min 2 max 3 id 4 command load one
Creates a conditional command: this command only gets activated if there are between 2 and 3 human players connected to the game. This is useful to make sure the game doesn't automatically load a map that doesn't have enough sides for all the connected players. As usual, either of (or all of) max, min, and id can be omitted.
$restart
Restarts current level. The same as the button action.
$start
Starts the current level. The same as the button action.
$speed 2
Sets the game speed to 2x. The number after speed can range between 1 and 3.
$host-count
Shows a tally of the games you hosted.
$double-ip
Checks for players who have the same IP. Sometimes this is legitimate (multiple players playing from the same house), sometimes a player cheats by controlling multiple sides.
$admin password xxx
Sets the password for remote administration to xxx
$a
Short for $admin
$admin red on
Grants the red player administration rights (see client commands below).
$admin off
Disallows all client players from issuing administration commands and disables the administration password.
$admin on
Allows players to log in using a password. Only use if a password was entered before and disabled by a $admin off command
$cl ~/path/file.txt / c:\path\file.txt
Launches a series of commands stored in a text file.
$max-player 4
Sets the maximum number of players to 4. The server will reject new players when at least 4 have already joined the game
$welcome Hello %p ! You play the color %c.
Changes the message newly connected players receive when they first join the server. %p instances are replaced with the player's name, %c with the color of his empire.
$gag red
Forbids the red player from emitting messages.
$gag all
Forbids all players from emitting messages; players joining the game thereafter are automatically gagged.
$ungag blue
Allows the blue player to send messages. If preceded by $gag all, it also allows new coming players to chat.
$ungag all
Allows all players to send messages. If preceded by $gag all, it also allows new coming players to chat.
$diplomacy [ off | private | public ]
Changes diplomacy mode
$star-victory 20 yellow
Enables a victory condition of controlling all yellow stars on the map for 20 game ticks.
$star-victory 5 blue teleport
Enables a victory condition of controlling the bluish teleport star for 5 game ticks. The other two teleport stars can be named by 'white teleport' or 'green teleport'
$star-victory 0 purple
Victory for the player who first conquers all purple stars.
$star-victory off
Removes star control as a victory condition
$at 100 speed 4
Causes the speed 4 command to execute 100 ticks into the any game after the statement is entered.
$every 100 say hello world
Causes the say hello world command to execute now and once every 100 ticks in the future.
$at 50 every 150 say foo
Causes the say foo command to execute 50 ticks into the game and then at every 150 ticks.
$clear-events
Clear all time events created by $at and $every commands
Client and server commands
$bell
Makes a ringing sound on the server's computer. Used to gain the server host's attention (or make thwm turn the sound off).
$surrender / $unsurrender
Give up. Raise the "white flag." If all player but one surrender, then that remaining player wins the game. People usually surrender as a courtesy to those who are out of the game and waiting for a new game to start. [Same as the button.]
$admin password xxx
Tries to log in as an administrator using the password xxx. If the password checks out, the client can issue administration commands.
$a / $admin [load risk]
Equivalent to the server host issuing a $load risk command. The client admin can use all of the commands available to the server host, except $join, $quit, and $admin password [pw] and $admin [color] (on) / (off). You may also use $a instead of $admin as a shortcut.
$stars
Displays number of stars controlled by each player.
$ungag / $gag [color] / (all)
Stops / starts displaying messages from a specific player or everyone.
$lag
Shows which players cause the game to slow down.
$ver
Displays the version of Pax the server is running.
Several shortcuts can be used in the editor view.
Ctrl + Arrow Key : Moves all the stars in the direction of the arrow key.
Ctrl + C : Centers the map.
Ctrl + D : Moves the mouse cursor to the smallest star link. Repeated presses move the mouse to the second shortest link and etc.
Editing a map manually, after creating the initial map in the editor, can allow you to add special features to your maps.
You can add a new line at the top: "author=your-name-here" Then, on the map select screen in-game, it will say [mapname] by [author].
The lines with "scalex" and "scaley" can allow you to shrink the map. The value can range from 0.1 to 1.0 (untested). The normal value is 1.0; if you change it to 0.7, the map will shrink to 70% of the x and/or y axes. This increases the space you have on the map to put more stars. However, you should be aware that for large maps (5+ kb), when a server loads the map, all players may get disconnected. This seems to be due to a problem with the Pax engine.
The majority of the lines of the map file correspond to the actual stars. Here is an example line:
Y-0-s0-x220-y86-n2-sup0-blo0 12 1
Y = the star is a Yellow star (production). Other values are: B (blue, speed), V (violet, repair), R (red, defense), G (green, attack), O (orange, no bonus), 1/2/3 (the three teleport star colors)
0 = the player who initially controls the star. If 0, the star is not under any player's control at the start of the map. Other values: A/B/C/D/E/F (for the six players)
s0 = The initial amount of ships on this star. Although the editor allows you to place a max of 255 ships on any star, you can change this value pretty high (values 10k+ are untested). E.g. s2500 = 2.5k ships on the star.
x220-y86 = The star is placed at the x,y coordinates (220, 86).
n2 = The number of stars connected to this star. In this case, this star has 2 stars linked to it.
sup0 = The editor doesn't allow you to change this value, but you can manually edit it. It refers to the number of initially damaged ships on the star. E.g. sup250 = The star has 250 damaged ships to start with. Note that the "s" value above must equal the number of damaged ships plus the number of non-damaged ships. E.g. if the star should have 25 regular ships, and 10 damaged ones, then the "s" value should be "s35" and the "sup" value should be "10".
blo0 = The editor doesn't allow you to change this value, but you can manually edit it. You can put the values "blo0" to "blo6". This attribute affects the brightness of newly-conquered stars. Whenever a star is conquered (goes from the control of one player to another - not from no control to a player), the star becomes a little brighter for a brief period of time. The "blo" value affects how bright the star gets and how long the brightness increases. E.g. "blo6" means the star will become the brightest 6 turns after the initial conquering. Untested.
The numbers after blo0 are the ID numbers of the stars connected to the star in question. The ID numbers are the position of the line of the star in the file. E.g.: the first star line in the file (usually line 8 or 9) has ID 0, the one below it has ID 1, and so on.
(The information in this mapfile editing section was compiled from this thread on the diogames forums and through my own personal research.)