[Pomoc] CP za posao

Započeo Brabus, Septembar 09, 2011, 23:59:44 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Skripta koju koristim: GodFather
Detaljan opis problema: Stvori se prvi CP i kad prodjem kroz njega ne stvara mi se drugi i taj prvi ostane na istom mjestu.
Dio skripte:
if(IsASweeper(tmpcar))
         {
             if(PlayerInfo[playerid][pSweepTime] == 0)
              {
               if(IsSweeping[playerid] == 0)
               {
                  SendClientMessage(playerid, COLOR_LIGHTBLUE, "Zapoceo si ciscenje grada,prati crveni checkpoint i auticem operi SF.");
                  SetPlayerCheckpoint(playerid,-2798.2200,1292.3821,5.2432, 5.0);
                  IsSweeping[playerid] = 1;
               }
               else
               {
                     SendClientMessage(playerid, COLOR_LIGHTRED, "Vec imas aktivirano ciscenje grada!");
               }
            }
            else
            {
                SendClientMessage(playerid, COLOR_LIGHTRED, "Ulica je cista! Pricekaj neko vrijeme da opet pocnes s radom!");
            }
         }
         else
         {
            SendClientMessage(playerid, COLOR_LIGHTRED, "Nisi u auticu za ciscenje grada.");
            return 1;
         }
      }
      return 1;
   }


if(IsSweeping[playerid]>0)
       {
          new tmpcar2 = GetPlayerVehicleID(playerid);
          if(IsASweeper(tmpcar2))
          {
             if(IsSweeping[playerid]==1)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2866.4756,1219.0432,5.1957,5.0);
                IsSweeping[playerid] = 2;
             }
             else if(IsSweeping[playerid]==2)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2883.1003,1076.0865,30.4857,5.0);
                IsSweeping[playerid] = 3;
             }
             else if(IsSweeping[playerid]==3)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2826.5110,922.2037,43.6314,8.0);
                IsSweeping[playerid] = 4;
             }
             else if(IsSweeping[playerid]==4)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2863.1445,734.0028,29.5695,8.0);
                IsSweeping[playerid] = 5;
             }
             else if(IsSweeping[playerid]==5)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2839.1450,521.9155,4.5592,8.0);
                IsSweeping[playerid] = 6;
             }
             else if(IsSweeping[playerid]==6)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2835.2617,463.7046,4.0117,8.0);
                IsSweeping[playerid] = 7;
             }
             else if(IsSweeping[playerid]==7)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2709.4812,455.1877,3.9048, 8.0);
                IsSweeping[playerid] = 8;
             }
             else if(IsSweeping[playerid]==8)
             {
                DisablePlayerCheckpoint(playerid);
                IsSweeping[playerid] = 9;
                SetPlayerCheckpoint(playerid, -2689.5435,414.1230,3.8691, 5.0);
             }
             else if(IsSweeping[playerid]==9)
             {



Neke slike/video za lakse dobivanje pomoci(neobavezno):

daj
callback
OnPlayerEnterCheckpoint
da vidim sta tamo imas

public OnPlayerEnterCheckpoint(playerid)
{
new string[128];
new name[MAX_PLAYER_NAME];
if(TaxiCallTime[playerid] > 0 && TaxiAccepted[playerid] < 999)
{
    TaxiAccepted[playerid] = 999;
GameTextForPlayer(playerid, "~w~Reached destination", 5000, 1);
TaxiCallTime[playerid] = 0;
DisablePlayerCheckpoint(playerid);
}
else if(BusCallTime[playerid] > 0 && BusAccepted[playerid] < 999)
{
    BusAccepted[playerid] = 999;
GameTextForPlayer(playerid, "~w~Reached destination", 5000, 1);
BusCallTime[playerid] = 0;
DisablePlayerCheckpoint(playerid);
}
else if(CP[playerid]==1)
{
    if(IsPlayerInAnyVehicle(playerid))
    {
    PlayerInfo[playerid][pJackSkill] ++;
if(PlayerInfo[playerid][pJackSkill] == 50)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Car Jack Skill is now Level 2, you will earn more Money and quicker Reload Time."); }
else if(PlayerInfo[playerid][pJackSkill] == 100)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Car Jack Skill is now Level 3, you will earn more Money and quicker Reload Time."); }
else if(PlayerInfo[playerid][pJackSkill] == 200)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Car Jack Skill is now Level 4, you will earn more Money and quicker Reload Time."); }
else if(PlayerInfo[playerid][pJackSkill] == 400)
{ SendClientMessage(playerid, COLOR_YELLOW, "* Your Car Jack Skill is now Level 5, you will earn more Money and quicker Reload Time."); }
new level = PlayerInfo[playerid][pJackSkill];
if(level >= 0 && level <= 50)
{
    new rand = random(sizeof(SELLCAR1));
    format(string, sizeof(string), "You sold a car for $%d, your reload time is 20 minutes.", SELLCAR1[rand]);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
GivePlayerMoney(playerid, SELLCAR1[rand]);
    PlayerInfo[playerid][pCarTime] = 1200;
}
else if(level >= 51 && level <= 100)
{
    new rand = random(sizeof(SELLCAR2));
    format(string, sizeof(string), "You sold a car for $%d, your reload time is 18 minutes.", SELLCAR2[rand]);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
GivePlayerMoney(playerid, SELLCAR2[rand]);
    PlayerInfo[playerid][pCarTime] = 1080;
}
else if(level >= 101 && level <= 200)
{
    new rand = random(sizeof(SELLCAR3));
    format(string, sizeof(string), "You sold a car for $%d, your reload time is 16 minutes.", SELLCAR3[rand]);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
GivePlayerMoney(playerid, SELLCAR3[rand]);
    PlayerInfo[playerid][pCarTime] = 960;
}
else if(level >= 201 && level <= 400)
{
    new rand = random(sizeof(SELLCAR4));
    format(string, sizeof(string), "You sold a car for $%d, your reload time is 14 minutes.", SELLCAR4[rand]);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
GivePlayerMoney(playerid, SELLCAR4[rand]);
    PlayerInfo[playerid][pCarTime] = 840;
}
else if(level >= 401)
{
    new money = 6000;
    format(string, sizeof(string), "You sold a car for $%d, your reload time is 12 minutes.", money);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
GivePlayerMoney(playerid, money);
    PlayerInfo[playerid][pCarTime] = 720;
}
GameTextForPlayer(playerid, "~y~Sold the car", 2500, 1);
CP[playerid] = 0;
    DisablePlayerCheckpoint(playerid);
    SetVehicleToRespawn(GetPlayerVehicleID(playerid));
}
else
{
    GameTextForPlayer(playerid, "Not in a car", 5000, 1);
}
}
else if(CP[playerid] == 5)
{
    GameTextForPlayer(playerid, "~y~At the Missions Checkpoint", 2500, 1);
CP[playerid] = 0;
    DisablePlayerCheckpoint(playerid);
}
else if(CP[playerid] == 9)//Karting
{
GameTextForPlayer(playerid, "~r~Wait here for more Kart Racers", 4000, 3);
DisablePlayerCheckpoint(playerid);
}
else if(CP[playerid] == 10) { CP[playerid] = 11; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,2258.7874,-2402.9712,12.7035,8.0); }
else if(CP[playerid] == 11) { CP[playerid] = 12; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,2225.8755,-2461.3875,12.7190,8.0); }
else if(CP[playerid] == 12) { CP[playerid] = 13; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,2276.9983,-2662.8328,12.8580,8.0); }
else if(CP[playerid] == 13) { CP[playerid] = 14; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,2449.1399,-2663.0562,12.8138,8.0); }
else if(CP[playerid] == 14) { CP[playerid] = 15; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,2566.9814,-2504.5686,12.7692,8.0); }
else if(CP[playerid] == 15) { CP[playerid] = 16; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,2719.0520,-2503.5962,12.7706,8.0); }
else if(CP[playerid] == 16) { CP[playerid] = 17; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,2720.7881,-2405.6589,12.7441,8.0); }
else if(CP[playerid] == 17) { CP[playerid] = 18; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,2571.5195,-2401.1531,12.7528,8.0); }
else if(CP[playerid] == 18) { CP[playerid] = 19; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,2406.6995,-2423.1182,12.6641,8.0); }
else if(CP[playerid] == 19) { CP[playerid] = 20; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,2322.9194,-2341.5715,12.6664,8.0); }
else if(CP[playerid] == 20)//End of Karting
{
if(IsSweeping[playerid]>0)
       {
          new tmpcar2 = GetPlayerVehicleID(playerid);
          if(IsASweeper(tmpcar2))
          {
             if(IsSweeping[playerid]==1)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2866.4756,1219.0432,5.1957,5.0);
                IsSweeping[playerid] = 2;
             }
             else if(IsSweeping[playerid]==2)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2883.1003,1076.0865,30.4857,5.0);
                IsSweeping[playerid] = 3;
             }
             else if(IsSweeping[playerid]==3)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2826.5110,922.2037,43.6314,8.0);
                IsSweeping[playerid] = 4;
             }
             else if(IsSweeping[playerid]==4)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2863.1445,734.0028,29.5695,8.0);
                IsSweeping[playerid] = 5;
             }
             else if(IsSweeping[playerid]==5)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2839.1450,521.9155,4.5592,8.0);
                IsSweeping[playerid] = 6;
             }
             else if(IsSweeping[playerid]==6)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2835.2617,463.7046,4.0117,8.0);
                IsSweeping[playerid] = 7;
             }
             else if(IsSweeping[playerid]==7)
             {
                DisablePlayerCheckpoint(playerid);
                SetPlayerCheckpoint(playerid, -2709.4812,455.1877,3.9048, 8.0);
                IsSweeping[playerid] = 8;
             }
             else if(IsSweeping[playerid]==8)
             {
                DisablePlayerCheckpoint(playerid);
                IsSweeping[playerid] = 9;
                SetPlayerCheckpoint(playerid, -2689.5435,414.1230,3.8691, 5.0);
             }
             else if(IsSweeping[playerid]==9)
             {
                 new cashes=(random(35-10)+10);
                 new pare=(random(20-5)+5);
                DisablePlayerCheckpoint(playerid);
                SendClientMessage(playerid, COLOR_LIGHTBLUE, "Ocistili ste dobar dio grada,ovo je vasa nagrada!");
                format(string, sizeof(string), "Zaradili ste $%d.", cashes);
                SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                IsSweeping[playerid] = 0;
                GivePlayerMoney(playerid, cashes);
                SBizzInfo[10][sbTill] += pare;
                PlayerInfo[playerid][pSweepTime] += 1200;
             }
          }
       }
CP[playerid] = 0;
    DisablePlayerCheckpoint(playerid);
    GetPlayerName(playerid, name, sizeof(name));
    if(FirstKartWinner == 999)
    {
        FirstKartWinner = playerid;
        for(new i = 0; i < MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
            if(PlayerKarting[i] != 0 && PlayerInKart[i] != 0)
            {
                format(string, sizeof(string), "* %s finished First in the Kart Race.",name);
                SendClientMessage(i, COLOR_WHITE, string);
            }
}
}
    }
    else if(SecondKartWinner == 999)
    {
        SecondKartWinner = playerid;
        for(new i = 0; i < MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
            if(PlayerKarting[i] != 0 && PlayerInKart[i] != 0)
            {
                format(string, sizeof(string), "* %s finished Second in the Kart Race.",name);
                SendClientMessage(i, COLOR_WHITE, string);
            }
}
}
    }
    else if(ThirdKartWinner == 999)
    {
        ThirdKartWinner = playerid;
        for(new i = 0; i < MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
            if(PlayerKarting[i] != 0 && PlayerInKart[i] != 0)
            {
                format(string, sizeof(string), "* %s finished Third in the Kart Race.",name);
                SendClientMessage(i, COLOR_WHITE, string);
                SendClientMessage(i, COLOR_WHITE, "** Karting Race Over **");
                CP[i] = 0;
                DisablePlayerCheckpoint(i);
            }
}
        }
    }
}
else if(MissionCheckpoint[playerid] > 0 && PlayMission[kToggle] == 1)//Missions + Checkpoint on toggle
{
        RingTone[playerid] = 20;
    switch(MissionCheckpoint[playerid])
    {
        case 1:
        {
format(string, sizeof(string), "%s", PlayMission[kGText1]);
GameTextForPlayer(playerid, string, 8000, 3);
format(string, sizeof(string), "%s", PlayMission[kText4]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
format(string, sizeof(string), "%s", PlayMission[kText5]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
format(string, sizeof(string), "%s", PlayMission[kText6]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
DisablePlayerCheckpoint(playerid);
SetPlayerCheckpoint(playerid, PlayMission[kCP2][0], PlayMission[kCP2][1], PlayMission[kCP2][2], 8);
MissionCheckpoint[playerid] = 2;
        }
        case 2:
        {
            format(string, sizeof(string), "%s", PlayMission[kGText2]);
GameTextForPlayer(playerid, string, 8000, 3);
format(string, sizeof(string), "%s", PlayMission[kText7]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
format(string, sizeof(string), "%s", PlayMission[kText8]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
format(string, sizeof(string), "%s", PlayMission[kText9]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
DisablePlayerCheckpoint(playerid);
SetPlayerCheckpoint(playerid, PlayMission[kCP3][0], PlayMission[kCP3][1], PlayMission[kCP3][2], 8);
MissionCheckpoint[playerid] = 3;
        }
        case 3:
        {
            format(string, sizeof(string), "%s", PlayMission[kGText3]);
GameTextForPlayer(playerid, string, 8000, 3);
format(string, sizeof(string), "%s", PlayMission[kText10]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
format(string, sizeof(string), "%s", PlayMission[kText11]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
format(string, sizeof(string), "%s", PlayMission[kText12]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
DisablePlayerCheckpoint(playerid);
SetPlayerCheckpoint(playerid, PlayMission[kCP4][0], PlayMission[kCP4][1], PlayMission[kCP4][2], 8);
MissionCheckpoint[playerid] = 4;
        }
        case 4:
        {
            format(string, sizeof(string), "%s", PlayMission[kGText4]);
GameTextForPlayer(playerid, string, 8000, 3);
format(string, sizeof(string), "%s", PlayMission[kText13]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
format(string, sizeof(string), "%s", PlayMission[kText14]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
format(string, sizeof(string), "%s", PlayMission[kText15]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
DisablePlayerCheckpoint(playerid);
SetPlayerCheckpoint(playerid, PlayMission[kCP5][0], PlayMission[kCP5][1], PlayMission[kCP5][2], 8);
MissionCheckpoint[playerid] = 5;
        }
        case 5:
        {
            format(string, sizeof(string), "%s", PlayMission[kGText5]);
GameTextForPlayer(playerid, string, 8000, 3);
format(string, sizeof(string), "%s", PlayMission[kText16]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
format(string, sizeof(string), "%s", PlayMission[kText17]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
format(string, sizeof(string), "%s", PlayMission[kText18]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
DisablePlayerCheckpoint(playerid);
SetPlayerCheckpoint(playerid, PlayMission[kCP6][0], PlayMission[kCP6][1], PlayMission[kCP6][2], 8);
MissionCheckpoint[playerid] = 6;
        }
        case 6:
        {
            format(string, sizeof(string), "%s", PlayMission[kGText6]);
GameTextForPlayer(playerid, string, 8000, 3);
format(string, sizeof(string), "..:: Mission Passed : %s | Reward received: $%d ::..", PlayMission[kTitle], PlayMission[kReward]);
SendClientMessage(playerid, COLOR_GREEN, string);
DisablePlayerCheckpoint(playerid);
GivePlayerMoney(playerid, PlayMission[kReward]);
PlayerInfo[playerid][pMissionNr] = PlayerOnMission[playerid];
MissionCheckpoint[playerid] = 0;
PlayerOnMission[playerid] = 0;
        }
    }
}
else
{
switch (gPlayerCheckpointStatus[playerid])
{
case CHECKPOINT_HOME:
    {
PlayerPlaySound(playerid, 1058, 0.0, 0.0, 0.0);
DisablePlayerCheckpoint(playerid);
gPlayerCheckpointStatus[playerid] = CHECKPOINT_NONE;
GameTextForPlayer(playerid, "~w~You are~n~~y~Home", 5000, 1);
    }
}
}
return 1;
}

velicne cp moraju biti iste kod tebe je jedan 5.0 drugi 7,5 treci 8.0
Vratio sam se ponovo ocekjute novi server...

Citat: Narco_VK poslato Septembar 10, 2011, 09:33:49 PRE PODNE
velicne cp moraju biti iste kod tebe je jedan 5.0 drugi 7,5 treci 8.0
Nije istina vidi ovu moju temu radijuse -.-
http://balkan-samp.com/forum/index.php?topic=30830.0    
   i nakraju sam probao i ovako da ubacim i opet izadje samo prvi njega proÄ'em i ostali neidu
public OnPlayerEnterCheckpoint(playerid)
{
    if(PlayerInfo[playerid][pKosenje] > 0)
   {
//--------ruta1
       if(PlayerToPoint(10.0, playerid,3444.1814,436.5919,3.4218))//cp1
       {
           if(PlayerInfo[playerid][pKosenje] == 1)//
           {
                     new Veh = GetPlayerVehicleID(playerid);
                     if(Veh == 100)//tu stavite id od vozila za kosenje
     {
                          PlayerInfo[playerid][pKosenje] = 2;// dodajemo vrijednost da se slucajno ne pogodi isti cp, ovo nije potrebno
                          SetPlayerCheckpoint(playerid, 1402.3662, -1436.7428, 23.3017,10.0);//
 }
           }
       }
       if(PlayerToPoint(10.0, playerid,1402.3662, -1436.7428, 23.3017))//cp2
       {
           if(PlayerInfo[playerid][pKosenje] == 2)//
           {
                     new Veh = GetPlayerVehicleID(playerid);
                     if(Veh == 100)
     {
                          PlayerInfo[playerid][pKosenje] = 3;//
                          SetPlayerCheckpoint(playerid, 3444.1814,436.5919,3.4218,10.0);//
 }
           }
}
       if(PlayerToPoint(10.0, playerid,3444.1814,436.5919,3.4218))//cp n-zi
       {
           if(PlayerInfo[playerid][pKosenje] == 3)//
           {
                     new Veh = GetPlayerVehicleID(playerid);
                     if(Veh == 100)
     {
                          PlayerInfo[playerid][pKosenje] = 0;//
                          DisablePlayerCheckpoint(playerid);
                          SendClientMessage(playerid, COLOR_GREEN ,"*kosenje uspjesno zavrseno");
//---------------------------------------------------------------ovo ispod nije potrebno
  GivePlayerMoney(playerid, 100);
                          SendClientMessage(playerid, COLOR_GREEN ,"Zarada = 100$");
 }
           }
           }
}
return 1;
}


if(strcmp(cmd, "/kosenje", true) == 0)
{
   if(IsPlayerConnected(playerid))
   {
           if(PlayerInfo[playerid][pKosenje] > 0)
           {
    SendClientMessage(playerid, COLOR_GREY, "*Vec imas aktivirano kosenje!");
    return 1;
           }
if(PlayerInfo[playerid][pJob] == 27)//<---- tu si stavite id koji stavite za taj posao
{

                  SendClientMessage(playerid,COLOR_PINK,"*Aktivirao si kosenje");
      PlayerInfo[playerid][pKosenje] = 1;//---- tu stavite vrijednos 1 za kosenje za toga igraca
          SetPlayerCheckpoint(playerid, 3444.1814,436.5919,3.4218,10.0);// tu stavite koordinate prvog cp-a
}
else
{
       SendClientMessage(playerid, COLOR_GREY, "Nemas posao kosaca trave!");
               return 1;
       }
}
return 1;
}
Poslednja Izmena: Septembar 10, 2011, 10:51:17 PRE PODNE od Ante_Street
Trazim "Profesionalnog Skriptera" da mi napravi jednu stvar,cijena nebitna nek mi se javi na pm....trazim lika koji zna raditi ne nekog pocetnika

Citat: Ante_Street poslato Septembar 10, 2011, 09:40:25 PRE PODNE
Citat: Narco_VK poslato Septembar 10, 2011, 09:33:49 PRE PODNE
velicne cp moraju biti iste kod tebe je jedan 5.0 drugi 7,5 treci 8.0
Nije istina vidi ovu moju temu radijuse -.-
http://balkan-samp.com/forum/index.php?topic=30830.0

nerazumijem kako na komandi ti cp 20.0 i taj prvi ti ocita i dalje nece drugi cp je 10.0...
Vratio sam se ponovo ocekjute novi server...

Citat: Narco_VK poslato Septembar 10, 2011, 09:42:04 PRE PODNE
Citat: Ante_Street poslato Septembar 10, 2011, 09:40:25 PRE PODNE
Citat: Narco_VK poslato Septembar 10, 2011, 09:33:49 PRE PODNE
velicne cp moraju biti iste kod tebe je jedan 5.0 drugi 7,5 treci 8.0
Nije istina vidi ovu moju temu radijuse -.-
http://balkan-samp.com/forum/index.php?topic=30830.0

nerazumijem kako na komandi ti cp 20.0 i taj prvi ti ocita i dalje nece drugi cp je 10.0...
Ma gdje ti vidis 20.0??
Stavio sam dva nacina izrade na svakom je radijus 10.0 i kod komandi ista prica 10.0 je radijus
Poslednja Izmena: Septembar 10, 2011, 09:47:41 PRE PODNE od Ante_Street
Trazim "Profesionalnog Skriptera" da mi napravi jednu stvar,cijena nebitna nek mi se javi na pm....trazim lika koji zna raditi ne nekog pocetnika

dragan12

if(IsSweeping[playerid]>0)
       {
          new tmpcar2 = GetPlayerVehicleID(playerid);
          if(IsASweeper(tmpcar2))
          {
             if(IsSweeping[playerid]==1)
             {
                SetPlayerCheckpoint(playerid, -2866.4756,1219.0432,5.1957,5.0);
                IsSweeping[playerid] = 2;
             }
             else if(IsSweeping[playerid]==2)
             {
                SetPlayerCheckpoint(playerid, -2883.1003,1076.0865,30.4857,5.0);
                IsSweeping[playerid] = 3;
             }
             else if(IsSweeping[playerid]==3)
             {
                SetPlayerCheckpoint(playerid, -2826.5110,922.2037,43.6314,8.0);
                IsSweeping[playerid] = 4;
             }
             else if(IsSweeping[playerid]==4)
             {
                SetPlayerCheckpoint(playerid, -2863.1445,734.0028,29.5695,8.0);
                IsSweeping[playerid] = 5;
             }
             else if(IsSweeping[playerid]==5)
             {
                SetPlayerCheckpoint(playerid, -2839.1450,521.9155,4.5592,8.0);
                IsSweeping[playerid] = 6;
             }
             else if(IsSweeping[playerid]==6)
             {
                SetPlayerCheckpoint(playerid, -2835.2617,463.7046,4.0117,8.0);
                IsSweeping[playerid] = 7;
             }
             else if(IsSweeping[playerid]==7)
             {
                SetPlayerCheckpoint(playerid, -2709.4812,455.1877,3.9048, 8.0);
                IsSweeping[playerid] = 8;
             }
             else if(IsSweeping[playerid]==8)
             {
                IsSweeping[playerid] = 9;
                SetPlayerCheckpoint(playerid, -2689.5435,414.1230,3.8691, 5.0);
             }
             else if(IsSweeping[playerid]==9)
             {
                 new cashes=(random(35-10)+10);
                 new pare=(random(20-5)+5);
                DisablePlayerCheckpoint(playerid);
                SendClientMessage(playerid, COLOR_LIGHTBLUE, "Ocistili ste dobar dio grada,ovo je vasa nagrada!");
                format(string, sizeof(string), "Zaradili ste $%d.", cashes);
                SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                IsSweeping[playerid] = 0;
                GivePlayerMoney(playerid, cashes);
                SBizzInfo[10][sbTill] += pare;
                PlayerInfo[playerid][pSweepTime] += 1200;
             }
          }
       }

Pazi sada probaj nesto ovako ali mislim da ce ovako pokazati samo poslednji CP ili tako nesto. Jer sa onim je sklanjao svaki CP pa postavljao sledeci. I da jos ako nebude hteo koristi IsPlayerInRangeOfPoint kod svakog za njegove kordinate i da tek onda prebaci ako je na tim kordinatama na sledeci CP.

Paco


dragan12

Citat: Paco poslato Septembar 10, 2011, 15:40:36 POSLE PODNE
Citat: Paco poslato Septembar 10, 2011, 09:33:49 PRE PODNE
velicne cp moraju biti iste kod tebe je jedan 5.0 drugi 7,5 treci 8.0
Aj objasni sto moraju da budu iste? Gde ispituje on ovde samo stavio da postavi CP.

Gagi nevalja onaj kod, opet isto. Prvi CP samo stoji.

dragan12

if(IsSweeping[playerid]>0)
       {
          new tmpcar2 = GetPlayerVehicleID(playerid);
          if(IsASweeper(tmpcar2))
          {
             if(IsSweeping[playerid]==1)
             {
if(IsPlayerInRangeOfPoint(playerid, 10.0, 1402.3662, -1436.7428, 23.3017))
{
                SetPlayerCheckpoint(playerid, -2866.4756,1219.0432,5.1957,5.0);
                IsSweeping[playerid] = 2;
}
             }
             else if(IsSweeping[playerid]==2)
             {
if(IsPlayerInRangeOfPoint(playerid, 5.0, -2866.4756,1219.0432,5.1957))
{
                SetPlayerCheckpoint(playerid, -2883.1003,1076.0865,30.4857,5.0);
                IsSweeping[playerid] = 3;
}
             }
             else if(IsSweeping[playerid]==3)
             {
if(IsPlayerInRangeOfPoint(playerid, 5.0, -2883.1003,1076.0865,30.4857))
{
                SetPlayerCheckpoint(playerid, -2826.5110,922.2037,43.6314,8.0);
                IsSweeping[playerid] = 4;
}
             }
             else if(IsSweeping[playerid]==4)
             {
if(IsPlayerInRangeOfPoint(playerid, 8.0, -2826.5110,922.2037,43.6314))
{
                SetPlayerCheckpoint(playerid, -2863.1445,734.0028,29.5695,8.0);
                IsSweeping[playerid] = 5;
}
             }
             else if(IsSweeping[playerid]==5)
             {
if(IsPlayerInRangeOfPoint(playerid, 8.0, -2863.1445,734.0028,29.5695))
{
                SetPlayerCheckpoint(playerid, -2839.1450,521.9155,4.5592,8.0);
                IsSweeping[playerid] = 6;
             }
}
             else if(IsSweeping[playerid]==6)
             {
if(IsPlayerInRangeOfPoint(playerid, 8.0, -2839.1450,521.9155,4.5592))
{
                SetPlayerCheckpoint(playerid, -2835.2617,463.7046,4.0117,8.0);
                IsSweeping[playerid] = 7;
             }
}
             else if(IsSweeping[playerid]==7)
             {
if(IsPlayerInRangeOfPoint(playerid, 8.0, -2835.2617,463.7046,4.0117))
{
                SetPlayerCheckpoint(playerid, -2709.4812,455.1877,3.9048, 8.0);
                IsSweeping[playerid] = 8;
             }
}
             else if(IsSweeping[playerid]==8)
             {
if(IsPlayerInRangeOfPoint(playerid, 8.0, -2709.4812,455.1877,3.9048))
{
                IsSweeping[playerid] = 9;
                SetPlayerCheckpoint(playerid, -2689.5435,414.1230,3.8691, 5.0);
             }
}
             else if(IsSweeping[playerid]==9)
             {
if(IsPlayerInRangeOfPoint(playerid, 5.0, 2689.5435,414.1230,3.8691))
{
                 new cashes=(random(35-10)+10);
                 new pare=(random(20-5)+5);
                DisablePlayerCheckpoint(playerid);
                SendClientMessage(playerid, COLOR_LIGHTBLUE, "Ocistili ste dobar dio grada,ovo je vasa nagrada!");
                format(string, sizeof(string), "Zaradili ste $%d.", cashes);
                SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                IsSweeping[playerid] = 0;
                GivePlayerMoney(playerid, cashes);
                SBizzInfo[10][sbTill] += pare;
                PlayerInfo[playerid][pSweepTime] += 1200;
             }
}
          }
       }

Aj probaj ovako nesto.