Initial commit
This commit is contained in:
27
highcommand.sqf
Normal file
27
highcommand.sqf
Normal file
@ -0,0 +1,27 @@
|
||||
0 spawn {
|
||||
// Replace `commander` with your unit variable
|
||||
_commander = commander;
|
||||
|
||||
waitUntil {
|
||||
sleep 1;
|
||||
|
||||
{
|
||||
_units =
|
||||
if (count (units _x select {alive _x}) != 0) then
|
||||
{
|
||||
_commander hcSetGroup [_x];
|
||||
}
|
||||
}
|
||||
forEach groups side _commander;
|
||||
|
||||
{
|
||||
if (count (units _x select {alive _x}) == 0) then
|
||||
{
|
||||
_commander hcRemoveGroup _x;
|
||||
}
|
||||
}
|
||||
forEach hcAllGroups _commander;
|
||||
|
||||
false;
|
||||
};
|
||||
};
|
||||
Reference in New Issue
Block a user