Jump to content

Recommended Posts



i am doing a mission where the task will be to eliminate all hostile forces within a certain area.  Then it is completed with mission end when all red are dead.


Whats the cleanest way to do it in the editor?


I have been able to do it, but the task is buggy and can’t be selected.  Can you explain what needs linked to what?  Trigger, tasks, markers and players etc.





Share this post

Link to post
Share on other sites

@Gary Loughran

First Welcome to Bis forums!

Second, JohnKalo has a good suggestion but what you ask isn't hard to do,

heres a little tutorial:


How to create an Area task which will end the

mission completed when all enemy are dead


Step 1: Area Trigger

1. Create a trigger - Trigger size should encompass the entire area the enemy is in, can be round or square up to you.


2. Name the trigger - In the variable name box (top of the trigger) put a name there, lets name it E1


3. Trigger Activation 





(put the faction side here so if red (opfor), green (independent), Blue - (Bluefor)


Activation Type 

Not present


4. Trigger expression


this (this is default so leave as is)


On activation

E1unitsdead = true;


Step 2: Task

5. Go to F5 Systems, then to intel


6. Place a Create Task module on the map next to the area of the operation


7. Edit the create task module:

- Go to where it says:                System specific - System: Create Task

- Owner  - (player faction)

- Task id - obj1

- Title - give it a name, so lets name it:     Clear the area

- Description - The enemy occupies this area move in and clear them out, leave no survivors (as an example put what you want).

- State - (this is the task boxes, the first square on the left will say Task created should be surrounded in green)

- Task type - (just an icon you can use to identify the type of task, so up to you).

Click ok to save and close.


8. Place two Set task state modules

- Edit one of them and set it to Assigned

- Edit the other one and set it to Succeeded

Press ok to save and close.


9. Sync the modules to the trigger

- Next your going to Right click on the  Set task state modules, and connect them (sync to) the Create task module.


10. Sync the Set task State Succeeded module to the trigger you created that encompasses the area where the enemy is at.


Step 3: Trigger

11. Place a trigger (no size)




On activation:

[ ] call bis_fnc_endmission;


Note: Dont copy and paste from the forum here, just type the codes in.



When you start the mission, if you go to your map you will

see the task there with the description. Hope this helps.

If you need a sample mission let me know i have one.


  • Like 5

Share this post

Link to post
Share on other sites

Excellent guys thanks!  Nearly 1000hrs logged into game and getting back into it after a break!  Sandbox with capital S!

  • Like 4

Share this post

Link to post
Share on other sites

All the task script info is here.

This topic has an interesting use of tasks,

You could make a trigger with condition,

East countSide thislist == 0 && endTRIG==1

Whenever you want the trigger to start checking for remaining EAST set the variable "endTRIG" to 1-- in case you don't want the trigger to start from the beginning of the scenario. Remember to put


in the init file so it is defined. Also in the init,

[true,["task1"],["Clear the Area","Hostiles","enemy"],enemyMARK,1,3,True] call BIS_fnc_taskCreate;
["task1","assigned"] call BIS_fnc_taskSetState;

 "enemyMark" is the object (marker) where you want the task to appear. Finally, in the On Activation field of the trigger,

endMission "END1";

You can see working examples, here

Have Fun!

  • Like 3

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