ACE3/addons/concertina_wire/functions/fnc_handleDamage.sqf
ulteq 3e25a8b4a9 Finished ACE2 port:
* The concertina wire can now be placed in the editor
* Added handleDamage EH to avoid wire destruction with bullets/grenades
* Added proper detection routine of what killed the wire
2015-06-10 22:29:33 +02:00

30 lines
473 B
Plaintext

/*
* Author: Ruthberg
*
* Handles wire damage
*
* Arguments:
* 0: wire <OBJECT>
* 1: selectionName <STRING>
* 2: damage <NUMBER>
* 3: source <OBJECT>
* 4: projectile <STRING>
*
* Return Value:
* Nothing
*
* Return value:
* None
*/
#include "script_component.hpp"
PARAMS_5(_wire,_selectionName,_damage,_source,_projectile);
if (_damage < 0.5) exitWith { 0 };
if (!(isNull _source)) then {
_wire setVariable [QGVAR(lastDamager), _source];
};
_damage