ACE3/addons/vehicledamage/XEH_preInit.sqf

81 lines
1.8 KiB
Plaintext
Raw Normal View History

#include "script_component.hpp"
ADDON = false;
// Extension engine functions
PREP(initializeExtension);
PREP(monitorResultsPFH);
PREP(parseResult);
PREP(callExtension);
2015-05-11 23:01:58 +00:00
GVAR(async) = true;
GVAR(ready) = false;
2015-05-11 23:01:58 +00:00
#ifdef DEBUG_LOG_EXTENSION
GVAR(debug_log) = [];
#endif
#ifdef DEBUG_EXTENSION_DYNLOAD
// This value is used for debug loading of the extension with dynload
2015-05-14 23:53:22 +00:00
GVAR(extensionLibrary) = "z\ace\extensions\build\vd\Debug\ace_vd_Debug.dll";
2015-05-11 23:01:58 +00:00
#endif
// Extension dispatch events
PREP(setAnimationNames);
// To extension send events
PREP(getAnimationStates);
// Core functionality
PREP(registerVehicleDamageHandler);
PREP(registerVehicleWithExtension);
PREP(unregisterWithExtension);
PREP(dispatchHitPart);
PREP(dispatchDamage);
PREP(doHit);
GVAR(vehicle_id) = 0;
GVAR(vehicles) = HASH_CREATE;
FUNC(_textVector) = {
private["_str"];
_str = format["%1;%2;%3", ((_this select 0) select 0), ((_this select 0) select 1), ((_this select 0) select 2)];
_str
};
2015-05-11 23:01:58 +00:00
#ifdef DEBUG_LOG_EXTENSION
FUNC(clipboardExport) = {
private["_chunks"];
_chunks = [];
_chunks = [_this select 0, ";"] call CBA_fnc_split;
{
private["_chunk"];
_chunk = _x + ";";
"ace_clipboard" callExtension format["%1", _chunk];
} forEach _chunks;
"ace_clipboard" callExtension "--COMPLETE--";
};
FUNC(exportLog) = {
private["_chunks"];
_chunks = [str(_this select 0), ","] call CBA_fnc_split;
{
private["_chunk"];
_chunk = _x + ";";
"ace_clipboard" callExtension format["%1", _chunk];
} forEach _chunks;
"ace_clipboard" callExtension "--COMPLETE--";
};
#endif
[] call FUNC(initializeExtension);
ADDON = true;