Greetings,
@GetDammage _unit>= 1.0;
~0.2
ok = createDialog "alliesmenu"
If this is the whole script, it wouldn't work, as you haven't told OFP what "_unit" is. Also you have a semicolon on the end of the first line, which is not required.
Here's a possible correction:
; die.sqs
_unit = _this select 0
#loop
?damage _unit >= 1: goto "dialog"
~0.2
goto "loop"
#dialog
OK = createDialog "alliesmenu"
exit
exec: [this] exec "die.sqs"
When the unit respawns, you will have to re execute the script, or it will only work once.
a dialog comes up so ONLY he can see it,
I assume you're talking about multiplayer here?
If so, I don't know how much I can help you. However, here's a few thoughts:
AFAIK, any scripts executed on the client side that don't run also on the server, will only affect that client. So, if you ran the dialog only on the client (no publicVariables), only that person will see it. Obviously, this can be done (look at MFCTI - that is filled with dialogs that are seen by only one person at a time).
My experience is outside MP scripting, so I am of limited use here. But you could DEPBO MFCTI, (or some other MP mission which uses dialogs) and see how it was done there.
-Supreme Commander PsyWarrior
-Psychic Productions Studios