Jump to content
JVez

Synchronized a group create.

Recommended Posts

Hello everyone. I am trying here to synchronize a group create by an action with the module of high-command-Subordinate. Is it fesable?

 

[getMarkerPos "MARK2", resistance, ["LIB_US_Engineer_w", "LIB_US_Engineer_w", "LIB_US_Engineer_w"]] call BIS_fnc_spawnGroup;

Here is the variable of my module: resistancegroup1

Share this post


Link to post
Share on other sites

I tried that:

 

_engineer = [getMarkerPos "MARK2", resistance, ["LIB_US_Engineer_w", "LIB_US_Engineer_w", "LIB_US_Engineer_w"]] call BIS_fnc_spawnGroup;
 	_engineer synchronizeObjectsAdd ["resistancegroup1"];

and it does not work ...

Share this post


Link to post
Share on other sites

Yeah because BIS_fnc_spawnGroup returns a group and not an object. The syntax looks like this:

object0 synchronizeObjectsAdd [object1, object2, object3,...,objectN];

Also putting "" around resistancegroup1 doesn't make sense, since it is a variable. Furthermore modules are only initalized at the start of the mission/their creation. Any further edits have no effect. There is a command to add a group to high command though:

_newGroup = [getMarkerPos "MARK2", resistance, ["LIB_US_Engineer_w", "LIB_US_Engineer_w", "LIB_US_Engineer_w"]] call BIS_fnc_spawnGroup;
player hcSetGroup [_newGroup]

hcSetGroup

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×