Gentlemen,
With your help I have got this far. Rather than attaching a mission, I will summarise the salient points because it explains things more clearly.
+++++++++++++++++++++++
init.sqs
=====
loonsAlive = 1
mission
=====
a group named sn with 5 members
exit.sqs
======
loonsAlive = count units sn
saveVar "loonsAlive"
exit
outro
====
a loon named loon1
Trigger hint format ["alive %1", loonsAlive]
Trigger:
condition: loonsAlive > 3
on activation: deleteVehicle loon1
++++++++++++++++++++++++
You must initialise the variable in init.sqs (or possibly elsewhere) otherwise it doesn't work at all.
When you test the Outro in the Mission Editor Loon1 appears and immediately vanishes. Bingo! (You can't use loonsAlive > 3 in his condition of presence field, it doesn't work.)
However, when you export the mission and try it from Single Missions, it doesn't work. The loon appears and stays appeared, and the hint gives you gobbledygook because it thinks the variable doesn't exist.
Any ideas? Have I missed something stupid?
Many thanks.