OK, you seem to be looking at the wrong corner of my
suggestion
I think you are talking about my way to add eventhandlers to
units inside the no fire zone.
What i meant for you to use is:
That part, where i'm removing the eventhandlers from every soldier, who leaves the no fire zone.
This is my original code:
Trigger 1: the nofire-zone trigger
size: as big as you want your nofire-zone (e.g: 20/20)
activation: anybody/present/once
name: triggerA
condition: this
Trigger 2: the outer nofire-zone trigger (place it at the same spot, where the nofire-zone trigger is)
size: bigger than the nofire-zone trigger (e.g: 40/40)
activation: anybody/present/once
name: triggerB
condition this
Trigger 3: init-trigger
size: 0/0
activation: none/once
countdown: min: 0.1 / max: 0.1 / mid: 0.1
condition: true
onActivation: updlistA = true
Trigger 4: update nofire-zone trigger
size: 0/0
activation: none/repeatedly
countdown: min: 0.1 / max: 0.1 / mid: 0.1
condition: updlistA
onActivation: "_x addeventhandler [{fired}, {_this select 0 setDammage 0.95}]" forEach list triggerA; updlistB = true; updlistA = false
important note - the countdown is required to get this whole thing to work (strange OFP editor)
Trigger 5: allow fire outer nofire-zone
size: 0/0
activation: none/repeatedly
condition: updlistB
onActivation: nofire = list triggerB - list triggerA; "_x removealleventhandlers {fired}" forEach nofire; updlistB = false; updlistA = true
I'm gonna rewrite that now, so that you will be able to
use it for your mission.
This is the one you need (feel free to compare both for better
understanding what i meant):
Trigger 1: the inner zone trigger - the area where your units have to stay inside
size: as big as you want your nofire-zone (e.g: 500/500)
activation: anybody/present/once
name: triggerA
condition: this
Trigger 2: the outer zone trigger (place it at the same spot, where the inner zone trigger is) - this trigger is required
to create a referback for those units outside the inner trigger
size: bigger than the nofire-zone trigger (e.g: 550/550)
activation: anybody/present/once
name: triggerB
condition this
Trigger 3: init-trigger
size: 0/0
activation: none/once
countdown: min: 0.1 / max: 0.1 / mid: 0.1
condition: true
onActivation: updlistA = true
Trigger 4: timeout 0.1 then repeat the kill outer zone trigger
size: 0/0
activation: none/repeatedly
countdown: min: 0.1 / max: 0.1 / mid: 0.1
condition: updlistA
onActivation: updlistB = true; updlistA = false
important note - the countdown is required to get this whole thing to work (strange OFP editor)
Trigger 5: kill everybody outside the inner zone trigger
size: 0/0
activation: none/repeatedly
countdown: min: 0.1 / max: 0.1 / mid: 0.1
condition: updlistB
onActivation: outerzone = list triggerB - list triggerA; "_x setdammage 1" forEach outerzone; updlistB = false; updlistA = true
btw - still wondering why you are using "setdammage 5",
as with setdammage 1 the unit would have reached it's
highest dammage level => killed.
~S~ CD