Replace '_' with ' '
#1

What is a quick and simple function to replace underscore with a space?
Reply
#2

pawn Код:
ReturnPlayerName(playerid, no_underscore = 1)
{
    new name[MAX_PLAYER_NAME];
    GetPlayerName(playerid, name, sizeof(name));
    if(no_underscore) for(new z = 0; z < MAX_PLAYER_NAME; z++) if(name[z] == '_') name[z] = ' ';
    return name;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)