Explorar o código

类型为8的礼包改成不受触发过就不能触发的设定

gitxsm hai 4 meses
pai
achega
bc552a9f3b
Modificáronse 1 ficheiros con 6 adicións e 2 borrados
  1. 6 2
      script/module/topup/GiftLogic.lua

+ 6 - 2
script/module/topup/GiftLogic.lua

@@ -76,9 +76,13 @@ local function genGiftData(human, id,startTime,region,isNew)
     }
     }
 end
 end
 
 
-local function genGift(human,id) 
+local function genGift(human,id)
+    local giftCfg = GiftExcel[id]
+    local gitftType = giftCfg and giftCfg.trigger or 0
+
     -- 已经触发过礼包了
     -- 已经触发过礼包了
-    if human.db.gift.unlock[id] then 
+    -- 新修改: 类型8不受这个影响
+    if human.db.gift.unlock[id] and GIFT_HERO_UPGRADE_STAR_DAILY ~= gitftType then
         return
         return
     end
     end
     human.db.gift.unlock[id] = true
     human.db.gift.unlock[id] = true