Casio91Fin 31 Posted October 21, 2021 How could I make this work? _AI_Leader = New_AI_Group createUnit [JalkavakiJohtajat select floor (random count JalkavakiJohtajat), _AI_Spawn_Pos, [], 0, "NONE"];if (_AI_Leader == "I_officer_F") then {_AI_Leader setRank "LIEUTENANT"; [_AI_Leader, "LIEUTENANT"] call BIS_fnc_setUnitInsignia;}; else they are. _AI_Leader setRank "SERGEANT"; [_AI_Leader, "SERGEANT"] call BIS_fnc_setUnitInsignia; Share this post Link to post Share on other sites
pierremgi 4739 Posted October 22, 2021 _AI_Leader is an object (unit), "I_officer_F" is a class of unit. You can't compare them by equal term. if (_AI_Leader isKindOf "I_Officer_F") then .... "LIEUTENANT" or "SERGEANT" are not insignia but rank. see: https://community.bistudio.com/wiki/Arma_3:_Unit_Insignia 1 Share this post Link to post Share on other sites
Casio91Fin 31 Posted October 22, 2021 i figured out what was the problem if (typeOf _AI_Leader == "I_officer_F") then {_AI_Leader setRank "LIEUTENANT"; [_AI_Leader, "LIEUTENANT"] call BIS_fnc_setUnitInsignia;} else {_AI_Leader setRank "SERGEANT"; [_AI_Leader, "SERGEANT"] call BIS_fnc_setUnitInsignia;}; 1 Share this post Link to post Share on other sites