2023-09-12 18:58:10 +00:00
|
|
|
#include "..\script_component.hpp"
|
2017-05-10 16:28:44 +00:00
|
|
|
/*
|
|
|
|
* Author: PabstMirror
|
|
|
|
* Add a explosive detonation handler.
|
|
|
|
* Should be called on all machines.
|
|
|
|
* Code needs to return BOOL: true(allowed) / false(blocked)
|
2022-04-14 07:22:23 +00:00
|
|
|
* See https://ace3.acemod.org/wiki/framework/explosives-framework.html for an example.
|
2017-05-10 16:28:44 +00:00
|
|
|
*
|
|
|
|
* Arguments:
|
|
|
|
* 0: Code <CODE>
|
|
|
|
* - Passed [Unit<OBJECT>, MaxRange <NUMBER>, Explosive <OBJECT>, FuzeTime <NUMBER>, TriggerItem <STRING>]
|
|
|
|
*
|
|
|
|
* Return Value:
|
|
|
|
* None
|
|
|
|
*
|
|
|
|
* Example:
|
|
|
|
* [{false}] call ace_explosives_fnc_addDetonateHandler;
|
|
|
|
*
|
|
|
|
* Public: Yes
|
|
|
|
*/
|
|
|
|
|
|
|
|
params [["_code", {true}, [{}]]];
|
|
|
|
|
|
|
|
GVAR(detonationHandlers) pushBack _code;
|