AJUDA - Aceitar convite
#1

Eu queria que quando convidar um player б entrar em uma org ele digitasse Aceitar convite antes de aceitar
No meu jб aceita automaticamente e eu nгo sei tirar :/

meu /convidar :
pawn Код:
if(strcmp(cmd, "/convidar", true) == 0)
    {
        if(IsPlayerConnected(playerid))
        {
            tmp = strtok(cmdtext, idx);
            if(!strlen(tmp))
            {
                SendClientMessage(playerid, COLOR_GRAD2, "USE: /convidar [ id ]");
                return 1;
            }
            new para1;
            new ftext[20];
            para1 = ReturnUser(tmp);
            if (PlayerInfo[playerid][pLider] >= 1)
            {
                if(IsPlayerConnected(para1))
                {
                    if(PlayerInfo[para1][pNivel] < 1) { SendClientMessage(playerid, COLOR_GREY, "So pode convidar quem й nivel 1 ou acima de 1!!!"); return 1;
                    }
                    if(para1 != INVALID_PLAYER_ID)
                        {
                            if (PlayerInfo[para1][pMembro] == 0 && PlayerInfo[para1][pFMember] == 255)
                            {
                            if(PlayerInfo[playerid][pLider] == 1) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "Policia Militar"; ChosenSkin[para1] = 282; SetPlayerSkin(para1, 282); }
                            else if(PlayerInfo[playerid][pLider] == 2) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "B.O.P.E"; ChosenSkin[para1] = 285; SetPlayerSkin(para1, 285); }
                            else if(PlayerInfo[playerid][pLider] == 3) { PlayerInfo[para1][pTeam] = 3; gTeam[para1] = 3; ftext = "Exйrcito"; ChosenSkin[para1] = 287; SetPlayerSkin(para1, 287); }
                            else if(PlayerInfo[playerid][pLider] == 4) { PlayerInfo[para1][pTeam] = 1; gTeam[para1] = 1; ftext = "Firemen/Ambulance"; ChosenSkin[para1] = 70; SetPlayerSkin(para1, 70); }
                            else if(PlayerInfo[playerid][pLider] == 5) { PlayerInfo[para1][pTeam] = 5; gTeam[para1] = 5; ftext = "-BluerBur-"; ChosenSkin[para1] = 115; SetPlayerSkin(para1, 115); }
                            else if(PlayerInfo[playerid][pLider] == 6) { PlayerInfo[para1][pTeam] = 5; gTeam[para1] = 5; ftext = "(--"; ChosenSkin[para1] = 121; SetPlayerSkin(para1, 121); }
                            else if(PlayerInfo[playerid][pLider] == 7) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "Prefeitura"; ChosenSkin[para1] = 163; SetPlayerSkin(para1, 163); }
                            else if(PlayerInfo[playerid][pLider] == 8) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 12; ftext = "Hitman Agency"; ChosenSkin[para1] = 127; SetPlayerSkin(para1, 127); }
                            else if(PlayerInfo[playerid][pLider] == 9) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 12; ftext = "Rede Globo"; ChosenSkin[para1] = 148; SetPlayerSkin(para1, 148); }
                            else if(PlayerInfo[playerid][pLider] == 10) { PlayerInfo[para1][pTeam] = 20; gTeam[para1] = 20; ftext = "Vazio"; ChosenSkin[para1] = 255; SetPlayerSkin(para1, 61); }
                            else if(PlayerInfo[playerid][pLider] == 11) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 12; ftext = "School Instructors"; ChosenSkin[para1] = 59; SetPlayerSkin(para1, 59); }
                            else if(PlayerInfo[playerid][pLider] == 12) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "Bombeiros"; ChosenSkin[para1] = 278; SetPlayerSkin(para1, 278); }
                            else if(PlayerInfo[playerid][pLider] == 13) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 2; ftext = "Mongols MC"; ChosenSkin[para1] = 255; SetPlayerSkin(para1, 61); }
                            else if(PlayerInfo[playerid][pLider] == 14) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 2; ftext = "Transnacional"; ChosenSkin[para1] = 255; SetPlayerSkin(para1, 61); }
                            else if(PlayerInfo[playerid][pLider] == 15) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 12; ftext = "Groove Street"; ChosenSkin[para1] = 105; SetPlayerSkin(para1, 105); }
                            else if(PlayerInfo[playerid][pLider] == 16) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 12; ftext = "AS-FARC"; ChosenSkin[para1] = 30; SetPlayerSkin(para1, 30); }
                            else if(PlayerInfo[playerid][pLider] == 17) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "Policia Civil"; ChosenSkin[para1] = 141; SetPlayerSkin(para1, 141); }
                            else if(PlayerInfo[playerid][pLider] == 18) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 12; ftext = "K.I.N.G Ballas"; ChosenSkin[para1] = 103; SetPlayerSkin(para1, 103); }
                            else if(PlayerInfo[playerid][pLider] == 19) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 12; ftext = "Los A.D.A Ki'ngs"; ChosenSkin[para1] = 109; SetPlayerSkin(para1, 109); }
                            else if(PlayerInfo[playerid][pLider] == 20) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 20; ftext = "Mafia Yakuza"; ChosenSkin[para1] = 169; SetPlayerSkin(para1, 169); }
                            else if(PlayerInfo[playerid][pLider] == 21) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 21; ftext = "Comando Vermelho"; ChosenSkin[para1] = 219; SetPlayerSkin(para1, 219); }
                            else if(PlayerInfo[playerid][pLider] == 22) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 22; ftext = "Mбfia La Hermandad"; ChosenSkin[para1] = 111; SetPlayerSkin(para1, 111); }
                            else if(PlayerInfo[playerid][pLider] == 23) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 23; ftext = "G-MOB"; ChosenSkin[para1] = 24; SetPlayerSkin(para1, 24); }
                            else if(PlayerInfo[playerid][pLider] == 24) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 24; ftext = "Drifters"; ChosenSkin[para1] = 28; SetPlayerSkin(para1, 28); }
                            else if(PlayerInfo[playerid][pLider] == 25) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "Policia Federal"; ChosenSkin[para1] = 287; SetPlayerSkin(para1, 287); }
                            else if(PlayerInfo[playerid][pLider] == 26) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 25; ftext = "TransTaxi"; ChosenSkin[para1] = 255; SetPlayerSkin(para1, 61); }
                            else if(PlayerInfo[playerid][pLider] == 27) { PlayerInfo[para1][pTeam] = 12; gTeam[para1] = 25; ftext = "SBT"; ChosenSkin[para1] = 148; SetPlayerSkin(para1, 148); }
                            else if(PlayerInfo[playerid][pLider] == 28) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "Policia Rodoviaria"; ChosenSkin[para1] = 148; SetPlayerSkin(para1, 148); }
                            else if(PlayerInfo[playerid][pLider] == 29) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 25; ftext = "C.T.P"; ChosenSkin[para1] = 148; SetPlayerSkin(para1, 148); }
                            else if(PlayerInfo[playerid][pLider] == 30) { PlayerInfo[para1][pTeam] = 2; gTeam[para1] = 2; ftext = "Governo Federal"; ChosenSkin[para1] = 148; SetPlayerSkin(para1, 148); }
                            else { return 1; }
                            GetPlayerName(para1, giveplayer, sizeof(giveplayer));
                            GetPlayerName(playerid, sendername, sizeof(sendername));
                            PlayerInfo[para1][pMembro] = PlayerInfo[playerid][pLider];
                            PlayerInfo[para1][pCargo] = 1;
                            printf("(AdminCmd) - %s convidou %s para entrar %s.", sendername, giveplayer, ftext);
                            format(string, sizeof(string), "Voce foi convidado para a %s, pelo Lнder %s", ftext, sendername);
                            SendClientMessage(para1, COLOR_LIGHTBLUE, string);
                            format(string, sizeof(string), "Voce convidou %s para a %s.", giveplayer,ftext);
                            SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                            SetPlayerInterior(para1,0);
                            PlayerInfo[playerid][pCarLic] = 1;
                            PlayerInfo[playerid][pFlyLic] = 1;
                            PlayerInfo[playerid][pBoatLic] = 1;
                            PlayerInfo[playerid][pFishLic] = 1;
                            PlayerInfo[playerid][pGunLic] = 1;
                            new rand = random(sizeof(gInviteSpawns));
                            SetPlayerPos(para1, gInviteSpawns[rand][0], gInviteSpawns[rand][1], gInviteSpawns[rand][2]); // Warp the player
                            SetPlayerFacingAngle(para1, gInviteSpawns[rand][3]);
                            SetPlayerCameraPos(para1,gInviteSpawns[rand][0] + 3, gInviteSpawns[rand][1], gInviteSpawns[rand][2]);
                            SetPlayerCameraLookAt(para1,gInviteSpawns[rand][0], gInviteSpawns[rand][1], gInviteSpawns[rand][2]);
                            TogglePlayerControllable(para1, 0);
                            SelectChar[para1] = 255;
                            SelectCharID[para1] = PlayerInfo[para1][pMembro];
                            SelectCharPlace[para1] = 1;
                            PlayerInfo[para1][pModel] = ChosenSkin[para1];
                            PlayerInfo[para1][pChar] = ChosenSkin[para1];
                            SendClientMessage(para1, COLOR_LIGHTRED, "* Use 'Proximo' para trocar a skin.");
                            SendClientMessage(para1, COLOR_LIGHTRED, "* Quando voce achar a Skin preferida, Digite 'Confirma'.");
                            }
                                else
                            {
                            SendClientMessage(playerid, COLOR_GREY, "Este player ou e Procura / Tem Emprego ou / Familia");
                            return 1;
                        }
                    }
                }
            }
            else
            {
                SendClientMessage(playerid, COLOR_GRAD1, "   Voce nao esta autorizado para usar este cmd ( Apenas Lideres )!");
            }
        }
        return 1;
    }
Reply
#2

Alguem ajuda ? ;x
Reply
#3

Double Post Owned ._.
Usa o Search
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)