Commit cdbcc3f2 authored by POLYMER's avatar POLYMER

fix

parent c99139e0
...@@ -68,15 +68,16 @@ function cm.initial_effect(c) ...@@ -68,15 +68,16 @@ function cm.initial_effect(c)
qe:SetRange(LOCATION_HAND) qe:SetRange(LOCATION_HAND)
local con = e0:GetCondition() local con = e0:GetCondition()
qe:SetCondition(function(e, tp, eg, ep, ev, re, r, rp) qe:SetCondition(function(e, tp, eg, ep, ev, re, r, rp)
return Duel.IsExistingMatchingCard(nil, tp, LOCATION_MZONE, 0, 1, nil) and return not Duel.IsExistingMatchingCard(nil, tp, LOCATION_MZONE, 0, 1, nil) and
(not con or con(e, tp, eg, ep, ev, re, r, rp)) (not con or con(e, tp, eg, ep, ev, re, r, rp))
end) end)
-- 修复未定义的tc变量 -- 修复未定义的tc变量
cm.global_jc[c] = cm.global_jc[c] or {} cm.global_jc[c] = cm.global_jc[c] or {}
cm.global_jc[c][#cm.global_jc[c] + 1] = qe cm.global_jc[c][#cm.global_jc[c] + 1] = qe
c:RegisterEffect(qe) c:RegisterEffect(qe)
e0:SetCondition(function(e, tp, eg, ep, ev, re, r, rp) e0:SetCondition(function(e, tp, eg, ep, ev, re, r, rp)
return not Duel.IsExistingMatchingCard(nil, tp, LOCATION_MZONE, 0, 1, nil) and return Duel.IsExistingMatchingCard(nil, tp, LOCATION_MZONE, 0, 1, nil) and
(not con or con(e, tp, eg, ep, ev, re, r, rp)) (not con or con(e, tp, eg, ep, ev, re, r, rp))
end) end)
...@@ -122,7 +123,7 @@ function cm.triggertg(e, tp, eg, ep, ev, re, r, rp, chk) ...@@ -122,7 +123,7 @@ function cm.triggertg(e, tp, eg, ep, ev, re, r, rp, chk)
-- 仅在装备怪兽攻击力为0时才会触发后续操作,所以这里添加条件判断 -- 仅在装备怪兽攻击力为0时才会触发后续操作,所以这里添加条件判断
local c = e:GetHandler() local c = e:GetHandler()
local ec = c:GetEquipTarget() local ec = c:GetEquipTarget()
if ec and (ec:GetAttack() - 748) == 0 then if ec and (ec:GetAttack() - 444) == 0 then
Duel.SetOperationInfo(0, CATEGORY_TOHAND, nil, 1, tp, LOCATION_DECK) Duel.SetOperationInfo(0, CATEGORY_TOHAND, nil, 1, tp, LOCATION_DECK)
Duel.SetOperationInfo(0, CATEGORY_RELEASE, ec, 1, tp, LOCATION_MZONE) Duel.SetOperationInfo(0, CATEGORY_RELEASE, ec, 1, tp, LOCATION_MZONE)
Duel.SetOperationInfo(0, CATEGORY_DESTROY, c, 1, 0, 0) Duel.SetOperationInfo(0, CATEGORY_DESTROY, c, 1, 0, 0)
...@@ -159,9 +160,9 @@ function cm.triggerop(e, tp, eg, ep, ev, re, r, rp) ...@@ -159,9 +160,9 @@ function cm.triggerop(e, tp, eg, ep, ev, re, r, rp)
Duel.Destroy(c, REASON_EFFECT) Duel.Destroy(c, REASON_EFFECT)
end end
end
end
end end
function cm.filter(c) function cm.filter(c)
return c:IsType(TYPE_EQUIP) and not c:IsCode(m) and c:IsAbleToHand() return c:IsType(TYPE_EQUIP) and not c:IsCode(m) and c:IsAbleToHand()
end end
......
...@@ -29,6 +29,7 @@ end ...@@ -29,6 +29,7 @@ end
function s.setcost(e,tp,eg,ep,ev,re,r,rp,chk) function s.setcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return c:IsAbleToDeckAsCost() end if chk==0 then return c:IsAbleToDeckAsCost() end
Duel.ConfirmCards(1-tp,c)
Duel.SendtoDeck(c,nil,SEQ_DECKSHUFFLE,REASON_COST) Duel.SendtoDeck(c,nil,SEQ_DECKSHUFFLE,REASON_COST)
end end
......
...@@ -32,6 +32,7 @@ end ...@@ -32,6 +32,7 @@ end
function s.tgcost(e,tp,eg,ep,ev,re,r,rp,chk) function s.tgcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return c:IsAbleToDeckAsCost() end if chk==0 then return c:IsAbleToDeckAsCost() end
Duel.ConfirmCards(1-tp,c)
Duel.SendtoDeck(c,nil,SEQ_DECKSHUFFLE,REASON_COST) Duel.SendtoDeck(c,nil,SEQ_DECKSHUFFLE,REASON_COST)
end end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment