SA-MP Forums Archive
Question? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Question? (/showthread.php?tid=261844)



Question? - GeonMake - 15.06.2011

As I do not accept the numbers and the name? I understand that this place but after?
pawn Код:
stock roleplayName(playerid) {
    if(!IsPlayerConnected(playerid)) return 1;
    new name[24]; GetPlayerName(playerid,name,24);
    for(new i = 0; i < strlen(name); i++)
    if(name[i] != '1')
    if(name[i] != '2')
    if(name[i] != '3')
    if(name[i] != '4')
    if(name[i] != '5')
    if(name[i] != '6')
    if(name[i] != '7')
    if(name[i] != '8')
    if(name[i] != '9')
    if(name[i] != '0')
    if(name[i] != '!')
    if(name[i] != '@')
    if(name[i] != '#')
    if(name[i] != '$')
    if(name[i] != '%')
    if(name[i] != '^')
    if(name[i] != '&')
    if(name[i] != '*')
    if(name[i] != '(')
    if(name[i] != ')')
    if(name[i] != '[')
    if(name[i] != ']')
    if(name[i] != '{')
    if(name[i] != '}')
    if(name[i] != ';')
    if(name[i] != ':')
    if(name[i] != '<')
    if(name[i] != '>')
    if(name[i] != '?')
    if(name[i] != '/')
    if(name[i] != '|')
    return 1;
    SendClientMessage(playerid, COLOR_YELLOW,"Please change your name to an RP name and then log back in.");
    SendClientMessage(playerid, COLOR_YELLOW,"If you have any questions you can visit EnGame.com");
    SendClientMessage(playerid, COLOR_YELLOW,"and find more information there.");
    if(!IsPlayerNPC(playerid))
    {
        Kick(playerid);
    }
    return 1;
}