EV data formats for version 1.1 upwards (more recent changes are marked in the respective declarations) EV data files consist of records of one or more types written consecutively. There's no information of how many records are stored in a file or how large one record is (some of the records have variable length). The first word of each data record is a type identifier, use it to check for format changes. If that identifier is unknown, then the record format is old or has changed. Note that all data fields can be invalid, this is usually indicated by having a value of $FFFF or -1 (for word or integer) or $FFFFFFF or -1 (for longints). Some data fields have a value of zero if they are invalid, especially for ship and planet records this is a bit confusing. Since EV is programmed in Pascal, most data formats are given in Pascal notation. However, I've translated the EPLAN*.DAT format to C so that you can compare and better understand the Pascal notation (see end of this file). Pascal data formats: Dataformat for ESHIP*.DAT : The file ESHIP*.DAT consists of records of the type tship tship=record typ:word; (* internal type declaration, valid valus are $0001 to $000F *) turn:word; (* turn of last info *) mass:word; (* ship mass *) ship:tshiprec; (* ship specs, see tshiprec *) nhistory:word; (* number of history records *) history:array[0..nhistory-1]of tshiphist; (*see tshiphist*) nchars:word; (* number of characters in notepad *) notepad:array[0..nchars-1]of char; end; tshiprec=record (* record as used by HOST program *) wID:word; (* ship's ID *) wRace:word; (* owner of ship *) sCode:array[0..2]of char; (* Friendly code; three characters *) wWarp:word; (* Speed of ship *) xDis, yDis:integer; (* Displacement next turn *) xCoord:word; (* Location of ship (xCoord, yCoord) *) yCoord:word; wDriveLevel:word; (* Tech level of engines *) wShipType:word; (* Type of ship (index in HULLSPEC.DAT) *) wBeamLevel:word; (* Tech level of beams *) wBeamWeapons:word; (* Number of beam weapons *) wFighterBays:word; (* Number of fighter bays *) wTorpLevel:word; (* Torp. tech. level *) wTorps:word; (* Number of torps/fighters *) wTorpsBays:word; (* Number of torp. lauchers *) wMission:word; (* Mission of the ship *) wEnemy:word; (* Primary enemy *) wTowTarget:word; (* Ship to tow *) wDamage:word; (* Ships damage in % *) wCrew:word; (* Number of crew members on ship *) wColonists:word; (* Number of colonists on ship *) sName:array[0..19]of char;(* Name of ship *) wFuel, wTri, wDur, wMol:word; (* Minerals on ship *) wSupplies:word; (* Supplies on ship *) wPClans,wPFuel,wPTri,wPDur,wPMol,wPSup:word; (* Cargo to planet *) wPID:word; (* ID of planet *) wSClans,wSFuel,wSTri,wSDur,wSMol,wSSup:word; (* Cargo to ship *) wSID:word; (* ID of ship *) wIntercept:word; (* ID of ship to intercept *) wMoney:word; (* MC's on ship *) end; tshiphist=record turn:word; xcoord:word; ycoord:word; owner:byte; (* NOTE: formerly, this was a word containing only the owner *) warp:byte; (* this is NEW starting with version 1.2.13 beta *) mass:word; end; Dataformat for EPLAN*.DAT : The file EPLAN*.DAT consists of records of the type tplanet tplanet=record typ:word; (* internal type declaration, $8080 from EV 1.02 upwards *) turn:word; (* turn of last info *) base:word; (* 0 if no base present *) custom:word; (* custom sort value *) nchars:word; (* size of notepad *) notepad:array[0..nchars-1] of char; planet:tplanrec; (* see below *) end; tplanrec=record (* record as used by HOST program *) wOwner:word; (* Owner (0 = no owner) *) wID:word; (* ID of planet *) sCode:array[0..2]of char; (* Friendly code *) wMines:word; (* Number of mineral mines *) wFactories:word; (* Number of factories *) wDefense:word; (* Defences on planet *) lFuel, lTri:longint; (* Mined minerals *) lDur, lMol:longint; lColonists:longint; (* Number of colonists *) lSupplies:longint; (* Supplies on planet *) lMoney:longint; (* MC's on planet *) lFuel_P, lTri_P:longint; (* Minerals IN planet *) lDur_P, lMol_P:longint; wFuel_D, wTri_D:word; (* Density of minerals in planet (in %) *) wDur_D, wMol_D:word; wColTax:word; (* Colonist-taxes in % *) wNativeTax:word; (* Native-taxes in % *) iColStatus:integer; (* <20 fighting ... 70 calm, 90 happy *) iNativeStatus:integer; (* id. *) wGov:word; (* Government of natives *) lNatives:longint; (* Number of natives *) wRace:word; (* Native's race (7=amph 8=ghip etc.) *) wPlanet:word; (* 100-Climate *) wbase:word; (* build starbase (0 do not build) *) end; Dataformat for EMINE*.DAT : The file EMINE*.DAT consists of records of the type tmine tmine=record typ:word; (* internal type declaration: $8100 *) turn:word; (* turn of last info *) mine:tminerec; (* see below*) nhist:word; history:array[0..nhist-1]of tminehist; (*see below*) end; tminehist=record turn:word; (* turn of info *) mine:tminerec; (* see below *) end; tminerec=record MinefieldID:word; XLocation:word; YLocation:word; Owner:word; (*1-11*) MinefieldUnits:longint; IsWeb:word; (*0=no, 1=yes*) end; Dataformat for EBASE*.DAT : The file EBASE*.DAT consists of records of the type tbase tbase=record typ:word; (* internal type declaration: $0081 *) turn:word; (* turn of last info *) wID:word; (* from here: record as used by HOST program *) wOwner:word; wDefence:word; (* Defence of starbase *) wDamage:word; (* Damage in % *) (* Tech levels *) wTechEngine:word; wTechHull:word; wTechBeam:word; wTechTorp:word; (* Items on starbase *) wEngines:array[1..9]of word; (* #engines on starbase index 0=stardrive 1 *) wHulls:array[1..20]of word; (* #Hulls, index = index in truehull *) wBeams:array[1..10]of word; (* #beam weapons on starbase index 0=Laser *) wTLaunchers:array[1..10]of word; (* #torp lauchers on base, 0=Mark 1 *) wTorps:array[1..10]of word; (* #tops on starbase index 0=Mark 1 *) wFighters:word; (* #fighters on base *) wFixID:word; (* ID of ship being fixed or recycled *) wFixShip:word; (* 0=do nothing, 1=fix ship, 2=recycle ship *) wMission:word; (* 1 = Refuel, 2 = Max defence, ... *) (* Ship being build *) wShip:word; (* Ship being build (index in truehull) *) wEngineLevel:word; (* Engine level of ship being build *) wBeamLevel:word; (* Beam level of ship being build *) wBeamOnShip:word; (* Number of beams on ship *) wTorpLevel:word; (* Torp. laucher tech level *) wTorpOnShip:word; (* Number of torp. laucher on ship *) wFightOnShip:word; (* Number of fighters on ship (0) *) end; Dataformat for EUFO*.DAT : The file EUFO*.DAT consists of records of the type tufo tufo=record typ:word; (* internal type declaration: $8800 *) turn:word; (* turn of last info *) ufoid:word; ufo:tufotype; (*see below*) nhist:word; history:array[0..nhist-1]of tufohist; (*see below*) end; tufotype=record (* this record is identical to the one used by the HOST program for UFOs *) marker:Integer; nm:array[0..19]of char; info1:array[0..19]of char; info2:array[0..19]of char; x:Integer; Y:Integer; warp:Integer; heading:Integer; rangeP:Integer; rangeS:Integer; edge:Integer; parent:Integer; end; tufohist=record turn:word; x:word; y:word; edge:word; end; Dataformat for ESTORM*.DAT : The file ESTORM*.DAT consists of records of the type tstorm tstorm=record typ:word; (* internal type declaration: $0200 *) turn:word; (* turn of last info *) StormID:word; LocationX:word; LocationY:word; Voltage:word; Heading:word; Speed:word; Radius:word; Class:word; Growth:word; end; Dataformat for EHOLE*.DAT : The file EHOLE*.DAT consists of records of the type thole thole=record typ:word; (* internal type declaration: $A400 *) turn:word; (* turn of last info *) LocationX:word; LocationY:word; Mass:integer; StableCode:word; WormID:integer; XExit:word; YExit:word; nhist:word; history:array[0..nhist-1]of tholehist; (*see below*) end; tholehist=record turn:word; LocationX:word; LocationY:word; Mass:word; StableCode:word; end; Dataformat for ESCORE*.DAT : The file ESCORE*.DAT consists of records of the type tscore3 or tscore1 tscore3=record typ:word; (* internal type declaration: $3002 *) turn:word; scores:array[1..11]of tracescore; buildpoints:array[1..11]of longint; (* PBPs for each race *) end; tscore1=record typ:word; (* internal type declaration: $1002 *) turn:word; scores:array[1..11]of tracescore; end; tracescore=record wPlanets,wCapitalShips,wFreighters,wBases:word; (* number of planets, ships, freighters, bases *) end; Dataformat for EGRAPH*.DAT : The file EGRAPH*.DAT consists of records of the types tline, tcircle, ttext tline=record typ:word; (* internal type declaration: $1001 *) turn:word; color:longint; (* windows RGB color *) x1,y1:word; x2,y2:word; width:word; (* linewidth in pixels *) end; tcircle=record typ:word; (* internal type declaration: $1004 *) turn:word; color:longint; x1,y1:word; rc:word; (* radius *) width:word; (* linewidth in pixels *) end; ttext=record typ:word; (* internal type declaration: $1003 *) turn:word; x1,y1:word; color:longint; font:tlogfont; (* windows font record *) nchars:word; (* number of characters in text including the zero char at the end *) stext:array[0..nchars-1]of char; end; C data format of EPLAN*.DAT typedef struct { WORD type; // 0x8080 WORD turn; // turn number of last info WORD base; // has a base (0=no) WORD custom; // EV custom planet value WORD notelen; // length of notepad char notepad[notelen]; // notepad; this one's the variable part ! WORD wOwner; // Owner (0 = no owner) WORD wID; // ID of planet char sCode[3]; // Friendly code WORD wMines; // Number of mineral mines WORD wFactories; // Number of factories WORD wDefense; // Defences on planet LONG lFuel, lTri; // Mined minerals LONG lDur, lMol; LONG lColonists; // Number of colonists LONG lSupplies; // Supplies on planet LONG lMoney; // MC's on planet LONG lFuel_P, lTri_P; // Minerals IN planet LONG lDur_P, lMol_P; WORD wFuel_D, wTri_D; // Density of minerals in planet (in %) WORD wDur_D, wMol_D; WORD wColTax; // Colonist-taxes in % WORD wNativeTax; // Native-taxes in % int iColStatus; // <20 fighting, 20 rioting, ... int iNativeStatus; // id. WORD wGov; // Government of natives (6=monarcy 5=feudel etc.) LONG lNatives; // Number of natives WORD wRace; // Native's race (7=amph 8=ghip etc.) WORD wPlanet; // 100-Climate. WORD wbase; // build base (0=no) } PlanetData;