addicted 1 Posted December 4, 2013 Hello I'm stuck. What need I to write in code to get number of players which play on crewman class on west side? "crewman class" I mean "b_crew_f". Regards Share this post Link to post Share on other sites
iceman77 14 Posted December 4, 2013 _crewmanCount_Blufor = {alive _x && typeOf _x == "b_crew_f"} count allUnits; player sideChat format ["%1", _crewmanCount_Blufor]; You can do a side check too, if you've blufor units joining opfor or resistance sides for example. Else, I would expect simply checking for the blufor crewman type (above) would be enough to return the count of crewman on the blufor side. _crewmanCount_Blufor = {alive _x && side _x == blufor && typeOf _x == "b_crew_f"} count allUnits; player sideChat format ["%1", _crewmanCount_Blufor]; Share this post Link to post Share on other sites
addicted 1 Posted December 4, 2013 (edited) Big thanks for so quick answear. I tried for 3hours now I will try it :) Edit. I used it because i needed all players dead or alive _crewmanCount_Blufor = {typeOf _x == "b_crew_f"} count allUnits; player sideChat format ["%1", _crewmanCount_Blufor]; But if I need all players should I use this? _crewmanCount_Blufor = {isPlayer _x && typeOf _x == "b_crew_f"} count allUnits; player sideChat format ["%1", _crewmanCount_Blufor]; On my computer it works. Thanks so much. Edited December 4, 2013 by addIcted Share this post Link to post Share on other sites
iceman77 14 Posted December 4, 2013 Ahh yes, isPlayer check is helpful for checking if units are players :). Especially if there are AI crewman on the map aswell. Else you wouldn't even need to check for players, if players only are going to be the crewman type. Share this post Link to post Share on other sites