AAC MyAAC - Show outfit on Highscore box

DukeeH

Active Member
Joined
Dec 6, 2010
Messages
525
Best answers
3
Reaction score
35
Hello, I'm looking for a way to show player's outfit on highscore box using MyAAC (0.8-dev).
Used to use Gesior, changed the code a bit but it's not working

Code:
       <img src="http://outfit-images.ots.me/outfit.php?id='.$player['looktype'].'&amp;addons='.$player['lookaddons'].'&amp;head='.$player['lookhead'].'&amp;body='.$player['lookbody'].'&amp;legs='.$player['looklegs'].'&amp;feet='.$player['lookfeet'].'" width="32" height="32">
highscores.php: [PHP] highscores - Pastebin.com

What it is showing:


Thanks for your time.
 
Last edited:

Leesne

Active Member
Joined
Dec 4, 2017
Messages
104
Best answers
16
Reaction score
45
function.lua
getTopPlayers doesn't select all the player information

Replace
Lua:
$players = $db->query('SELECT `id`, `name`, `level`, `experience`' . ($is_tfs10 ? '' : ', `online`') . '
With:
Lua:
$players = $db->query('SELECT `id`, `name`, `level`, `experience`,`looktype`,`lookaddons`,`lookhead`,`lookbody`,`looklegs`,`lookfeet`' . ($is_tfs10 ? '' : ', `online`') . '
There is more code after that so don't replace the whole line.. just the exact code above.
 
OP
DukeeH

DukeeH

Active Member
Joined
Dec 6, 2010
Messages
525
Best answers
3
Reaction score
35
Thanks.

www/system/functions.php
At line 993:
Code:
        $players = $db->query('SELECT `id`, `name`, `level`, `experience`,`looktype`,`lookaddons`,`lookhead`,`lookbody`,`looklegs`,`lookfeet`' . ($is_tfs10 ? '' : ', `online`') . ' FROM `players` WHERE `group_id` < ' . $config['highscores_groups_hidden'] . ' AND `id` NOT IN (' . implode(', ', $config['highscores_ids_hidden']) . ') AND `' . $deleted . '` = 0 AND `account_id` != 1 ORDER BY `experience` DESC LIMIT ' . (int)$limit)->fetchAll();
 

Leesne

Active Member
Joined
Dec 4, 2017
Messages
104
Best answers
16
Reaction score
45
No worries, DuleeH, hope it helps.. Good luck.
 
Top