Commit ecba3752 authored by Huangnan's avatar Huangnan

fix

parent 1fe7c80f
Pipeline #35747 passed with stages
in 39 minutes and 35 seconds
No preview for this file type
...@@ -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:IsFaceup() then
if Duel.Equip(tp,tc,c)>0 then if Duel.Equip(tp,c,tc) 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()
......
...@@ -35,10 +35,10 @@ function s.initial_effect(c) ...@@ -35,10 +35,10 @@ function s.initial_effect(c)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function s.spcon(e,tp,eg,ep,ev,re,r,rp) function s.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_ONFIELD,0,1,nil,e,tp) return Duel.IsExistingMatchingCard(s.chkfilter,tp,LOCATION_ONFIELD,0,1,nil,e,tp)
end end
function s.spcon2(e,tp,eg,ep,ev,re,r,rp) function s.spcon2(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_ONFIELD,0,1,nil,e,tp) return not Duel.IsExistingMatchingCard(s.chkfilter,tp,LOCATION_ONFIELD,0,1,nil,e,tp)
end end
function s.chkfilter(c) function s.chkfilter(c)
return (c.ThKingdWei or c:GetFlagEffect(17243108)>0) and c:IsFaceup() return (c.ThKingdWei or c:GetFlagEffect(17243108)>0) and c:IsFaceup()
...@@ -125,7 +125,7 @@ end ...@@ -125,7 +125,7 @@ end
-- ②效果处理 -- ②效果处理
function s.drop(e,tp,eg,ep,ev,re,r,rp) function s.drop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local b1=Duel.IsExistingMatchingCard(aux.nzatk(),tp,0,LOCATION_MZONE,1,nil) local b1=Duel.IsExistingMatchingCard(aux.nzatk,tp,0,LOCATION_MZONE,1,nil)
local b2=c:IsAbleToHand() and c:IsRelateToEffect(e) local b2=c:IsAbleToHand() and c:IsRelateToEffect(e)
local chk0=Duel.IsExistingMatchingCard(s.chkfilter0,tp,0,LOCATION_HAND,1,nil) local chk0=Duel.IsExistingMatchingCard(s.chkfilter0,tp,0,LOCATION_HAND,1,nil)
local chk1=Duel.IsExistingMatchingCard(s.chkfilter1,tp,0,LOCATION_HAND,1,nil,tp) local chk1=Duel.IsExistingMatchingCard(s.chkfilter1,tp,0,LOCATION_HAND,1,nil,tp)
...@@ -148,7 +148,7 @@ function s.drop(e,tp,eg,ep,ev,re,r,rp) ...@@ -148,7 +148,7 @@ function s.drop(e,tp,eg,ep,ev,re,r,rp)
if not b1 then return end if not b1 then return end
-- 怪兽处理 -- 怪兽处理
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local g=Duel.SelectMatchingCard(tp,aux.nzatk(),tp,0,LOCATION_MZONE,1,1,nil) local g=Duel.SelectMatchingCard(tp,aux.nzatk,tp,0,LOCATION_MZONE,1,1,nil)
if #g>0 then if #g>0 then
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
......
...@@ -33,7 +33,7 @@ end ...@@ -33,7 +33,7 @@ end
cm.SetCard_JYMFS=true cm.SetCard_JYMFS=true
function cm.thfilter(c) function cm.thfilter(c)
return c.SetCard_JYMFS and c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsAbleToHand() return c.SetCard_JYMFS and c:IsType(TYPE_MONSTER) and c:IsAbleToHand()
end end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_GRAVE,0,1,nil) 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