[Ajuda] Spawnar - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: Non-English (
https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (
https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (
https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] Spawnar (
/showthread.php?tid=356738)
Spawnar -
GhosT_[] - 04.07.2012
й tipo assim eu tentei fazer que o player nao pudesse spawna se nгo tiver logado ou registrado mas nгo deu certo porque mesmo senгo registrar ou logar o player spawna e aparece a mensagem que tem de registrar/logar antes '-'
Resumindo: nгo quero que o player spawne antes logar/regitrar
cуdigo
Код:
public OnPlayerRequestSpawn(playerid)
{
if(!udb_Exists(PlayerName(playerid)))
{
SendClientMessage(playerid, COLOR_RED, "Seu nick nгo й registrado.Antes spawnar use >> /registrar [senha]");
return true;
}
if(udb_Exists(PlayerName(playerid)))
{
SendClientMessage(playerid, COLOR_RED, "Seu nick й registrado.Antes spawnar use >> /logar [senha]");
return true;
}
return 1;
}
alguem pode me ajudar
Re: Spawnar -
blacktrindade - 04.07.2012
pawn Код:
public OnPlayerRequestSpawn(playerid)
{
if(!udb_Exists(PlayerName(playerid)))
{
SendClientMessage(playerid, COLOR_RED, "Seu nick nгo й registrado.Antes spawnar use >> /registrar [senha]");
return false;
}
if(udb_Exists(PlayerName(playerid)))
{
SendClientMessage(playerid, COLOR_RED, "Seu nick й registrado.Antes spawnar use >> /logar [senha]");
return false;
}
return 1;
}
Re: Spawnar -
Crueliz0n - 04.07.2012
pawn Код:
public OnPlayerRequestSpawn(playerid)
{
if(!udb_Exists(PlayerName(playerid)))
{
SendClientMessage(playerid, COLOR_RED, "Seu nick nгo й registrado.Antes spawnar use >> /registrar [senha]");
return false;
}
if(Logado[playerid] == 0)
{
SendClientMessage(playerid, COLOR_RED, "Seu nick й registrado.Antes spawnar use >> /logar [senha]");
return false;
}
return 1;
}
Re: Spawnar -
ipsBruno - 04.07.2012
pawn Код:
public OnPlayerRequestSpawn(playerid) {
if(!udb_Exists(PlayerName(playerid))) {
return SendClientMessage(playerid, COLOR_RED, "Seu nick nгo й registrado.Antes spawnar use >> /registrar [senha]"), false;
}
if(VARIAVELLOGADO == false) {
return SendClientMessage(playerid, COLOR_RED, "Seu nick й registrado.Antes spawnar use >> /logar [senha]"), false;
return 1;
}
VARIAVELLOGADO deve ser a variбvel ou array que checa se o jogador estб logado
Exemplo:
pLogado[playerid]
GetPVarInt(playerid, "logado")
Re: Spawnar -
GhosT_[] - 05.07.2012
Consegui com o cуdigo do DraKiNs Obrigado

e obrigado ao blacktrindade e ao BlackDonelly que tentaram me ajudar