mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
parent
88eb4c6cd3
commit
525f3c5ce3
@ -1,5 +1,5 @@
|
|||||||
|
|
||||||
PREP(handleDamage);
|
PREP(handleDamageBox);
|
||||||
PREP(engineFire);
|
PREP(engineFire);
|
||||||
PREP(cookOff);
|
PREP(cookOff);
|
||||||
PREP(smoke);
|
PREP(smoke);
|
||||||
|
@ -25,7 +25,7 @@ GVAR(cacheTankDuplicates) = call CBA_fnc_createNamespace;
|
|||||||
["ReammoBox_F", "init", {
|
["ReammoBox_F", "init", {
|
||||||
(_this select 0) addEventHandler ["HandleDamage", {
|
(_this select 0) addEventHandler ["HandleDamage", {
|
||||||
if ((_this select 0) getVariable [QGVAR(enableAmmoCookoff), GVAR(enableAmmobox)]) then {
|
if ((_this select 0) getVariable [QGVAR(enableAmmoCookoff), GVAR(enableAmmobox)]) then {
|
||||||
_this call FUNC(handleDamage);
|
_this call FUNC(handleDamageBox);
|
||||||
};
|
};
|
||||||
}];
|
}];
|
||||||
}, nil, nil, true] call CBA_fnc_addClassEventHandler;
|
}, nil, nil, true] call CBA_fnc_addClassEventHandler;
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#include "script_component.hpp"
|
#include "script_component.hpp"
|
||||||
/*
|
/*
|
||||||
* Author: KoffeinFlummi, commy2
|
* Author: KoffeinFlummi, commy2
|
||||||
* Handles all incoming damage for tanks (including wheeled APCs).
|
* Handles all incoming damage for boxi
|
||||||
*
|
*
|
||||||
* Arguments:
|
* Arguments:
|
||||||
* HandleDamage EH <ARRAY>
|
* HandleDamage EH <ARRAY>
|
||||||
@ -10,7 +10,7 @@
|
|||||||
* Damage to be inflicted. <NUMBER>
|
* Damage to be inflicted. <NUMBER>
|
||||||
*
|
*
|
||||||
* Example:
|
* Example:
|
||||||
* _this call ace_cookoff_fnc_handleDamage
|
* _this call ace_cookoff_fnc_handleDamageBox
|
||||||
*
|
*
|
||||||
* Public: No
|
* Public: No
|
||||||
*/
|
*/
|
||||||
@ -23,13 +23,6 @@ if (damage _vehicle >= 1) exitWith {};
|
|||||||
// If cookoff is disabled exit
|
// If cookoff is disabled exit
|
||||||
if (_vehicle getVariable [QGVAR(enable), GVAR(enable)] in [0, false]) exitWith {};
|
if (_vehicle getVariable [QGVAR(enable), GVAR(enable)] in [0, false]) exitWith {};
|
||||||
|
|
||||||
// Check for players and exit if none found and the enable for players only setting is true
|
|
||||||
if (
|
|
||||||
_vehicle getVariable [QGVAR(enable), GVAR(enable)] isEqualTo 1
|
|
||||||
&& {fullCrew [_vehicle, "", false] findIf {isPlayer (_x select 0)} == -1}
|
|
||||||
&& {_simulationType isNotEqualTo "box"}
|
|
||||||
) exitWith {};
|
|
||||||
|
|
||||||
// get hitpoint name
|
// get hitpoint name
|
||||||
private _hitpoint = "#structural";
|
private _hitpoint = "#structural";
|
||||||
|
|
Loading…
Reference in New Issue
Block a user