Peršokti į turinį

Checkpoint taskai


Recommended Posts

   if(checkpointid == bmx[1] == 1) //This checks what checkpoint it is before it continues
    {
        if(IsPlayerInAnyVehicle(playerid))
        {
                if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
                {
                        SetVehiclePos(GetPlayerVehicleID(playerid), 914.6419,-1416.6122,12.7083);
                        SetCameraBehindPlayer(playerid);
                        GameTextForPlayer(playerid, "+100xp", 4000, 5); //It will show this if a player steps in the checkpoint
                        GivePlayerScore( playerid, 100 );
                        DestroyDynamicCP(bmx[1]);
                        bmx[playerid] = 2;
                        bmx[2] = CreateDynamicCP(972.4807,-1380.8164,21.1588, 2, 50, -1, -1, 100);
                }
                else
                {
                        SendClientMessage(playerid,-1, "ERROR: Jus turite sedeti masinoje");
                }
        }
        else
        {
                SetPlayerPos(playerid, 914.6419,-1416.6122,12.7083);
                SetPlayerFacingAngle(playerid, 110.5445);
                SetCameraBehindPlayer(playerid);
        }
        return 1;
    }
    else if(checkpointid == bmx[2] == 1) //This checks what checkpoint it is before it continues
    {
        if(IsPlayerInAnyVehicle(playerid))
        {
                if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
                {
                        GameTextForPlayer(playerid, "Iveikete gavote +150xp", 4000, 5); //It will show this if a player steps in the checkpoint
                        DestroyDynamicCP(bmx[2]);
                        GivePlayerScore( playerid, 150 );
                        bmx[3] = CreateDynamicCP(972.4807,-1380.8164,21.1588, 2, 50, -1, -1, 100);
                        SetVehiclePos(GetPlayerVehicleID(playerid), 914.6419,-1416.6122,12.7083);
                        SetCameraBehindPlayer(playerid);
                }
                else
                {
                        SendClientMessage(playerid,-1, "ERROR: Jus turite sedeti masinoje");
                }
        }
        else
        {
                SetPlayerPos(playerid, 914.6419,-1416.6122,12.7083);
                SetPlayerFacingAngle(playerid, 110.5445);
                SetCameraBehindPlayer(playerid);
        }
        return 1;
    }
 array must be indexed (variable "bmx")

Dar buna, kad nukelia i antra zona na atsako i pirma cp ir sukuria nauja cp 2 uzvaziavus ant antro cp antras cp atsako i pirmo veiksma duoda 100xp ir nutelina vel "vaziuoti" link antro cp kame b─Śda?

Nuoroda ─» komentar─ů
Dalintis per kit─ů puslap─»

klaid┼│ neb─Śra, bet v─Ślgi tas pats u┼żva┼żiuoji ant pirmo cp gauni 100xp nutelina ir sukuria antra cp u┼żva┼żiuodamas ant 2cp tur─Śtum gauti 150xp, bet visgi viska duoda i┼í 1cp 100xp.

Nuoroda ─» komentar─ů
Dalintis per kit─ů puslap─»

Prisijungti prie diskusijos

Palikti atsakym─ů galite i┼í karto, o u┼żsiregistruoti v─Śliau. Jeigu jau turite paskyr─ů m┼źs┼│ forume, Prisijunkite.

Sve─Źias
Atsakyti šioje temoje...

×   ─«klijuotas tekstas turi teksto formatavim─ů.   Pa┼íalinti teksto formatavim─ů

  Galimi tik 75 veidukai.

×   Nuoroda buvo automati┼íkai ─»terpta.   ─«terpti nuorod─ů paprastai

×   J┼źs┼│ ankstesnis prane┼íimas buvo atkurtas.   I┼ívalyti redaktori┼│

×   J┼źs negalite ─»kelti nuotraukas tiesiogiai.─«kelkite arba ─»d─Śkite nuotraukas i┼í URL.

  • ┼áiame puslapyje nar┼ío:   0 nariai

    • N─Śra registruot┼│ nari┼│ per┼żi┼źrin─Źi┼│ ┼í─» forum─ů.

├Ś
├Ś
  • Sukurti nauj─ů...