Code:
public CallBack_Top(Handle:owner, Handle:hndl, const String:error[], any:userid)
{
if(!Timer_IsEnabled()) return;
ErrorCheck(hndl, error, "CallBack_Top");
new client = GetClientOfUserId(userid);
if(!client || !IsClientInGame(client))
return;
new iIndex, iPoints;
decl String:sName[32];
if(SQL_GetRowCount(hndl))
{
new Handle:hPack = CreateDataPack();
WritePackCell(hPack, iIndex);
while(SQL_FetchRow(hndl))
{
SQL_FetchString(hndl, 0, sName, sizeof(sName));
iPoints = SQL_FetchInt(hndl, 1);
WritePackString(hPack, sName);
WritePackCell(hPack, iPoints);
iIndex++;
}
SetPackPosition(hPack, 0);
WritePackCell(hPack, iIndex);
CreateTopMenu(client, hPack);
}
else
CPrintToChat(client, "%t", "Phrase_Rank_None");
}
Hello. I had updated my compiler and having issue with SetPackPosition for some reason.
SetPackPosition(hPack, 0); <-- this line throws warning
__________________