From 283806369a5e6e9a671fc9ea581920f3ce7b2d20 Mon Sep 17 00:00:00 2001 From: slawkens1 Date: Sat, 13 Jan 2018 19:34:53 +0100 Subject: [PATCH] * fixes to the latest commit (removed some files) * otserv 0.6.3: fixed some warning (on the characters page) and fatal mysql error (on the mango signature) * update TODO --- TODO | 1 + system/pages/characters.php | 4 ++-- templates/kathrine/style.css | 2 +- templates/tibiacom/config.php | 2 +- tools/signature/mango.php | 4 +++- 5 files changed, 8 insertions(+), 5 deletions(-) diff --git a/TODO b/TODO index f85ac4df..253bf0b5 100644 --- a/TODO +++ b/TODO @@ -29,6 +29,7 @@ * remove tibiacom template, and include it as a plugin 2.0 + * remove signatures, creature images (make a separate plugins for them) - this way we save 2.5mb of space * remove gesior backward support * remove compat functions * remove $template['link_*'] diff --git a/system/pages/characters.php b/system/pages/characters.php index b1658926..bb64e5e0 100644 --- a/system/pages/characters.php +++ b/system/pages/characters.php @@ -234,7 +234,7 @@ if($player->isLoaded() && !$player->isDeleted()) $dead_add_content = ''; $deaths = array(); if($db->hasTable('killers')) { - $player_deaths = $db->query('SELECT `id`, `date`, `level` FROM `player_deaths` WHERE `player_id` = '.$player->getId().' ORDER BY `date` DESC LIMIT 0,10;'); + $player_deaths = $db->query('SELECT `id`, `date`, `level` FROM `player_deaths` WHERE `player_id` = '.$player->getId().' ORDER BY `date` DESC LIMIT 0,10;')->fetchAll(); if(count($player_deaths)) { $number_of_rows = 0; @@ -292,7 +292,7 @@ WHERE killers.death_id = '".$death['id']."' ORDER BY killers.final_hit DESC, kil $deaths_db = $db->query('SELECT `player_id`, `time`, `level`, `killed_by`, `is_player`' . $mostdamage . ' FROM `player_deaths` - WHERE `player_id` = ' . $player->getId() . ' ORDER BY `time` DESC LIMIT 10;'); + WHERE `player_id` = ' . $player->getId() . ' ORDER BY `time` DESC LIMIT 10;')->fetchAll(); if(count($deaths_db)) { diff --git a/templates/kathrine/style.css b/templates/kathrine/style.css index 9162325f..8c7aac7a 100644 --- a/templates/kathrine/style.css +++ b/templates/kathrine/style.css @@ -3,7 +3,7 @@ body { - background: #a7a597 url('images/background.png') no-repeat top left; + background: #a7a597 url('images/background.jpg') no-repeat top left; margin: 0px; padding: 0px; font-family: Verdana, Arial, Helvetica, sans-serif; diff --git a/templates/tibiacom/config.php b/templates/tibiacom/config.php index f96798b4..585085c8 100644 --- a/templates/tibiacom/config.php +++ b/templates/tibiacom/config.php @@ -10,7 +10,7 @@ $config['boxes'] = "highscores,newcomer,gallery,networks,poll"; $config['network_facebook'] = 'tibia'; // leave empty to disable $config['network_twitter'] = 'tibia'; // leave empty to disable -$config['background_image'] = "background-artwork-860.jpg"; +$config['background_image'] = "background-artwork.jpg"; $config['logo_image'] = "tibia-logo-artwork-top.gif"; $config['gallery_image'] = 1; $config['menu_categories'] = array( diff --git a/tools/signature/mango.php b/tools/signature/mango.php index c8b82a3a..b0cca33f 100644 --- a/tools/signature/mango.php +++ b/tools/signature/mango.php @@ -31,7 +31,7 @@ $MadGD = new MadGD( SIGNATURES_BACKGROUNDS.$background ); $MadGD->testMode = false; - $MadGD->setDefaultStyle( SIGNATURES_FONTS.'arial.ttf', SIGNATURES_FONTS.'arialbd.ttf', 8 ); + $MadGD->setDefaultStyle( SIGNATURES_FONTS.'arialbd.ttf', SIGNATURES_FONTS.'arialbd.ttf', 8 ); $MadGD->setEquipmentBackground( SIGNATURES_IMAGES.'equipments.png' ); /** NAME **/ @@ -67,6 +67,8 @@ $town = 'town'; if($db->hasColumn('houses', 'town_id')) $town = 'town_id'; + else if($db->hasColumn('houses', 'townid')) + $town = 'townid'; $house = $db->query( 'SELECT `houses`.`name`, `houses`.`' . $town . '` as town FROM `houses` WHERE `houses`.`owner` = '.$player->getId().';' )->fetchAll(); if ( count( $house ) != 0 )