19.12.2012, 09:18
Atleast guys, explain what the problem was. By pasting the code into his gamemode, he will never learn what it was wrong in case it happens again..
What are you trying to display is the id of the player which is integer, not string.
You can use the name/ID too, but you need to GetPlayerName first.
pawn Код:
format(string, sizeof string, "[SERVER] %d amount of Money has been Sent to %s", amount, giveplayerid);
format(string, sizeof string, "[SERVER] %d amount of Money has Sent by %s", amount, playerid);
pawn Код:
format(string, sizeof string, "[SERVER] %d amount of Money has been Sent to %d", amount, giveplayerid);
format(string, sizeof string, "[SERVER] %d amount of Money has Sent by %d", amount, playerid);
pawn Код:
new
name[ MAX_PLAYER_NAME ],
gname[ MAX_PLAYER_NAME ]
;
GetPlayerName(playerid, name, sizeof(name));
GetPlayerName(giveplayerid, gname, sizeof(gname));
format(string, sizeof string, "[SERVER] %d amount of Money has been Sent to %s(%d)", amount, gname, giveplayerid);
format(string, sizeof string, "[SERVER] %d amount of Money has Sent by %s(%d)", amount, name, playerid);