This commit is contained in:
aozhiwei 2024-10-08 15:19:03 +08:00
parent 52b6a66dfa
commit 22e24628b4

View File

@ -24,10 +24,9 @@ class BattleBoxService {
$lstVal = mt\Parameter::getListValue('battle_event_loot_per_game'); $lstVal = mt\Parameter::getListValue('battle_event_loot_per_game');
if (!$allocableNum <= 0 || empty($lstVal) || count($lstVal) < 2) { if (!$allocableNum <= 0 || empty($lstVal) || count($lstVal) < 2) {
$rnd = rand($lstVal[0], $lstVal[1]); $rnd = rand($lstVal[0], $lstVal[1]);
if ($rnd <= 0) { if ($rnd > 0) {
return; $boxNum = min($rnd, $allocableNum);
} }
$boxNum = min($rnd, $allocableNum);
} }
} }
return $boxNum; return $boxNum;