posao

Započeo Ante_Dracar aka Lopa, Jun 29, 2010, 14:18:03 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

ovako trebam malu pomoc...
napravio sam posao GRADJEVINAR...prvo se zaposlim i znaci to radi...ali kada upisem komandu /gradi pojavi mi se prvi kroug kroz koji moram proci ali kada prodjem kroz njega nece da ga makne i da ide na iduci...pa ako moze pomoc...

SLIKA===http://www.zaslike.com/viewer.php?file=w6hpft8oeteggdghqot6.png


EVO KOMANDA ZA ZAPOSLIT RADI 100%
if(strcmp(cmd, "/gradjevinar", true) == 0)
{
   if(IsPlayerConnected(playerid))
   {
       if(PlayerToPoint(5.0,playerid,-2073.5686,268.2052,35.3813))
       {
           if(PlayerInfo[playerid][pJob] == 0)
           {
               PlayerInfo[playerid][pJob] = 23;
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "* %s uzima posao gradjevinara.", sendername);
SendClientMessage(playerid, COLOR_GREY, "Ako zelite graditi upisite /gradi");
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
           }
           else
           {
               SendClientMessage(playerid, COLOR_GREY, "   Imate posao !");
               return 1;
           }
       }
       else
       {
           SendClientMessage(playerid, COLOR_GREY, "   Nisi na mjestu za posao !");
           return 1;
       }
   }
   return 1;
}


EVO KOMANDA ZA GRADIT NE RADI TAJ CRVENI KRUG...
if(strcmp(cmd, "/gradi", true) == 0)
{
   if(IsPlayerConnected(playerid))
   {
       if(PlayerInfo[playerid][pJob] == 23)
       {
           SendClientMessage(playerid, COLOR_GREY, "   na poziciji za uzest opremu kako bi mogli poceti graditi !");
   
if(PlayerToPoint(15.0,playerid,-2079.7004,260.7307,35.2572))
{
SetPlayerCheckpoint(giveplayerid, -2097.9990,182.1046,35.1184,5.0);
CP[giveplayerid] = 900;
}
else
{
    SendClientMessage(playerid, COLOR_GREY, "   Nisi na poziciji za uzest opremu kako bi mogli poceti graditi !");
    return 1;
}
}
}
  return 1;
}



EVO TI KRUGOVI...NAPOMENA OVAJ KRUG STO SE NALAZU U OVOME POVISE KVADRATICU...
SetPlayerCheckpoint(giveplayerid, -2097.9990,182.1046,35.1184,5.0);
CP[giveplayerid] = 900;


ZNACI TAJ KORDINAT NEMAM DOLI DISU OSTALI KRUGOVI...


else if(CP[playerid] == 900) { CP[playerid] = 901; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2097.7751,155.8687,35.1218,10.0); }
   else if(CP[playerid] == 901) { CP[playerid] = 902; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2081.2036,181.7803,35.1112,10.0); }
   else if(CP[playerid] == 902) { CP[playerid] = 903; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2068.1763,201.2154,35.5955,10.0); }
   else if(CP[playerid] == 903) { CP[playerid] = 904; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2051.3174,224.6756,35.6276,10.0); }
   else if(CP[playerid] == 904) { CP[playerid] = 905; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2050.6860,252.0351,35.3826,10.0); }
   else if(CP[playerid] == 905) { CP[playerid] = 906; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2057.1824,272.7188,35.3485,10.0); }
   else if(CP[playerid] == 906) { CP[playerid] = 907; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2074.0659,278.7420,35.3403,10.0); }
   else if(CP[playerid] == 907) { CP[playerid] = 908; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2094.8401,275.2155,35.1811,10.0); }
   else if(CP[playerid] == 908) { CP[playerid] = 909; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2125.5425,294.4122,34.8399,10.0); }
    else if(CP[playerid] == 909) { CP[playerid] = 910; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2103.4158,282.5852,35.1632,10.0); }
    else if(CP[playerid] == 910) { CP[playerid] = 911; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2085.4800,283.4416,35.4646,10.0); }
    else if(CP[playerid] == 911) { CP[playerid] = 912; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2054.0432,265.6967,35.7499,10.0); }
    else if(CP[playerid] == 912) { CP[playerid] = 913; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2050.2249,238.6608,35.6857,10.0); }
    else if(CP[playerid] == 913) { CP[playerid] = 914; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2059.1221,215.4383,35.5842,10.0); }
    else if(CP[playerid] == 914) { CP[playerid] = 915; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2078.9775,214.1233,35.3772,10.0); }
   else if(CP[playerid] == 915) { CP[playerid] = 916; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2086.0662,229.6242,35.6191,10.0); }
    else if(CP[playerid] == 916) { CP[playerid] = 917; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2090.4343,249.6210,35.9832,10.0); }
   else if(CP[playerid] == 917) { CP[playerid] = 918; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2088.8979,270.5758,35.3381,10.0); }
       else if(CP[playerid] == 918)
{
CP[playerid] = 0;
DisablePlayerCheckpoint(playerid);
SendClientMessage(playerid, COLOR_LIGHTRED, "Vi ste upravo zavrsili ciscenje i zaradili dzeparac. ");
GivePlayerMoney(playerid, 1200);
}




Poslednja Izmena: Jun 29, 2010, 14:58:07 POSLE PODNE od lopalopa

znaci evo ovako da razjasnimo xD

PRvo

if(PlayerInfo[playerid][pJob] == 0) - pazi na to sve sto si ubacivo pise ti negdje za poso pazi da ti je ID posla u svemu sta si napravio isti

Drugo

TU
if(PlayerToPoint(5.0,playerid,-2073.5686,268.2052,35.3813))
tu
if(PlayerToPoint(15.0,playerid,-2079.7004,260.7307,35.2572))
{
SetPlayerCheckpoint(giveplayerid, -2097.9990,182.1046,35.1184,5.0);

TU
SetPlayerCheckpoint(giveplayerid, -2097.9990,182.1046,35.1184,5.0);
CP[giveplayerid] = 900;


i tu
else if(CP[playerid] == 900) { CP[playerid] = 901; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid, -2097.7751,155.8687,35.1218,10.0); }

ti moraju biti iste koordinate, znaci ako ti je PRvi checkpoint -2097.9990,182.1046,35.1184,5.0, onda sve tu di sam ti stavio stavis isto

3. Evo ti iz mog gamemoda pa pogledaj primjer korisno ce ti bit

////////////////////////////////////////////////////////////////////
pRuta1Time,
pRuta1,

if(strcmp(cmd, "/ruta1", true) == 0)
{
   if(IsPlayerConnected(playerid))
  {
       if(PlayerInfo[playerid][pJob] == 16)
{
   if(PlayerOnMission[playerid] > 0)
   {
       SendClientMessage(playerid, COLOR_GREY, "   Trenutno ste na misiji, nemozete koristiti ovu komandu !");
       return 1;
   }
       if(PlayerInfo[playerid][pRuta1] == 0)
       {
           GameTextForPlayer(playerid, "~w~Prenesite naftu iz ~r~San Fierra", 5000, 1);
           CP[playerid] = 16;
           SetPlayerCheckpoint(playerid, -1805.9058,64.5985,14.7246,8.0);
       }
       else
       {
           SendClientMessage(playerid, COLOR_GREY, "   Vec ste prenjeli posiljku, pricekajte  1 minutu te odaberite Rutu !");
       }
}
else
{
SendClientMessage(playerid, COLOR_GREY, "   Niste vozac kamiona !");
}
}//not connected
return 1;
}


if(CP[playerid] == 16)//ruta 1
{
GameTextForPlayer(playerid, "~w~Poceli ste prevozit  ~n~~r~Naftu", 5000, 1);
DisablePlayerCheckpoint(playerid);
CP[playerid] = 108;
SetPlayerCheckpoint(playerid, -1805.9058,64.5985,14.7246,8.0);
}
if(CP[playerid] == 108) { CP[playerid] = 109; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,-1805.9058,64.5985,14.7246,8.0); }//RUTA 1
else if(CP[playerid] == 109) { CP[playerid] = 110; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,-1802.2156,-159.4107,8.0942,8.0); }//RUTA 2
else if(CP[playerid] == 110) { CP[playerid] = 111; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,-1815.5449,-404.1072,15.7815,8.0); }//RUTA 3
else if(CP[playerid] == 111) { CP[playerid] = 112; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,-1819.4063,-568.6556,16.1037,8.0); }//ruta 4
else if(CP[playerid] == 112) { CP[playerid] = 113; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,-1764.5992,-630.5197,17.4039,8.0); }//RUTA 5
else if(CP[playerid] == 113) { CP[playerid] = 114; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,-1692.5559,-760.0424,39.7682,8.0); }//ruta 6
else if(CP[playerid] == 114) { CP[playerid] = 115; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,-1526.9343,-818.5987,56.5874,8.0); }//ruta 7
else if(CP[playerid] == 115) { CP[playerid] = 116; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,-1349.2634,-817.8057,77.2705,8.0); }//ruta 8
else if(CP[playerid] == 116) { CP[playerid] = 117; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,-1171.9075,-659.8380,44.9968,8.0); }//Ruta 9
else if(CP[playerid] == 117) { CP[playerid] = 118; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,-1103.8671,-501.3656,32.1262,8.0); }//ruta 10
else if(CP[playerid] == 118) { CP[playerid] = 119; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,-1046.7745,-462.3519,35.1721,8.0); }//ruta 11
else if(CP[playerid] == 119) { CP[playerid] = 120; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,-1038.1851,-567.9130,31.7350,8.0); }//ruta 12
else if(CP[playerid] == 120) { CP[playerid] = 121; DisablePlayerCheckpoint(playerid); SetPlayerCheckpoint(playerid,-1031.5090,-674.5381,31.7358,8.0); }//ruta 13
else if(CP[playerid] == 121)//Kraj rute 1
   {
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Prevezli ste naftu i zaradili $1000.");
DisablePlayerCheckpoint(playerid);
GivePlayerMoney(playerid, 1000);
CP[playerid] = 0;
PlayerInfo[playerid][pRuta1] = 100;
}


i pogledaj sad moj 1 checkpoint pa svoj pa mi reci u cemu si pogrijesio! nadam se da sam ti pomogo

[ugl. Nervirate me kad radite svoje server, a tek ucite skriptat pa otvarate 10000 tema {takav sam bio i ja, al sam skuzio da bolje malo promislit glavom i mucit se pa naucit} al ne vi odmah nove teme otvarate meni ce pomoc svi sta cu se ja mucit itd itd, gledaj tutoriale uci se snadi se druze]
Poslednja Izmena: Jul 01, 2010, 03:26:29 PRE PODNE od Kiki_Radeon