Commit fe039100 authored by TanakaKotoha's avatar TanakaKotoha

mopemope

parent e0430abb
Pipeline #809 passed with stages
in 45 minutes and 42 seconds
No preview for this file type
......@@ -42,6 +42,8 @@ function cm.flipop(e,tp,eg,ep,ev,re,r,rp)
if g:GetCount()>0 then
Duel.HintSelection(g)
if Duel.Remove(g,POS_FACEUP,REASON_EFFECT)~=0 then
local ttc=Duel.GetOperatedGroup():GetFirst()
gs.Cntact(ttc)
if Duel.GetMatchingGroupCount(Card.IsFacedown,tp,0,LOCATION_ONFIELD,nil)<=0 then return end
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_FIELD)
......
......@@ -73,6 +73,8 @@ function cm.flipop(e,tp,eg,ep,ev,re,r,rp)
if g:GetCount()>0 then
Duel.HintSelection(g)
if Duel.SendtoGrave(g,REASON_EFFECT)~=0 then
local ttc=Duel.GetOperatedGroup():GetFirst()
gs.Cntact(ttc)
local dg=Duel.GetFieldGroup(tp,LOCATION_DECK,LOCATION_DECK)
if Duel.IsExistingMatchingCard(Card.IsFacedown,tp,0,LOCATION_ONFIELD,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(m,8)) then
Duel.ConfirmCards(tp,dg)
......
......@@ -35,7 +35,8 @@ function cm.flipop(e,tp)
local sg=Duel.SelectMatchingCard(tp,Card.IsAbleToGrave,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
if #sg>0 then
if Duel.SendtoGrave(sg,REASON_EFFECT)~=0 then
gs.Cntact(sg:GetFirst())
local ttc=Duel.GetOperatedGroup():GetFirst()
gs.Cntact(ttc)
if Duel.IsExistingMatchingCard(cm.changefilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,e:GetHandler()) and Duel.SelectYesNo(tp,aux.Stringid(m,5)) then
local sc=Duel.SelectMatchingCard(tp,cm.changefilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,e:GetHandler()):GetFirst()
if not sc:IsImmuneToEffect(e) then
......@@ -54,5 +55,5 @@ function cm.flipop(e,tp)
end
end
end
end
end
end
\ No newline at end of file
......@@ -42,7 +42,8 @@ function cm.flipop(e,tp)
local sg=Duel.SelectMatchingCard(tp,Card.IsAbleToRemove,tp,LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD+LOCATION_GRAVE,1,1,nil)
if #sg>0 then
if Duel.Remove(sg,POS_FACEUP,REASON_EFFECT)~=0 then
gs.Cntact(sg:GetFirst())
local ttc=Duel.GetOperatedGroup():GetFirst()
gs.Cntact(ttc)
if Duel.IsExistingMatchingCard(cm.changefilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,e:GetHandler()) and Duel.SelectYesNo(tp,aux.Stringid(m,5)) then
local sc=Duel.SelectMatchingCard(tp,cm.changefilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,e:GetHandler()):GetFirst()
if not sc:IsImmuneToEffect(e) then
......
......@@ -26,14 +26,14 @@ function cm.initial_effect(c)
e3:SetRange(LOCATION_FZONE)
e3:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_MAIN_END)
e3:SetCountLimit(1)
e1:SetCondition(cm.sumaddcon)
e3:SetCondition(cm.sumaddcon)
e3:SetOperation(cm.sumaddop)
c:RegisterEffect(e3)
--
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(m,3))
e4:SetCategory(CATEGORY_POSITION)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e4:SetCode(EVENT_PHASE+PHASE_END)
e4:SetRange(LOCATION_FZONE)
e4:SetCountLimit(1,m)
......@@ -100,10 +100,9 @@ function cm.econ(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==e:GetHandler():GetControler() and Duel.IsExistingMatchingCard(Card.IsFacedown,tp,LOCATION_ONFIELD,0,1,nil)
end
function cm.thfilter(c,g)
local sg=Group.CreateGroup()
local sg=g
sg:AddCard(c)
local gg=Group.__sub(g,sg)
return gg:GetClassCount(Card.GetRace)==gg:GetCount() and c:IsAbleToHand() and c:IsSetCard(0xcca) and c:IsType(TYPE_MONSTER)
return sg:GetClassCount(Card.GetRace)>=g:GetClassCount(Card.GetRace) and c:IsAbleToHand() and c:IsType(TYPE_MONSTER) and c:IsSetCard(0xcca)
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
......
......@@ -42,6 +42,17 @@ function cm.initial_effect(c)
local e6=e5:Clone()
e6:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e6)
--
local e02=Effect.CreateEffect(c)
e02:SetType(EFFECT_TYPE_SINGLE)
e02:SetCode(EFFECT_LEAVE_FIELD_REDIRECT)
e02:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e02:SetCondition(cm.recon)
e02:SetValue(LOCATION_REMOVED)
c:RegisterEffect(e02)
end
function cm.recon(e)
return e:GetHandler():IsFaceup()
end
function cm.eqfilter(c)
return c:IsFacedown() and Duel.GetLocationCount(tp,LOCATION_SZONE)>0 and (c:IsControler(tp) or c:IsAbleToChangeControler())
......
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