Index


Using WDCreator

WDCreator.exe is a tool which allows you to put many files into single file with '.wd' extension. 
First, it's important to understand how game file system is working. Data files can be stored in '*.wd' files (as standard files are) or can be stored in subdirectories in Earth 2150 as separate files (like levels created in editor which are stored in 'Levels' directory). WD files contains directory structure - files of different types are in different directories. Name of '*.wd' file isn't important althrough usualy standard '*.wd' files contains files from directory with this name (f.e. Scripts.wd contains files from Scripts directory). If file with the same name exist in the same directory in some '*.wd' file and uder Earth 2150 directory then game uses newer file.

WDCreator.exe can be used in two ways. If you want just add files from one directory to one '*.wd' file you can call WDCreator.exe with specific parameters. For more complicated operations you can call WDCreator.exe with  special file name as parameter which contains commands for execute. You can add files to '*.wd' file with or without compression. Script and level files are compressed itself so there should be add without compression.
As you can see in examples below file names contains slashes and backslashes. Backslashes are in the "external" part of path, and slashes are in "internal" part of path - which is part of game file system. You must use slashes properly otherwise game can't handle this files. If some path ends with f.e. 'Scripts/>.eco' than char '>' mean "all files in this directory and its subdirectories".
Note that for scripts and levels you must use option 'c' or '<archive'.

Parameters for WDCreator.exe:
WDCreator.exe <WDFile> [<command> [command args]]
possible commands:
a - add files to WD without compression
p - add files to WD with compression 
c - add files to WD (added files are already compressed)
examples:
WDCreator.exe MyLevels.wd c C:\Game\Earth/Levels/*.lnd C:\Game\Earth/Levels/*.mis
WDCreator.exe MyScripts.wd c ./Scripts/Units/MyTank.eco ./Scripts/Gametypes/MyMultiGame.eco
WDCreator.exe MyScripts.wd c ./Scripts/Gametypes/Single/*.eco
Using configuration files:
WDCreator @scriptFile [define [define]]
where scriptFile is a file with following commands:
>wdfile - set name of wd and its guid
>pack - set compression for file (default)
>store - unset compression for file 
>archive - information that file is already compressed (required for scripts and levels)
>binary - type of file - binary (default)
>text  - type of file - text file
>add - add file to WD
examples:
WDCreator.exe @WDCreator.dat SCRIPTS
WDCreator.exe @WDCreator.dat ALL
with following WDCreator.dat file: 
#ifdef ALL
#define LEVELS
#define SCRIPTS
#define LANGUAGE
#endif
#ifdef LANGUAGE
<wdFile Language.wd
<add <text "c:\Games\Earth/Language/*.txt"
<add "c:\Games\Earth/Language/*.lan"
#endif
#ifdef LEVELS
<wdFile Levels.wd
<add <archive "c:\Games\Earth/Levels/*.lnd"
<add <archive "c:\Games\Earth/Levels/*.mis"
#endif
#ifdef SCRIPTS
<wdFile Scripts.wd
<add <archive "c:\Games\Earth/Scripts/>.eco"
#endif