From bce84d9a2dd41c181ee5c887532053385ee61f5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicol=C3=A1s=20Badano?= Date: Fri, 16 Jan 2015 12:38:43 -0300 Subject: [PATCH] respawn: raise "killedByFriendly" ACE event globally --- .../respawn/functions/fnc_showFriendlyFireMessage.sqf | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/addons/respawn/functions/fnc_showFriendlyFireMessage.sqf b/addons/respawn/functions/fnc_showFriendlyFireMessage.sqf index f384b69284..7d1b374252 100644 --- a/addons/respawn/functions/fnc_showFriendlyFireMessage.sqf +++ b/addons/respawn/functions/fnc_showFriendlyFireMessage.sqf @@ -1,16 +1,16 @@ /* Name: ACE_Respawn_fnc_showFriendlyFireMessages - + Author(s): commy2 - + Description: shows a message in system chat of who killed who - + Parameters: 0: OBJECT - unit 1: OBJECT - killer - + Returns: VOID */ @@ -25,5 +25,8 @@ _killer = _this select 1; if (_unit != _killer && side group _unit in [side group ACE_player, civilian] && {side group _killer == side group ACE_player}) then { systemChat format ["%1 was killed by %2", [_unit] call EFUNC(common,getName), [_killer] call EFUNC(common,getName)]; + // Raise custom event. @todo: remove [_unit, "killedByFriendly", [_unit, _killer]] call EFUNC(common,callCustomEventHandlers); + // Raise ACE globalEvent + ["killedByFriendly", [_unit, _killer]] call EFUNC(common,globalEvent); };