_objlist = _this select 0
_i = 0
#loop
_obj = _objlist select _i
?("tank" counttype [_obj] > 0) : hint "_obj is a tank";exit
_i = _i + 1
~0.5
?_i < count _objlist : goto "loop"
This little script checks all objects in the _objlist and when it's a tank, a hint is shown and the script exit.
How can I count empty vehicles with the counttype command?
I tried this :
...
?(("tank" counttype [_obj] > 0) && (count crew _obj == 0)) : hint "_obj is an empty tank";exit
...
Nope. :-\
It doesn't count an empty tank as a tank in the first place!
Anybody a solution for this?