20.09.2015, 04:31
You could also, for a little memory optimization(I think), get rid of "string2" and put
right where you use the string2
example:
Its a little better (In my option) as it takes less space and doesn't use that "little" heap size, but if you're using the value twice I think using a string will be better, as you don't have to get the value twice..
pawn Код:
(GetPVarInt(id, string)) ? ("{33FF33}Completed") : ("{FF3333}Not Completed")
example:
pawn Код:
//instead of
new string[x];
string = (GetPVarInt(id, string)) ? ("{33FF33}Completed") : ("{FF3333}Not Completed");
SendClientMessage(playerid, -1, string);
//do
SendClientMessage(playerid, -1, (GetPVarInt(id, string)) ? ("{33FF33}Completed") : ("{FF3333}Not Completed"));