OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: Lone~Wolf on 18 Feb 2010, 18:22:27
-
How would I be able to HintC format etc. so that it displayed every unit in an array - or rather, their name in text - and their x and y co-ordinates.
I'm trying to create a system whereby I can determine all the units that have died over the course of the mission and the positions of those still alive.
:dunno:
-
Not entirely sure how to approach your overall problem. But in response to your question, use a script like this. Place a trigger with name triggername, set to anybody present, and run the script with parameters:
[list triggername] exec "hintclist.sqs"
Made with care by RKurtzDmitriyev productions. No animal testing was used. :P
_a = _this select 0
_c = 0
_n = 0
_d = ""
titleText ["Generating list...(this may take a moment)","plain"]
#loop
~0.1
_o = _a select _c
_s = format ["%1 \n %2\n", _o, [getpos _o select 0, getpos _o select 1]]
_d = _d + _s
_c = _c + 1
_n = _n + 1
? _n < 13 && (_c < count _a): goto "loop"
hintC format ["%1", _d]
? _c == count _a : titleText ["done","plain"]; exit
titleText ["Generating next page","plain"]
_d = ""
_n = 0
goto "loop"
-
Sorry to be a while in replying, and thx for the script.
I'm not sure how to use it but I'll figure that out some other time.
Thanks,
Lone-Wolf :cool2: