29.01.2013, 13:50
PHP код:
if(CCP[playerid] == 1)
{
new vehicleid = GetPlayerVehicleID(playerid);
if(IsATestCar(vehicleid))
{
new Float:health;
GetVehicleHealth(vehicleid, health);
if(health > 950.0)
{
DisablePlayerCheckpoint(playerid);
CCP[playerid] = 2;
SetPlayerCheckpoint(playerid, 1429.81,-1732.20,13.38, 10.0);
}
else
{
SendClientMessage(playerid, COLOR_LIGHTBLUE,"Driver Instructor says: The car is to damaged!");
SendClientMessage(playerid, COLOR_LIGHTBLUE,"Driver Instructor says: You didn't passed the test, please try again!");
DisablePlayerCheckpoint(playerid);
RemovePlayerFromVehicle(playerid);
SetVehicleToRespawn(vehicleid);
PlayerInfo[playerid][pTakingLesson] = 0;
}
}
else
{
SendClientMessage(playerid, COLOR_LIGHTBLUE,"Driver Instructor says: You are not in a car!");
SendClientMessage(playerid, COLOR_LIGHTBLUE,"Driver Instructor says: You didn't pass the test, please try again!");
DisablePlayerCheckpoint(playerid);
RemovePlayerFromVehicle(playerid);
SetVehicleToRespawn(vehicleid);
PlayerInfo[playerid][pTakingLesson] = 0;
}
}
else if(CCP[playerid] == 2)
{
DisablePlayerCheckpoint(playerid);
CCP[playerid] = 3;
SetPlayerCheckpoint(playerid, 1820.42,-1732.44,13.38, 10.0);
}
after that if I going to another check point every time is doing me this meesage "Driver Instructor says: The car is to damaged!"
Sorry for my bad english.