AvestX 5 Odesláno: 7. Listopad, 2009 Share Odesláno: 7. Listopad, 2009 Zdar, takže Mizi udělal registraci přes dialog, to tu bylo před tim, ale nyní jsem udělal vlastní 100% Funkční registraci přes dialog ! Takže, nahoru do modu: #include // Má každý #include // Pokud nemáte stahněte www.pawno.cz/include #include // Pokud nemáte stahněte www.pawno.cz/include nyní pokud nemáte definaci DCMD tak nahoru: #define dcmd(%1,%2,%3) if ((strcmp((%3)[1], #%1, true, (%2)) == 0) && ((((%3)[(%2) + 1] == 0) && (dcmd_%1(playerid, "")))||(((%3)[(%2) + 1] == 32) && (dcmd_%1(playerid, (%3)[(%2) + 2]))))) return 1 Nyní si nadefinujeme barvu pro ty co to chtějí skusit: #define BARVA 0xEFEFF7AA // Pak si můžete změnit ! a pod to new PLAYERLIST_authed[MAX_PLAYERS]; pod to znovu pokud nemáte vložte: stock SystemMsg(playerid,msg[]) { if ((IsPlayerConnected(playerid))&&(strlen(msg)>0)) { SendClientMessage(playerid,COLOR_SYSTEM,msg); } stock PlayerName(playerid) { new name[255]; GetPlayerName(playerid, name, 255); return name; } return 1; } Nyní do OnPlayerConnect: PLAYERLIST_authed[playerid] = false; if (!PLAYERLIST_authed[playerid]) { if(udb_Exists(PlayerName(playerid))) // Když jeho ucet existuje { ShowPlayerDialog(playerid,2,DIALOG_STYLE_INPUT,"Registrace","Vítej zpět !\nNapiš heslo !","Použít","Odpojit"); // Když existuje zobrazíme dialog } else { ShowPlayerDialog(playerid,1,DIALOG_STYLE_INPUT,"Registrace","Vítej !\nZaregistruj se, napiš heslo","Použít","Odpojit"); // Když neexistuje zobrazíme dialog } } Nyní OnPlayerDisconnect if (PLAYERLIST_authed[playerid]) // Kdyz je prihlaseny { dUserSetINT(PlayerName(playerid)).("money",GetPlayerMoney(playerid)); // Ulozime penize } PLAYERLIST_authed[playerid] = false; // Dame ho ze neni odpojen A nyní OnDialogResponse if(dialogid == 1) { if(response == 1) { if (udb_Exists(PlayerName(playerid))) return ShowPlayerDialog(playerid,2,DIALOG_STYLE_INPUT,"Registrace","Přihlaš se ! napiš heslo","Použít","Odpojit"); if (strlen(inputtext)==0) return ShowPlayerDialog(playerid,1,DIALOG_STYLE_INPUT,"Registrace","Musíš napsat heslo !","Použít","Odpojit"); if (udb_Create(PlayerName(playerid),inputtext)) return ShowPlayerDialog(playerid,2,DIALOG_STYLE_INPUT,"Registrace","Víborně, nyní napiš znovu heslo !","Použít","Odpojit"); } if(response == 2) { Kick(playerid); } } //============================================================================== if(dialogid == 2) { if(response == 1) { if (strlen(inputtext)==0) return ShowPlayerDialog(playerid,2,DIALOG_STYLE_INPUT,"Registrace","Musíš zadat heslo !\nNapiš heslo !","Použít","Odpojit"); if (udb_CheckLogin(PlayerName(playerid),inputtext)) { GivePlayerMoney(playerid,dUserINT(PlayerName(playerid)).("money")-GetPlayerMoney(playerid)); PLAYERLIST_authed[playerid] = true; return SendClientMessage(playerid, BARVA, "Úspěšně přihlášen !"); } return ShowPlayerDialog(playerid,2,DIALOG_STYLE_INPUT,"Registrace","Nespravne heslo !","Použít","Odpojit"); } if(response == 2) { Kick(playerid); } } Všechno není popsaný pac me to nebaví ale kdyz tomu nerozumite tak si to nedělejte ... je to predelana normal registracka od Daffyho .. Link to comment Share on other sites More sharing options...
zpatecnik 0 Odesláno: 7. Listopad, 2009 Share Odesláno: 7. Listopad, 2009 Vypadá to dobře :thumbup: To se bude urcite hodne lidem hodit (me ne ja uz to mam ) Link to comment Share on other sites More sharing options...
AvestX 5 Odesláno: 7. Listopad, 2009 Author Share Odesláno: 7. Listopad, 2009 Nj, já mam sice vlastní, ale tohle mi hodně pomohlo, tak sem to tem dal. Link to comment Share on other sites More sharing options...
Guest Calebs Odesláno: 7. Listopad, 2009 Share Odesláno: 7. Listopad, 2009 Prosím tě mohl bys mi poslat tvůj inc dini?? mě to píše že mám v tomto inc errory Link to comment Share on other sites More sharing options...
Marwin37 5 Odesláno: 8. Listopad, 2009 Share Odesláno: 8. Listopad, 2009 ffredyka je lepší a kratší a je pře dini Link to comment Share on other sites More sharing options...
StarsCream_Cze 1 Odesláno: 8. Listopad, 2009 Share Odesláno: 8. Listopad, 2009 má tam hodně děr a celkově je to zbytečně dlouhé... nejlepší je udělat si vlastní Link to comment Share on other sites More sharing options...
AvestX 5 Odesláno: 8. Listopad, 2009 Author Share Odesláno: 8. Listopad, 2009 tjn, ale pro takoví co neví Link to comment Share on other sites More sharing options...
Vidie 5 Odesláno: 8. Listopad, 2009 Share Odesláno: 8. Listopad, 2009 je to good ale trochu mi to erroruje. Link to comment Share on other sites More sharing options...
Guest 3X1T3R Odesláno: 8. Listopad, 2009 Share Odesláno: 8. Listopad, 2009 je to good ale trochu mi to erroruje. aj mne ale take sproste errory že ..... "lol" no comment Link to comment Share on other sites More sharing options...
Vidie 5 Odesláno: 8. Listopad, 2009 Share Odesláno: 8. Listopad, 2009 jasne omfg ze nemam nadefinovane Informace a přitom mam Link to comment Share on other sites More sharing options...
Guest 3X1T3R Odesláno: 8. Listopad, 2009 Share Odesláno: 8. Listopad, 2009 jasne omfg ze nemam nadefinovane Informace a přitom mam šak to je quality by ten čo sem da chybne "lol" Link to comment Share on other sites More sharing options...
Majitel ffredyk 167 Odesláno: 8. Listopad, 2009 Majitel Share Odesláno: 8. Listopad, 2009 Tvl.. Jsi sem mel hodit muj ze stolkara.. Link to comment Share on other sites More sharing options...
Vidie 5 Odesláno: 8. Listopad, 2009 Share Odesláno: 8. Listopad, 2009 ja mam errory jak svina: C:\Users\David PC.DAVID-PC\Desktop\untitlm.pwn(200) : error 021: symbol already defined: "Jmeno" C:\Users\David PC.DAVID-PC\Desktop\untitlm.pwn(249) : warning 204: symbol is assigned a value that is never used: "Informace" C:\Users\David PC.DAVID-PC\Desktop\untitlm.pwn(783) : error 017: undefined symbol "Informace" C:\Users\David PC.DAVID-PC\Desktop\untitlm.pwn(783) : warning 215: expression has no effect C:\Users\David PC.DAVID-PC\Desktop\untitlm.pwn(783) : error 001: expected token: ";", but found "]" C:\Users\David PC.DAVID-PC\Desktop\untitlm.pwn(783) : error 029: invalid expression, assumed zero C:\Users\David PC.DAVID-PC\Desktop\untitlm.pwn(783) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 5 Errors. Link to comment Share on other sites More sharing options...
Mmartin 0 Odesláno: 8. Listopad, 2009 Share Odesláno: 8. Listopad, 2009 hmm, celkom mi to ide, ale pod ucet prihlasit s akymkolvek heslom, a neuklada mi peniaze Link to comment Share on other sites More sharing options...
_Speedy 2 Odesláno: 8. Listopad, 2009 Share Odesláno: 8. Listopad, 2009 Tvl.. Jsi sem mel hodit muj ze stolkara.. Lol tu tvoju čo musimš napisať login aby sa ty zobrazilo okno a ked už sa zaregistruješ a potom sa chceš prihlasiť tak stači dať esc a nemusiš sa ani prihlasiť alebo znova napisať register a zmeniť heslo Link to comment Share on other sites More sharing options...
Majitel ffredyk 167 Odesláno: 8. Listopad, 2009 Majitel Share Odesláno: 8. Listopad, 2009 Tvl.. Jsi sem mel hodit muj ze stolkara.. Lol tu tvoju čo musimš napisať login aby sa ty zobrazilo okno a ked už sa zaregistruješ a potom sa chceš prihlasiť tak stači dať esc a nemusiš sa ani prihlasiť alebo znova napisať register a zmeniť heslo Kdybys nebyl blbej tak si to upravis Link to comment Share on other sites More sharing options...
_Speedy 2 Odesláno: 8. Listopad, 2009 Share Odesláno: 8. Listopad, 2009 Omg ale tam nieje čo opraviť to už neopravi nik Link to comment Share on other sites More sharing options...
Majitel ffredyk 167 Odesláno: 8. Listopad, 2009 Majitel Share Odesláno: 8. Listopad, 2009 Omg ale tam nieje čo opraviť to už neopravi nik Rikas ty Link to comment Share on other sites More sharing options...
rEf 53 Odesláno: 10. Listopad, 2009 Share Odesláno: 10. Listopad, 2009 E:\DOCUME~1\free\Plocha\PEOPLE~1.PWN(2) : fatal error 100: cannot read from file: "dini" Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase 1 Error. Help co stim je? Link to comment Share on other sites More sharing options...
zpatecnik 0 Odesláno: 10. Listopad, 2009 Share Odesláno: 10. Listopad, 2009 nemas include "dini" Link to comment Share on other sites More sharing options...
rEf 53 Odesláno: 10. Listopad, 2009 Share Odesláno: 10. Listopad, 2009 nemas include "dini" A kde ho seženu dáš mi ho sem ke stažení pls? Link to comment Share on other sites More sharing options...
Guest LuCkY Odesláno: 13. Listopad, 2009 Share Odesláno: 13. Listopad, 2009 je to good ale trochu mi to erroruje. Pravda.... :-D tjn, ale pro takoví co neví Jako já, to nebude dobrý, protože nechapou errory :-D Link to comment Share on other sites More sharing options...
Guest zdenek Odesláno: 14. Listopad, 2009 Share Odesláno: 14. Listopad, 2009 Zde si to muzete stahnou je to i opravene Link to comment Share on other sites More sharing options...
NextWarrior 0 Odesláno: 14. Listopad, 2009 Share Odesláno: 14. Listopad, 2009 pekny TuT,je videt ze sis dal zalezet Link to comment Share on other sites More sharing options...
kiwi 0 Odesláno: 24. Listopad, 2009 Share Odesláno: 24. Listopad, 2009 TUT je to hezký, dialog mi jede, ale když dám přihlásit se správným heslem, nic se mi neobjeví a ani mě to nepřihlásí. Jakto? 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