Commit 20a85a68 authored by Nemo Ma's avatar Nemo Ma

fix

parent d321160c
...@@ -36,7 +36,7 @@ function c113398100.cfilter(c) ...@@ -36,7 +36,7 @@ function c113398100.cfilter(c)
return c:IsRace(RACE_SPELLCASTER) and (c:IsLocation(LOCATION_GRAVE) or c:IsFaceup()) return c:IsRace(RACE_SPELLCASTER) and (c:IsLocation(LOCATION_GRAVE) or c:IsFaceup())
end end
function c113398100.drcon(e,tp,eg,ep,ev,re,r,rp) function c113398100.drcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp and Duel.IsExistingMatchingCard(c113398100.cfilter,tp,LOCATION_MZONE+LOCATION_GRAVE,0,1,nil) return Duel.GetTurnPlayer()==tp --and Duel.IsExistingMatchingCard(c113398100.cfilter,tp,LOCATION_MZONE+LOCATION_GRAVE,0,1,nil)
end end
function c113398100.filter(c) function c113398100.filter(c)
return c:IsSetCard(0x306e) and c:GetCode()~=113398100 and c:IsType(TYPE_SPELL) and c:IsAbleToDeck() return c:IsSetCard(0x306e) and c:GetCode()~=113398100 and c:IsType(TYPE_SPELL) and c:IsAbleToDeck()
......
function c114824019.initial_effect(c) function c114824019.initial_effect(c)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetTarget(c114824019.shtg) e1:SetTarget(c114824019.shtg)
e1:SetOperation(c114824019.shop) e1:SetOperation(c114824019.shop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone() local e2=e1:Clone()
e2:SetCode(EVENT_FLIP) e2:SetCode(EVENT_FLIP)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_SUMMON) e3:SetCategory(CATEGORY_SUMMON)
e3:SetType(EFFECT_TYPE_QUICK_O) e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetRange(LOCATION_HAND) e3:SetRange(LOCATION_HAND)
e3:SetCode(EVENT_FREE_CHAIN) e3:SetCode(EVENT_FREE_CHAIN)
e3:SetHintTiming(0,TIMING_DRAW_PHASE+TIMING_CHAIN_END+TIMING_END_PHASE) e3:SetHintTiming(0,TIMING_DRAW_PHASE+TIMING_CHAIN_END+TIMING_END_PHASE)
e3:SetCost(c114824019.sumcost) e3:SetCost(c114824019.sumcost)
e3:SetTarget(c114824019.sumtg) e3:SetTarget(c114824019.sumtg)
e3:SetOperation(c114824019.sumop) e3:SetOperation(c114824019.sumop)
c:RegisterEffect(e3) c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE) e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetCode(EFFECT_CANNOT_MSET) e4:SetCode(EFFECT_CANNOT_MSET)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c114824019.filter(c) function c114824019.filter(c)
return c:IsSetCard(0x306e) and c:IsType(TYPE_SPELL) and c:IsAbleToHand() return c:IsSetCard(0x306e) and c:IsType(TYPE_SPELL) and c:IsAbleToHand()
end end
function c114824019.shtg(e,tp,eg,ep,ev,re,r,rp,chk) function c114824019.shtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end end
function c114824019.shop(e,tp,eg,ep,ev,re,r,rp) function c114824019.shop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c114824019.filter,tp,LOCATION_DECK,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c114824019.filter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT) Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g) Duel.ConfirmCards(1-tp,g)
end end
end end
function c114824019.sumcost(e,tp,eg,ep,ev,re,r,rp,chk) function c114824019.sumcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return Duel.GetFlagEffect(tp,114824019)==0 end if chk==0 then return Duel.GetFlagEffect(tp,114824019)==0 end
Duel.RegisterFlagEffect(tp,114824019,RESET_CHAIN,0,1) Duel.RegisterFlagEffect(tp,114824019,RESET_CHAIN,0,1)
end end
function c114824019.sumtg(e,tp,eg,ep,ev,re,r,rp,chk) function c114824019.sumtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsSummonable(true,nil) or e:GetHandler():IsMSetable(true,nil) end if chk==0 then return e:GetHandler():IsSummonable(false,nil) or e:GetHandler():IsMSetable(true,nil) end
Duel.SetOperationInfo(0,CATEGORY_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SUMMON,e:GetHandler(),1,0,0)
end end
function c114824019.sumop(e,tp,eg,ep,ev,re,r,rp) function c114824019.sumop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end if not c:IsRelateToEffect(e) then return end
Duel.Summon(tp,c,true,nil) Duel.Summon(tp,c,false,nil)
end end
\ No newline at end of file
...@@ -40,6 +40,7 @@ function cm.dfilter(c) ...@@ -40,6 +40,7 @@ function cm.dfilter(c)
return c:IsFaceup() and c:IsCode(40010230) return c:IsFaceup() and c:IsCode(40010230)
end end
function cm.actcon(e,tp,eg,ep,ev,re,r,rp) function cm.actcon(e,tp,eg,ep,ev,re,r,rp)
local tp=e:GetHandlerPlayer()
return Duel.GetFlagEffect(tp,40009560)>0 or Duel.IsExistingMatchingCard(cm.dfilter,tp,LOCATION_MZONE,0,1,nil) return Duel.GetFlagEffect(tp,40009560)>0 or Duel.IsExistingMatchingCard(cm.dfilter,tp,LOCATION_MZONE,0,1,nil)
end end
function cm.cfilter(c) function cm.cfilter(c)
......
...@@ -39,6 +39,7 @@ function cm.dfilter(c) ...@@ -39,6 +39,7 @@ function cm.dfilter(c)
return c:IsFaceup() and c:IsCode(40010230) return c:IsFaceup() and c:IsCode(40010230)
end end
function cm.actcon(e,tp,eg,ep,ev,re,r,rp) function cm.actcon(e,tp,eg,ep,ev,re,r,rp)
local tp=e:GetHandlerPlayer()
return Duel.GetFlagEffect(tp,40009560)>0 or Duel.IsExistingMatchingCard(cm.dfilter,tp,LOCATION_MZONE,0,1,nil) return Duel.GetFlagEffect(tp,40009560)>0 or Duel.IsExistingMatchingCard(cm.dfilter,tp,LOCATION_MZONE,0,1,nil)
end end
function cm.cfilter(c) function cm.cfilter(c)
......
...@@ -38,6 +38,7 @@ function cm.dfilter(c) ...@@ -38,6 +38,7 @@ function cm.dfilter(c)
return c:IsFaceup() and c:IsCode(40010230) return c:IsFaceup() and c:IsCode(40010230)
end end
function cm.actcon(e,tp,eg,ep,ev,re,r,rp) function cm.actcon(e,tp,eg,ep,ev,re,r,rp)
local tp=e:GetHandlerPlayer()
return Duel.GetFlagEffect(tp,40009560)>0 or Duel.IsExistingMatchingCard(cm.dfilter,tp,LOCATION_MZONE,0,1,nil) return Duel.GetFlagEffect(tp,40009560)>0 or Duel.IsExistingMatchingCard(cm.dfilter,tp,LOCATION_MZONE,0,1,nil)
end end
function cm.tfilter(c,tp) function cm.tfilter(c,tp)
......
...@@ -38,7 +38,8 @@ function c72410620.initial_effect(c) ...@@ -38,7 +38,8 @@ function c72410620.initial_effect(c)
end end
function c72410620.spcon(e,c) function c72410620.spcon(e,c)
if c==nil then return true end if c==nil then return true end
return Duel.GetMatchingGroupCount(nil,c:GetControler(),LOCATION_ONFIELD,LOCATION_ONFIELD,nil)>=7 local g=Duel.GetFieldGroup(0,LOCATION_ONFIELD,LOCATION_ONFIELD)
return #g>=7 and g:FilterCount(Card.IsAbleToGraveAsCost,nil)==#g
end end
function c72410620.spop(e,tp,eg,ep,ev,re,r,rp,c) function c72410620.spop(e,tp,eg,ep,ev,re,r,rp,c)
......
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