Jump to content
  • 0

sqlite gangs


andy47

Question

am o problema la comanda gangs numarul de gangpoints din baza de date nu coincide cu numarul de gangpoints cand folosesc comanda gangs

CMD:gangs(playerid, params[])
{
	new gpstring[345];
    new DBResult:query = db_query(GangDatabase, "SELECT `NameGang`,`GangPoints` FROM `Gangs` ORDER BY `GangPoints` DESC LIMIT 10"), string[64];
	for(new i=0; i < db_num_rows(query); i++)
	{
	    new gNume[MAX_GANG_NAME];
		db_get_field_assoc(query,"NameGang",gNume,MAX_GANG_NAME);
		db_get_field_assoc(query,"GangPoints",gpstring,sizeof(gpstring));
		format(string,sizeof(string), "%d. %s %d", i+1, gNume, gpstring);
		SCM(playerid, WHITE,string);
	    db_next_row(query);
	}
	db_free_result(query);
	return 1;
}

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

Guest
This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • 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.