Commit f6964062 authored by salix5's avatar salix5

fix

parent 92564431
......@@ -8,15 +8,18 @@ function c6859683.initial_effect(c)
e1:SetOperation(c6859683.operation)
c:RegisterEffect(e1)
end
function c6859683.filter(c)
not c:IsType(TYPE_PENDULUM)
end
function c6859683.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetFieldGroupCount(tp,0,LOCATION_EXTRA)>=2 end
local g=Duel.GetFieldGroup(tp,0,LOCATION_EXTRA)
if chk==0 then return g:FilterCount(c6859683.filter,nil)>=2 end
end
function c6859683.operation(e,tp,eg,ep,ev,re,r,rp)
local cg=Duel.GetFieldGroup(tp,0,LOCATION_EXTRA)
Duel.ConfirmCards(tp,cg)
local g=Duel.GetMatchingGroup(Card.IsType,1-tp,LOCATION_EXTRA,0,nil,TYPE_FUSION)
if g:GetCount()<2 then return end
local rg=g:RandomSelect(tp,2)
Duel.SendtoGrave(rg,REASON_EFFECT)
if rg:GetCount()<2 then
local cg=Duel.GetFieldGroup(tp,0,LOCATION_EXTRA)
Duel.ConfirmCards(tp,cg)
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