Commit f9482c04 authored by POLYMER's avatar POLYMER

fix

parent 59054105
...@@ -87,9 +87,10 @@ function cm.op5(e,tp,eg,ep,ev,re,r,rp) ...@@ -87,9 +87,10 @@ function cm.op5(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
Duel.Hint(3,tp,HINTMSG_EQUIP) Duel.Hint(3,tp,HINTMSG_EQUIP)
local g=Duel.SelectMatchingCard(tp,cm.w,tp,LOCATION_MZONE,0,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,cm.w,tp,LOCATION_MZONE,0,1,1,nil,e,tp)
if #g>0 and c:IsRelateToEffect(e) then local tc=g:GetFirst()
local tc=g:GetFirst() if tc and c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) then
if Duel.Equip(tp,tc,c)>0 then if Duel.Equip(tp,tc,c)>0 then
Duel.BreakEffect()
Duel.Draw(tp,1,REASON_EFFECT) Duel.Draw(tp,1,REASON_EFFECT)
end end
end end
......
...@@ -81,8 +81,7 @@ function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -81,8 +81,7 @@ function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
end end
function s.eqop(e,tp,eg,ep,ev,re,r,rp) function s.eqop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS) local tg=Duel.GetTargetsRelateToChain():Filter(aux.NecroValleyFilter(aux.TRUE),nil)
local tg=g:Filter(Card.IsRelateToEffect,nil,e)
if c:IsRelateToEffect(e) and c:IsFaceup() then if c:IsRelateToEffect(e) and c:IsFaceup() then
if Duel.GetLocationCount(tp,LOCATION_SZONE)>=tg:GetCount() then if Duel.GetLocationCount(tp,LOCATION_SZONE)>=tg:GetCount() then
local tc=tg:GetFirst() local tc=tg:GetFirst()
......
...@@ -34,6 +34,7 @@ function s.initial_effect(c) ...@@ -34,6 +34,7 @@ function s.initial_effect(c)
e2:SetOperation(s.spop) e2:SetOperation(s.spop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DRAW+CATEGORY_REMOVE)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SSET) e1:SetCode(EVENT_SSET)
......
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