Commit e6905b24 authored by wyykak's avatar wyykak

fix

Signed-off-by: wyykak's avatarwyykak <wyy_1414@126.com>
parent 6937d705
Pipeline #14381 passed with stage
in 57 seconds
...@@ -32,7 +32,7 @@ function c60722.filter(c,tp) ...@@ -32,7 +32,7 @@ function c60722.filter(c,tp)
end end
function c60722.condition(e,tp,eg,ep,ev,re,r,rp) function c60722.condition(e,tp,eg,ep,ev,re,r,rp)
local ex,tg,tc=Duel.GetOperationInfo(ev,CATEGORY_DESTROY) local ex,tg,tc=Duel.GetOperationInfo(ev,CATEGORY_DESTROY)
return ex and tg~=nil and tc+tg:FilterCount(c60722.filter,nil,tp)-tg:GetCount()>0 and not re:GetHandler():IsLocation(LOCATION_REMOVED) return ex and tg~=nil and tc+tg:FilterCount(c60722.filter,nil,tp)-tg:GetCount()>0 and not re:GetHandler():IsLocation(LOCATION_REMOVED) and rp==1-tp
end end
function c60722.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c60722.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsDiscardable() end if chk==0 then return e:GetHandler():IsDiscardable() end
......
...@@ -14,7 +14,7 @@ function cm.initial_effect(c) ...@@ -14,7 +14,7 @@ function cm.initial_effect(c)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function cm.filter(c) function cm.filter(c)
return c:IsSetCard(0x999) and c:IsAbleToDeck() and c:IsType(TYPE_MONSTER) return c:IsSetCard(0x999) and c:IsAbleToDeck() and c:IsType(TYPE_MONSTER) and c:IsFaceup()
end end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function cm.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE+LOCATION_REMOVED) and chkc:IsControler(tp) and cm.filter(chkc) end if chkc then return chkc:IsLocation(LOCATION_GRAVE+LOCATION_REMOVED) and chkc:IsControler(tp) and cm.filter(chkc) end
......
...@@ -31,14 +31,16 @@ function c74563043.initial_effect(c) ...@@ -31,14 +31,16 @@ function c74563043.initial_effect(c)
e1:SetOperation(c74563043.vnop) e1:SetOperation(c74563043.vnop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function c74563043.vnfilter(c,tp)
return c:IsAbleToRemove(tp,POS_FACEDOWN) and c:IsControler(1-tp)
end
function c74563043.vntg(e,tp,eg,ep,ev,re,r,rp,chk) function c74563043.vntg(e,tp,eg,ep,ev,re,r,rp,chk)
local lg=e:GetHandler():GetLinkedGroup():Filter(Card.IsAbleToRemove,nil,POS_FACEDOWN) local lg=e:GetHandler():GetLinkedGroup():Filter(c74563043.vnfilter,nil,tp)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,0,LOCATION_MZONE,1,nil,e,tp,lg) end if chk==0 then return #lg>0 end
Duel.SetOperationInfo(0,CATEGORY_REMOVE,lg,lg:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_REMOVE,lg,lg:GetCount(),0,0)
end end
function c74563043.vnop(e,tp,eg,ep,ev,re,r,rp) function c74563043.vnop(e,tp,eg,ep,ev,re,r,rp)
local lg=e:GetHandler():GetLinkedGroup():Filter(Card.IsAbleToRemove,nil,POS_FACEDOWN) local lg=e:GetHandler():GetLinkedGroup():Filter(c74563043.vnfilter,nil,tp)
if Duel.GetLocationCount(tp,LOCATION_SZONE)<lg:GetCount() then return end
local c=e:GetHandler() local c=e:GetHandler()
local tc=lg:GetFirst() local tc=lg:GetFirst()
while tc do while tc do
......
...@@ -12,15 +12,19 @@ function c74563606.initial_effect(c) ...@@ -12,15 +12,19 @@ function c74563606.initial_effect(c)
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_SZONE) e2:SetRange(LOCATION_SZONE)
e2:SetCountLimit(1) e2:SetCountLimit(1)
e2:SetTarget(c74563606.lvtg)
e2:SetOperation(c74563606.lvop) e2:SetOperation(c74563606.lvop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c74563606.lvfilter(c,lv) function c74563606.lvfilter(c,lv)
return c:IsFaceup() and (c:IsLevelAbove(0) and not c:IsLevel(lv)) or (c:IsRankAbove(0) and not c:IsRank(lv)) return c:IsFaceup() and (c:IsLevelAbove(0) and not c:IsLevel(lv)) or (c:IsRankAbove(0) and not c:IsRank(lv))
end end
function c74563606.lvtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c74563606.lvfilter,tp,LOCATION_MZONE,0,1,nil,6) end
end
function c74563606.lvop(e,tp,eg,ep,ev,re,r,rp) function c74563606.lvop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local g=Duel.GetMatchingGroup(c74563606.lvfilter,tp,LOCATION_MZONE,0,nil,0) local g=Duel.GetMatchingGroup(c74563606.lvfilter,tp,LOCATION_MZONE,0,nil,6)
local lc=g:GetFirst() local lc=g:GetFirst()
while lc do while lc do
if lc:IsLevelAbove(0) then if lc:IsLevelAbove(0) then
......
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