problem with cmd /top with mysql
#6

Quote:
Originally Posted by willbedie
Посмотреть сообщение
Try this if you're using MYSQL R41+

PHP код:
CMD:top(playerid
{
    new 
query[256];
    
mysql_format(Databasequerysizeof(query), "SELECT * `RESPECT` FROM `players` WHERE `RESPECT` > 0 ORDER BY `RESPECT` DESC LIMIT 0, 10"true); 
    
mysql_tquery(Databasequery); 
    new 
gString[256], name[MAX_PLAYER_NAME]; 
    new 
rows cache_num_rows(); 
    if (
rows
    { 
        for (new 
0rows++) 
        { 
            
cache_get_value(i"USERNAME"pInfo[playerid][Name], MAX_PLAYER_NAME); 
            
cache_get_value_int(i"RESPECT"pInfo[playerid][Respect]); 
            
format(gStringsizeof(gString), "%s%s %d Respect\n"gStringnamepInfo[playerid][Respect]); 
        } 
        
ShowPlayerDialog(playeridDIALOG_TOPDIALOG_STYLE_LIST"Top Respect"gString"Ok"""); 
    } 
    return 
1


EDITED, my bad sorry.
Reply


Messages In This Thread
problem with cmd /top with mysql - by wallen - 27.02.2018, 12:08
Re: problem with cmd /top with mysql - by X337 - 27.02.2018, 12:16
Re: problem with cmd /top with mysql - by solstice_ - 27.02.2018, 12:18
Re: problem with cmd /top with mysql - by kingmk - 27.02.2018, 12:24
Re: problem with cmd /top with mysql - by wallen - 27.02.2018, 12:56
Re: problem with cmd /top with mysql - by solstice_ - 27.02.2018, 12:58
Re: problem with cmd /top with mysql - by wallen - 27.02.2018, 13:05
Re: problem with cmd /top with mysql - by Stev - 27.02.2018, 13:17
Re: problem with cmd /top with mysql - by wallen - 27.02.2018, 14:33
Re: problem with cmd /top with mysql - by wallen - 27.02.2018, 16:38

Forum Jump:


Users browsing this thread: 1 Guest(s)