ID Doesnt show - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: ID Doesnt show (
/showthread.php?tid=654786)
ID Doesnt show -
MrNasa - 06.06.2018
When recieving a pm , /ask , whisper etc... The player's ID doesn't show up beside his name , what was the function for it ?
Re: ID Doesnt show -
andrejc999 - 06.06.2018
Do you mean that the message doesn't get formatted the right way?
When you're formatting a message and you want to insert a playerid in it, use %u.
Btw I found a bug, when you try to put %u in > [] ([%u]) it doesn't format it the right way and if this happens to you try using %i instead of %u.
Re: ID Doesnt show -
GTLS - 06.06.2018
use,
PHP код:
format(pmstr, sizeof(pmstr), "[PM From %s[%d]] %s",PlayerName, playerid, params);
You have to use "%d" modifier and playerid to display the player's ID