_man = man5
if(alive Man1)then{man1 = _man; goto "NEXT"}
if(alive Man2)then{man2 = _man; goto "NEXT"}
if(alive Man3)then{man3 = _man; goto "NEXT"}
if(alive Man4)then{man4 = _man; goto "NEXT"}
if(alive Man5)then{man5 = _man; goto "NEXT"}
#NEXT
_man groupchat "Hello, message is......"
;; continue with rest of code
The above code must be run on all clients
eg ?(local player):[]exec "myscript.sqs"
Reason:
Groupchat is a local command, meaning, it will not be transmitted across a network, therefore you have to run the script that runs the code executed on all clients.
If its for the start of the mission, the Init.sqs is as goods as any, or possibly the Intro script
What the script does:
1) Looks to see if the first name in the list, eg man1 is alive, if so it skips checking the rest and jumps to the "next" label and so on and so forth