[Ajuda] /veiculo vender bugado
#1

O gm que estou usando tem Sistema de concessionaria VIP,Eu vo la,compro meu carro vip,mais nao consigo vender,eu entro no carro e diz,voce tem 2000 de dinheiro no porta luvas /retirargrana mais ai quando eu do /veiculo vender,diz que o carro nao й meu,alguem me ajuda?Nao postei nada porque nao sei oque postar,Peзam para mim postar o comando sei la algo do tipo(eu nao sei oque postar,espero que voces me digam oque postar para voces poderem arrumar,Obrigado)
Reply
#2

se for zcmd tenta esse
pawn Код:
else if(!strcmp(opcao, "vender", true))
    {
        GetPlayerName(playerid, Nome, sizeof(Nome));
        if(PlayerInfo[playerid][pCarKey] == 0)
        {
            SendClientMessage(playerid, COLOR_GREY, "Vocк nгo tem um Veiculo.");
            return 1;
        }
        if(PlayerInfo[playerid][pCarKey] != 0 && strcmp(Nome, CarInfo[PlayerInfo[playerid][pVeiculo]][cOwner], true) == 0)
        {
            new car = PlayerInfo[playerid][pVeiculo];
            CarInfo[car][cOwned] = 0;
            GetPlayerName(playerid, Nome, sizeof(Nome));
            strmid(CarInfo[car][cOwner], "Dealership", 0, strlen("Dealership"), 999);
            GivePlayerMoney(playerid,CarInfo[car][cValue]);
            PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
            format(STR, sizeof(STR), "~w~Voce vendeu seu Veiculo por: ~n~~g~$%d", CarInfo[car][cValue]);
            GameTextForPlayer(playerid, STR, 10000, 3);
            RemovePlayerFromVehicle(playerid);
            TogglePlayerControllable(playerid, 1);
            PlayerInfo[playerid][pCarKey] = 0;
            PlayerInfo[playerid][pVeiculo] = 0;
            SaveCars();
            return 1;
        }
    }
se for strcmp tenta esse
pawn Код:
if(strcmp(tmp, "vender", true) == 0)
        {
            if(IsPlayerConnected(playerid))
            {
                GetPlayerName(playerid, playername, sizeof(playername));
                if(PlayerInfo[playerid][pCarKey] == 0 && PlayerInfo[playerid][pCarKey2] == 0 && PlayerInfo[playerid][pCarKey3] == 0)
                {
                    SendClientMessage(playerid, COLOR_GREY, "Vocк nгo tem um Carro VIP.");
                    return 1;
                }
                if(PlayerInfo[playerid][pCarKey] != vehid && PlayerInfo[playerid][pCarKey2] != vehid && PlayerInfo[playerid][pCarKey3] != vehid)
                {
                    SendClientMessage(playerid, COLOR_GREY, "Esse nгo й seu Carro VIP.");
                    return 1;
                }
                if(PlayerInfo[playerid][pCarKey] != 0 && strcmp(playername, CarInfo[PlayerInfo[playerid][pVeiculo]][cOwner], true) == 0)
                {
                    new rand;
                    new car = PlayerInfo[playerid][pVeiculo];
                    CarInfo[car][cOwned] = 0;
                    CarInfo[car][cModel] = 560;
                    CarInfo[car][cColorOne] = 0;
                    CarInfo[car][cColorTwo] = 0;
                    GetPlayerName(playerid, sendername, sizeof(sendername));
                    strmid(CarInfo[car][cOwner], "Dealership", 0, strlen("Dealership"), 999);
                    GivePlayerMoney(playerid,CarInfo[car][cValue]);
                    PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
                    format(string, sizeof(string), "~w~Carro Vip Vendido Por: ~n~~g~$%d", CarInfo[car][cValue]);
                    GameTextForPlayer(playerid, string, 10000, 3);
                    RemovePlayerFromVehicleEx(playerid);
                    TogglePlayerControllable(playerid, 1);
                    PlayerInfo[playerid][pCarKey] = 0;
                    PlayerInfo[playerid][pVeiculo] = 0;
                    rand = random(sizeof(gRandomCarsSpawns));
                    CarInfo[car][cLocationx] = gRandomCarsSpawns[rand][0];
                    CarInfo[car][cLocationy] = gRandomCarsSpawns[rand][1];
                    CarInfo[car][cLocationz] = gRandomCarsSpawns[rand][2];
                    CarInfo[car][cAngle] = gRandomCarsSpawns[rand][3];
                    SaveCars();
                    return 1;
                }
Reply
#3

Quote:
Originally Posted by JuniorRock
Посмотреть сообщение
O gm que estou usando tem Sistema de concessionaria VIP,Eu vo la,compro meu carro vip,mais nao consigo vender,eu entro no carro e diz,voce tem 2000 de dinheiro no porta luvas /retirargrana mais ai quando eu do /veiculo vender,diz que o carro nao й meu,alguem me ajuda?Nao postei nada porque nao sei oque postar,Peзam para mim postar o comando sei la algo do tipo(eu nao sei oque postar,espero que voces me digam oque postar para voces poderem arrumar,Obrigado)
posta o comando ae
Reply
#4

Quote:
Originally Posted by Copom_policia
Посмотреть сообщение
posta o comando ae
pawn Код:
if(strcmp(tmp, "vender", true) == 0)
        {
            if(IsPlayerConnected(playerid))
            {
                GetPlayerName(playerid, playername, sizeof(playername));
                if(PlayerInfo[playerid][pCarKey] == 0 && PlayerInfo[playerid][pCarKey2] == 0 && PlayerInfo[playerid][pCarKey3] == 0)
                {
                    SendClientMessage(playerid, COLOR_GREY, "Vocк nгo tem um Carro VIP.");
                    return 1;
                }
                if(PlayerInfo[playerid][pCarKey] != vehid && PlayerInfo[playerid][pCarKey2] != vehid && PlayerInfo[playerid][pCarKey3] != vehid)
                {
                    SendClientMessage(playerid, COLOR_GREY, "Esse nгo й seu Carro VIP.");
                    return 1;
                }
                if(PlayerInfo[playerid][pCarKey] != 0 && strcmp(playername, CarInfo[PlayerInfo[playerid][pVeiculo]][cOwner], true) == 0)
                {
                    new rand;
                    new car = PlayerInfo[playerid][pVeiculo];
                    CarInfo[car][cOwned] = 0;
                    CarInfo[car][cModel] = 560;
                    CarInfo[car][cColorOne] = 0;
                    CarInfo[car][cColorTwo] = 0;
                    GetPlayerName(playerid, sendername, sizeof(sendername));
                    strmid(CarInfo[car][cOwner], "Dealership", 0, strlen("Dealership"), 999);
                    GivePlayerMoney(playerid,CarInfo[car][cValue]);
                    PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
                    format(string, sizeof(string), "~w~Carro Vip Vendido Por: ~n~~g~$%d", CarInfo[car][cValue]);
                    GameTextForPlayer(playerid, string, 10000, 3);
                    RemovePlayerFromVehicleEx(playerid);
                    TogglePlayerControllable(playerid, 1);
                    PlayerInfo[playerid][pCarKey] = 0;
                    PlayerInfo[playerid][pVeiculo] = 0;
                    rand = random(sizeof(gRandomCarsSpawns));
                    CarInfo[car][cLocationx] = gRandomCarsSpawns[rand][0];
                    CarInfo[car][cLocationy] = gRandomCarsSpawns[rand][1];
                    CarInfo[car][cLocationz] = gRandomCarsSpawns[rand][2];
                    CarInfo[car][cAngle] = gRandomCarsSpawns[rand][3];
                    SaveCars();
                    return 1;
                }
                else if(PlayerInfo[playerid][pCarKey2] != 0 && strcmp(playername, CarInfo[PlayerInfo[playerid][pVeiculo2]][cOwner], true) == 0)
                {
                    new rand;
                    new car = PlayerInfo[playerid][pVeiculo2];
                    CarInfo[car][cOwned] = 0;
                    CarInfo[car][cModel] = 560;
                    CarInfo[car][cColorOne] = 0;
                    CarInfo[car][cColorTwo] = 0;
                    GetPlayerName(playerid, sendername, sizeof(sendername));
                    strmid(CarInfo[car][cOwner], "Dealership", 0, strlen("Dealership"), 999);
                    GivePlayerMoney(playerid,CarInfo[car][cValue]);
                    PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
                    format(string, sizeof(string), "~w~Carro Vip Vendido Por: ~n~~g~$%d", CarInfo[car][cValue]);
                    GameTextForPlayer(playerid, string, 10000, 3);
                    RemovePlayerFromVehicleEx(playerid);
                    TogglePlayerControllable(playerid, 1);
                    PlayerInfo[playerid][pCarKey2] = 0;
                    PlayerInfo[playerid][pVeiculo2] = 0;
                    rand = random(sizeof(gRandomCarsSpawns));
                    CarInfo[car][cLocationx] = gRandomCarsSpawns[rand][0];
                    CarInfo[car][cLocationy] = gRandomCarsSpawns[rand][1];
                    CarInfo[car][cLocationz] = gRandomCarsSpawns[rand][2];
                    CarInfo[car][cAngle] = gRandomCarsSpawns[rand][3];
                    SaveCars();
                    return 1;
                }
                else if(PlayerInfo[playerid][pCarKey3] != 0 && strcmp(playername, CarInfo[PlayerInfo[playerid][pVeiculo3]][cOwner], true) == 0)
                {
                    new rand;
                    new car = PlayerInfo[playerid][pVeiculo3];
                    CarInfo[car][cOwned] = 0;
                    CarInfo[car][cModel] = 560;
                    CarInfo[car][cColorOne] = 0;
                    CarInfo[car][cColorTwo] = 0;
                    GetPlayerName(playerid, sendername, sizeof(sendername));
                    strmid(CarInfo[car][cOwner], "Dealership", 0, strlen("Dealership"), 999);
                    GivePlayerMoney(playerid,CarInfo[car][cValue]);
                    PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
                    format(string, sizeof(string), "~w~Carro Vip Vendido Por: ~n~~g~$%d", CarInfo[car][cValue]);
                    GameTextForPlayer(playerid, string, 10000, 3);
                    RemovePlayerFromVehicleEx(playerid);
                    TogglePlayerControllable(playerid, 1);
                    PlayerInfo[playerid][pCarKey3] = 0;
                    PlayerInfo[playerid][pVeiculo3] = 0;
                    rand = random(sizeof(gRandomCarsSpawns));
                    CarInfo[car][cLocationx] = gRandomCarsSpawns[rand][0];
                    CarInfo[car][cLocationy] = gRandomCarsSpawns[rand][1];
                    CarInfo[car][cLocationz] = gRandomCarsSpawns[rand][2];
                    CarInfo[car][cAngle] = gRandomCarsSpawns[rand][3];
                    SaveCars();
                    return 1;
                }
            }
            return 1;
        }
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)