Particle Script

Retro games feature a uniform, fixed-function Effect Script system for describing various geometrical effects and weapon systems. The PAK archives contain binary resources using FourCCs to build a key-value dictionary. These codes correspond to application-specific parameters controlling the effect system in question.

The binary script format uses a grammar that supports,  ,  ,  , and parameters to be evaluated and assigned to the dictionary. In addition, the various effect systems provide dynamic node classes that are evaluated as part of the effect runtime. Ultimately, the systems use a recursive, node-based approach of generating animated scalar and vector values to control the effect.

File Layout
All effect script file formats use a context-sensitive, free-form layout to build the key-value dictionary.


 * Script Magic FourCC (see table below)
 * Entries
 * Key FourCC (see script-format articles)
 * Value Parameter(s) (one of:)
 * : Bool/Scalar/Vector literal
 * bool/int/float/float3/float4 value
 * : Dummy value (equivalent to not specifying the key at all)
 * Node Key (see below)
 * Node Parameters

Script Nodes
Many of the animated qualities in effect scripts are achieved with dynamic script nodes. These nodes provide parameter I/O interfaces and internally process numeric data that passes through. They may also gather data from other sources within the effect system.

Scope is one of (Constant, System, Particle, Auto)


 * Constant parameters are evaluated once initially and retained within the system.
 * System parameters are evaluated per-system, per-frame.
 * Particle parameters are evaluated per-system, per-frame, per-particle-instance.
 * Auto parameters select their scope based on the node's parent context.