Hi everyone,
I forgot that foreach loop to create groups.. ie foreach unit in group unit belong to group <groupname>
and also how to assign a unit as leader of the group.
I know I can just create a group with F2 or add soldiers and group them. But I need them to belong to a groupname so I can use it in scripts rather than single out every unit get it?
Its been a long while.. I can't find this anywhere on google I'm probably not using the proper keywords.
I wouldn't be surprised if its somewhere in the OFP section.. I think I remember asking this question like 10 million years ago
EDIT
~~~
lol I keep answering my own questions you guys are gonna think I'm schitzo... anyway atleast others will benefit from this..
So deep within the bowels of the internet I found the command :
This is how:
*********
In init: groupname = group this; //I know its in the comref but its not clear because it uses player/player as an example heh
Now how would I go about making this into a foreach loop for every unit in the group?
in my script...
So let's assume the leader of the group is called groupleader and the group's name is groupname
{_x group groupname} forEach units groupleader
is that it?