Doesnt seem to be working for me. It is an .sqs file.
#Loop
trigeast = createTrigger ["EmptyDetector", position DetectLoRgt ]
trigeast setTriggerActivation ["EAST", "PRESENT", false]
trigeast setTriggerArea [500, 700, 0, true ]
trigeast setTriggerType "switch"
trigeast setTriggerStatements ["this", "", ""]
trigger setTriggerTimeout [0, 0, 0, false ]
~1
_vehListB = list trigeast
east_troops = []
{{if (alive _x) then {east_troops = east_troops + [_x]}} forEach crew _x} forEach _vehListB
~1
hint format ["East soldiers still alive:\nEast: %1",{alive _x} count east_troops]
~1
;Here the trigger you just created is deleted, so less lag!
deletevehicle trigeast
~1
if _x > "0" then goto "Loop" else 0 objstatus DONE; obj0_done=true;deletemarker objeast