From 18b85d8c5d3630b109ec29b6be988b314f946ff9 Mon Sep 17 00:00:00 2001 From: yangduo Date: Mon, 31 Mar 2025 17:01:36 +0800 Subject: [PATCH] fix --- webapp/classes/RechargeActivity.php | 2 +- webapp/controller/RechargeController.class.php | 2 +- webapp/controller/SoloController.class.php | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/webapp/classes/RechargeActivity.php b/webapp/classes/RechargeActivity.php index 3c58345..3de9192 100644 --- a/webapp/classes/RechargeActivity.php +++ b/webapp/classes/RechargeActivity.php @@ -77,7 +77,7 @@ class RechargeActivity } $nowTime = time(); $todaysecs = phpcommon\getdayseconds($nowTime); - $daysumtarget = intval(metatable\getParameterById(RECHARGE_TARGET)) * 10; + $daysumtarget = intval(metatable\getParameterById(RECHARGE_TARGET)['param_value']) * 10; foreach ($activityconf as $itemconf) { if ($nowTime < strtotime($itemconf['time1']) || $nowTime > strtotime($itemconf['time2'])) { continue; diff --git a/webapp/controller/RechargeController.class.php b/webapp/controller/RechargeController.class.php index 18c6ff5..cd6a227 100644 --- a/webapp/controller/RechargeController.class.php +++ b/webapp/controller/RechargeController.class.php @@ -919,7 +919,7 @@ class RechargeController if (!$solorow) { $privilege = new classes\Privilege(); - $medals = intval(metatable\getParameterById(MEDAL_LIMIT)) + $privilege->getMedalLimitPlus($account_id); + $medals = intval(metatable\getParameterById(MEDAL_LIMIT)['param_value']) + $privilege->getMedalLimitPlus($account_id); $gamelevel = array( 'curlevel' => 1, 'curwave' => 0, diff --git a/webapp/controller/SoloController.class.php b/webapp/controller/SoloController.class.php index 84f435b..d4bd27e 100644 --- a/webapp/controller/SoloController.class.php +++ b/webapp/controller/SoloController.class.php @@ -87,7 +87,7 @@ class SoloController $medals = 0; $privilege = new classes\Privilege(); - $medalsgrowlimit = intval(metatable\getParameterById(MEDAL_LIMIT)) + $privilege->getMedalLimitPlus($account_id); + $medalsgrowlimit = intval(metatable\getParameterById(MEDAL_LIMIT)['param_value']) + $privilege->getMedalLimitPlus($account_id); $nowtime = time(); $lastredeem = $nowtime; $level = 1; @@ -137,7 +137,7 @@ class SoloController ) ); } else { - $medalsecs = intval(metatable\getParameterById(MEDAL_SECONDS)); + $medalsecs = intval(metatable\getParameterById(MEDAL_SECONDS)['param_value']); $lastredeem = $solorow['lastredeem']; $medals = $solorow['medals']; $lastoffline = $solorow['lastoffline']; @@ -155,7 +155,7 @@ class SoloController if ($lastoffline + 3600 <= $nowtime) { $offlinehours += ($nowtime - $lastoffline) / 3600; - $offlinelimit = metatable\getParameterById(OFFLINE_LIMIT) + $privilege->getOfflineLimitPlus($account_id); + $offlinelimit = intval(metatable\getParameterById(OFFLINE_LIMIT)['param_value']) + $privilege->getOfflineLimitPlus($account_id); if ($offlinehours > $offlinelimit) { $offlinehours = $offlinelimit; } @@ -811,7 +811,7 @@ class SoloController $curmedals = $solorow['medals'] - $medalcost; $lastredeem = $solorow['lastredeem']; $privilege = new classes\Privilege(); - $medalsgrowlimit = intval(metatable\getParameterById(MEDAL_LIMIT)) + $privilege->getMedalLimitPlus($account_id); + $medalsgrowlimit = intval(metatable\getParameterById(MEDAL_LIMIT)['param_value']) + $privilege->getMedalLimitPlus($account_id); if ($solorow['medals'] >= $medalsgrowlimit && $curmedals < $medalsgrowlimit) { $lastredeem = time(); }