From 8b12d876a09fc35c787e76281576eb624a835230 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E9=92=8A?= Date: Wed, 29 Oct 2025 19:59:36 +0800 Subject: [PATCH] =?UTF-8?q?=E7=9B=B2=E7=9B=92=E8=BD=AC=E7=9B=98=20?= =?UTF-8?q?=E4=BC=98=E5=8C=96-=E9=A3=98=E5=B1=8F=E5=A4=84=E7=90=86=20?= =?UTF-8?q?=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../model/BlindBoxTurntableGiftDrawWorldNew.php | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/application/api/model/BlindBoxTurntableGiftDrawWorldNew.php b/application/api/model/BlindBoxTurntableGiftDrawWorldNew.php index c3512ae..5e66649 100644 --- a/application/api/model/BlindBoxTurntableGiftDrawWorldNew.php +++ b/application/api/model/BlindBoxTurntableGiftDrawWorldNew.php @@ -111,7 +111,8 @@ class BlindBoxTurntableGiftDrawWorldNew extends Model $this->handlePostDrawOperations( $precomputedResults, $boxTurntableLog, - $room_id + $room_id, + $total_num ); // 6. 构建并返回结果 return $this->buildDrawResult($boxTurntableLog, $giftCounts); @@ -870,7 +871,8 @@ class BlindBoxTurntableGiftDrawWorldNew extends Model private function handlePostDrawOperations( $precomputedResults, $boxTurntableLog, - $room_id + $room_id, + $total_num ) { // 获取巡乐会配置(使用缓存) $xlh_ext = $this->getCachedGiftBag(13); @@ -878,7 +880,7 @@ class BlindBoxTurntableGiftDrawWorldNew extends Model $this->batchInsertBlindBoxResults($precomputedResults, $boxTurntableLog); // 2. 处理巡乐会相关操作 if (!empty($xlh_ext) && $xlh_ext['inlet_bag_id'] == $precomputedResults[0]['gift_bag_detail']['gift_bag_id']) { - $this->handleXlhOperations($room_id, $xlh_ext); + $this->handleXlhOperations($room_id, $xlh_ext,$total_num); } } /** @@ -909,14 +911,16 @@ class BlindBoxTurntableGiftDrawWorldNew extends Model /** * 处理巡乐会相关操作 */ - private function handleXlhOperations($room_id, $xlh_ext) + private function handleXlhOperations($room_id, $xlh_ext,$total_num) { $xlhIsPiaoPing = 0; $xlhPeriodsNum = $this->getCachedXlhPeriodsNum("get"); - if($xlhPeriodsNum == $xlh_ext['open_condition']['waiting_start_num']){ + //上一次的数量 + $xlhLastPeriodsNum = $xlhPeriodsNum-$total_num; + if($xlhLastPeriodsNum < $xlhPeriodsNum && $xlhPeriodsNum >= $xlh_ext['open_condition']['waiting_start_num']){ $xlhIsPiaoPing = 1; } - if($xlhPeriodsNum == $xlh_ext['open_condition']['start_num']){ + if($xlhLastPeriodsNum < $xlhPeriodsNum && $xlhPeriodsNum >= $xlh_ext['open_condition']['start_num']){ $xlhIsPiaoPing = 2; } // 处理飘屏