OFPEC Forum

Editors Depot - Mission Editing and Scripting => Arma2 - Editing/Scripting General => Topic started by: urias03 on 05 Jan 2010, 17:27:42

Title: 2 questions-IED and confiriming a kill
Post by: urias03 on 05 Jan 2010, 17:27:42
Hey all I'm currently making a mission in ARMA 2 and need some help:
1.how can I make IED?
2.I want the mission to be over only after the enemy is dead so I want that the player will have to confirm the kill and only after all the enemies are dead the mission will be over

Title: Re: 2 questions-IED and confiriming a kill
Post by: JasonO on 05 Jan 2010, 18:53:57
A basic ID could involve a trigger. Simply place a trigger over the area of how it can be triggered (covering a road etc) and then put the code below in the activation field. Any unit that wonders in would get a nasty blast.

change obj1 at the end to an object at the side of the road. If you want it to be invisible you can use a game logic object and name it obj1.

Code: [Select]
ied1 = "Bo_GBU12_LGB" createvehicle getpos obj1
You will also need to set the activation to whichever side you want to be able to trigger it.

You can change the "Bo_GBU12_LGB" part to a smaller explosion if you wish. Visit this list (http://www.ofpec.com/COMREF/index.php?action=read&id=210) and look at the 'Ammo Classname' column. Play around with the artillery, grenades etc to get your desired effect.

For your second part you can use another trigger. Make it cover the whole area where the enemy might go. Set it activation to the enemy side and click the box saying 'not present'. When there is 0 enemy left in this trigger you can have it end. Do this by using the following code in the activation field.

Code: [Select]
hint "Mission Complete!"; endMission "END1";
Good Luck! :good:
Title: Re: 2 questions-IED and confiriming a kill
Post by: urias03 on 07 Jan 2010, 21:54:10
great thanks :P