Personal Best 0 Posted May 30, 2021 I made a little script to check the player's uniform, following other topics I found and the script wiki. For some reason, it doesn't work properly. _khokholUniform = ["LOP_U_UKR_Fatigue_Digit","LOP_U_UKR_Fatigue_TanMTP","LOP_U_UKR_Fatigue_DPMW_DPMD","LOP_U_UKR_Fatigue_IzlomTTsKO","LOP_U_UKR_Fatigue_TTsKO"]; if ((uniform GeorgeCluny) in _khokholUniform) then { systemChat "Success"; } else { systemChat "Failure"; }; it spits out both systemChat messages at once and also outputs an error saying '|#|else' Error Undefined variable in expression: else whatever the player is wearing. I'm not very experienced in scripting. Any help would be appreciated Share this post Link to post Share on other sites
sarogahtyp 1109 Posted May 30, 2021 For me all looks good. U should check ur code for invisible characters. Maybe there is such nearby the else. Invisible chars are a common problem when copying code out of forums. You can use a software which is able to show invisible chars like some office applications. Maybe notepad++ has an option for it as well. 1 Share this post Link to post Share on other sites
Personal Best 0 Posted May 30, 2021 6 minutes ago, sarogahtyp said: For me all looks good. U should check ur code for invisible characters. Maybe there is such nearby the else. Invisible chars are a common problem when copying code out of forums. You can use a software which is able to show invisible chars like some office applications. Maybe notepad++ has an option for it as well. I actually already solved my problem. I restructured my code a little bit. Now it looks like this: _khokholUniform = ["LOP_U_UKR_Fatigue_Digit","LOP_U_UKR_Fatigue_TanMTP","LOP_U_UKR_Fatigue_DPMW_DPMD","LOP_U_UKR_Fatigue_IzlomTTsKO","LOP_U_UKR_Fatigue_TTsKO"]; if ((uniform GeorgeCluny) in _khokholUniform) then [{systemChat "Success";}, {systemChat "Failure";}]; Works like a charm. Thank you for the response. 1 Share this post Link to post Share on other sites