[Pomoc] Errori

Započeo Robertoo_Salgadoo, Maj 07, 2017, 13:40:35 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Skripta koju koristim:Meine
Detaljan opis problema:Radio sam pban komandu i izbacuje mi neke erore
Dio skripte: [pawn]YCMD:pban(playerid, params[],help)
{
   if(PlayerInfo[playerid][pAdmin] < 3) return Error(playerid, "Niste ovlasceni da koristite ovu komandu");
      new id, rsn[40],time;
      if(sscanf(params, "us[40]", id, razlog)) return Koriscenje(playerid,"/pban [ID/Deo Imena] [Dani 1-26] [Razlog]");
      if(time > 26 || time < 1) return Error(playerid, "Dani ne mogu ici preko 26 i ispod 1!");
      if(id == INVALID_PLAYER_ID) return Error(playerid,"Pogresili ste ID!");
       if(PlayerInfo[id][pBanovan] == 1) return Info(playerid,"Dogodila se GRESKA | Taj igrac je vec banovan!");
      new d,m,y,bx,ca;
       getdate(y,m,d);
      bx = d+time;
      if(m == 12 && bx > 31) { ca = bx-31; m = 1; y++; }
      else if(bx > 31 && m == 1) { ca = bx-31; m++; }
      else if(m == 2 && bx > 29 && y == 2015) { ca = bx-29; m++; }
      else if(m == 2 && bx > 28 && y == 2016) { ca = bx-28; m++; }
      else if(bx > 31 && m == 3) { ca = bx-31; m++; }
      else if(bx > 30 && m == 4) { ca = bx-30; m++; }
      else if(bx > 31 && m == 5) { ca = bx-31; m++; }
      else if(bx > 30 && m == 6) { ca = bx-30; m++; }
      else if(bx > 31 && m == 7) { ca = bx-31; m++; }
      else if(bx > 31 && m == 8) { ca = bx-31; m++; }
      else if(bx > 30 && m == 9) { ca = bx-30; m++; }
      else if(bx > 31 && m == 10) { ca = bx-31; m++; }
      else if(bx > 30 && m == 11) { ca = bx-30; m++; }
      else if(bx > 31 && m == 12) { ca = bx-31; m++; }
      else ca = bx;
      PBanInfo[id][pBanDani] = ca;
      PBanInfo[id][pBanMesec] = m;
      PBanInfo[id][pBanGodina] = y;
   new id, string[128], razlog[40];
   PlayerInfo[id][pBanovan] = 1;
   format(PlayerInfo[id][pBRazlog],40,razlog);
   SacuvajKorisnike(id);
    SAMF(-1, ""SCRVENA1"[BAN] "BELA"Admin: %s | Igrac: %s | Razlog: %s", GetName(playerid), GetName(id), razlog);
    format(string,sizeof(string),""SCRVENA1"[BAN] "BELA"Banovali ste igraca %s | Razlog: %s", GetName(id), razlog);
    SCM(playerid,-1,string);
    format(string,sizeof(string),""SCRVENA1"[BAN] "BELA"Banovani ste od strane admina %s | Razlog: %s", GetName(playerid), razlog);
    SCM(id,-1,string);
   format(string,sizeof(string), "BAN | Staff: %s | Igrac: %s | Razlog: %s", GetName(playerid), GetName(id), razlog);
   UpisiLog(LOG_PBAN, string);
   g_Ban(id);
    return 1;
}[/pawn]

[pawn]C:\Users\Slavche\Desktop\server 2\gamemodes\undergroundRP.pwn(25865) : warning 219: local variable "Ime_Igraca" shadows a variable at a preceding level
C:\Users\Slavche\Desktop\server 2\gamemodes\undergroundRP.pwn(48332) : warning 204: symbol is assigned a value that is never used: "string"
C:\Users\Slavche\Desktop\server 2\gamemodes\undergroundRP.pwn(48363) : warning 204: symbol is assigned a value that is never used: "string"
C:\Users\Slavche\Desktop\server 2\gamemodes\undergroundRP.pwn(48394) : warning 217: loose indentation
C:\Users\Slavche\Desktop\server 2\gamemodes\undergroundRP.pwn(48396) : warning 209: function "@_yCh" should return a value
C:\Users\Slavche\Desktop\server 2\gamemodes\undergroundRP.pwn(48401) : warning 217: loose indentation
C:\Users\Slavche\Desktop\server 2\gamemodes\undergroundRP.pwn(48402) : error 017: undefined symbol "razlog"
C:\Users\Slavche\Desktop\server 2\gamemodes\undergroundRP.pwn(48427) : warning 217: loose indentation
C:\Users\Slavche\Desktop\server 2\gamemodes\undergroundRP.pwn(48427) : error 021: symbol already defined: "id"
C:\Users\Slavche\Desktop\server 2\gamemodes\undergroundRP.pwn(48401) : warning 204: symbol is assigned a value that is never used: "rsn"
C:\Users\Slavche\Desktop\server 2\gamemodes\undergroundRP.pwn(58879) : warning 203: symbol is never used: "Tornjak_DOO"
Pawn compiler 3.2.3664           Copyright (c) 1997-2006, ITB CompuPhase


2 Errors.
[/pawn]
Neke slike/video za lakse dobivanje pomoci(neobavezno): http://imgur.com/a/oeTPS avo sliku

[pawn]YCMD:pban(playerid, params[],help)
{
   if(PlayerInfo[playerid][pAdmin] < 3) return Error(playerid, "Niste ovlasceni da koristite ovu komandu");
    new id, razlog[40],time,d,m,y,bx,ca,string[128];
    if(sscanf(params, "uis[40]", id, time, razlog)) return Koriscenje(playerid,"/pban [ID/Deo Imena] [Dani 1-26] [Razlog]");
    if(time > 26 || time < 1) return Error(playerid, "Dani ne mogu ici preko 26 i ispod 1!");
    if(id == INVALID_PLAYER_ID) return Error(playerid,"Pogresili ste ID!");
   if(PlayerInfo[id][pBanovan] == 1) return Info(playerid,"Dogodila se GRESKA | Taj igrac je vec banovan!");
   getdate(y,m,d);
    bx = d+time;
    if(m == 12 && bx > 31) { ca = bx-31; m = 1; y++; }
    else if(bx > 31 && m == 1) { ca = bx-31; m++; }
    else if(m == 2 && bx > 29 && y == 2015) { ca = bx-29; m++; }
    else if(m == 2 && bx > 28 && y == 2016) { ca = bx-28; m++; }
    else if(bx > 31 && m == 3) { ca = bx-31; m++; }
    else if(bx > 30 && m == 4) { ca = bx-30; m++; }
    else if(bx > 31 && m == 5) { ca = bx-31; m++; }
    else if(bx > 30 && m == 6) { ca = bx-30; m++; }
    else if(bx > 31 && m == 7) { ca = bx-31; m++; }
    else if(bx > 31 && m == 8) { ca = bx-31; m++; }
    else if(bx > 30 && m == 9) { ca = bx-30; m++; }
    else if(bx > 31 && m == 10) { ca = bx-31; m++; }
    else if(bx > 30 && m == 11) { ca = bx-30; m++; }
    else if(bx > 31 && m == 12) { ca = bx-31; m++; }
    else ca = bx;
    PBanInfo[id][pBanDani] = ca;
    PBanInfo[id][pBanMesec] = m;
    PBanInfo[id][pBanGodina] = y;
   PlayerInfo[id][pBanovan] = 1;
   format(PlayerInfo[id][pBRazlog],40,razlog);
   SacuvajKorisnike(id);
    SAMF(-1, ""SCRVENA1"[BAN] "BELA"Admin: %s | Igrac: %s | Razlog: %s", GetName(playerid), GetName(id), razlog);
    format(string,sizeof(string),""SCRVENA1"[BAN] "BELA"Banovali ste igraca %s | Razlog: %s", GetName(id), razlog);
    SCM(playerid,-1,string);
    format(string,sizeof(string),""SCRVENA1"[BAN] "BELA"Banovani ste od strane admina %s | Razlog: %s", GetName(playerid), razlog);
    SCM(id,-1,string);
   format(string,sizeof(string), "BAN | Staff: %s | Igrac: %s | Razlog: %s", GetName(playerid), GetName(id), razlog);
   UpisiLog(LOG_PBAN, string);
   g_Ban(id);
    return 1;
}[/pawn]

Probaj ovako za to (valjda bi trebalo raditi, na brzinu sam uradio, ak ne napisi popravit cu)

a za ono D_KUCA komandu sto si radio



Loose indetation riješavaš tako što poravnaš linije.
heroin rap - Moskri u kuci, od sledece lajne glava ce mi puci

Sredio sam to hvala buraz
Jos ovo sad neznam kako sam se banovao na server kad idem da se logujem pise mi You are banned from this server ali to je na moj server kako da resim to

Citat: Robertoo_Salgadoo poslato Maj 07, 2017, 14:15:34 POSLE PODNE
Sredio sam to hvala buraz
Jos ovo sad neznam kako sam se banovao na server kad idem da se logujem pise mi You are banned from this server ali to je na moj server kako da resim to
Provjeri samp.ban fajl i folder banova i unbanuj se, ak nema, onda samo reconnect vrjtno ili rr ruter
heroin rap - Moskri u kuci, od sledece lajne glava ce mi puci