I have this code but sometimes sort order is mixing for public displayasdls(id).
Example:
Nick1 - 10 Goal
Nick2 - 9 Goal
Nick3 - 8 Goal
Nick4 - 7 Goal
Nick5 - 6 Goal
But sometime showing this type:
Nick5 - 6 Goal
Nick4 - 7 Goal
Nick1 - 10 Goal
Nick3 - 8 Goal
Nick2 - 9 Goal
how do i fix this problem?
new MadeRecord[MAX_PLAYER + 1][RECORDS+1]
PHP Code:
Event_Record(id, recordtype, amt, exp) {
if(amt == -1)
MadeRecord[id][recordtype]++
else
MadeRecord[id][recordtype] = amt
new playerRecord = MadeRecord[id][recordtype]
if(playerRecord > TopPlayer[1][recordtype])
{
TopPlayer[0][recordtype] = id
TopPlayer[1][recordtype] = playerRecord
new name[MAX_PLAYER+1]
get_user_name(id,name,MAX_PLAYER)
format(TopPlayerName[recordtype],MAX_PLAYER,"%s",name)
}
g_Experience[id] += exp
}
////......
if(distshot > MadeRecord[ballowner][DISTANCE])
Event_Record(ballowner, DISTANCE, distshot, 0)// record distance, and make that distance exp
Event_Record(ballowner, GOAL, -1, gainedxp)
////....