Page MenuHomeFeedback Tracker

UnitKilled EH breaking regular Killed EH
Feedback, NormalPublic

Description

When you add the new UnitKilled group EH to a group, it affects the arguments of the regular Killed EH by switching arguments: The UnitKilled EH receives the Killed EH arguments and vice versa.
When you don't add the UnitKilled group EH, everything works as expected.

Details

Severity
Major
Resolution
Open
Reproducibility
Always
Operating System
Windows 11 x64
Category
General
Steps To Reproduce

Run this in any mission:

_group = createGroup west;
_target = _group createUnit ["B_GEN_Soldier_F", getPos player, [], 0, "NONE"];

_group addEventHandler ["UnitKilled", {
    diag_log ["UnitKilled", _thisEvent, _this, _this apply {typeName _x}];	
}];

_target addEventHandler ["Killed", {
    diag_log ["Killed", _thisEvent, _this, _this apply {typeName _x}];	
}];

_target setDamage 1;

Result:

10:45:51 ["UnitKilled","UnitKilled",[B Alpha 2-1:1,B Alpha 2-1:1,<NULL-object>,true],["OBJECT","OBJECT","OBJECT","BOOL"]]
10:45:51 ["Killed","Killed",[B Alpha 2-1,B Alpha 2-1:1,B Alpha 2-1:1,<NULL-object>,true],["GROUP","OBJECT","OBJECT","OBJECT","BOOL"]]
Additional Information

Event Timeline

johnb43 created this task.Sat, Oct 19, 10:47 AM

Revision: 152295

BIS_fnc_KK removed BIS_fnc_KK as the assignee of this task.Sat, Oct 19, 1:42 PM
BIS_fnc_KK changed the task status from New to Feedback.
BIS_fnc_KK added a subscriber: BIS_fnc_KK.
mrzorn added a subscriber: mrzorn.Sat, Oct 19, 4:03 PM