Checkpoint help
#1

pawn Код:
public OnPlayerEnterCheckpoint(playerid)
{
    new playervehicleid = GetPlayerVehicleID(playerid);

    if(gObjectiveReached) return;
    if(playervehicleid == OBJECTIVE_VEHICLE_BLUE && gTeam[playerid] == TEAM_BLUE)
    {   // Blue OBJECTIVE REACHED.
        {
            GameTextForAll("~w~Head back to the ~r~Naval Ship",3000,5);
            DisablePlayerCheckpoint(playerid);
            SetPlayerCheckpoint(playerid,-1389.5182,492.2472,3.0391,5.0);
        }
        else if(playervehicleid == OBJECTIVE_VEHICLE_BLUE && gTeam[playerid] == TEAM_BLUE)
        {   // Blue OBJECTIVE REACHED 2.
            {
                GameTextForAll("~w~Get out of the truck, The truck is set to ~n~explode in ~r~15 seconds",3000,5);
                DisablePlayerCheckpoint(playerid);
            }
        }
        return;
    }
}
However, this isn't correct. Whenever the first checkpoint is called, the second one isn't.
Also, I want to know what function to use to create an explosion after the second checkpoint is called.
I still have my rustiness, sorry.
Reply


Messages In This Thread
Checkpoint help - by HydraX - 17.06.2011, 15:27
AW: Checkpoint help - by Nero_3D - 17.06.2011, 15:33
Re: Checkpoint help - by HydraX - 17.06.2011, 15:37
AW: Checkpoint help - by Nero_3D - 17.06.2011, 16:02
Re: Checkpoint help - by HydraX - 17.06.2011, 16:06
Re: Checkpoint help - by HydraX - 17.06.2011, 16:25

Forum Jump:


Users browsing this thread: 5 Guest(s)