OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: Ilkka on 09 Jan 2003, 20:19:32
-
How can i make objective to be completed when player have taken three explosives from ammocrate? And how to make objective to be completed when three targets are destroyed?
-
I donÂ't know the first one but the other one is simple. Name the tagets you want the player to destroy, then simply put:
NOT(alive unitname)
in a condition field, then use the obj_status command to make him complete the misison.
-
Well... i'm not too sure about the ammo crate... you'll have to count the amount of ammo that is in it at the start and then set up some sort of condition via a trigger that when the ammo is below a certain amount the trigger goes off :)
For the targets being destroyed.. here is what I would do...
make sure the targets are named..... then make yourself a trigger and throw this in the condition field...
(target1 getdammage > .9) and (target2 getdammage > .9) and (target3 getdammage > .9)
now.. when all three targets are damaged more than 90% the trigger will go off... and whatever you place in the init field ( the bit about objectives completed ;) ) will occur
-
How can i put multiple names to NOT(alive) command. I canm put only one.
-
To see if the player has 3 satchel charges, just count how many he has, there should be something on that in the editors depot.
To use several ?(NOT (alive name)) use the &&.
?(NOT (alive Unit1)) && (NOT (alive Unit2)) && (NOT (alive Unit3))