Balkan SA:MP

PAWN skriptanje, gamemodovi, filterskripte, include fajlovi, mape, pluginovi => Razgovor u vezi PAWN - skriptanja => Temu započeo: [Perfect] Mihailo poslato Avgust 04, 2013, 14:53:15 POSLE PODNE

Naslov: [Pomoc] Oko bilborda nesto nece da radi :(
Poruka od: [Perfect] Mihailo poslato Avgust 04, 2013, 14:53:15 POSLE PODNE
Imam problem sa bilbordima, sve je ok kad compile nema warninga i to ali kad dodjem kod oglasa i kucam /bilbordad ja kliknem na izbor i nista se ne desi evo kodva:
if(dialogid == 269386)
{
if(response)
  {
if(listitem == 0)
  {
      if(GetPlayerMoney(playerid) < 600)
      {
SendClientMessage(playerid, -1, "Nemate dovoljno novca za oglas.");
return 1;
      }
ShowPlayerDialog(playerid, 269385, DIALOG_STYLE_LIST, "Sta prodajete?", "Vozilo\nKucu\nBiznis", "Uredu", "Otkazi");
                TrajanjeOglasa[playerid] = 60000;
                GivePlayerMoney(playerid, -600);
}
    if(listitem == 1)
    {
    if(GetPlayerMoney(playerid) < 800)
      {
SendClientMessage(playerid, -1, "Nemate dovoljno novca za oglas.");
return 1;
      }
ShowPlayerDialog(playerid, 269385, DIALOG_STYLE_LIST, "Sta prodajete?", "Vozilo\nKucu\nBiznis", "Uredu", "Otkazi");
TrajanjeOglasa[playerid] = 120000;
GivePlayerMoney(playerid, -800);
}
    if(listitem == 2)
    {
    if(GetPlayerMoney(playerid) < 1000)
      {
SendClientMessage(playerid, -1, "Nemate dovoljno novca za oglas.");
return 1;
      }
ShowPlayerDialog(playerid, 269385, DIALOG_STYLE_LIST, "Sta prodajete?", "Vozilo\nKucu\nBiznis", "Uredu", "Otkazi");
                TrajanjeOglasa[playerid] = 180000;
                GivePlayerMoney(playerid, -1000);
        }
        }
        return 1;
}

if(dialogid == 269385)
{
if(response)
  {
if(listitem == 0)
  {
ShowPlayerDialog(playerid, 269387, DIALOG_STYLE_INPUT, "Unesite cenu vozila.", "Cena vozila:", "Uredu", "Otkazi" );
                Prodaja[playerid] = 1;
}
    if(listitem == 1)
    {
ShowPlayerDialog(playerid, 269387, DIALOG_STYLE_INPUT, "Unesite cenu kuce.", "Cena kuce:", "Uredu", "Otkazi" );
Prodaja[playerid] = 2;
}
    if(listitem == 2)
    {
ShowPlayerDialog(playerid, 269387, DIALOG_STYLE_INPUT, "Unesite cenu biznisa.", "Cena biznisa:", "Uredu", "Otkazi" );
                Prodaja[playerid] = 3;
        }
        }
        return 1;
}

        if(dialogid == 269387)
{
if(response)
{
if(IsPlayerConnected(playerid))
{
    if(strlen(inputtext))
    {
        new Cena = strval(inputtext);
    if(Cena > 9000000 || Cena < 0)
    {
    SendClientMessage(playerid, -1, "Cena ne moze biti manja od 0 ili veca od 90000000." );
    ShowPlayerDialog(playerid, 269384, DIALOG_STYLE_INPUT, "Unesite cenu.", "Cena:", "Uredu", "Otkazi" );
        return 1;
    }
if(IsNumeric(inputtext))//
{
    if(Prodaja[playerid] == 1)
{
SendClientMessage(playerid, -1, "Slovima unesite model vozila. Primer: Monster." );
ShowPlayerDialog(playerid, 269384, DIALOG_STYLE_INPUT, "Unesite model vozila.", "Model:", "Uredu", "Otkazi" );
CenaO[playerid] = Cena;
return 1;
}
if(Prodaja[playerid] == 2)
{
    SendClientMessage(playerid, -1, "Slovima unesite vrstu kuce. Primer: Vila." );
ShowPlayerDialog(playerid, 269384, DIALOG_STYLE_INPUT, "Unesite vrstu kuce.", "Vrsta:", "Uredu", "Otkazi" );
CenaO[playerid] = Cena;
return 1;
}
if(Prodaja[playerid] == 3)
{
    SendClientMessage(playerid, -1, "Slovima unesite vrstu biznisa. Primer: Ammunation." );
ShowPlayerDialog(playerid, 269384, DIALOG_STYLE_INPUT, "Unesite vrstu biznisa.", "Vrsta:", "Uredu", "Otkazi" );
CenaO[playerid] = Cena;
return 1;
}
}
else
{
SendClientMessage(playerid, -1, "Moras koristiti brojeve." );
ShowPlayerDialog(playerid, 269387, DIALOG_STYLE_INPUT, "Unesite cenu.", "Cena:", "Uredu", "Otkazi" );
return 1;
}
}
else
{
    SendClientMessage(playerid, -1, "Ovo polje ne sme ostati prazno." );
    ShowPlayerDialog(playerid, 269387, DIALOG_STYLE_INPUT, "Unesite cenu.", "Cena:", "Uredu", "Otkazi" );
return 1;
}
}
}
return 1;
}

if(dialogid == 269384)
{
   // new string[256];
    //new sendername[MAX_PLAYER_NAME];
//GetPlayerName(playerid, sendername, sizeof(sendername));
if(response)
{
if(IsPlayerConnected(playerid))
{
    /*if(AntiReklama(inputtext) && !IsPlayerAdmin(playerid))//
    {
        Kick(playerid);
        //SendClientMessage(playerid, -1, "Reklama." );
    return 1;
    }*/
    if(strlen(inputtext))
    {
    if(IsNumeric(inputtext))
{
SendClientMessage(playerid, -1, "U ovo polje ne mozete unositi brojeve." );
    if(Prodaja[playerid] == 1){ShowPlayerDialog(playerid, 269384, DIALOG_STYLE_INPUT, "Unesite model vozila.", "Model:", "Uredu", "Otkazi" );}
    if(Prodaja[playerid] == 2){ShowPlayerDialog(playerid, 269384, DIALOG_STYLE_INPUT, "Unesite vrstu kuce.", "Model:", "Uredu", "Otkazi" );}
    if(Prodaja[playerid] == 3){ShowPlayerDialog(playerid, 269384, DIALOG_STYLE_INPUT, "Unesite vrstu Biznisa.", "Model:", "Uredu", "Otkazi" );}
    return 1;
}
    if(strlen(inputtext) > 10)
{
SendClientMessage(playerid, -1, "U ovo polje ne mozete uneti rec sa vise od 10 slova." );
    if(Prodaja[playerid] == 1){ShowPlayerDialog(playerid, 269384, DIALOG_STYLE_INPUT, "Unesite model vozila.", "Model:", "Uredu", "Otkazi" );}
    if(Prodaja[playerid] == 2){ShowPlayerDialog(playerid, 269384, DIALOG_STYLE_INPUT, "Unesite vrstu kuce.", "Model:", "Uredu", "Otkazi" );}
    if(Prodaja[playerid] == 3){ShowPlayerDialog(playerid, 269384, DIALOG_STYLE_INPUT, "Unesite vrstu Biznisa.", "Model:", "Uredu", "Otkazi" );}
    return 1;
}
if(Prodaja[playerid] == 1){format(string, sizeof(string), "---------------- Oglas ----------------\nNa prodaju: Vozilo\nCena: %d\nModel: %s\nTelefon: %d", CenaO[playerid], inputtext, PlayerInfo[playerid][pPnumber]);}
  if(Prodaja[playerid] == 2){format(string, sizeof(string), "---------------- Oglas ----------------\nNa prodaju: Kuca\nCena: %d\nVrsta: %s\nTelefon: %d", CenaO[playerid], inputtext, PlayerInfo[playerid][pPnumber]);}
  if(Prodaja[playerid] == 3){format(string, sizeof(string), "---------------- Oglas ----------------\nNa prodaju: Biznis\nCena: %d\nVrsta: %s\nTelefon: %d", CenaO[playerid], inputtext, PlayerInfo[playerid][pPnumber]);}
for(new i = 0;i<6;i++)
{
SetObjectMaterialText(OglasO[i], string, 0, 50, "Arial", 13, 0, -32256, -16777216, 0);
}
RSOglas = SetTimer("RestartOglasa", TrajanjeOglasa[playerid], 0);
SendClientMessage(playerid, -1, "{157DEC}[INFO] {FFFFFF}Uspesno ste postavili oglas... " );
OglasDat = 1;
new Str1[256];
format(Str1, sizeof(Str1), "Igrac %s je postavio vrstu oglasa {FF0000}%s {FF6347}na bilborde. {FFFFFF}(Provera zbog reklamiranja.)", sendername,inputtext);
PosaljiAdminima(COLOR_LIGHTRED,Str1);
return 1;
}
  else
{
    SendClientMessage(playerid, -1, "Ovo polje ne sme ostati prazno." );
    if(Prodaja[playerid] == 1){ShowPlayerDialog(playerid, 130, DIALOG_STYLE_INPUT, "Unesite model vozila.", "Model:", "Uredu", "Otkazi" );}
    if(Prodaja[playerid] == 2){ShowPlayerDialog(playerid, 130, DIALOG_STYLE_INPUT, "Unesite vrstu kuce.", "Model:", "Uredu", "Otkazi" );}
    if(Prodaja[playerid] == 3){ShowPlayerDialog(playerid, 130, DIALOG_STYLE_INPUT, "Unesite vrstu Biznisa.", "Model:", "Uredu", "Otkazi" );}
return 1;
}
}
}
return 1;
}

A evo i komande:
if(strcmp(cmd, "/bilbordad", true) == 0)
{
    if(IsPlayerConnected(playerid))
    {
  if(!IsPlayerInRangeOfPoint(playerid, 5.0,1736.7319,-1272.0305,13.6000))
        {
                SendClientMessage(playerid, COLOR_GREY, "Morate biti u AD studiju kako bi dao oglas!");
                return 1;
        }
if(PlayerInfo[playerid][pLevel] < 5)
{
SendClientMessage(playerid, COLOR_GRAD1, "Nemate dovoljan level za koriscenje Bilbord Oglasa. (Min lvl 5.)!");
return 1;
}
    if(OglasDat == 1)
{
    SendClientMessage(playerid, COLOR_GRAD1, "Neko je pre vas dao oglas morate sacekati da prodje vreme oglasa.");
return 1;
}
ShowPlayerDialog(playerid, 269386, DIALOG_STYLE_LIST, "Trajanje oglasa.", "1 min 600$\n2 min 800$\n3 min 1000$", "Uredu", "Otkazi");
}
return 1;
}
Naslov: Odg: [Pomoc] Oko bilborda nesto nece da radi :(
Poruka od: [Euro Samp]Shadow poslato Avgust 04, 2013, 15:48:49 POSLE PODNE
daj ovaj dialog 269385
Naslov: Odg: [Pomoc] Oko bilborda nesto nece da radi :(
Poruka od: [Perfect] Mihailo poslato Avgust 04, 2013, 16:52:25 POSLE PODNE
pa evo ti svi dialozi su ti ovde malopre sam postao xD :
if(dialogid == 269385)
{
if(response)
  {
if(listitem == 0)
  {
ShowPlayerDialog(playerid, 269387, DIALOG_STYLE_INPUT, "Unesite cenu vozila.", "Cena vozila:", "Uredu", "Otkazi" );
                Prodaja[playerid] = 1;
}
    if(listitem == 1)
    {
ShowPlayerDialog(playerid, 269387, DIALOG_STYLE_INPUT, "Unesite cenu kuce.", "Cena kuce:", "Uredu", "Otkazi" );
Prodaja[playerid] = 2;
}
    if(listitem == 2)
    {
ShowPlayerDialog(playerid, 269387, DIALOG_STYLE_INPUT, "Unesite cenu biznisa.", "Cena biznisa:", "Uredu", "Otkazi" );
                Prodaja[playerid] = 3;
        }
        }
        return 1;
}
Naslov: Odg: [Pomoc] Oko bilborda nesto nece da radi :(
Poruka od: ShoneSS poslato Jun 29, 2014, 14:33:19 POSLE PODNE
Daj link od Bilborda da test na mom serveru. Mislim da znam problem  8)
Naslov: Odg: [Pomoc] Oko bilborda nesto nece da radi :(
Poruka od: Joy poslato Jun 29, 2014, 15:14:50 POSLE PODNE
Jesi probao da smanjis taj ID dialoga,stvarno je veliki ID dialoga,probaj staviti id sa manje cifara....
Naslov: Odg: [Pomoc] Oko bilborda nesto nece da radi :(
Poruka od: [beNNy] poslato Jun 30, 2014, 09:46:29 PRE PODNE
Imaš max dialog ID koliko može,u tebe je veće u tebe duplo smanji to.