Index: script/c0.lua ================================================================== --- script/c0.lua +++ script/c0.lua @@ -40,36 +40,35 @@ local cache_7 local cache_8 local cache_9 local _ fun["Debug.ReloadFieldBegin"] = Debug.ReloadFieldBegin -Debug.ReloadFieldBegin = function(str_1, str_2) - str["不洗牌"] = str_1 & DUEL_PSEUDO_SHUFFLE - str["无BP"] = str_1 & DUEL_ATTACK_FIRST_TURN - str["无AI"] = str_1 & DUEL_SIMPLE_AI +Debug.ReloadFieldBegin = function(u1, u2) + str["不洗牌"] = u1 & DUEL_PSEUDO_SHUFFLE + str["无BP"] = u1 & DUEL_ATTACK_FIRST_TURN + str["无AI"] = u1 & DUEL_SIMPLE_AI str["规则表"] = { [3] = "大师3 ", [4] = "新大师 ", [5] = "大师2020 ", } - if str_2 then - str["规则"] = str["规则表"][str_2] - + if u2 then + str["规则"] = str["规则表"][u2] else str["规则"] = str["规则表"][5] end - fun["Debug.ReloadFieldBegin"](str_1, str_2) + fun["Debug.ReloadFieldBegin"](u1, u2) end -fun["一_随机抽卡"] = function(str_1) - str["随机抽卡的数量"] = str_1 +fun["一_随机抽卡"] = function(u1) + str["随机抽卡的数量"] = u1 str["效果"] = Effect.GlobalEffect() str["效果"]:SetType(EFFECT_TYPE_FIELD + EFFECT_TYPE_CONTINUOUS) str["效果"]:SetCode(EVENT_ADJUST) str["效果"]:SetCondition(aux.TRUE) function cache_1(effect_event, player_who_activate_the_effect) Duel.ShuffleDeck(0) - Duel.Draw(0, str_1, REASON_RULE) + Duel.Draw(0, u1, REASON_RULE) effect_event:Reset() end str["效果"]:SetOperation(cache_1) Duel.RegisterEffect(str["效果"], 0) end @@ -109,21 +108,19 @@ end end if Card.IsType(card, TYPE_PENDULUM) then for i = 1, #str["无效果灵摆怪兽表"] do if Card.IsCode(card, str["无效果灵摆怪兽表"][i]) then - else return true end end end - return false end -fun["一_开局添加手卡"] = function(str_1) +fun["一_开局添加手卡"] = function(u1) str["开局添加手卡"] = true - str["开局添加手卡的数量"] = str_1 + str["开局添加手卡的数量"] = u1 str["效果"] = Effect.GlobalEffect() str["效果"]:SetType(EFFECT_TYPE_FIELD + EFFECT_TYPE_CONTINUOUS) str["效果"]:SetCode(EVENT_ADJUST) str["效果"]:SetCondition(aux.TRUE) function cache_1(effect_event, player_who_activate_the_effect) @@ -131,26 +128,26 @@ player_who_activate_the_effect, Card.IsAbleToHand, player_who_activate_the_effect, LOCATION_DECK, 0, - str_1, - str_1, + u1, + u1, nil ) Duel.SendtoHand(str["玩家选定的卡"], nil, REASON_RULE) effect_event:Reset() end str["效果"]:SetOperation(cache_1) Duel.RegisterEffect(str["效果"], 0) end -fun["一_禁格"] = function(str_1) +fun["一_禁格"] = function(u1) str["禁格"] = true - str["禁格的数量"] = str_1 + str["禁格的数量"] = u1 str["效果"] = Effect.GlobalEffect() str["效果"]:SetCode(EFFECT_USE_EXTRA_MZONE) - str["效果"]:SetValue(str_1) + str["效果"]:SetValue(u1) Duel.RegisterEffect(str["效果"], 0) end --第二层------------------------------- local cache_1 local cache_2 @@ -161,30 +158,29 @@ local cache_7 local cache_8 local cache_9 local _ fun["Debug.ReloadFieldEnd"] = Debug.ReloadFieldEnd -Debug.ReloadFieldEnd = function(str_1) +Debug.ReloadFieldEnd = function(u1) fun["Debug.ReloadFieldEnd"]() - if str_1 then - fun["一_随机抽卡"](str_1) + if u1 then + fun["一_随机抽卡"](u1) end end -fun["二_印卡"] = function(str_1, str_2, str_3) +fun["二_印卡"] = function(u1, u2, str_3) if str_3 then - else - str_3 = str_2 + str_3 = u2 end Debug.ShowHint( "点击对方额外卡组可以进行印卡。\n手卡只能印 " - .. str_2 + .. u2 .. " 张。\n最多可以印 " .. str_3 .. " 张" ) - str["效果"] = Effect.CreateEffect(str_1) + str["效果"] = Effect.CreateEffect(u1) str["当前印卡数"] = 1 str["效果"]:SetType(EFFECT_TYPE_IGNITION) str["效果"]:SetProperty( EFFECT_FLAG_BOTH_SIDE + EFFECT_FLAG_UNCOPYABLE + EFFECT_FLAG_CANNOT_NEGATE + EFFECT_FLAG_CANNOT_DISABLE ) @@ -191,11 +187,11 @@ str["效果"]:SetTarget(fun["一_该效果不能被连锁"]) str["效果"]:SetRange(LOCATION_EXTRA) function print_hand(effect_event, player_who_activate_the_effect) announce_card = Duel.AnnounceCard(player_who_activate_the_effect) card = Duel.CreateToken(player_who_activate_the_effect, announce_card) - if str["当前印卡数"] <= str_2 then + if str["当前印卡数"] <= u2 then str["当前印卡数"] = str["当前印卡数"] + 1 Duel.SendtoHand(card, nil, REASON_RULE) else if str["当前印卡数"] <= str_3 then @@ -208,11 +204,11 @@ effect_event:Reset() end end end str["效果"]:SetOperation(print_hand) - str_1:RegisterEffect(str["效果"]) + u1:RegisterEffect(str["效果"]) end fun["二_开局说明"] = function() str["这个残局的效果卡数量"] = Duel.GetMatchingGroupCount(fun["是否效果卡"], 0, str["所有区域"], str["所有区域"], nil) str["超量素材组"] = Duel.GetOverlayGroup(0, LOCATION_MZONE, LOCATION_MZONE) @@ -242,35 +238,23 @@ if str["随机抽卡的数量"] then str["开局说明"] = str["开局说明"] .. "抽" .. str["随机抽卡的数量"] .. "卡 " end Debug.ShowHint(str["开局说明"]) end ---第三层------------------------------- -local cache_1 -local cache_2 -local cache_3 -local cache_4 -local cache_5 -local cache_6 -local cache_7 -local cache_8 -local cache_9 -local _ fun["aux.BeginPuzzle"] = aux.BeginPuzzle -aux.BeginPuzzle = function(str_1, str_2) +aux.BeginPuzzle = function(u1, u2) fun["aux.BeginPuzzle"]() - if str_1 then - fun["一_开局添加手卡"](str_1) + if u1 then + fun["一_开局添加手卡"](u1) end - if str_2 then - fun["一_禁格"](str_2) + if u2 then + fun["一_禁格"](u2) end fun["二_开局说明"]() fun["一_通关邀请"]() - fun["一_失败得分"]() end --兼容层------------------------------- fun["印卡"] = fun["二_印卡"] fun["开局添加手卡"] = fun["一_开局添加手卡"] fun["是否效果卡"] = fun["一_是否效果卡"] fun["禁格"] = fun["一_禁格"] fun["随机抽卡"] = fun["一_随机抽卡"]