Skip to content

Features and Configuration

szapp edited this page Nov 4, 2017 · 29 revisions

Initialization by Features

Gothic Free Aim comes various features (besides free aiming itself). These features can be used completely independently, even without using free aiming itself. To use GFA with a selected set of features only, GFA can be initialized with different flags.

Flag Feature
GFA_RANGED Free aiming for ranged combat
GFA_SPELLS Free aiming for spells
GFA_REUSE_PROJECTILES Shot projectiles are collectable
GFA_CUSTOM_COLLISIONS Manipulate collision behaviors
GFA_CRITICALHITS Critical hits for ranged combat
GFA_ALL Use all features

These flags can be combined to initialize GFA selectively:

GFA_Init(GFA_ALL);                                        // Initialize all features
GFA_Init(GFA_ALL & ~GFA_REUSE_PROJECTILES & ~GFA_SPELLS); // Initialize all but re-using of projectiles and free aiming for spells
GFA_Init(GFA_RANGED | GFA_CRITICALHITS);                  // Initialize free aiming for ranged combat and critical hits only

Recommended Initialization

If you want to implement GFA into your modification without any additional work, it is recommended to initialize it without re-usable projectiles. This feature would require additional tweaking, because you would need to reduce the numbers of arrows and bolts in the world. Otherwise there would be too many (since the player can pick them up again). For tips and tricks on how to easily re-balance your mod-project including a provided script, read on here.

Aside from that feature, GFA is well-balanced and does not require any changes on the rest of your mod-project.

GFA_Init(GFA_ALL & ~GFA_REUSE_PROJECTILES);

Configuration

The configuration is mostly implemented by calling outsourced functions. This is to separate the internal mechanisms of this script package cleanly from the customization. These outsourced configuration functions can be freely adjusted. The only restrictions are the function signature and the type of return value. What happens inside the functions is fully up to you.
Other settings are offered as constants that can simply be changed.

The configuration is grouped by features.