05.07.2012, 18:47
Hey there
I'm trying to make a macro, like this one:
But with this kind of code:
But I have no idea how to deal with the variables in maccro, and imagine if I had several variables, like pName(playerid), pName(targetid)...
I tried to make it, and I got this:
Does anyone know how to do that?
Thanks
I'm trying to make a macro, like this one:
pawn Код:
#define SVR_ERR_MSG(%0,%1) SendClientMessage(%0, COLOR_RED, "(Server) >> " %1);
pawn Код:
new string[128];
format(string, sizeof(string), "(Server) >> %s did this...", pName(playerid));
SendClientMessageToAll(COLOR_RED, string);
I tried to make it, and I got this:
pawn Код:
#define SVR_MSG(%0, %1, %2) \
new string[128]; \
format(string, sizeof(string), "(Server) >>" %1); \
SendClientMessage(%0, -1, %1);
Thanks
