boban88 6 Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 Takže vitajte pod vplyvom tažkých sedatív som nevedel čo mám robiť lebo spať sa nedá tak som sa vrhol do pawna a vytvoril jednoduchú vec o ktorú som žiadal QWERa lebo sa mi nechcelo ale vysral sa namňa No dobre idem k veci ide o jednoduchý MultiLanguageSystém ktorý je robený formou STOCKu nieje to nič ťažké ale možno sa vám zíde. Ak niekto nevie čo je to ML System tak to je dosť zlé ide len o jednu vec takže nejak extra to opisovať nebudem vytvoíme jednu premennú ktorú setneme na 0 0 = SK 1 = CZ samozrejme nikto si nedá SK/CZ ML dajte si EN/DE/PL atd co len chcete new Jazyk[MAX_PLAYERS] = 0; Vytvorenie Názov premennej Velkost pola pre hracov idealne je si dat cislo ktore odpoveda slotom servera Nastavíme hodnotu na 0 teda SK Samotný STOCK stock MLM(playerid,farba,SK[],CZ[]) { switch(Jazyk[playerid]) { case 0:{SendClientMessage(playerid,farba,SK);} case 1:{SendClientMessage(playerid,farba,CZ);} } return 1; } Príklad použitia: if (strcmp("/nieco", cmdtext, true, 5) == 0) { MLM(playerid,ZELENA,"Vitajte","Vítejte"); return 1; } Odosle to spravu takto Vitajte mame setnutu 0 Prvá správa je SK druhá CZ nepomýlte sa a nastavovanie premennej pre hráča napríklad príkazom je potrebne do príkazu dat Jazyk[playerid] = 1; 1 alebo 0 to je už na vás tak to je vše EDIT: Trosku som sa stym este pohral lebo zrejme budete chciet aj dialogy v ML tak tu je stock na INPUT dialog na ostatne uz je to to iste to si uz budete dokazat aj samy upravit stock MLMDI(playerid,ID,DSI,t1[],pt1[],b1[],bu1[],t2[],pt2[],b2[],bu2[])//playerid dialogID style nadpis podtext buton1 buton2 { switch(Jazyk[playerid]) { case 0:{ShowPlayerDialog(playerid,ID,DSI,t1,pt1,b1,bu1);} case 1:{ShowPlayerDialog(playerid,ID,DSI,t2,pt2,b2,bu2);} } return 1; } priklad: MLMDI(playerid,5, DIALOG_STYLE_INPUT, "Dobry den", "Vitajte", "klik1", "klik2","Dobre jitro","Vitejte","klik1","klik2"); Link to comment Share on other sites More sharing options...
Mattsy 29 Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 Pekné a jednoduché ešte si mohol napísať že ak majú len dva jazyku tak je lepšie použiť bool ako v tomto prípade ale chválim :thumbup: Link to comment Share on other sites More sharing options...
Frajtr 8 Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 radši bych použil bool proměnu stejně pracuješ jen z 0/1 ale jinak jednoduché provedení není zbytečně složité a je to i celkem slušně popsáno za mě máš 1 podtrženo i když jsi mohl popsat samotnou funkci a její parametry ale to je jedno Link to comment Share on other sites More sharing options...
boban88 6 Odesláno: 13. Leden, 2012 Author Share Odesláno: 13. Leden, 2012 tak este nieco som pridal EDIT je v prvom prispevku a j bool na 2 staci ale tak pocitam ze ludia si daju aj 3-4 a to si uz dorobit vedia Link to comment Share on other sites More sharing options...
Guest Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 Spíš bych to řešil terárnou podmínkou #define MuLM(%0,%1,%2,%3,%4,%5,%6,%7,%8,%9,%10) ShowPlayerDialog(%0,%1,%2,(Z[%0]) ? %3 : %4,(Z[%0]) ? %5 : %6,(Z[%0]) ? %7 : %8,(Z[%0]) ? %9 : %10) Nezkoušel jsem ale mělo by to jít PS.: Proměnnou Z jsem použil jako boolean tj. logická proměnná Link to comment Share on other sites More sharing options...
tbx 7 Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 Podle mého názoru blbost dávat přímo SCM, lepší by bylo vracet správný string, tedy neco jako stock getMLText(playerid, lang1[], lang2[]) { switch(Jazyk[playerid]) { case 0:{return lang1;} case 1:{return lang2;} } } Správností syntaxe si nejsem absolutně jist, pawn už dlouho nedělám. Link to comment Share on other sites More sharing options...
DooM 93 Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 pekne promyslene :thumbup: Link to comment Share on other sites More sharing options...
Guest Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 vytvoril jednoduchú vec o ktorú som žiadal QWERa lebo sa mi nechcelo ale vysral sa namňa ehm... [1. 1. 2012 16:33:37] denis granec: ale nechec sa mi [1. 1. 2012 16:33:40] denis granec: *nechce [1. 1. 2012 16:33:42] boban88: halooo moderator ziadam o pomoc ? [1. 1. 2012 16:33:47] denis granec: je to preena a string a podmienka [1. 1. 2012 16:33:56] denis granec: no neviem kto bol globálny moderátor na pawno.cz [1. 1. 2012 16:34:05] boban88: presne bol [1. 1. 2012 16:34:14] boban88: ale ty si [1. 1. 2012 16:34:23] boban88: a si modik pawno sekcie tak neser [1. 1. 2012 16:34:47] boban88: tak najdi mi aspon henten mozno si to prerobim ak by sa mi chcelo [1. 1. 2012 16:37:30] denis granec: new Language[MAX_PLAYERS]; stock SCM(id,c,l[],ll[]){ if(Language[id] == 0) SendClientMessage(id,c,l); else SendClientMessage(id,c,ll); } [1. 1. 2012 16:38:10] boban88: wtf ? [1. 1. 2012 16:39:31] denis granec: a máš ML [1. 1. 2012 16:40:11] denis granec: a ešte stock SCMTA(c,l[],ll[]){ ForPlayers(i){ SCM(i,c,l,ll); } } [1. 1. 2012 16:40:20] denis granec: lenže ty asi nemáš funkciu "ForPlayers" [1. 1. 2012 16:40:28] denis granec: a tak sprav obyčjaný cyklus [1. 1. 2012 16:41:24] boban88: tvl ja som ztoho k***t serem nato nebude ML [1. 1. 2012 16:41:44] denis granec: preoč [1. 1. 2012 16:41:54] denis granec: iba SCM(playerid,-1,"Ahoj","Hi"); [1. 1. 2012 16:42:09] denis granec: alebo SCMTA(-1,"Ahok","Hi"); [1. 1. 2012 16:42:12] denis granec: a je to [1. 1. 2012 16:45:13] boban88: ach [1. 1. 2012 16:45:37] denis granec: ? [1. 1. 2012 16:46:17] boban88: hodis mi sem picovinu ked ti hovorim ze ani stock na playername si uz nwm poskladat [1. 1. 2012 16:47:11] denis granec: čo ? [1. 1. 2012 16:47:15] denis granec: hodil som ti sem úplný script omg [1. 1. 2012 16:47:56] boban88: jebem nato stačilo dať do nazov.pwn alebo nazov.inc new Jazyk[MAX_PLAYERS] = 0; tú hodnotu 0 nastaví aj bez nastavenia... ale kebyže dáš new Jazyk[MAX_PLAYERS] = 50; tak hodnotu 50 nastaví iba prvej premene (Jazyk[0]) ostatné premeny (for(new i = 1; i < MAX_PLAYERS;i++) printf("%d %d",i,Jazyk)) budú mať hodnotu 0 treba určenú hodnotu nastaviť všetkým premenám a to takto new Jazyk[MAX_PLAYERS] = {50,...}; // nastaví všetkým premenám hodnotu 50 Link to comment Share on other sites More sharing options...
Guest Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 Ještě SCM & SCMTA pomocí define #define SCM2(%0,%1,%2,%3) SendClientMessage(%0,%1,(Z[%0]) ? %2 : %3) #define SCMTA2(%0,%1,%2) SendClientMessageToAll(%0,(Z[%0]) ? %1 : %2) Link to comment Share on other sites More sharing options...
GAMELASTERツ 73 Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 urobil by som to inak... Dost blbe, lebo to posiela SendClientMessage, napr niekto potrebuje SendClientMessageToAll alebo na dialog, na poziadanie urobim TUT Link to comment Share on other sites More sharing options...
Guest Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 #define SCMTA2(%0,%1,%2) SendClientMessageToAll(%0,(Z[%0]) ? %1 : %2) blbosť... Link to comment Share on other sites More sharing options...
Guest Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 #define SCMTA2(%0,%1,%2) SendClientMessageToAll(%0,(Z[%0]) ? %1 : %2) blbosť... Důvod? Link to comment Share on other sites More sharing options...
Guest Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 "%0" je pri SCMTA farba... Link to comment Share on other sites More sharing options...
Guest Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 "%0" je pri SCMTA farba... Ano ... a co? Link to comment Share on other sites More sharing options...
Guest Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 Tak to poviem inak... SCMTA nemá parameter "playerid" Link to comment Share on other sites More sharing options...
Guest Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 Ah ... už vím co myslíš Link to comment Share on other sites More sharing options...
Guest Odesláno: 13. Leden, 2012 Share Odesláno: 13. Leden, 2012 takže cyklus a SCM... Link to comment Share on other sites More sharing options...
roland811 0 Odesláno: 8. Září, 2012 Share Odesláno: 8. Září, 2012 tento TUT nefunguje spravil som si ho error ani warning mi to nepíše ale proste keď dôjdem na server tak sa mi nič neobjaví čo som tam spravil aby to bolo na dva jazyky .. Link to comment Share on other sites More sharing options...
boban88 6 Odesláno: 8. Září, 2012 Author Share Odesláno: 8. Září, 2012 co presne ti nefunguje ukaz kod alebo nieco tut je bezchybny Link to comment Share on other sites More sharing options...
roland811 0 Odesláno: 8. Září, 2012 Share Odesláno: 8. Září, 2012 SPD(playerid,DIALOGID_MLSYSTEM,DIALOG_STYLE_MSGBOX,"Jazyk - Language","Vítaj na servéri !/nWelcome on this server !/nVyberte si aký jazyk chcete používať !/nYou must choose your language !","SVK","ENG"); if(dialogid == DIALOGID_MLSYSTEM) { if(response == 0) { Jazyk[playerid] = 1; } if(response == 1) { Jazyk[playerid] = 0; } return 1; } MLMDI(playerid,DIALOGID_MLSYSTEM2,DIALOG_STYLE_PASSWORD, "Registrácia","Vítaj na servéri ! /nZadaj svoje nové heslo !","Registrovať","Odpojiť","Register","Welcom on this server/nPress your new password !","Register","Quit"); toto je môj kód ktorý nepíše žiadny error ani warning ale proste to nejde Link to comment Share on other sites More sharing options...
TGC_Łukáš 4 Odesláno: 8. Září, 2012 Share Odesláno: 8. Září, 2012 Fakt pekný TuT. Určite využijem Link to comment Share on other sites More sharing options...
boban88 6 Odesláno: 8. Září, 2012 Author Share Odesláno: 8. Září, 2012 najprv je response 1 ptm 0 EDIT: v jednom scripte som to chalanovi robil takto a ide to bez problemov if(dialogid == LANGUAGE) { if(response == 1) { Language[playerid] = 0; SendClientMessage(playerid,ZELENA,"You choose the english language."); } if(response == 0) { Language[playerid] = 1; SendClientMessage(playerid,ZELENA,"Zvolil si si slovenský jazyk."); } } Link to comment Share on other sites More sharing options...
roland811 0 Odesláno: 8. Září, 2012 Share Odesláno: 8. Září, 2012 public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) { if(dialogid == 2) { if(response == 1) { if(zamestnani[playerid] != Taxikar) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako taxikár !"); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Taxikar; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný."); } } return 1; } if(dialogid == 100) //ID Dialógu { if(response == 1) //Tlačidlo 1 (Ľavé tlačidlo) { if(listitem == 0) //Prvá položka v dialógu { ShowPlayerDialogEx(playerid,101,DIALOG_STYLE_LIST,"Výber skínov","7\n142\n182\n220","Vybrať","koniec"); } else if(listitem == 1) //Druhá položka v dialógu { SendClientMessage(playerid,0xFFFFFFFF,"Stlačil si na riadok č.2"); } else if(listitem == 2) //Tretia položka v dialógu { SendClientMessage(playerid,0xFFFFFFFF,"Stlačil si na riadok č.3"); } } return 1; } if(dialogid == 101) //ID Dialógu { if(response == 1) //Tlačidlo 1 (Ľavé tlačidlo) { if(listitem == 0) //Prvá položka v dialógu { SetPlayerSkin(playerid, 7); } else if(listitem == 1) //Druhá položka v dialógu { SetPlayerSkin(playerid, 142); } else if(listitem == 2) //Tretia položka v dialógu { SetPlayerSkin(playerid, 182); } else if(listitem == 3) //Tretia položka v dialógu { SetPlayerSkin(playerid, 220); } } return 1; } if(dialogid == 3) { if(response == 1) { if(zamestnani[playerid] != Policajt) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako policajt."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Policajt; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !."); } } return 1; } if(dialogid == 4) { if(response == 1) { if(zamestnani[playerid] != SWAT) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako SWAT."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = SWAT; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 5) { if(response == 1) { if(zamestnani[playerid] != FBI) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako FBI."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = FBI; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 6) { if(response == 1) { if(zamestnani[playerid] != Pravnik) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako právnik."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Pravnik; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 7) { if(response == 1) { if(zamestnani[playerid] != Prostitutka) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako prostitútku."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Prostitutka; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 8) { if(response == 1) { if(zamestnani[playerid] != Novinar) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako novinár."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Novinar; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 9) { if(response == 1) { if(zamestnani[playerid] != Stavbar) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako stavbár."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Stavbar; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 10) { if(response == 1) { if(zamestnani[playerid] != Namornik) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako námorník."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Namornik; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 11) { if(response == 1) { if(zamestnani[playerid] != Smetiar) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako smetiar."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Smetiar; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 12) { if(response == 1) { if(zamestnani[playerid] != SECURITY) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako SECURITY."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = SECURITY; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 13) { if(response == 1) { if(zamestnani[playerid] != Kamionista) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako kamionista."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Kamionista; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 14) { if(response == 1) { if(zamestnani[playerid] != Transporter) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako transportér."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Transporter; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 15) { if(response == 1) { if(zamestnani[playerid] != Odtahovka) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako odťahovka."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Odtahovka; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 16) { if(response == 1) { if(zamestnani[playerid] != Automechanik) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako automechanik."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Automechanik; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 17) { if(response == 1) { if(zamestnani[playerid] != Hasic) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako hasič."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Hasic; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 18) { if(response == 1) { if(zamestnani[playerid] != Doktor) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako doktor."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Doktor; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 19) { if(response == 1) { if(zamestnani[playerid] != Pilot) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako pilot."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Pilot; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 20) { if(response == 1) { if(zamestnani[playerid] != Mafian) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako mafián."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Mafian; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 21) { if(response == 1) { if(zamestnani[playerid] != Terorista) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako terorista."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Terorista; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 22) { if(response == 1) { if(zamestnani[playerid] != Vojak) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako vojak."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Vojak; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == 23) { if(response == 1) { if(zamestnani[playerid] != Dozorca) { SCM(playerid, 0xFFFFFFF, "[POVOLANIE] Zamestnal si sa ako dozorca."); GivePlayerWeapon(playerid,22,100); zamestnani[playerid] = Dozorca; SetPlayerSkin(playerid, 171); } else { SCM(playerid,0xFFFFFFF,"[POVOLANIE] Tu si už zamestnaný !"); } } return 1; } if(dialogid == DIALOGID_REGISTER) { if(response == 0) { SCM(playerid,0xFFFFFFFF,"SERVER : Odpojil si sa zo servéru !"); Kick(playerid); } if(response == 1) { { if(!strlen(inputtext)) return SPD(playerid,DIALOGID_REGISTER,DIALOG_STYLE_PASSWORD,"Registrácia","Vítaj na servéri ! /nZadaj svoje nové heslo !","Registrovať","Odpojiť"); else if(udb_Create(PlayerName(playerid),inputtext)) { SpawnPlayer(playerid); SCM(playerid,0xFFFFFFFF,"Úspešne si sa zaregistroval !"); GivePlayerMoney(playerid,500); login[playerid]=true; zamestnani[playerid] = 0; AdminLevel[playerid] = 0; wanted[playerid] = 0; } } } return 1; } if(dialogid == DIALOGID_LOGIN) { if(response == 0) { SCM(playerid,0xFFFFFFFF,"Odpojil si sa zo servéru !"); Kick(playerid); } if(response == 1) { if(!strlen(inputtext)) return SPD(playerid,DIALOGID_LOGIN,DIALOG_STYLE_PASSWORD,"Prihlasovanie","Vítaj na servéri : %s /nZadaj svoje heslo !","Prihlásiť","Odpojiť"); else if(udb_CheckLogin(PlayerName(playerid),inputtext)) { SCM(playerid,0xFFFFFFFF,"Úspešne si sa prihlásil !"); SpawnPlayer(playerid); GivePlayerMoney(playerid,dUserINT(PlayerName(playerid)).("Peniaze")-GetPlayerMoney(playerid)); SetPlayerSkin(playerid,dUserINT(PlayerName(playerid)).("Skin")-GetPlayerSkin(playerid)); } else { SPD(playerid,DIALOGID_MLSYSTEM,DIALOG_STYLE_MSGBOX,"Jazyk - Language","Vítaj na servéri !/nWelcome on this server !/nVyberte si aký jazyk chcete používať !/nYou must choose your language !","SVK","ENG"); f(dialogid == DIALOGID_MLSYSTEM) { if(response == 0) { Jazyk[playerid] = 1; } if(response == 1) { Jazyk[playerid] = 0; } return 1; } MLMDI(playerid,DIALOGID_MLSYSTEM2,DIALOG_STYLE_PASSWORD, "Registrácia","Vítaj na servéri : %s /nZadaj svoje nové heslo !","Registrovať","Odpojiť","Register","Welcom on this server/nPress your new password !","Register","Left"); // MLMDI(playerid,5, DIALOG_STYLE_INPUT, "Dobry den", "Vitajte", "klik1", "klik2","Dobre jitro","Vitejte","klik1","klik2"); SPD(playerid,DIALOGID_BADLOGIN,DIALOG_STYLE_MSGBOX,"Zlé heslo","Zadal si nesprávne heslo od účtu !","Znova","Odpojiť"); PassKick[playerid] ++; } if(PassKick[playerid] == 3) { new str[128]; format(str,128,"[ SERVER ] Hráč %s bol vyhodený za zle zadané heslo 3/3 !",PlayerName(playerid)); SendClientMessageToAll(COLOR_RED,str); Kick(playerid); } } return 1; } if(dialogid == DIALOGID_BADLOGIN) { if(response == 0) { SCM(playerid,COLOR_RED,"[ SERVER] Odpojil si sa zo serveru !"); Kick(playerid); } if(response == 1) { SPD(playerid,DIALOGID_LOGIN,DIALOG_STYLE_PASSWORD,"Prihlásenie","Prosím zadaj znovu svoje heslo od tvojho účtu !","Prihlásenie","Odhlásiť"); } } return 1; } Link to comment Share on other sites More sharing options...
boban88 6 Odesláno: 8. Září, 2012 Author Share Odesláno: 8. Září, 2012 lol tie returny daj do prdele ma tam byt iba jeden ktory ukoncuje cely public Link to comment Share on other sites More sharing options...
roland811 0 Odesláno: 8. Září, 2012 Share Odesláno: 8. Září, 2012 aha no ok :-D ja som ich tam cpal jak ujetý :-D Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now