Jump to content
  • 0




  Versiunea Mysql: R39-6 

Deci problema e urmatoarea: cand dau in dialog valoarea pe care vreau sa o setez la nivelul unui player, nu ii actualizeaza acelui player nimic.

Observatie: PlayerInfo pentru player-ul acela se schimba la valoarea pusa, dar nu se actualizeaza in baza de date.


// Am un dialog unde ii setezi nivelul unui player
  	if(!IsNumeric(inputtext)) return SCM(playerid, verde_inchis, "Ai introdus si alte caractere!");
	new player;
	player = GetPVarInt(playerid, "PlayerID");
	PlayerInfo[player][pNivel] = strval(inputtext);

// Si aici o functie care actualizeaza perfect la playerid dar la player-ul din set nu

function UpdatePlayerInfo(playerid) {
	gQuery[0] = EOS;
	mysql_format(SQL, gQuery, sizeof(gQuery), "UPDATE `users` SET `Nivel` = %d WHERE `ID` = '%d'", PlayerInfo[playerid][pNivel], PlayerInfo[playerid][pSQLID]);
	mysql_tquery(SQL, gQuery, "", "", playerid);
	return 1;


Edited by ShaggyShaggy
Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0
Acum 4 minute, Banditul a spus:

Si functia de update unde este chemata? Pentru ca nu sa o folosesti in dialog de set dupa ce se modifica

Deasemenea merita sa te uiti si in mysql log sa vezi daca sunt ceva erori

La conectare este un SetTimerEx pentru fiecare player cu functia aia de Update. O sa verific logu, mersi de sugestie.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.