From 0810022ed33703d701b94532874ecf61b1b011a6 Mon Sep 17 00:00:00 2001 From: "Igor Barkov [iwork]" Date: Wed, 12 Dec 2018 14:40:49 +0200 Subject: [PATCH] =?UTF-8?q?=D0=9D=D0=BE=D0=B2=D0=B0=D1=8F=20=D1=84=D1=83?= =?UTF-8?q?=D0=BD=D0=BA=D1=86=D0=B8=D1=8F=20=D0=BF=D0=BE=D0=B4=D1=81=D1=87?= =?UTF-8?q?=D1=91=D1=82=D0=B0=20=D0=BC=D0=B0=D1=81=D1=81=D1=8B=20=D0=B2?= =?UTF-8?q?=D0=B5=D1=89=D0=B5=D0=B9:=20=D0=B2=D1=8B=D0=B4=D0=B5=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=D0=B8=D0=B5=20=D0=BF=D0=BE=D1=80=D0=BE=D0=B3=D0=BE?= =?UTF-8?q?=D0=B2=D1=8B=D1=85=20=D0=B7=D0=BD=D0=B0=D1=87=D0=B5=D0=BD=D0=B8?= =?UTF-8?q?=D0=B9.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- functions.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/functions.php b/functions.php index 7b297aa..d771d5e 100644 --- a/functions.php +++ b/functions.php @@ -2741,7 +2741,9 @@ function getItemsMassaInfo() { $i_row = db::c()->query('SELECT SUM(`massa`) AS `massa`, SUM(`gmeshok`) AS `massa_bonus` FROM `inventory` WHERE `setsale` = 0 AND `owner` = ?i',$_SESSION['uid'])->fetch_assoc(); $u_row = db::c()->query('SELECT `sila` FROM `users` WHERE `id` = ?i', $_SESSION['uid'])->fetch_assoc(); - return $i_row['massa'] . "/" . ($u_row['sila'] * 4 + $i_row['massa_bonus']); + if ($i_row['massa'] > $u_row['sila'] * 4 + $i_row['massa_bonus']) + return "" . $i_row['massa'] . "/" . ($u_row['sila'] * 4 + $i_row['massa_bonus']); + else return $i_row['massa'] . "/" . ($u_row['sila'] * 4 + $i_row['massa_bonus']); } function addlog($id, $log)