Help with code, why do i get these errors?
#1

Hi i am trying to code it so that when the player enters into the checkpoint it first-

checks to see whether he is in a vehicle-if not it deletes the checkpoint.

if he is in vehicle i need to check whether trailer is attached..

Hopefully you can see what i am trying to do by my code.

Код:
public OnPlayerEnterCheckpoint(playerid) {

new vehicleid=GetPlayerVehicleID( playerid );
if (IsPlayerInVehicle(playerid,vehicleid) ) {

if ( IsTrailerAttachedToVehicle(vehicleid) );
 {
SendClientMessage( playerid, 0xAFAFAFAA, " Congratulations!" );
GivePlayerMoney(playerid, 5000);
DisablePlayerCheckpoint(playerid);
}
else {
SendClientMessage( playerid, 0xAFAFAFAA, "You need a trailer." );
}}

else { DisablePlayerCheckpoint(playerid);
}

return 1;
}
i get two errors when i compile this.

: error 029: invalid expression, assumed zero
: error 036: empty statement

Thanks in advance,
josh

Reply


Messages In This Thread
Help with code, why do i get these errors? - by Bofhead - 20.06.2009, 08:39
Re: Help with code, why do i get these errors? - by MenaceX^ - 20.06.2009, 08:44
Re: Help with code, why do i get these errors? - by AiVAMAN - 20.06.2009, 09:10
Re: Help with code, why do i get these errors? - by Yuryfury - 25.06.2009, 15:00

Forum Jump:


Users browsing this thread: 1 Guest(s)