Vespa97 Posted January 14, 2016 Posted January 14, 2016 Salut am urmat un tutorial pentru system de register/login ,totul a fost perfect pana am mai adaugat cateva variabile pentru bani,rp,job,admin.La inceput a mers bine. De fiecare data cand fac cate un cont nou prima data imi apar cati bani am la acel textdraw din samp verde cu dolarul in fata ,dar la stats apare ca am 0.Daca ies si intru iara dispar toti banii de la textdraw si apare la stats.Si a 3-a oara cand ma conectez nu mai am nimic.
Gireada Posted January 15, 2016 Posted January 15, 2016 Imi poti spune, pe ce sistem este(dini/mysql/sql), sa-mi arati comanda stat si functia care updateaza variabilele?
Vespa97 Posted January 15, 2016 Author Posted January 15, 2016 Mysql, cred ca imi lipseste acea functie pentu updatarea variabilei...un exemplu te rog ?
Gireada Posted January 15, 2016 Posted January 15, 2016 new string[256]; format(string,sizeof(string),"UPDATE `users` SET `fieldname` = '%s' WHERE `username` = '%s'",string to update); mysql_query(string);
Vespa97 Posted January 16, 2016 Author Posted January 16, 2016 Spoiler public OnPlayerConnect(playerid) new query[100]; mysql_format(handle, query, sizeof(query), "SELECT * FROM conturi WHERE Nume = '%s'", GetName(playerid)); mysql_tquery(handle, query, "OnPlayerLogin", "i", playerid);
Vespa97 Posted January 16, 2016 Author Posted January 16, 2016 Nu mai conteaza T.C este mai usor pe dini inteleg mai bine
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