24.07.2012, 19:27
Hey, I have a small roleplay server running. Sadly, it shows the "_" between the firstname and lastname, how can I remove this so it doesn't get shown in the chatbox?
Search for the sign "_" in the string, then replace it with " ". I found a code for you. pawn Код:
Usage: pawn Код:
pawn Код:
|
RemoveUnderscore(playerid)
{
new szPlayerName[ MAX_PLAYER_NAME ];
GetPlayerName(playerid, szPlayerName, MAX_PLAYER_NAME);
for(new i=0; i < MAX_PLAYER_NAME; ++i)
{
if(szPlayerName[i] == EOS)break;
if(szPlayerName[i] == '_')
szPlayerName[i] = ' ';
}
SetPlayerName(playerid, szPlayerName);
}