CONTROL.DAT - Checksums

DOS Planets

CONTROL.DAT exists once per directory, even for more than one player. Then it contains information for all players in this directory, all need to play in the same game.

Winplan

For each player a single CONTRLx.DAT file. Winplan can handle multiple games in one directory, and one game spread over multiple directories, as long as there are no race collisions (i.e., two times player 3 in the same directory won't work).

 +0 500 DWORDs  Checksums of all ships
                For each ship in SHIPx.DAT, the sum of all bytes in the
                ship record is computed. Positions of unavailable ships
                are undefined and contain parts of deleted files.
+2000   -"-     Checksums of all planets.
                The same for all planets in PDATAx.DAT
+4000   -"-     Checksums of starbases
                The same for all starbases in BDATAx.DAT
+6000   WORD    0 ?
--- Host999 Games ---
+6002 n BYTEs   apparently unused
+8000 499 DWORDs Checksums of ships 501..999. Not all these need to be
                present if the corresponding ships do not exist.

The word at +6000 might be a side-effect when the file is created: To make room for 6000 bytes, do a `Seek(6000)' followed by some `Write' statement.

If this information is incorrect, Planets doesn't show an error message. It corrects the problem, but only if the erroneous record is accessed from within the client program. MAKETURN aborts with the following error message if it finds any mismatch: "DATA ENCRIPT ERROR". (This typo has successfully hidden itself in all versions, from DOS Planets up to Winplan 3.52...)