Jump to content

looping plans


S7EVEN
 Share

Recommended Posts

I'm trying to get and entire platoon to execute a single plan, but every time I run it in-game only one of the four teams does it.. :( I know I could use "execute plan team" four times, but I intend to use far more then four teams in the future, so I really need to work this whole looping business.

here's the script:

Group: <Default>

Comment:

Trigger Event:

5 second(s) elapsed.

Responses:

Use Attack Group. to loop over all teams in Attacking Platoon after this block.

Group: Attack Group.

Comment:

Trigger Event:

A team loop is ready to process Attack Team Ref.

Responses:

Allow this block to be reactivated.

Assign Attack square plan to Attack Team Ref and execute.

I know I'm close, but I'm definitely missing something..

Thanks in advance.

Link to comment
Share on other sites

In my experience, a plan can't be assigned to more than one team, so if it's already being run by one team and you assign it to another that won't work...

There are more technically proficient scripters around who might know better, though, as I never really learned the looping business.

Link to comment
Share on other sites

I use this type of loop all the time with no issues at all. Regardless of how many teams it has to loop. There must be something in your script that is preventing it from working. If you like, open script and go to summary and copy paste it into a PM, I`ll have a look at it.

What you have posted is the same as what I script, so that bit is correct. Do the teams already have a plan? If so add this to the script:

Trigger Event:

A team loop is ready to process Attack Team Ref.

Responses:

Allow this block to be reactivated.

Cancel any plans assigned to Attack Team Ref

Assign Attack square plan to Attack Team Ref and execute.

Link to comment
Share on other sites

I have used the same plan for multiple teams without issue in the past. But I do not recall ever having so many teams that needed to execute a single plan that I felt it was worth resorting to a loop to do it....

Tinker's point about being sure you have canceled any plan the team may have had is important, You also need to be sure that the first step in the triggered plan is in fact something that all of the teams will be able to find/execute.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...