loose indentation

Započeo Kirali, Avgust 22, 2019, 01:42:43 PRE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Problem(error/warning): Nez sta mi nevalja ako neko moze pomoci ja jednostavno nevidim u cemu je problem
Deo skripte: [pawn]//stats novi
forward ShowStats(playerid, targetid);

public ShowStats(playerid,targetid)
{
    if(IsPlayerConnected(playerid)&&IsPlayerConnected(targetid))
   {
      new cash = GetPlayerMoney(targetid);
      new atext[20];
      if(PlayerInfo[targetid][xPol] == 1) { atext = "Musko"; }
      else if(PlayerInfo[targetid][xPol] == 2) { atext = "Zensko"; }
        new otext[20];
      if(PlayerInfo[targetid][xDrzava] == 1) { otext = "Makedonija"; }
      else if(PlayerInfo[targetid][xDrzava] == 2) { otext = "Hrvatska"; }
      else if(PlayerInfo[targetid][xDrzava] == 3) { otext = "Srbija"; }
      else if(PlayerInfo[targetid][xDrzava] == 4) { otext = "Crne_Gore"; }
        else if(PlayerInfo[targetid][xDrzava] == 5) { otext = "Bosna i Hercegovina"; }
        else if(PlayerInfo[targetid][xDrzava] == 6) { otext = "Ostalo"; }
      new ttext[64];
      if(PlayerInfo[targetid][xClan] == 1 || PlayerInfo[targetid][xLider] == 1) { ttext = "Policija"; }
      else if(PlayerInfo[targetid][xClan] == 2 || PlayerInfo[targetid][xLider] == 2) { ttext = "ATJ"; }
      else if(PlayerInfo[targetid][xClan] == 3 || PlayerInfo[targetid][xLider] == 3) { ttext = "Hitna Pomoc"; }
      else if(PlayerInfo[targetid][xClan] == 4 || PlayerInfo[targetid][xLider] == 4) { ttext = "CNN"; }
      else if(PlayerInfo[targetid][xClan] == 5 || PlayerInfo[targetid][xLider] == 5) { ttext = "Groove Street Families"; }
      else if(PlayerInfo[targetid][xClan] == 6 || PlayerInfo[targetid][xLider] == 6) { ttext = "Ballas"; }
      else if(PlayerInfo[targetid][xClan] == 7 || PlayerInfo[targetid][xLider] == 7) { ttext = "La Cosa Nostra"; }
      else if(PlayerInfo[targetid][xClan] == 8 || PlayerInfo[targetid][xLider] == 8) { ttext = "Yakuza"; }
      else if(PlayerInfo[targetid][xClan] == 9 || PlayerInfo[targetid][xLider] == 9) { ttext = "Mara Salvatrucha 13"; }
        else if(PlayerInfo[targetid][xClan] == 10 || PlayerInfo[targetid][xLider] == 10) { ttext = "Los Sureños"; }
      else if(gTeam[targetid] == 3 || gTeam[targetid] == 4) { ttext = "None"; }
      else
      { ttext = "Civil"; }
      new ftext[30];
      if(PlayerInfo[targetid][xClan] == 1 || PlayerInfo[targetid][xLider] == 1)
     { ftext = "Policija"; }
       if(PlayerInfo[targetid][xClan] == 2 || PlayerInfo[targetid][xLider] == 2)
     { ftext = "ATJ"; }
     else if(PlayerInfo[targetid][xClan] == 3 || PlayerInfo[targetid][xLider] == 3)
     { ftext = "Hitna Pomoc"; }
     else if(PlayerInfo[targetid][xClan] == 4 || PlayerInfo[targetid][xLider] == 4)
     { ftext = "CNN"; }
     else if(PlayerInfo[targetid][xClan] == 5 || PlayerInfo[targetid][xLider] == 5)
     { ftext = "Groove Street Families"; }
     else if(PlayerInfo[targetid][xClan] == 6 || PlayerInfo[targetid][xLider] == 6)
     { ftext = "Ballas"; }
     else if(PlayerInfo[targetid][xClan] == 7 || PlayerInfo[targetid][xLider] == 7)
     { ftext = "La Cosa Nostra"; }
     else if(PlayerInfo[targetid][xClan] == 8 || PlayerInfo[targetid][xLider] == 8)
     { ftext = "Yakuza"; }
     else if(PlayerInfo[targetid][xClan] == 9 || PlayerInfo[targetid][xLider] == 9)
     { ftext = "Mara Salvatrucha 13"; }
     else if(PlayerInfo[targetid][xClan] == 10 || PlayerInfo[targetid][xLider] == 10)
     { ftext = "Los Sureños"; }
     else
     { ftext = "Civil"; }
     new rtext[64];
      if(gTeam[targetid] == 5)
      {
      if(PlayerInfo[targetid][xRank] == 1) { rtext = "Outsider"; }
        else if(PlayerInfo[targetid][xRank] == 2) { rtext = "Associate"; }
     else if(PlayerInfo[targetid][xRank] == 3) { rtext = "Soldier"; }
        else if(PlayerInfo[targetid][xRank] == 4) { rtext = "Capo"; }
        else if(PlayerInfo[targetid][xRank] == 5) { rtext = "Underboss"; }
      else if(PlayerInfo[targetid][xRank] == 6) { rtext = "Godfather"; }
      else { rtext = "Outsider"; }
      }
     else if(PlayerInfo[targetid][xClan] == 1 || PlayerInfo[targetid][xLider] == 1)//Policija
     {
         if(PlayerInfo[targetid][xRank] == 1) { rtext = "Policajac"; }
        else if(PlayerInfo[targetid][xRank] == 2) { rtext = "Stariji policajac"; }
        else if(PlayerInfo[targetid][xRank] == 3) { rtext = "Inspektor"; }
        else if(PlayerInfo[targetid][xRank] == 4) { rtext = "Visi inspektor"; }
        else if(PlayerInfo[targetid][xRank] == 5) { rtext = "Zamjenik sefa"; }
         else if(PlayerInfo[targetid][xRank] == 6) { rtext = "Sef policije"; }
        else { rtext = "Policajac"; }
     }
     else if(PlayerInfo[targetid][xClan] == 2 || PlayerInfo[targetid][xLider] == 2)//ATJ
     {
         if(PlayerInfo[targetid][xRank] == 1) { rtext = "Agent"; }
        else if(PlayerInfo[targetid][xRank] == 2) { rtext = "Specijalni agent"; }
        else if(PlayerInfo[targetid][xRank] == 3) { rtext = "Specijalni agent"; }
        else if(PlayerInfo[targetid][xRank] == 4) { rtext = "Stariji agent"; }
        else if(PlayerInfo[targetid][xRank] == 5) { rtext = "Zamenik sefa"; }
         else if(PlayerInfo[targetid][xRank] == 6) { rtext = "Sef ATJ-a"; }
        else { rtext = "Agent"; }
     }
     else if(PlayerInfo[targetid][xClan] == 3 || PlayerInfo[targetid][xLider] == 3)//Hitna Pomoc
     {
         if(PlayerInfo[targetid][xRank] == 1) { rtext = "Apsolvent"; }
        else if(PlayerInfo[targetid][xRank] == 2) { rtext = "Operater sale"; }
        else if(PlayerInfo[targetid][xRank] == 3) { rtext = "Doktor"; }
        else if(PlayerInfo[targetid][xRank] == 4) { rtext = "Glavni Doktor"; }
        else if(PlayerInfo[targetid][xRank] == 5) { rtext = "Zamjenik direktora"; }
         else if(PlayerInfo[targetid][xRank] == 6) { rtext = "Direktor"; }
        else { rtext = "Apsolvent"; }
     }
     else if(PlayerInfo[targetid][xClan] == 4 || PlayerInfo[targetid][xLider] == 4)//CNN ili Novinari
     {
         if(PlayerInfo[targetid][xClan] == 1) { rtext = "Novinar"; }
        else if(PlayerInfo[targetid][xClan] == 2) { rtext = "Reporter"; }
        else if(PlayerInfo[targetid][xClan] == 3) { rtext = "Urednik"; }
        else if(PlayerInfo[targetid][xClan] == 4) { rtext = "Glavni Urednik"; }
        else if(PlayerInfo[targetid][xClan] == 5) { rtext = "Zamjenik Direktora"; }
         else if(PlayerInfo[targetid][xClan] == 6) { rtext = "Direktor"; }
        else { rtext = "Paramedic"; }
     }
     else if(PlayerInfo[targetid][xClan] == 5 || PlayerInfo[targetid][xLider] == 5)//GFS
     {
         if(PlayerInfo[targetid][xRank] == 1) { rtext = "Soulja"; }
         else if(PlayerInfo[targetid][xRank] == 2) { rtext = "Gangsta"; }
        else if(PlayerInfo[targetid][xRank] == 3) { rtext = "Thug"; }
        else if(PlayerInfo[targetid][xRank] == 4) { rtext = "Homie"; }
        else if(PlayerInfo[targetid][xRank] == 5) { rtext = "O.G"; }
        else if(PlayerInfo[targetid][xRank] == 6) { rtext = "Boss"; }
        else { rtext = "Soulja"; }
     }
     else if(PlayerInfo[targetid][xClan] == 6 || PlayerInfo[targetid][xLider] == 6)//Ballas
     {
         if(PlayerInfo[targetid][xRank] == 1) { rtext = "Mobster"; }
        else if(PlayerInfo[targetid][xRank] == 2) { rtext = "Junkie"; }
        else if(PlayerInfo[targetid][xRank] == 3) { rtext = "Smuggler"; }
        else if(PlayerInfo[targetid][xRank] == 4) { rtext = "Road capitain"; }
        else if(PlayerInfo[targetid][xRank] == 5) { rtext = "Main biker"; }
        else if(PlayerInfo[targetid][xRank] == 6) { rtext = "Boss"; }
        else { rtext = "Outsider"; }
     }
     else if(PlayerInfo[targetid][xClan] == 7 || PlayerInfo[targetid][xLider] == 7)//LCN
     {
         if(PlayerInfo[targetid][xRank] == 1) { rtext = "Associate"; }
        else if(PlayerInfo[targetid][xRank] == 2) { rtext = "Caporegime"; }
        else if(PlayerInfo[targetid][xRank] == 3) { rtext = "Head capo"; }
        else if(PlayerInfo[targetid][xRank] == 4) { rtext = "Consiglieri"; }
        else if(PlayerInfo[targetid][xRank] == 5) { rtext = "Front Boss"; }
        else if(PlayerInfo[targetid][xRank] == 6) { rtext = "Head Boss"; }
        else { rtext = "Pripravnik"; }
     }
     else if(PlayerInfo[targetid][xClan] == 8 || PlayerInfo[targetid][xLider] == 8)//YAKUZA
     {
         if(PlayerInfo[targetid][xRank] == 1) { rtext = "Wakashu"; }
        else if(PlayerInfo[targetid][xRank] == 2) { rtext = "Shin"; }
        else if(PlayerInfo[targetid][xRank] == 3) { rtext = "Shatei"; }
        else if(PlayerInfo[targetid][xRank] == 4) { rtext = "Shateigashira"; }
        else if(PlayerInfo[targetid][xRank] == 5) { rtext = "Wakagashira"; }
         else if(PlayerInfo[targetid][xRank] == 6) { rtext = "Boss"; }
        else { rtext = "Wakashu"; }
     }
     else if(PlayerInfo[targetid][xClan] == 9 || PlayerInfo[targetid][xLider] == 9)//MS13
     {
         if(PlayerInfo[targetid][xRank] == 1) { rtext = "Shestiorka"; }
        else if(PlayerInfo[targetid][xRank] == 2) { rtext = "Patsani"; }
        else if(PlayerInfo[targetid][xRank] == 3) { rtext = "Byki"; }
        else if(PlayerInfo[targetid][xRank] == 4) { rtext = "Capo"; }
        else if(PlayerInfo[targetid][xRank] == 5) { rtext = "UnderBoss"; }
         else if(PlayerInfo[targetid][xRank] == 6) { rtext = "Boss"; }
        else { rtext = "Shestiorka"; }
     }
     else if(PlayerInfo[targetid][xClan] == 10 || PlayerInfo[targetid][xLider] == 10)//LS
     {
         if(PlayerInfo[targetid][xRank] == 1) { rtext = "Guero"; }
        else if(PlayerInfo[targetid][xRank] == 2) { rtext = "Cholo"; }
        else if(PlayerInfo[targetid][xRank] == 3) { rtext = "Buscavidas"; }
        else if(PlayerInfo[targetid][xRank] == 4) { rtext = "Soldado"; }
        else if(PlayerInfo[targetid][xRank] == 5) { rtext = "Vato del Jefe"; }
         else if(PlayerInfo[targetid][xRank] == 6) { rtext = "Jefe"; }
        else { rtext = "Guero"; }
     }
     else
     {
     rtext = "Nijedan";
     }
        new jtext[64];
        if(PlayerInfo[targetid][xPosao] == 1) { jtext = "Kosac Trave"; }
        else if(PlayerInfo[targetid][xPosao] == 2) { jtext = "Gradjevinar"; }
        else if(PlayerInfo[targetid][xPosao] == 3) { jtext = "Rudar"; }
        else if(PlayerInfo[targetid][xPosao] == 4) { jtext = "Komunalac"; }
        else if(PlayerInfo[targetid][xPosao] == 5) { jtext = "Tempo Dostava"; }
        else if(PlayerInfo[targetid][xPosao] == 6) { jtext = "Pilot"; }
        else if(PlayerInfo[targetid][xPosao] == 7) { jtext = "Bus Vozac"; }
        else if(PlayerInfo[targetid][xPosao] == 8) { jtext = "Mehanicar"; }
        else if(PlayerInfo[targetid][xPosao] == 9) { jtext = "Farmer"; }
        else if(PlayerInfo[targetid][xPosao] == 10) { jtext = "Pizza"; }
        else if(PlayerInfo[targetid][xPosao] == 11) { jtext = "Taxi"; }
      else { jtext = "Nezaposlen"; }
      
        new drank[20];
        if(PlayerInfo[targetid][xVIPLevel] == 1) { drank = "VIP Level 1"; }
        else if(PlayerInfo[targetid][xVIPLevel] == 2) { drank = "VIP Level 2"; }
        else if(PlayerInfo[targetid][xVIPLevel] == 3) { drank = "VIP Level 3"; }
        else if(PlayerInfo[targetid][xVIPLevel] == 4) { drank = "VIP Level 4"; }
        else if(PlayerInfo[targetid][xVIPLevel] == 5) { drank = "VIP Level 5"; }
        else { drank = "Nijedan"; }

     new age = PlayerInfo[targetid][xGodine];
     new ptime = PlayerInfo[targetid][xOnlineSati];
     new lotto = PlayerInfo[targetid][xLottoNumber];
     new drugs = PlayerInfo[targetid][xDrug];
     new mats = PlayerInfo[targetid][xMaterijali];
     new wanted = GetPlayerWantedLevel(playerid);
     new level = PlayerInfo[targetid][xLevel];
     new exp = PlayerInfo[targetid][xRespekt];
     new pnumber = PlayerInfo[targetid][xBrojTelefona];
     new mobkredit = PlayerInfo[targetid][xTelefonBon];
     new account = PlayerInfo[targetid][xBRacun];
     new satiorg = PlayerInfo[targetid][xOrgUgovor];
     new iskustvo = (PlayerInfo[playerid][xLevel] * 4)+4;
     new housekey = PlayerInfo[targetid][xProperty];
     new bizkey = PlayerInfo[targetid][xFirmaID];
     new carkey = PlayerInfo[targetid][xVoziloID];
     new carkey2 = PlayerInfo[targetid][xVoziloID];
     new carkey3 = PlayerInfo[targetid][xVoziloID];
     new rpp = PlayerInfo[targetid][xRPPoen];
     new check = PlayerInfo[targetid][xPlatniRacun];
     new zlato = PlayerInfo[targetid][xZlato];
     new ticket = PlayerInfo[targetid][xPDStatsTicket];
     new name[MAX_PLAYER_NAME];
     GetPlayerName(targetid, name, sizeof(name));
     new Float:px,Float:py,Float:pz;
     GetPlayerPos(targetid, px, py, pz);
     new coordsstring1[390];
      new coordsstring2[400];
      new coordsstring3[400];
      new coordsstring4[380];
      new stats[1800];
      format(coordsstring1, sizeof(coordsstring1),"{0090ff}--------------------------------------------------------------------\n{FFFFFF}Licna karta\n{0090ff}Ime i Prezime:{FFFFFF}[%s]\n{0090ff}Pol:{FFFFFF}[%s]\n{0090ff}Starost:{FFFFFF}[%d]\n{0090ff}Drzava:{FFFFFF}[%s]\n\n\nPodaci sa servera\n{0090ff}Level:{FFFFFF}[%d]\n{0090ff}Sati igranja:{FFFFFF}[%d]\n{0090ff}Respekti:{FFFFFF}[%d/%d]\n{0090ff}Donatorski rank:{FFFFFF}[%s]",name,atext,age,otext,level,ptime,exp,iskustvo,drank);
      format(coordsstring2, sizeof(coordsstring2),"\n{0090ff}Broj telefona:{FFFFFF}[%d]\n{0090ff}Posao:{FFFFFF}[%s]\n{0090ff}Organizacija:{FFFFFF}[%s]\n{0090ff}Rank:{FFFFFF}[%s]\n{0090ff}Radni staz:{FFFFFF}[%d]\n{0090ff}Lotto broj:{FFFFFF}[%d]\n{0090ff}Wanted level:{FFFFFF}[%d]\n{0090ff}RP Poeni:{FFFFFF}[%d]\n{0090ff}Kredit:{FFFFFF}[%d]",pnumber,jtext,xClan,rtext,satiorg,lotto,wanted,rpp,mobkredit);
      format(coordsstring3, sizeof(coordsstring3),"\n{0090ff}Ticketi:{FFFFFF}[%d]\n\n\nNovcano stanje\n{0090ff}Plata:{FFFFFF}[%d]\n{0090ff}Novac u dzepu:{FFFFFF}[%d]\n{0090ff}Novac u banci:{FFFFFF}[%d]\n{0090ff}Zlato:{FFFFFF}[%d]\n\n\nTorba\n{0090ff}Droga:{FFFFFF}[%d]\n{0090ff}Materijali:{FFFFFF}[%d]\n\n\nImovina\n{0090ff}Kuca:{FFFFFF}[%d]  {0090ff}Biznis:{FFFFFF}[%d]",ticket,check,cash,account,zlato,drugs,mats,housekey,bizkey);
      format(coordsstring4, sizeof(coordsstring4),"\n{0090ff}Veh 1:{FFFFFF}[%d]  {0090ff}Veh 2:{FFFFFF}[%d]  {0090ff}Veh 3:{FFFFFF}[%d]\n{0090ff}--------------------------------------------------------------------", carkey,carkey2,carkey3);
      format(stats, sizeof(stats),"%s%s%s%s",coordsstring1,coordsstring2,coordsstring3,coordsstring4);
      ShowPlayerDialog(playerid, sizeof(stats), DIALOG_STYLE_MSGBOX, "  {0073AA}Balkan Legacy RolePlay", stats , "U redu", "");
 
[/pawn]
pawno: [pawn]D:\server\mod\gamemodes\lrp.pwn(93976) : warning 217: loose indentation
D:\server\mod\gamemodes\lrp.pwn(93979) : warning 217: loose indentation
D:\server\mod\gamemodes\lrp.pwn(93981) : warning 217: loose indentation
D:\server\mod\gamemodes\lrp.pwn(93999) : warning 217: loose indentation
D:\server\mod\gamemodes\lrp.pwn(94114) : warning 217: loose indentation
D:\server\mod\gamemodes\lrp.pwn(94128) : warning 217: loose indentation
D:\server\mod\gamemodes\lrp.pwn(94136) : warning 217: loose indentation
Pawn compiler 3.2.3664           Copyright (c) 1997-2006, ITB CompuPhase

Header size:          30484 bytes
Code size:          6271068 bytes
Data size:         40499488 bytes
Stack/heap size:      16384 bytes; estimated max. usage: unknown, due to recursion
Total requirements:46817424 bytes

7 Warnings.[/pawn]
Poslednja Izmena: Avgust 22, 2019, 02:16:14 PRE PODNE od Bašovski

Mora sve da ti bude ravno
primer ne sme da bude ovako

              new coordsstring1[390];
new coordsstring2[400];

Znaci da je poravnano


new coordsstring1[390];
new coordsstring2[400];

Lupi tab na linijama koje nisu poravnane, preporuka koristi Sublime 3 jer imas reindent i bolja mogucnost pisanja koda :)

One And Only
Old Member
Since AVGUST 2013. :)
GAME OVER - SCRIPTING
SINCE 2009 - 2020