pawn Код:
if (strcmp("/fixv", cmdtext, true, 10) == 0)
{
new VehicleID = GetPlayerVehicleID(playerid);
new money = GetPlayerMoney(playerid); // check the money
if(money > 9999) // check if the player has more than 10000
{
RepairVehicle(VehicleID); // repair already sets the car hp to 1000, not needed to set it apart.
GivePlayerMoney(playerid, - 10000);
}
return 1;
}
You must make a money check, you can always check the wiki first....