From d896798e14a981101ec7a67b3dd46aba48d5dc84 Mon Sep 17 00:00:00 2001 From: pitch314 <8677243+pitch314@users.noreply.github.com> Date: Thu, 14 Jan 2021 03:34:15 -1000 Subject: [PATCH] =?UTF-8?q?Ajout=20possibilit=C3=A9=20graph=20m=C3=AAme=20?= =?UTF-8?q?sans=20points=20g=C3=A9n=C3=A9ral.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- views/home_stat.php | 34 ++++++++++++---------------------- 1 file changed, 12 insertions(+), 22 deletions(-) diff --git a/views/home_stat.php b/views/home_stat.php index 3cd4547c..165d6d42 100755 --- a/views/home_stat.php +++ b/views/home_stat.php @@ -293,8 +293,7 @@ // on fabrique toutes les courbes ici global $zoom; $zoom = 'false'; - $curve = create_curves($user_data["user_stat_name"], $min_date, $max_date, - $player_comp); + $curve = create_curves($user_data["user_stat_name"], $min_date, $max_date, $player_comp); $title = $lang['HOME_STATS_GRAPHIC_TITLE']; if (!empty($user_data["user_stat_name"])) { @@ -327,17 +326,17 @@ echo ""; echo "
"; // pas d info - if ($b == 0 && $d == 0 && $l == 0 && $t == 0) { + if ($b == 0 && $d == 0 && $l == 0 && $t == 0) { // calcul impossible ( non connaissance du classement) echo $lang['HOME_STATS_GRAPHIC_NOEMPIREDATA']; } - -// calcul impossible ( non connaissance du classement) - elseif ($last["general_pts"] == 0) { - echo $lang['HOME_STATS_GRAPHIC_NOSTATSDATA']; - } - -// autrement on affiche rien : on prepare juste l affichage du script + // elseif ($last["general_pts"] == 0) { // autrement on affiche rien : on prepare juste l affichage du script + // echo $lang['HOME_STATS_GRAPHIC_NOSTATSDATA']; + // } else { + if ($last["general_pts"] == 0) { + echo $lang['HOME_STATS_GRAPHIC_NOSTATSDATA'] . "
/n"; + $f = round(all_fleet_cumulate($user_building) / 1000); // only FOR et Sat, pour le moment + } $pie_point = create_pie($b . "_x_" . $d . "_x_" . $l . "_x_" . $f . "_x_" . $t, "Batiments_x_Défenses_x_Lunes_x_Flotte_x_Technologies", $lang['HOME_STATS_GRAPHIC_LASTREPARTITION'], "pie_point"); @@ -362,13 +361,9 @@ $pie_empire = ""; echo ""; echo "
"; - // pas d info - if ($b == 0 && $d == 0 && $l == 0 && $t == 0) { + if ($b == 0 && $d == 0 && $l == 0 && $t == 0) { // pas d info echo $lang['HOME_STATS_GRAPHIC_NOEMPIREDATA']; - } - -// autrement on affiche rien : on prepare juste l affichage du script - else { + } else { // autrement on affiche rien : on prepare juste l affichage du script $pie_empire = create_pie(implode('_x_', $planet), implode('_x_', $planet_name), $lang['HOME_STATS_GRAPHIC_REPARTITION'], "pie_empire"); } @@ -377,12 +372,7 @@ echo ""; ?> - - - -
- - +