stock Nome(playerid)
{
new Nome[MAX_PLAYER_NAME];
GetPlayerName(playerid, Nome, sizeof(Nome));
return Nome;
}
public OnPlayerConnect(playerid)
{
if(strfind(Nome, "[", true) || strfind(Nome, "]", true) || strfind(Nome, "_", true))
{
SendClientMessage(playerid, -1, "Seu nick nгo pode contar colchetes ( [ ] ) ou underline ( _ )");
Kick(playerid);
return 1;
}
return 1;
}
Tenta ai garoto
pawn Код:
pawn Код:
|
new Nome[MAX_PLAYER_NAME];
GetPlayerName(playerid, Nome, sizeof(Nome));
for(new i = 0; i < strlen(Nome); i++)
{
if((Nome[i] < 65 || Nome[i] > 90) && (Nome[i] < 97 || Nome[i] > 122) && Nome[i] != 95)
{
SendClientMessage(playerid, 0xFFFFFFFF, "Nгo й permitido TAG nesse servidor. Use Nome_Sobrenome");
Kick(playerid);
}
}
//•~•~•~•~•~•~•~•~•~•~•~•~•~( Equipe_xD )•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~//
// Criado Por Tiger_xD !! Nao Retira os Creditos !!
// Criado Por Tiger_xD !! Nao Retira os Creditos !!
// Criado Por Tiger_xD !! Nao Retira os Creditos !!
//•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~//
//•~•~•~•( include )•~•~•~•~//
#include <a_samp>
//•~•~•~•~( New )•~•~•~•~•~//
#define COLOR_AZUL 0x0019FFFF
#define MSGPLAYER SendClientMessage
//•~•~•~•~•~•~( New )•~•~•~•~•~•~//
new gstring[128];
//•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~//
public OnFilterScriptInit()
{
print("\n(•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~)");
print(" Sistema Criado Por Tiger_xD");
print("(•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~)\n");
return 1;
}
//•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~//
public OnFilterScriptExit()
{
print("\n(•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~)");
print(" Sistema Criado Por Tiger_xD");
print("(•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~)\n");
return 1;
}
//•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~//
public OnPlayerConnect(playerid)
{
if(strfind(PlayerName(playerid), "_", true) == -1 || strfind(PlayerName(playerid), "[", true) != -1 || strfind(PlayerName(playerid), "]", true) != -1 || strfind(PlayerName(playerid), "lixo", true) != -1 || strfind(PlayerName(playerid), "buceta", true) != -1 || strfind(PlayerName(playerid), "caralho", true) != -1 || strfind(PlayerName(playerid), "[", true) != -1 || strfind(PlayerName(playerid), "server", true) != -1
|| strfind(PlayerName(playerid), "servidor", true) != -1 || strfind(PlayerName(playerid), "crash", true) != -1 || strfind(PlayerName(playerid), "bpl", true) != -1 || strfind(PlayerName(playerid), "gamerx", true) != -1 || strfind(PlayerName(playerid), "[", true) != -1 || strfind(PlayerName(playerid), "189", true) != -1 || strfind(PlayerName(playerid), "201", true) != -1 || strfind(PlayerName(playerid), "200", true) != -1 || strfind(PlayerName(playerid), ".", true) != -1
|| strfind(PlayerName(playerid), "*", true) != -1 || strfind(PlayerName(playerid), "(", true) != -1 || strfind(PlayerName(playerid), ")", true) != -1 || strfind(PlayerName(playerid), "@", true) != -1 || strfind(PlayerName(playerid), "amx", true) != -1 || strfind(PlayerName(playerid), "prn", true) != -1 || strfind(PlayerName(playerid), "__", true) != -1)
{
MSGPLAYER(playerid, COLOR_AZUL, "Vocк Foi Kickado por usar algum nome incorreto!");
MSGPLAYER(playerid, COLOR_AZUL, "Seu nome deve ser no formato Nome_Sobrenome");
MSGPLAYER(playerid, COLOR_AZUL, "Troque-o e volte, Obrigado.");
Kick(playerid);
fremove(gstring);
return 1;
}
return 1;
}
//•~•~•~•~•~•~•~•~•~•~•~•~•~•~/
stock PlayerName(playerid)
{
new Name[MAX_PLAYER_NAME];
GetPlayerName(playerid, Name, MAX_PLAYER_NAME);
return Name;
}
//•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~•~//
Paulor o seu codig so funciono para o da [TAG] mais o do nome sem o Underline n funciono ele aparece assim:
ao invez de Aparece q so pode usar nome_sobrenome se poder me ajudar nesse ganha Rep + MAis vlw paulor |
new Nome[MAX_PLAYER_NAME];
GetPlayerName(playerid, Nome, sizeof(Nome));
for(new i = 0; i < strlen(Nome); i++)
{
if((Nome[i] < 65 || Nome[i] > 90) && (Nome[i] < 97 || Nome[i] > 122) || Nome[i] == 95)
{
SendClientMessage(playerid, 0xFFFFFFFF, "Nгo й permitido TAG('[]') e '_' nesse servidor. Use NomeSobrenome");
Kick(playerid);
}
}
new Nome[MAX_PLAYER_NAME];
GetPlayerName(playerid, Nome, sizeof(Nome));
for(new i = 0; i < strlen(Nome); i++)
{
if((Nome[i] < 65 || Nome[i] > 90) && (Nome[i] < 97 || Nome[i] > 122) && Nome[i] != 95)
{
SendClientMessage(playerid, 0xFFFFFFFF, "Nгo й permitido TAG nesse servidor. Use Nome_Sobrenome");
Kick(playerid);
}
}
Entao tava certo o 1°.
pawn Код:
|