The publish process creates a .CD subfolder in the work directory, and
copies all files needed for the project into it.The
content of the .CD folder can be then be put onto CD-ROM or
on a website
for distribution. In the free version, most options
are greyed out - just click [Ok] for starting
the publish process. Otherwise the following options are available:
P Generates a WRS resource file that contains all files belonging to the project in compressed
and encrypted form. Note that some file types, like DLL plugins or
movie files, can not be contained in a resource but must physically
exist in the .CD folder - see remarks below.
a window definition
file (acknex.wdf) for the current
WDL project settings
file determines the starting behavior of the application: showing a
setting command line options, displaying
compiler messages and so on.
If a syntax error was found in the window definition, or an image file belonging to it was not found or has a wrong format, an ERRNO error message is issued and the acknex.wdf file is not created.
a redistributable level editor, WEDS.EXE, in the .CD
folder (only when a resource file is created). WEDS is
a stripped down version of WED and can be used by the end user for
creating own levels for
and WAD files belonging to the game levels should also be provided
on the end user CD-ROM. WEDS uses all entities and behavior
actions found in the resource file. For entities to be visible
in the editor, they have to exist in the same folder as the resource
file. When providing maps to be edited, make sure that they either have no main script assigned - otherwise WEDS will complain when the script is missing.
can be loaded externally, but not edited.
the engine and compiles the lite-C source code into an executable that is then
copied into the .CD subfolder (not available in the free or Team Editions). Otherwise, the source code (.c or .wdl) is copied directly into the .CD subfolder, and compiled on the fly when starting the published executable.
Creates the EXE file (scriptname.exe) and redistributable
engine DLL (acknex.dll)
for starting the game.
If [Compile EXE] is unchecked, the path to
an EXE file can be given here (default: acknex.exe).
When calling the engine DLL from an external application, give the
path to the executable here. If the path field is left empty, no EXE
and no engine DLL are created. Note that the engine DLL is 'locked'
to the EXE file - it
start a different game or an afterwards changed script. The Trial,
Lite, or Team Editions don't generate an EXE and DLL file in the .CD
!! Please note:
For creating the .CD subfolder, the work folder
must be write enabled under
Windows Vista or above! Therefore don't create your projects in the Gamestudio installation folder (which is normally only write enabled for the administrator under Vista), but in the Documents section of your PC.
EXE files and icons
The engine EXE and DLL files are only created when the publish
process does not encounter an error. Errors
- normally missing files - are indicated in
the publish window.
- The EXE is named after the main script. The name must not contain spaces or special characters other than '-' or '_'. The EXE file contains a manifest that is compatible to the Microsoft Games for Windows standard.
- For using an EXE file with an individual icon, create a copy of the acknex.exe engine in your Gamestudio folder, alter the icon of the copy with an Icon Manager program, and give the path to the altered EXE in the Engine field (or just copy it back to acknex.exe). The executable will then be created from your copy with the altered icon, rather than from the original engine. The icon from the EXE will also be used for the task bar.
Please note that afterwards altering the icon of a published executable won't work.
If an icon file named "32.ico" (size 32x32) or "16.ico" (size 16x16) is found in the work folder, it is automatically loaded and used for the task bar icon instead of the icon from the EXE.
Alternatively you can use the SED ChangeExeIcon plugin for patching the executable with your own icon.
- For creating a screen saver, rename the published .EXE to .SCR. When running it from the Windows folder, make sure to set the PLUGINDIR to a different path. Otherwise the published engine scans for plugins in the current folder, which will cause an extremely slow startup when the folder contains hundreds of DLLs, like the Windows folder.
- The source code for acknex.exe is available in the engine SDK. You can create your own executable as long as you provide a machine readable copy of the full source code along with the product. P If you own the Pro Edition or a SDK license, you don't need to provide the source code.
The publish process normally finds automatically all files that belong the the game. For this,
it scans the current level, the scripts, and all further WMP levels
given with the LEVEL statement. All
file names given in quotes ("")
or angular brackets (<>) in the script,
and all entity and sound files from the levels
are included in
the .CD folder or the resource. The file names must not be
longer than 32 characters, and must not contain special characters
except '-', '+', '_'.
For including additional files
not referenced in the script or level,
use the BIND statement.
For preventing a certain file to be included, begin its script name with an underscore "_" (i.e. "_not_me.avi"). If a file with this name does not exist, the engine opens a file with the same name but without underscore ("not_me.avi"). This file is not published or added to the resource.
- For excluding all files with a certain extension from the resource or from
being published at all, use EXCLUDE_RESOURCE or EXCLUDE_PUBLISH statements in the data/options.scr configuration file. By default, files with the extension AVI, MPG, MOV,
and DLL are not included in a resource
and files with the
or TMP are not
published at all.
The files are searched in the order given by the order
of PATH statements.
If two files with the same name are found, external files normally have priority over files inside a resource. For preventing that entities and levels are loaded from external files in the release version, set preload_mode to 16 or above. This increases the security of online games.
- Subfolders are
not created in the .CD folder.
If you want to use subfolders in a published project, place the files manually in the subfolders.
E Publishing Legacy Mode projects or old C-Script (.wdl) projects is only supported by the Extra Edition or above, but not by the free version. Old projects
have a limit of 40 .wdl files in the published version.
Make sure to include all required plugins from the acknex_plugins folder
or the work folder folder
to the published project. For supporting older DirectX9 versions
on the target machines,
either provide a DirectX setup with your installation program, or include the d3dx9_42.dll and - if
shaders are used - also d3dcompiler_42.dll. Both files can be found in the Gamestudio folder. When using A8 physics,
several PhysX DLLs must also be included - for details see Physics.
WRS is a container for all sorts of files that belong to a game. They are stored in a special compressed and encrypted format that can be read by all Gamestudio versions, but generated only by the Pro Edition P .
At engine start, all WRS resources found in the work folder are automatically opened, and the files in them become available to the project.
types must physically exist in the file system
, and thus can not be directly opened from inside a resource. For instance, DLL files must be available to the Windows OS, and streamed files such as movies or OpenAL sounds must be physically accessible to their media player. Those files can still be packed into a WRS resource, but must be renamed to *.pak and unpacked at project start into the work folder, using the file_cpy command.
- P For manually generating a WRS resource file with arbitrary content, make a WDL script that only consist of BIND statements for all files you want to include, and publish that WDL file with SED or with a command line option (f.i. wed -r mybind.wdl).
Check Resource in the Publish Dialog. The resulting WRS file can then be found in the .CD folder.
When all necessary game files, resources, and DLLs are included, Gamestudio applications run directly from their folder and normally don't require an installer. When an engine window is opened (video_screen > 0), DirectX 9.0c is required on the target PC. This should be the case for all PCs manufactured after 2006; when you want to support older systems, it might make sense to deploy a recent DirectX 9 installer.
- When using Physics, the PhysX system software must be installed on the target system; you'll find details in the PhysX chapter.
- When using OpenAL, the OpenAL DLL must be installed on the target system; you'll find details under snd_createoal.