[Ajuda] OnPlayerConnect
#10

Quote:
Originally Posted by GHLEMES
Посмотреть сообщение
PT passei o PlayerConnect mas o q quero arrumar й isso

pawn Код:
new string[128], Nome_Player[24];
    GetPlayerName(playerid, Nome_Player, 24);
    format(string, 128, "%s [ID:%d] {00FF00}conectou-se {CCCCCC}ao Auto Mais Caminhoneiro!", Nome_Player, playerid);
    SendClientMessageToAll(-1, string);
    if(APlayerData[playerid][PlayerLevel] > 0)
    {
        format(string, sizeof(string), "{ff7c00}O Administrador {FFFFFF}%s{ff7c00} (ID: {FFFFFF}%i{ff7c00}){00FF00} Entrou{D7D7D7} no Servidor.", Nome_Player, playerid);
        SendClientMessageToAll(0xFF0000FF, string);
        SendClientMessage(playerid, -1, "{FF0000}~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
        SendClientMessage(playerid, -1, "");
        SendClientMessage(playerid, -1, "                  Brasil Auto Mais Caminhoneiro             ");
        SendClientMessage(playerid, -1, "");
        SendClientMessage(playerid, -1, "{FF0000}~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
        SendClientMessage(playerid, 0xFF0000FF, "-  {a9c4e4}Administrador: {FF0000}Sim");
        new DName[MAX_PLAYER_NAME], Don[50];
        GetPlayerName(playerid,DName,sizeof(DName));
        format(Don,sizeof(Don),"~y~%s ~r~ON",DName);
        return 0;
    }
    if(APlayerData[playerid][PlayerName])
    {
        format(string, sizeof(string), "{ff7c00}O Jogador {FFFFFF}%s{ff7c00} (ID: {FFFFFF}%i{ff7c00}) Entrou no Servidor.", Nome_Player, playerid);
        SendClientMessageToAll(0xFF0000FF, string);
        SendClientMessage(playerid, -1, "{FF0000}~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
        SendClientMessage(playerid, -1, "");
        SendClientMessage(playerid, -1, "                  Brasil Auto Mais Caminhoneiro             ");
        SendClientMessage(playerid, -1, "");
        SendClientMessage(playerid, -1, "{FF0000}~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
        SendClientMessage(playerid, 0xFF0000FF, "-  {a9c4e4}Administrador: {FF0000}Nгo");
        SendClientMessage(playerid, 0xFF0000FF, "-  {a9c4e4}Player VIP: {FF0000}Nгo");
        return 0;
    }
    if (IsPlayerVIP(playerid))
    {
        format(string, sizeof(string), "{D7D7D7}O Jogador Vip {00FFFF}%s{D7D7D7} (ID: {00FFFF}%i{D7D7D7}){00FF00} Entrou{D7D7D7} no Servidor.", Nome_Player, playerid);
        SendClientMessageToAll(0xFF0000FF, string);
        SendClientMessage(playerid, -1, "{FF0000}~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
        SendClientMessage(playerid, -1, "");
        SendClientMessage(playerid, -1, "                  Brasil Auto Mais Caminhoneiro             ");
        SendClientMessage(playerid, -1, "");
        SendClientMessage(playerid, -1, "{FF0000}~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
        SendClientMessage(playerid, 0xFF0000FF, "-  {a9c4e4}Administrador: {FF0000}Nгo");
        new DName[MAX_PLAYER_NAME];
        GetPlayerName(playerid,DName,sizeof(DName));
        SendClientMessage(playerid, 0xFF0000FF, "-  {a9c4e4}Player VIP: {FF0000}Sim");
        return 0;
    }
Todos estгo dando certo, menos o do VIP, quando o VIP entra nгo aparece

VIP=
pawn Код:
if (IsPlayerVIP(playerid))
    {
        format(string, sizeof(string), "{D7D7D7}O Jogador Vip {00FFFF}%s{D7D7D7} (ID: {00FFFF}%i{D7D7D7}){00FF00} Entrou{D7D7D7} no Servidor.", Nome_Player, playerid);
        SendClientMessageToAll(0xFF0000FF, string);
        SendClientMessage(playerid, -1, "{FF0000}~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
        SendClientMessage(playerid, -1, "");
        SendClientMessage(playerid, -1, "                  Brasil Auto Mais Caminhoneiro             ");
        SendClientMessage(playerid, -1, "");
        SendClientMessage(playerid, -1, "{FF0000}~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
        SendClientMessage(playerid, 0xFF0000FF, "-  {a9c4e4}Administrador: {FF0000}Nгo");
        new DName[MAX_PLAYER_NAME];
        GetPlayerName(playerid,DName,sizeof(DName));
        SendClientMessage(playerid, 0xFF0000FF, "-  {a9c4e4}Player VIP: {FF0000}Sim");
        return 0;
    }
ta resumi isso tudo nisto:

pawn Код:
new string[128], Nome_Player[24];
    GetPlayerName(playerid, Nome_Player, 24);
    format(string, 128, "%s [ID:%d] {00FF00}conectou-se {CCCCCC}ao Auto Mais Caminhoneiro!", Nome_Player, playerid);
    SendClientMessageToAll(-1, string);
   
    if(APlayerData[playerid][PlayerLevel] > 0)
        format(string, sizeof(string), "{ff7c00}O Administrador {FFFFFF}%s{ff7c00} (ID: {FFFFFF}%i{ff7c00}){00FF00} Entrou{D7D7D7} no Servidor.", Nome_Player, playerid);
    else
        format(string, sizeof(string), "{ff7c00}O Jogador {FFFFFF}%s{ff7c00} (ID: {FFFFFF}%i{ff7c00}) Entrou no Servidor.", Nome_Player, playerid);
    SendClientMessageToAll(0xFF0000FF, string);
   
    SendClientMessage(playerid, -1, "{FF0000}~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
    SendClientMessage(playerid, -1, "");
    SendClientMessage(playerid, -1, "                  Brasil Auto Mais Caminhoneiro             ");
    SendClientMessage(playerid, -1, "");
    SendClientMessage(playerid, -1, "{FF0000}~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
   
    format(string, sizeof(string), "-  {a9c4e4}Administrador: %s", APlayerData[playerid][PlayerLevel] > 0 ? ("{FF0000}Sim") : ("{FF0000}Nгo"));
    SendClientMessage(playerid, 0xFF0000FF, string);
    format(string, sizeof(string), "-  {a9c4e4}Player VIP: %s", IsPlayerVIP(playerid) ? ("{FF0000}Sim") : ("{FF0000}Nгo"));
    SendClientMessage(playerid, 0xFF0000FF, string);
   
    if(IsPlayerVIP(playerid))
    {
        format(string, sizeof(string), "{D7D7D7}O Jogador Vip {00FFFF}%s{D7D7D7} (ID: {00FFFF}%i{D7D7D7}){00FF00} Entrou{D7D7D7} no Servidor.", Nome_Player, playerid);
        SendClientMessageToAll(0xFF0000FF, string);
    }
teste
Reply


Messages In This Thread
OnPlayerConnect - by GHLEMES - 13.06.2014, 20:37
Re: OnPlayerConnect - by Dolby - 13.06.2014, 21:00
Re: OnPlayerConnect - by Cor3y - 13.06.2014, 21:01
Re: OnPlayerConnect - by GHLEMES - 13.06.2014, 21:13
Re: OnPlayerConnect - by Dolby - 13.06.2014, 21:19
Re: OnPlayerConnect - by GHLEMES - 14.06.2014, 01:10
Re: OnPlayerConnect - by PT - 14.06.2014, 12:52
Re: OnPlayerConnect - by GHLEMES - 14.06.2014, 18:45
Re: OnPlayerConnect - by GHLEMES - 14.06.2014, 21:44
Re: OnPlayerConnect - by PT - 14.06.2014, 22:32

Forum Jump:


Users browsing this thread: 1 Guest(s)