[pomoc] Parking Servis

Započeo Danijel96.pwn, Oktobar 04, 2011, 09:11:38 PRE PODNE

prethodna tema - sledeća tema

0 članova i 2 gostiju pregledaju ovu temu.

skripta koju korisim :BU
opis problema: kako da napravim na ovu komandu da clanovi parking servisa nemoraju platiti ulaz a svi ostali da moraju
dio skripte:

if (strcmp("/parkingservis", cmdtext, true, 10) == 0)
{
if (PlayerToPoint(15, playerid,-76.479598999023, -353.17669677734, 3.2030787467957)) //zatvoreno
    {
    if(GetPlayerMoney(playerid) < 500)
        {
       SendClientMessage(playerid, COLOR_GREY, "Nemate dovoljno novca da platite ulaz");
       return 1;
        }
      MoveObject(ps,-76.520751953125, -353.15032958984, -2.9739863872528, 1.5); //otvoreno
      SetTimer("pszatvori", 6000, 0);
      SafeGivePlayerMoney(playerid, - 500);
      SendClientMessage(playerid, COLOR_BLUE,"Otvorili ste kapiju Parking Servisa.");
      GetPlayerName(playerid, sendername, sizeof(sendername));
      format(string, sizeof(string), "* %s uzima daljinski i kapiju Parking Servisa.", sendername);
      ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
    }
    else { SendClientMessage(playerid, COLOR_GREY,"Destinacija je previse udaljena.");}
  }

Respect: Gagi, Maki187, Phillips, TerminuS, Neno, Lepotic, [AL] K4[Я]!K3â,,¢, Gotti747

ako je parking server org neka dodas da ta organizacija nemoras
if(PlayerInfo[playerid][pMember] == idorg||PlayerInfo[playerid][pLeader] == idorg)
{
MoveObject(ps,-76.520751953125, -353.15032958984, -2.9739863872528, 1.5); //otvoreno
SendClientMessage(playerid, COLOR_GREEN, "Ti radis u PArking servisu i nemoras platit");
}

i stavis ako igrac nije u org

      else
      {
         SendClientMessage(playerid, COLOR_YELLOW, "Neradis u PArking servisu i moras platit 500$");
                                          SafeGivePlayerMoney(playerid, - 500);
      }
Vratio sam se ponovo ocekjute novi server...

probacu sad napravit

EDIT: Zna li neko ovo sloziti u tu komandu
Poslednja Izmena: Oktobar 04, 2011, 11:43:35 PRE PODNE od danijel123
Respect: Gagi, Maki187, Phillips, TerminuS, Neno, Lepotic, [AL] K4[Я]!K3â,,¢, Gotti747

if (strcmp("/parkingservis", cmdtext, true, 10) == 0)
{
if (strcmp("/parkingservis", cmdtext, true, 10) == 0)
{
if (PlayerToPoint(15, playerid,-76.479598999023, -353.17669677734, 3.2030787467957)) //zatvoreno
               {
                if(PlayerInfo[playerid][pJob] == ID)
   {
   if(GetPlayerMoney(playerid) < 500)
       {
      SendClientMessage(playerid, COLOR_GREY, "Nemate dovoljno novca da platite ulaz");
      return 1;
       }
      MoveObject(ps,-76.520751953125, -353.15032958984, -2.9739863872528, 1.5); //otvoreno
      SetTimer("pszatvori", 6000, 0);
      SafeGivePlayerMoney(playerid, - 500);
      SendClientMessage(playerid, COLOR_BLUE,"Otvorili ste kapiju Parking Servisa.");
      GetPlayerName(playerid, sendername, sizeof(sendername));
      format(string, sizeof(string), "* %s uzima daljinski i kapiju Parking Servisa.", sendername);
      ProxDetector(30.0, playerid, string,       COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
}
else
{
SendClientMessage(playerid, COLOR_GREY,"Destinacija je previse udaljena.");
}
}
return 1;
}

EDIT:eve probaj vaka, Mislev neki eror xD
Poslednja Izmena: Oktobar 04, 2011, 14:47:49 POSLE PODNE od mayk

staje ovo ????
Respect: Gagi, Maki187, Phillips, TerminuS, Neno, Lepotic, [AL] K4[Я]!K3â,,¢, Gotti747

dragan12

Mozes i ovako kako ti sada ja budem dao lepse izgleda:
if (strcmp("/parkingservis", cmdtext, true, 10) == 0)
{
if (PlayerToPoint(15, playerid,-76.479598999023, -353.17669677734, 3.2030787467957)) //zatvoreno
    {
    if(GetPlayerMoney(playerid) < 500)
        {
       SendClientMessage(playerid, COLOR_GREY, "Nemate dovoljno novca da platite ulaz");
       return 1;
        }
if(PlayerInfo[playerid][pMember] == idorg||PlayerInfo[playerid][pLeader] == idorg) return MoveObject(ps,-76.520751953125, -353.15032958984, -2.9739863872528, 1.5), SendClientMessage(playerid, COLOR_GREEN, "Ti radis u PArking servisu i nemoras platit");//Obavezno promeni idorg u ID organizacije.
      MoveObject(ps,-76.520751953125, -353.15032958984, -2.9739863872528, 1.5); //otvoreno
      SetTimer("pszatvori", 6000, 0);
      SafeGivePlayerMoney(playerid, - 500);
      SendClientMessage(playerid, COLOR_BLUE,"Otvorili ste kapiju Parking Servisa.");
      GetPlayerName(playerid, sendername, sizeof(sendername));
      format(string, sizeof(string), "* %s uzima daljinski i kapiju Parking Servisa.", sendername);
      ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
    }
    else { SendClientMessage(playerid, COLOR_GREY,"Destinacija je previse udaljena.");}
  }

if(PlayerInfo[playerid][pMember] == idorg||PlayerInfo[playerid][pLeader] == idorg)   return MoveObject(ps,-76.520751953125, -353.15032958984, -2.9739863872528, 1.5), SendClientMessage(playerid, COLOR_GREEN, "Ti radis u PArking servisu i nemoras platit"); Samo ID org promenis. Znaci ako je igrac clan organizacije otvorice mu kapiju i poslati poruku onu. Iznad je sve ubaceno.


dragan12

Citat: [A]Maki187 poslato Oktobar 04, 2011, 15:53:17 POSLE PODNE
A jel bi ti nama rekao jel ti je ovo posao ili org zasta trazis ?
Pa ako je posao samo neka stavi
if(PlayerInfo[playerid][pJob] == id posla)   return MoveObject(ps,-76.520751953125, -353.15032958984, -2.9739863872528, 1.5), SendClientMessage(playerid, COLOR_GREEN, "Ti radis u Parking servisu i nemoras platit");

hvala gagi

ovo je org pise ti lepo
Respect: Gagi, Maki187, Phillips, TerminuS, Neno, Lepotic, [AL] K4[Я]!K3â,,¢, Gotti747