17.01.2016, 13:55
Maybe you guys can help me out?
Код:
./includes/callbacks.pwn(4973) : error 014: invalid statement; not in switch ./includes/callbacks.pwn(4973) : warning 215: expression has no effect ./includes/callbacks.pwn(4973) : error 001: expected token: ";", but found ":" ./includes/callbacks.pwn(4973) : error 029: invalid expression, assumed zero ./includes/callbacks.pwn(4973) : fatal error 107: too many error messages on one line
PHP код:
case CHECKPOINT_DMV:
{
switch(GetPVarInt(playerid, "DriveTest"))
{
case 0:
{
if(GetPVarInt(playerid, "DriveLic") == 1) return SendClientMessage(playerid,COLOR_GREY,"You already have a license.");
if(GetPlayerMoneyEx(playerid) >= 500)
{
GivePlayerMoneyEx(playerid,-500);
GameTextForPlayer(playerid, "~r~-$500.", 5000, 1);
SendClientMessage(playerid,COLOR_LIGHTBLUE,"Head outside to the vehicles and begin your driving test.");
SetPVarInt(playerid, "DriveTest", 1);
}
else SendClientMessage(playerid,COLOR_GREY,"You need $500 to do the test.");
}
case 2: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,2084.9592,-1878.3547,13.1988,5.0);
case 3: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,2085.4121,-1794.3701,13.2646,5.0);
case 4: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,2061.9492,-1749.2493,13.2614,5.0);
case 5: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1981.0918,-1749.8353,13.2578,5.0);
case 6: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1909.6647,-1749.3674,13.2578,5.0);
case 7: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1839.1298,-1749.5602,13.2578,5.0);
case 8: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1824.8691,-1726.7939,13.2578,5.0);
case 9: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1824.5071,-1683.5410,13.2579,5.0);
case 10: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1824.3438,-1641.0778,13.2579,5.0);
case 11: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1833.2657,-1550.5740,13.2541,5.0);
case 12: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1829.5264,-1457.5667,13.2478,5.0);
case 13: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1758.8507,-1440.8928,13.2418,5.0);
case 14: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1692.9579,-1438.1527,13.2586,5.0);
case 15: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1608.6155,-1430.0377,13.2774,5.0);
case 16: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1608.3904,-1372.4042,14.8665,5.0);
case 17: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1609.6169,-1332.5227,17.1635,5.0);
case 18: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1628.3630,-1305.7866,16.5843,5.0);
case 19: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1684.5138,-1305.9886,13.5838,5.0);
case 20: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1744.9943,-1300.3932,13.3428,5.0);
case 21: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1784.3658,-1281.6708,13.3438,5.0);
case 22: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1866.8568,-1262.2316,13.2581,5.0);
case 23: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,2000.2797,-1262.5417,23.6994,5.0);
case 24: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,2065.5117,-1284.9235,23.6953,5.0);
case 25: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,2065.6699,-1359.4589,23.6938,5.0);
case 26: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,2109.7046,-1411.3933,23.7027,5.0);
case 27: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,2110.0352,-1490.2906,23.6909,5.0);
case 28: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,2109.9658,-1599.6238,25.0737,5.0);
case 29: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,2083.6077,-1772.7036,13.2608,5.0);
case 30: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,2057.0925,-1808.8322,13.2577,5.0);
case 31: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1986.9674,-1809.8187,13.2578,5.0);
case 32: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1958.8763,-1827.8669,13.2578,5.0);
case 33: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1959.6487,-1897.9441,13.2578,5.0);
case 34: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,1973.6750,-1934.2632,13.2576,5.0);
case 35: SetPVarInt(playerid, "DriveTest", GetPVarInt(playerid, "DriveTest")+1), SetPlayerCheckpoint(playerid,2055.5962,-1915.2133,13.4219,5.0);
case 36:
{
new Float:health;
GetVehicleHealth(GetPlayerVehicleID(playerid),health);
DisablePlayerCheckpoint(playerid);
if(health <= 500.0) PrintTestResult(playerid, 2, "Vehicle Is Too Damaged");
else if(GetPVarInt(playerid, "TestTime") >= 301) PrintTestResult(playerid, 2, "Too Slow");
else if(GetPVarInt(playerid, "TestTime") <= 90) PrintTestResult(playerid, 2, "Too Fast");
else if(GetPVarFloat(playerid,"TestSpeed") >= 95.0) PrintTestResult(playerid, 2, "Broke Speed Limit");
else
{
PlayAudioStreamForPlayerEx(playerid, "http://rebound-rp.com/r-rp-soundeffects/theme.mp3");
PrintTestResult(playerid, 1, "All Qualifications Correct");
//SetPVarInt(playerid, "DriveLic", 1);
PlayerInfo[playerid][pCarLic] = 1;
}
TogglePlayerAllDynamicCPs(playerid, true);
SetPVarInt(playerid, "Checkpoint", CHECKPOINT_NONE);
SetVehicleToRespawn(GetPlayerVehicleID(playerid));