WHY???
#1

Why the heck can't I get the first character of a player name when they connect?

pawn Код:
public OnPlayerConnect(playerid)
{
    new name[MAX_PLAYER_NAME+1];
    GetPlayerName(playerid,name,sizeof(name));
    printf("Name0: %s", name[0]);
    printf("Name1: %s", name[1]);
    if(name[0] == 0 || name[0] == 1 || name[0] == 2 || name[0] == 3 || name[0] == 4 || name[0] == 5 || name[0] == 6 || name[0] == 7 || name[0] == 8 || name[1] == 9)
    {
        SendClientMessage(playerid, 0xFF5E81FF, "The first character of your name cannot be a number");
        SetTimerEx("InitiateKick", 500, false, "i", playerid);
    }
return 1;
}
Код:
[23:41:25] [join] 1SlonCHL has joined the server (0:192.168.1.2)
[23:41:25] Name0: 1SlonCHL 
[23:41:25] Name1: SlonCHL
name[0] = 1SlonCHL, name[1] = SlonCHL, WTF
Reply


Messages In This Thread
WHY??? - by SlonCHL - 27.11.2013, 14:47
Re: WHY??? - by Konstantinos - 27.11.2013, 14:55
Re: WHY??? - by SlonCHL - 27.11.2013, 14:58
Re: WHY??? - by Konstantinos - 27.11.2013, 15:01
Re: WHY??? - by SlonCHL - 27.11.2013, 15:05
Re: WHY??? - by SlonCHL - 26.12.2013, 14:45

Forum Jump:


Users browsing this thread: 2 Guest(s)