Removal of underscores
#1

How would I go about doing so? I had a code snippet from a while ago, but I'm a bit rusty and can't re-create it.. and I seem to have lost it.
Reply
#2

pawn Код:
for ( new i, s = strlen( string ); i < s; ++i )
    if ( string[ i ] == '_' )
        string[ i ] = ' ';
Reply
#3

Quote:
Originally Posted by bigcomfycouch
Посмотреть сообщение
pawn Код:
for ( new i, s = strlen( string ); i < s; ++i )
    if ( string[ i ] == '_' )
        string[ i ] = ' ';
And how would I go about using that with things such as GetPlayerName?

pawn Код:
stock pName(playerid)
{
    new Name[MAX_PLAYER_NAME];
    GetPlayerName(playerid, Name, sizeof(Name));
    return Name;
}
I have that, how would I go about modifying it to get rid of the _?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)