Hey Folks,
i have a small issue in my mission. Once the player gets killed he can choose another unit via teamswitch until the whole squad is dead. However, he looses access to the supports provided by BIS' support module. I've tried several ways to re-add the supports, noe of them worked. Any ideas?
What i've tried already:
1. Adding supports to all playable units
// Works only for actual player
{[_x, IP_SuppReq, IP_SuppPro_Trans] call BIS_fnc_addSupportLink} forEach IP_PLAYERGROUP;
2. Script gets called from init and waits for the groupleader to die and then links the module to the new leader:
sleep 1;
_grp = group player;
while {(count units _grp) > 0} do {
_ldr = leader _grp;
waitUntil{!alive _ldr};
IP_SuppReq synchronizeObjectsRemove [_ldr];
_ldr synchronizeObjectsRemove [iP_SuppReq];
waitUntil{(leader _grp) != _ldr};
_ldr = leader _grp;
// [_ldr, IP_SuppReq, IP_SuppPro_Trans] call BIS_fnc_addSupportLink;
IP_SuppReq synchronizeObjectsAdd [_ldr];
_ldr synchronizeObjectsAdd [iP_SuppReq];
};
Tried the above code with different ways, none of them works.