+0     WORD    Player Id
 +2     DWORD   Number of commands. THost accepts no more than 5000.
 +6  10 BYTEs   Date of last turn: mm-dd-yyyy
+16   8 BYTEs   Time of last turn: hh:mm:ss
+24     WORD    unused
+26     WORD    Timestamp Checksum
--- only, if commands exist ---
+28     BYTE    unused
+29   n DWORDs  File positions of the commands, each increased by 1
Command:
 +0     WORD    Command Code
 +2   n BYTEs   Data

A command is a request for the host to change a value. For example, the action "build a factory" is encoded as three commands: `PlanetChangeFactories', `PlanetChangeMoney' and `PlanetChangeSupplies'. MAKETURN looks for differences between the xxx.DAT and xxx.DIS files, and emits such commands.

A TRN file does not contain a list of things you did this turn ("sell one supply"), it contains just the net effects. If you undo one action (e.g., raise taxes, then lower them to their original value), this is not reflected in the TRN file (here: no tax change command is generated at all).

There are 4 groups of commands (values in decimal, not all numbers are actually used):

   1..19        Ships (SHIPx.DAT/.DIS)
  20..39        Planets (PDATAx.DAT/.DIS)
  40..59        Starbases (BDATAx.DAT/.DIS)
   >= 60        general (Password, messages - GENx.DAT, MESSx.DAT)

THost rejects unknown numbers as "Unknown OPP" with a cheat warning, but no consequences for the player. PHost does not accept turns with invalid commands.

The command names given below are these used in my UN-TRN program, you should recognize what they do from their names and arguments: The arguments are usually "snippets" from a player-side data file.