[pomoc]default checkpoint

Započeo BloOm3R!, Mart 26, 2011, 10:27:24 PRE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Skripta koju koristim:GF
Detaljan opis problema:Zanima me kako mogu napravit default checkpoint npr. ako je jedan kod burga jedan kod policije a stavljeni su u modu prvi po redu kod policije a drugi kod burga kako da napravim sad da jedanput bude kod burga jedanput kod policije a ne da bude prvi koji je stavljen prvi...
Dio skripte:
Neke slike/video za lakse dobivanje pomoci(neobavezno):
Poslednja Izmena: Mart 26, 2011, 10:27:39 PRE PODNE od Bloomer


nista nisam skonto u ovom  :D

evo npr ovu komandu kako da bude default da stavlja cpove
Citatif(strcmp(cmd, "/kosenje", true) == 0)
   {
       if(IsPlayerConnected(playerid))
       {
         if(PlayerInfo[playerid][pJob] == 6)
          {
               if(Kosilica(idcar))
               {
                if(KosacPosao[playerid] == 0)
                {
                   KosacPosao[playerid] = 1;
                   SetPlayerCheckpoint(playerid, 2033.7037,-1206.8521,21.8814,5.0);
                  CP[playerid] = 50;
                  TogglePlayerControllable(playerid,1);
                }
                else
                {
                   SendClientMessage(playerid, COLOR_CRVENA, "[ERROR]: Vec si zapoceo sa poslom.");
                }
               }
               else
               {
                   SendClientMessage(playerid, COLOR_CRVENA, "[ERROR]: Morate biti u kosilici.");
               }
         }
      }
   }

Ti mislis da stavi tva ili vise cp-a uporedo za jednog igraca? Ako je tako onda nemoze jer je limit 1

evo objasnit cu malo bolje


kad igrac kuca /kosenje dobija cp koji ja imam obicno stavljen prvi po redu...imam ih sve ukupno 10 jedan za drugim al ja sad ocu kad kuca /kosenje pocne jedanput od 5. pa jedanput od 8. i tako da nebude uvjek prvi na istom mjestu...i ostali,kao na ch za zastitara

Hahhahaahahahahahahhahahahahhaha/.../hahahhahahah


To nije default vec random?


Daj nam CPove koje oces da ti budu tako rand... Post nemogu ovako da ti pomognem

evo cpove
CitatAddStaticVehicle(572,2033.7037,-1206.8521,21.8814,217.1922,12,12); // checkpoint 1
AddStaticVehicle(572,1919.9739,-1228.7462,17.8331,23.9585,12,12); // checkpoint 2
AddStaticVehicle(572,1901.3993,-1151.9857,23.9549,11.7308,12,12); // checkpoint 3
AddStaticVehicle(572,1947.4020,-1151.2452,21.3389,268.7188,12,12); // checkpoint 4
AddStaticVehicle(572,2036.5687,-1148.8398,23.6194,264.9325,12,12); // checkpoint 5
AddStaticVehicle(572,2009.4231,-1242.7227,22.2411,125.1993,12,12); // checkpoint 6
AddStaticVehicle(572,1955.5325,-1230.7494,19.3771,41.7452,12,12); // checkpoint 7
AddStaticVehicle(572,2005.0786,-1167.2902,20.4908,42.4414,12,12); // checkpoint 8
AddStaticVehicle(572,2038.0942,-1246.6910,23.0711,202.5446,12,12); // checkpoint 9
AddStaticVehicle(572,1928.0767,-1213.4518,19.4805,25.5960,12,12); // checkpoint 10
AddStaticVehicle(572,1866.7335,-1241.8611,14.0371,211.5599,12,12); // checkpoint 11
AddStaticVehicle(572,1951.8098,-1170.8796,19.9412,336.3219,12,12); // checkpoint 12
AddStaticVehicle(572,2030.3759,-1161.3545,21.8133,255.7265,12,12); // checkpoint 13
AddStaticVehicle(572,2020.5845,-1233.4797,21.5185,119.0852,12,12); // checkpoint 14
AddStaticVehicle(572,1995.5323,-1171.7660,20.0226,46.3683,12,12); // checkpoint 15

CitatTo nije default vec random?
:D kako god...


Evo ja ti imam ovako u modu


new Float:gSweeperPoints[16][3] = {
{2003.3517,-1730.5336,13.1080},//tu stavis ove svoje CP!
{2243.8682,-1895.1603,13.1057},
{2872.5264,-1507.8936,10.5887},
{2733.4851,-1079.1128,69.0215},
{2491.6882,-1096.9484,48.1798},
{1973.2815,-1173.0474,25.6866},
{1441.3285,-1038.8422,23.4461},
{1041.5815,-776.1030,104.3925},
{958.6799,-1034.2134,29.8119},
{995.9623,-1351.8215,13.0737},
{793.3896,-1583.4993,13.1155},
{368.1902,-1977.2362,7.3970},
{834.1572,-1794.8837,13.5680},
{1243.4885,-1853.9174,13.1080},
{1527.9438,-1663.3240,13.1080},
{2083.6062,-1843.3563,13.1080}
};



Komanda

if(!strcmp(cmdtext, "/Pocnicistiti", true)) // malo izmenis jer je ovo za cistenje
    {
if(IsPlayerConnected(playerid))
{
    if(PlayerInfo[playerid][pJob] != 21)
    {
        SendClientMessage(playerid, COLOR_GREY, "   Nisi cistac ! ");
        return 1;
    }
    if(PlayerIsSweeping[playerid] == 1)
    {
        SendClientMessage(playerid, COLOR_GREY, "   Vec radis ! ");
        return 1;
    }
    if(IsASweeper(idcar))
    {
        PlayerIsSweeping[playerid] = 1;
        TogglePlayerControllable(playerid, 1);
        new randomize;
        randomize = random(sizeof(gSweeperPoints));
        SetPlayerCheckpoint(playerid, gSweeperPoints[randomize][0], gSweeperPoints[randomize][1], gSweeperPoints[randomize][2], 5.0);
        SendClientMessage(playerid, COLOR_WHITE, "Idi do checkpointa");
new y, m, d;
new h,mi,s;
getdate(y,m,d);
gettime(h,mi,s);
format(string,sizeof(string), "(%d/%d/%d)[%d:%d:%d] %s [CMD] -> /Pocnicistiti",d,m,y,h,mi,s,sendername);
CommandLog(string);
    }
}
return 1;
    }



I sad kod OnPlayerEnterCheckpoint

if(PlayerIsSweeping[playerid] == 1)//Isto izmjenis...
{
    if(IsPlayerInAnyVehicle(playerid))
    {
        new carid = GetPlayerVehicleID(playerid);
        if(IsASweeper(carid))
        {
            new cashes=(random(35-10)+10);
            PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0);
            format(string, sizeof(string), "~g~%d$ ~w~Dodano na placu",cashes);
            GameTextForPlayer(playerid, string, 5000, 1);
            DisablePlayerCheckpoint(playerid);
            PlayerInfo[playerid][pPayCheck] += cashes * 5;
            new randomss;
        randomss = random(sizeof(gSweeperPoints));
        SetPlayerCheckpoint(playerid, gSweeperPoints[randomss][0], gSweeperPoints[randomss][1], gSweeperPoints[randomss][2], 5.0);
        }
    }
    return 1;
}



Evo ak sam ti pomogao :D Nisam objasnjavao al mislim da znas..
/