cba_fnc_taskdefend units stuck raising/lowering weapon

I'm creating a group of units around an object and I'm giving them an objective to defend a location. It works as expected, the units either patrol the area or setup in nearby buildings.

_group = creategroup independent;
{
    _pos = (getpos _cache) findemptyposition[10, 100, _x];
    _unit = _group createunit [_x, _pos, [], 0, "NONE"];
} foreach _random_group;
_group setspeedmode "LIMITED";
_group setBehaviour "SAFE";
[_group, (getpos _cache), 100, 2, true] call cba_fnc_taskdefend;

However, I noticed that if a unit decides to enter a building and occupies one of the positions sometimes that causes units to infinitely raise and lower their weapons until they're fired upon. They won't respond to movement either. It's not specific to a map, it happens on Altis and Stratis as well. I've only noticed it using the taskdefend function. It makes the encounters rather pathetic because you can walk up to the enemy in plain sight without being shot.

EDIT: Noticed after posting an issue on github exists: https://github.com/CBATeam/CBA_A3/issues/551

Posted Dec 25, 2016, 10:29 AM UTC · edited

21
tsarcorp•

Oh, so that explains those dudes raising and lowering their guns all the time when i'd go to clear buildings in Liberation.

1