Car Sale
#1

Is there any command that can sell all the vehlices
Reply
#2

i think no
Reply
#3

Sure, but you'd have to create it. You just have to put the 'sold' variable to 'not sold' in every car.
Reply
#4

can you create it for me pls
Reply
#5

That will be impossible without any information about the way you have set up your system.
Reply
#6

Something like this:

pawn Код:
new carsold[MAX_VEHICLES];
Command:

pawn Код:
CMD:sellvehicle(playerid[])
{
    if(carsold[vehicleid] == 1) return SendClientMessage(playerid,0xFF0000FF,"You have already sold this car.");
    SendClientMessage(playerid,orange,"***Car Sold!***");
    GivePlayerMoney(playerid,5000);
    return 1;
}
But i don't think it's correct,i just gave you an example.You have to get the vehicle id of the driver and put the variable carsold on 1 when you sold the car,and 0 when the car isn't sold.

Remember to reset the variable when a player disconnect or at least put a timer.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)