03.10.2016, 17:22
ay
This isn't working. Anyone that is familliar with the new MySQL versions enough to make this work?
Код:
if(!strcmp(cmd, "/top", true))
{
new query[128];
mysql_format(SQL, query, sizeof(query), "SELECT * FROM `users` ORDER BY 'score' DESC LIMIT 3");
mysql_tquery(SQL, query, "ScoreTopFive", "i", playerid);
return 1;
}
forward ScoreTopFive(playerid);
public ScoreTopFive(playerid)
{
new string[128];
new name[25], score;
for(new i = 0; i < rows; i ++)
{
cache_get_value_name(i, "username", name);
cache_get_value_int(i, "score", score);
format(string, 128, "%d. %s - %d", i+1, name, score);
SendClientMessage(playerid, -1, string);
}
return 1;
}


