Good tutorial, you just forgot to mention that ternary operator supports multiple conditions.
For example:
And btw, you don't need brackets, just own preference.
EDIT: You need brackets if you aren't using the community compiler, found out a few days ago..
For example:
PHP Code:
SendClientMessage(playerid, -1, playerData[playerid][pAdmin] == 1 ? "Admin lvl 1" : playerData[playerid][pAdmin] == 2 ? "Admin lvl 2" : playerData[playerid][pAdmin] == 3 ? "Admin lvl 3" : "Admin lvl 4");
And btw, you don't need brackets, just own preference.
EDIT: You need brackets if you aren't using the community compiler, found out a few days ago..