Jump to content
Sign in to follow this  
panda123

Give name group

Recommended Posts

I am using this script found in the forum

West setFriend [East,0];
East setFriend [West,0];

EastGrp01a = Creategroup EAST;
_leader = EastGrp01a createUnit ["TK_INS_Soldier_TL_EP1", [(getMarkerPos "se") select 0,(getMarkerPos "se") select 1,0], [], 3, "FORM"];
_unit = EastGrp01a createUnit ["TK_INS_Soldier_2_EP1", [(getMarkerPos "se") select 0,(getMarkerPos "se") select 1,0], [], 3, "FORM"];
_unit = EastGrp01a createUnit ["TK_INS_Soldier_EP1", [(getMarkerPos "se") select 0,(getMarkerPos "se") select 1,0], [], 3, "FORM"];
_unit = EastGrp01a createUnit ["TK_INS_Soldier_2_EP1", [(getMarkerPos "se") select 0,(getMarkerPos "se") select 1,0], [], 3, "FORM"];
_unit = EastGrp01a createUnit ["TK_INS_Soldier_EP1", [(getMarkerPos "se") select 0,(getMarkerPos "se") select 1,0], [], 3, "FORM"];
_unit = EastGrp01a createUnit ["TK_INS_Soldier_AT_EP1", [(getMarkerPos "se") select 0,(getMarkerPos "se") select 1,0], [], 3, "FORM"];
_unit = EastGrp01a createUnit ["TK_INS_Soldier_AT_EP1", [(getMarkerPos "se") select 0,(getMarkerPos "se") select 1,0], [], 3, "FORM"];
_unit = EastGrp01a createUnit ["TK_INS_Soldier_MG_EP1", [(getMarkerPos "se") select 0,(getMarkerPos "se") select 1,0], [], 3, "FORM"];
_unit = EastGrp01a createUnit ["TK_INS_Soldier_2_EP1", [(getMarkerPos "se") select 0,(getMarkerPos "se") select 1,0], [], 3, "FORM"];
_leader = leader EastGrp01a;
wp1 = EastGrp01a addwaypoint [position wpe, 0];
wp1 setwaypointtype "MOVE";
wp1 setWaypointCombatMode "RED";
wp1 setWaypointFormation "LINE";
wp1 setWaypointSpeed "NORMAL";
wp1 setWaypointBehaviour "AWARE";
wp2 = EastGrp01a addwaypoint [position target, 0];
wp2 setwaypointtype "SAD";
wp2 setWaypointCombatMode "RED";
wp2 setWaypointFormation "LINE";
wp2 setWaypointSpeed "NORMAL";
wp2 setWaypointBehaviour "AWARE";



EastGrp01b = Creategroup EAST;
_leader = EastGrp01b createUnit ["TK_INS_Soldier_TL_EP1", [(getMarkerPos "se1") select 0,(getMarkerPos "se1") select 1,0], [], 3, "FORM"];
_unit = EastGrp01b createUnit ["TK_INS_Soldier_2_EP1", [(getMarkerPos "se1") select 0,(getMarkerPos "se1") select 1,0], [], 3, "FORM"];
_unit = EastGrp01b createUnit ["TK_INS_Soldier_EP1", [(getMarkerPos "se1") select 0,(getMarkerPos "se1") select 1,0], [], 3, "FORM"];
_unit = EastGrp01b createUnit ["TK_INS_Soldier_AT_EP1", [(getMarkerPos "se1") select 0,(getMarkerPos "se1") select 1,0], [], 3, "FORM"];
_unit = EastGrp01b createUnit ["TK_INS_Soldier_AT_EP1", [(getMarkerPos "se1") select 0,(getMarkerPos "se1") select 1,0], [], 3, "FORM"];
_unit = EastGrp01b createUnit ["TK_INS_Soldier_MG_EP1", [(getMarkerPos "se1") select 0,(getMarkerPos "se1") select 1,0], [], 3, "FORM"];
_unit = EastGrp01b createUnit ["TK_INS_Soldier_2_EP1", [(getMarkerPos "se1") select 0,(getMarkerPos "se1") select 1,0], [], 3, "FORM"];
_leader = leader EastGrp01b;
wp1 = EastGrp01b addwaypoint [position wpe1, 0];
wp1 setwaypointtype "MOVE";
wp1 setWaypointCombatMode "RED";
wp1 setWaypointFormation "LINE";
wp1 setWaypointSpeed "NORMAL";
wp1 setWaypointBehaviour "AWARE";
wp2 = EastGrp01b addwaypoint [position target, 0];
wp2 setwaypointtype "SAD";
wp2 setWaypointCombatMode "RED";
wp2 setWaypointFormation "LINE";
wp2 setWaypointSpeed "NORMAL";
wp2 setWaypointBehaviour "AWARE";

I thought EastGrp01a and EastGrp01b was the name of groups, then in a trigger I put !alive EastGrp01b && !alive EastGrp01a with ending condition but it didn't work so I've added in the script EastGrp01b (or a) = group this; still not working.

My question is how to give a name to a spwaned group ? (if it is possible) Just an indication.

Share this post


Link to post
Share on other sites

group will never be alive or not alive, the units in the group on the other hand, will.

trigger:

cond:

({alive _x} count units groupname) < 5

on act:

hint "there are less than 5 units alive in groupname"

Share this post


Link to post
Share on other sites
group will never be alive or not alive, the units in the group on the other hand, will.

ah ok I didn't know that

trigger:

cond:

({alive _x} count units groupname) < 5

oh yes I should think about this hieroglyphe. I have it in a file on my pc, must be hidden somewhere :p

on act:

hint "there are less than 5 units alive in groupname"

Thanks for your help :bounce3:

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
Sign in to follow this  

×