18.11.2015, 12:40
(
Последний раз редактировалось Opeal; 18.11.2015 в 13:16.
)
I confuse about this.
I load my database like this.
and my command /stats like this.
and this showed when i ingame.
why i found two times same word?
please help!
I load my database like this.
Код:
stock LoadDataString(playerid) { new query[300], pName[24], savingstring[10]; GetPlayerName(playerid, pName, 24); format(query, sizeof(query), "SELECT * FROM `playerchar` WHERE `charname` = '%s'", pName); mysql_query(query); mysql_store_result(); while(mysql_fetch_row_format(query,"|")) { mysql_fetch_field_row(savingstring[1], "username"); strmid(PlayerInfo[playerid][uName], savingstring[1], 0, strlen(savingstring[1]), 255); mysql_fetch_field_row(savingstring[2], "origin"); strmid(PlayerInfo[playerid][pOrigin], savingstring[2], 0, strlen(savingstring[2]), 255); } mysql_free_result(); }
Код:
CMD:stats(playerid, params[]) { if(IsPlayerConnected(playerid)) { new str[128]; format(str, sizeof(str), "Username: %s | Origin: %s", PlayerInfo[playerid][uName], PlayerInfo[playerid][pOrigin]); SendClientMessage(playerid ,0xFFFFFFAA, str); return 1; } return SendClientMessage(playerid, 0xAFAFAFAA, "Kamu harus login terlebih dahulu untuk menggunakan command ini."); }
why i found two times same word?
please help!