Daxic 0 Odesláno: 27. Prosinec, 2009 Share Odesláno: 27. Prosinec, 2009 DObry den potřeboval bych pomoct mám registraci a v ní chci aby se po odlognutí se uložila proměná a při načtení se načetla problem je v tom že nevím jak se ukládají promené. Link to comment Share on other sites More sharing options...
0 ATomas 291 Odesláno: 27. Prosinec, 2009 Share Odesláno: 27. Prosinec, 2009 pokud pouzivas dudb tak takto dUserSetINT("jmeno adresare").("jmeno polozky",promena); Link to comment Share on other sites More sharing options...
0 Guest Stefi414 Odesláno: 27. Prosinec, 2009 Share Odesláno: 27. Prosinec, 2009 lol ja mam dudb reg a ked dam pod to tak mi pise warning ze mam 2x nadefinovany v includ kto by mal to opravene dajte mi upload includy dudb dutils Y_Objects Thank You Link to comment Share on other sites More sharing options...
0 Daxic 0 Odesláno: 27. Prosinec, 2009 Author Share Odesláno: 27. Prosinec, 2009 to je na to aby se to uložilo a pokud to chci přo loginu vyvolat tu proměnou? Link to comment Share on other sites More sharing options...
0 ATomas 291 Odesláno: 27. Prosinec, 2009 Share Odesláno: 27. Prosinec, 2009 tak si das promena = dUserINT("jmeno adresare").("jmeno polozky"); Link to comment Share on other sites More sharing options...
0 Daxic 0 Odesláno: 27. Prosinec, 2009 Author Share Odesláno: 27. Prosinec, 2009 nwm čím to je žádné errory to neháže ale ani to tu proměnou neuloží ... nebo nenačte Tady je Disconnect: public OnPlayerDisconnect(playerid, reason) { if (PLAYERLIST_authed[playerid]) { dUserSetINT(PlayerName(playerid)).("money",GetPlayerMoney(playerid)); dUserSetINT("PlayerName").("povol",povolani[playerid]); } PLAYERLIST_authed[playerid]=false; return 1; } Tady je pokud napíše /login heslo : if (strlen(params)==0) return SystemMsg(playerid,"Login with: '/login password'"); if (udb_CheckLogin(PlayerName(playerid),params)) { GivePlayerMoney(playerid,dUserINT(PlayerName(playerid)).("money")-GetPlayerMoney(playerid)); povolani[playerid] = dUserINT(PlayerName(playerid)).("povol"); PLAYERLIST_authed[playerid]=true; return SystemMsg(playerid,"Successfully authed!"); } return SystemMsg(playerid,"Login is failed!"); A tady je to jak by se mnelo projevit jestli to je správne: public OnPlayerSpawn(playerid)//vybírání skinu { if(povolani[playerid] == 0) { AddPlayerClass(34, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(243, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(239, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(291, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(47, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(130, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(131, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(135, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(94, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(128, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(137, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(159, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(162, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P } if(povolani[playerid] == 4) { SetPlayerColor(playerid,0xFF0000FF); SetPlayerSkin(playerid,217); GivePlayerWeapon(playerid,4,1); GivePlayerWeapon(playerid,24,10); SetPlayerPos(playerid,1243.1223,331.4654,19.5547); } else if(povolani[playerid]== 1) { SetPlayerColor(playerid,0x666666FF); SetPlayerSkin(playerid,50); SetPlayerPos(playerid,1243.1223,331.4654,19.5547); } else if(povolani[playerid]== 2) { SetPlayerColor(playerid,0xFF7700FF); SetPlayerSkin(playerid,71); SetPlayerPos(playerid,1243.1223,331.4654,19.5547); } else if(povolani[playerid]==3) { SetPlayerColor(playerid,0x8800FFFF); SetPlayerSkin(playerid,61); SetPlayerPos(playerid,1243.1223,331.4654,19.5547); } else if(povolani[playerid]== 5) { SetPlayerColor(playerid,0xFFEE00FF); SetPlayerSkin(playerid,66); SetPlayerPos(playerid,1243.1223,331.4654,19.5547); } else if(povolani[playerid] == 6) { SetPlayerColor(playerid,0x1100FFFF); SetPlayerSkin(playerid,283); SetPlayerPos(playerid,1243.1223,331.4654,19.5547); } else if(povolani[playerid] == 7) { SetPlayerColor(playerid,0x00FFEEFF); SetPlayerSkin(playerid,276); SetPlayerPos(playerid,1243.1223,331.4654,19.5547); } return 1; } A jinak ta promená se mi nastavuje ... prosím pomocte Link to comment Share on other sites More sharing options...
0 AvestX 5 Odesláno: 27. Prosinec, 2009 Share Odesláno: 27. Prosinec, 2009 LoL to: AddPlayerClass(34, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(243, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(239, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(291, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(47, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(130, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(131, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(135, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(94, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(128, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(137, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(159, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P AddPlayerClass(162, 1243.1223,331.4654,19.5547,331.2053, 0, 0, 0, 0, 0, 0); //3 P dej do OnGameModeInt jinak rači nekoukam Link to comment Share on other sites More sharing options...
0 Daxic 0 Odesláno: 27. Prosinec, 2009 Author Share Odesláno: 27. Prosinec, 2009 dal sem to do OnGameModelinit ale stejně to nefunguje chyba bude zřejmě někde dále "pale" prosim pomožte už nwm co dále ... Link to comment Share on other sites More sharing options...
0 ATomas 291 Odesláno: 27. Prosinec, 2009 Share Odesláno: 27. Prosinec, 2009 chyba je zde dUserSetINT("PlayerName").("povol",povolani[playerid]); to ti vytvori soubor PlayerName,dudb.sav a ne jmeno toho hrace takto si to udelej dUserSetINT(PlayerName(playerid)).("povol",povolani[playerid]); Link to comment Share on other sites More sharing options...
Dotaz
Daxic 0
DObry den potřeboval bych pomoct mám registraci a v ní chci aby se po odlognutí se uložila proměná a při načtení se načetla problem je v tom že nevím jak se ukládají promené.
Link to comment
Share on other sites
8 odpovědí na tuto otázku
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