function onlineMapRenderCallback($data, $x, $y) { $imgX = 16; $imgY = 16; $x = round($x - $imgX / 2, 0); $y = round($y - $imgY / 2, 0); $gender = $data['gender']; $class = $data['class']; $race = $data['race']; $level = $data['level']; $faction = getPlayerFaction($race); $map_name = getMapName($data['map']); $area_name = getAreaNameFromPoint($data['map'], $data['position_x'], $data['position_y'], $data['position_z']); $img = $faction == 0 ? "gps_icon1.png" : "gps_icon.png"; $text = "<table class=online_map>"; $text .= "<tr><td class=" . ($faction == 0 ? "aname" : "hname") . ">" . $data['name'] . "</td></<tr>"; if ($area_name) { $text .= "<tr><td align=center>{$area_name}<br>"; } $text .= "<tr><td align=center>"; $text .= "<img width=20 src=" . getRaceImage($race, $gender) . "> <img width=20 src=" . getClassImage($class) . "><br>"; $text .= getRace($race) . "<br>"; $text .= getClass($class) . "<br>"; $text .= "Level - {$level}<br>"; $text .= "</td></tr>"; $text .= "</table>"; return '<img src="images/map_points/' . $img . '" class=point style="left: ' . $x . '; top: ' . $y . ';" ' . addTooltip($text) . '>' . "\n"; }
} if ($config['show_player_fields']) { //include("show_char_data.php"); //showPlayerData($char_data); } include "show_char_equip.php"; showPlayerEquip($guid, $char, $char_data, $char_stats); if ($config['show_player_skill']) { include "show_char_talents.php"; showPlayerTalents($guid, $class, $char['level'], $char['activeSpec']); echo "<br>"; include "show_char_skill.php"; showPlayerSkills($guid); echo "<br>"; include "show_char_achievements.php"; showPlayerAchievements($guid, getPlayerFaction($race)); echo "<br>"; include "show_char_reputation.php"; showPlayerReputation($guid, $class, $race); echo "<br>"; include "show_char_quest.php"; showPlayerQuests($guid, $char_data); echo "<br>"; include "show_char_inventory.php"; showPlayerInventory($guid, $char_data); echo "<br>"; include "show_char_guild.php"; $guildid = 0; showPlayerGuild($guid, $char_data); echo "<br>"; include "show_char_3d.php";
function getAchievementFaction($guid, $faction) { if ($guid && ($player = getCharacter($guid, 'race'))) { return getPlayerFaction($player['race']) == 0 ? 1 : 0; } return $faction; }
function getFactionImage($race) { $faction = getPlayerFaction($race); if ($faction == 0) { return "images/player_info/factions_img/alliance.gif"; } if ($faction == 1) { return "images/player_info/factions_img/horde.gif"; } return 0; }