Page MenuHomeFeedback Tracker

Group event handler combat modes returns wrong modes
New, NormalPublic

Description

So i was playing around with the flee mechanic. According to the documentation fleeing.

Fleeing units in combatMode red, will be set to yellow when fleeing to avoid engaging enemies while doing so.

I used this code to see the combat mode change:

{
	_x addEventHandler ["CombatModeChanged", {
		params ["_group", "_newMode"];
		systemChat format ["CombatModeChanged: %1, %2",_group,_newMode];
	}];
} forEach groups west;

And i get COMBAT back or UNCHANGED.
So this is not what i expected to see. I was expecting colors according to the documentation Combat_Modes
I think it might be returning behavior instead of combat mode.

Details

Severity
Minor
Resolution
Open
Reproducibility
Always
Operating System
Windows 11 x64
Category
General
Steps To Reproduce
  1. PLace an infantry group
  2. Set it's fleeing to 1 or set it to 9 and make an enemy attck
  3. add the example eventhandler to the group
  4. play

Event Timeline

Darkbelg created this task.Dec 8 2023, 10:12 PM

did you check via sqf commands after a slight delay yet? it could be the EH triggers before the combat mode change happens

also there is two level of combat modes - could be the EH returns the "wrong one"

group: https://community.bistudio.com/wiki/combatMode
unit: https://community.bistudio.com/wiki/unitCombatMode
both: https://community.bistudio.com/wiki/combatBehaviour

which is which of the two levels is quite confusing

also there is behaviour and combat mode - two different things but the naming isnt used consistently: https://community.bistudio.com/wiki/behaviour
might be the wiki linking the wrong one from here: CombatModeChanged: https://community.bistudio.com/wiki/Arma_3:_Event_Handlers#CombatModeChanged

however BehaviourChanged group EH is missing

Hello, the event handler was indeed named in a confusing fashion; the wiki has been fixed to reflect the returned behaviour.

Seems like I forget to mention I was basing myself on the wiki of the event handler.

This comment was removed by dedmen.
dedmen added a subscriber: dedmen.Jan 16 2024, 11:38 AM