12.11.2013, 12:29
Why it gives Server Unknow command? There is no warning or any print error from mysql. There might be some mistake from the code below. Please let me know. thank you!
Код:
COMMAND:top(playerid, params[]) { new Query[160], count = 10, result[2][32], stringt[(24 + 10) * 10]; mysql_format(gSQL, Query, "SELECT `Score`, `PlayerName` FROM `"#MYSQL_TABLE"` ORDER BY `Score` ASC LIMIT 10"); mysql_function_query(gSQL, Query, true, "LoadPlayer", "d", playerid); if (mysql_num_rows() < 1) return 0; while (mysql_retrieve_row() && count > 0) { mysql_fetch_field_row(result[0], "Score"); mysql_fetch_field_row(result[1], "PlayerName"); format(stringt, sizeof(stringt), "%s%d. %s: %d\n", stringt, count--, result[1],strval(result[0])); } ShowPlayerDialog(playerid, 1223, DIALOG_STYLE_MSGBOX, "Top 10", stringt, "Close", ""); return 1; }