ID Beside name on chat.
#1

I was currently using this:

pawn Код:
public OnPlayerText(playerid,text[])
{
  new pname[MAX_PLAYER_NAME+5];
  new pname2[MAX_PLAYER_NAME+5];
  GetPlayerName(playerid,pname,sizeof(pname));
  format(pname2,sizeof(pname2),"%s[%d]",pname,playerid);
  SetPlayerName(playerid,pname2);
  SendPlayerMessageToAll(playerid,text);
  SetPlayerName(playerid,pname);
  return 0;
}
Which made your name like this

[SU]BP13[1]: Hello Jim


But in the server log its a nightmare to do anything because it appears as this:

[00:00:05] [chat] [[SU]BP13]: Hello Jim
[00:00:05] [nick] [SU]BP13 nick changed to [SU]BP13[1]
[00:00:05] [nick] [SU]BP13[1] nick changed to [SU]BP13

Every time a word was sent on the chatbox. Is there a way that you can make name changes not show up on the log or make it so it shows like this (Last Resort)

[SU]BP13:[1] Hello Jim.

Thanks for the help.
Reply
#2

I don't think so. You could make your own server log I guess that wouldn't log this.
Reply
#3

pawn Код:
public OnPlayerText(playerid, text[])
{
new string[128];
format(string,sizeof(string),(%d): %s",playerid, text);
SendPlayerMessageToAll(playerid,string);
return 0;
}
Prints in my logs like this:

Код:
[13:59:55] [chat] [[EP]Awaran]: hey whats up
Reply
#4

Wow, this is cool.

Helped me too.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)