Well the multiplayer part is the most tricky one here.
You have to know that: every custom action happens local
Now everything you do in a custom action, will only be executed, where the action was triggered.
The example, i've sent you would work in multiplayer for
two players. The only thing which would have to be done is:
create different arrays of group, for different players.
Hell, it should even work for more than two players, but only
if everybody playable has to control his own units, without
touching units of somebody else.
Anyway, back to multiplayer and your problem:
Do you acc the actions again, once the player respawns into
the next teammember, or did you only expect them to switch
to the new leader automatically?
Let's say you want to move something by onMapsingleclick.
If the script, where onMapsingleclick is used, was started
from the action menu, then the parameter _pos only exists,
where the action was executed.
Also, if you move a marker's position, the marker will only move,
where the custom action has been executed.
You need to work with:
publicVariable "variablename"
to transfer changed variables from local to global
Also note that you can't use publicVariable for strings or arrays.
You can only do it with: numeric variables, boolean (true/false),
group/object/units.
I do not exactly know, how you did setup your scenario, and
what you've done for multiplayer yet with it.
What i know for sure is: how to make a multiplayer mission
Once i'll make motag fully multiplayer able (not too far from
now), i'll use OPF's multiplayer weakness as to my advantage.
I'll use the fact that things happen local, just to enable everybody to use the very same scripts and variables, without
them comming across somewhere.
If you want to use more complex stuff like strings and arrays
to be transfered, you need to watch out for CoC network services.
hmm - better not confuse you anymore here
~S~ CD