Commit 5f933e40 authored by POLYMER's avatar POLYMER

fix

parent 2cd4ac4b
......@@ -58,7 +58,7 @@ if not Duel.GetMustMaterial then
end
end
function cm.spfilter(c,sc)
return c:IsCanBeXyzMaterial(sc) and ((c:IsOnField() and c:IsFaceup() and (c:IsXyzLevel(sc,8) or c:IsRank(8) or (c:IsAttribute(ATTRIBUTE_FIRE) and c:IsRace(RACE_FAIRY)))) or (c:IsLocation(LOCATION_HAND) and (c:IsAttribute(ATTRIBUTE_FIRE) and c:IsRace(RACE_FAIRY))))
return c:IsCanBeXyzMaterial(sc) and ((c:IsOnField() and c:IsFaceup() and (c:IsXyzLevel(sc,8) or c:IsRank(8) or (c:IsAttribute(ATTRIBUTE_FIRE) and c:IsRace(RACE_FAIRY)))) or (c:IsLocation(LOCATION_HAND) and (c:IsAttribute(ATTRIBUTE_FIRE) and c:IsRace(RACE_FAIRY))) or (c:IsXyzLevel(sc,8) or c:IsRank(8)))
end
function cm.hand(g)
return g:FilterCount(Card.IsLocation,nil,LOCATION_HAND)<=1
......@@ -73,6 +73,7 @@ function cm.spcon(e,c,og,min,max)
maxc=math.min(maxc,max)
end
if maxc<minc then return false end
local mg=nil
local g=Duel.GetMatchingGroup(cm.spfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,c,c)
if og then
mg=og:Filter(cm.spfilter,c,c)
......@@ -96,6 +97,7 @@ function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk,c,og,min,max)
if max<maxc then maxc=max end
end
local g=Duel.GetMatchingGroup(cm.spfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,c,c)
local mg=nil
if og then
mg=og:Filter(cm.spfilter,c,c)
else
......
......@@ -56,7 +56,7 @@ if not Duel.GetMustMaterial then
end
end
function cm.spfilter(c,sc)
return c:IsCanBeXyzMaterial(sc) and ((c:IsOnField() and c:IsFaceup() and (c:IsXyzLevel(sc,8) or c:IsRank(8) or (c:IsAttribute(ATTRIBUTE_WATER) and c:IsRace(RACE_FAIRY)))) or (c:IsLocation(LOCATION_HAND) and (c:IsAttribute(ATTRIBUTE_WATER) and c:IsRace(RACE_FAIRY))))
return c:IsCanBeXyzMaterial(sc) and ((c:IsOnField() and c:IsFaceup() and (c:IsXyzLevel(sc,8) or c:IsRank(8) or (c:IsAttribute(ATTRIBUTE_WATER) and c:IsRace(RACE_FAIRY)))) or (c:IsLocation(LOCATION_HAND) and (c:IsAttribute(ATTRIBUTE_WATER) and c:IsRace(RACE_FAIRY))) or (c:IsXyzLevel(sc,8) or c:IsRank(8)))
end
function cm.hand(g)
return g:FilterCount(Card.IsLocation,nil,LOCATION_HAND)<=1
......@@ -71,6 +71,7 @@ function cm.spcon(e,c,og,min,max)
maxc=math.min(maxc,max)
end
if maxc<minc then return false end
local mg=nil
local g=Duel.GetMatchingGroup(cm.spfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,c,c)
if og then
mg=og:Filter(cm.spfilter,c,c)
......@@ -94,6 +95,7 @@ function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk,c,og,min,max)
if max<maxc then maxc=max end
end
local g=Duel.GetMatchingGroup(cm.spfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,c,c)
local mg=nil
if og then
mg=og:Filter(cm.spfilter,c,c)
else
......
......@@ -160,6 +160,7 @@ end
function cm.desop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tg=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS)
if not tg then return end
local cg=tg:Filter(cm.imfilter,nil,e,re)
if c:IsRelateToEffect(e) and #cg>0 then
Duel.Overlay(c,cg)
......
......@@ -98,7 +98,7 @@ end
function s.locfilter1(c)
return c:IsPreviousLocation(LOCATION_ONFIELD) and c:IsLocation(LOCATION_ONFIELD)
and (c:GetPreviousSequence()~=c:GetSequence() or c:GetPreviousControler()~=c:GetControler() or c:GetPreviousLocation()~=c:GetLocation())
and c:GetFlagEffect(id)==0
and c:GetFlagEffect(id+1)==0
end
function s.descon(e,tp,eg,ep,ev,re,r,rp)
......
--神力释放-真祖姿态
function c98500310.initial_effect(c)
aux.AddCodeList(c,10000000,10000010,10000020)
aux.EnableChangeCode(c,7373632,LOCATION_MZONE+LOCATION_GRAVE)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(98500310,0))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_TOGRAVE)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCondition(c98500310.condition2)
e1:SetTarget(c98500310.target)
e1:SetOperation(c98500310.activate)
c:RegisterEffect(e1)
--SpecialSummon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(98500310,1))
e2:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_SZONE)
e2:SetCountLimit(1,98500311)
e2:SetCondition(c98500310.condition2)
e2:SetTarget(c98500310.sptg)
e2:SetOperation(c98500310.spop)
c:RegisterEffect(e2)
--fusion summon
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(98500310,2))
e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_SZONE)
e3:SetCountLimit(1,98500311)
e3:SetCondition(c98500310.condition2)
e3:SetTarget(c98500310.fstg)
e3:SetOperation(c98500310.fsop)
c:RegisterEffect(e3)
Duel.AddCustomActivityCounter(98500310,ACTIVITY_SPSUMMON,c98500310.counterfilter)
aux.AddCodeList(c,10000000,10000010,10000020)
aux.EnableChangeCode(c,7373632,LOCATION_MZONE+LOCATION_GRAVE)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(98500310,0))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_TOGRAVE)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetTarget(c98500310.target)
e1:SetOperation(c98500310.activate)
c:RegisterEffect(e1)
--SpecialSummon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(98500310,1))
e2:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_SZONE)
e2:SetCountLimit(1,98500311)
e2:SetTarget(c98500310.sptg)
e2:SetOperation(c98500310.spop)
c:RegisterEffect(e2)
--fusion summon
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(98500310,2))
e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_SZONE)
e3:SetCountLimit(1,98500311)
e3:SetTarget(c98500310.fstg)
e3:SetOperation(c98500310.fsop)
c:RegisterEffect(e3)
Duel.AddCustomActivityCounter(98500310,ACTIVITY_SPSUMMON,c98500310.counterfilter)
end
function c98500310.counterfilter(c)
return not (c:IsAttribute(ATTRIBUTE_DIVINE) and c:IsSummonLocation(LOCATION_HAND) and c:IsLevel(12))
return not (c:IsAttribute(ATTRIBUTE_DIVINE) and c:IsSummonLocation(LOCATION_HAND) and c:IsLevel(12))
end
function c98500310.cfilter(c)
return c:IsFaceup() and c:IsRace(RACE_DIVINE)
return c:IsFaceup() and c:IsRace(RACE_DIVINE)
end
function c98500310.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c98500310.cfilter,tp,LOCATION_MZONE,0,1,nil)
return Duel.IsExistingMatchingCard(c98500310.cfilter,tp,LOCATION_MZONE,0,1,nil)
end
function c98500310.condition2(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(c98500310.cfilter,tp,LOCATION_MZONE,0,1,nil)
return not Duel.IsExistingMatchingCard(c98500310.cfilter,tp,LOCATION_MZONE,0,1,nil)
end
function c98500310.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetCustomActivityCount(98500310,tp,ACTIVITY_SPSUMMON)==0 end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTargetRange(1,0)
e1:SetTarget(c98500310.splimit)
Duel.RegisterEffect(e1,tp)
if chk==0 then return Duel.GetCustomActivityCount(98500310,tp,ACTIVITY_SPSUMMON)==0 end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTargetRange(1,0)
e1:SetTarget(c98500310.splimit)
Duel.RegisterEffect(e1,tp)
end
function c98500310.splimit(e,c,sump,sumtype,sumpos,targetp,se)
return c:IsAttribute(ATTRIBUTE_DIVINE) and c:IsLocation(LOCATION_HAND) and c:IsLevel(12)
return c:IsAttribute(ATTRIBUTE_DIVINE) and c:IsLocation(LOCATION_HAND) and c:IsLevel(12)
end
function c98500310.thfilter(c)
return c:IsCode(10000000,10000010,10000020) and c:IsAbleToHand()
return c:IsCode(10000000,10000010,10000020) and c:IsAbleToHand()
end
function c98500310.tgfilter(c)
return c:IsCode(10000000,10000010,10000020) and c:IsAbleToGrave()
return c:IsCode(10000000,10000010,10000020) and c:IsAbleToGrave()
end
function c98500310.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c98500310.thfilter,tp,LOCATION_DECK,0,1,nil) or Duel.IsExistingMatchingCard(c98500310.tgfilter,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end
local b1=Duel.IsExistingMatchingCard(c98500310.thfilter,tp,LOCATION_DECK,0,1,nil)
local b2=Duel.IsExistingMatchingCard(c98500310.tgfilter,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil)
if chk==0 then return Duel.IsExistingMatchingCard(c98500310.thfilter,tp,LOCATION_DECK,0,1,nil) or Duel.IsExistingMatchingCard(c98500310.tgfilter,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end
local b1=Duel.IsExistingMatchingCard(c98500310.thfilter,tp,LOCATION_DECK,0,1,nil)
local b2=Duel.IsExistingMatchingCard(c98500310.tgfilter,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil)
local op=aux.SelectFromOptions(tp,
{b1,aux.Stringid(98500310,0)},
{b2,aux.Stringid(98500310,6)})
e:SetLabel(op)
if op==1 then
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
else
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK+LOCATION_HAND)
end
{b1,aux.Stringid(98500310,0)},
{b2,aux.Stringid(98500310,6)})
e:SetLabel(op)
if op==1 then
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
else
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK+LOCATION_HAND)
end
end
function c98500310.activate(e,tp,eg,ep,ev,re,r,rp)
local op=e:GetLabel()
if op==1 then
local g=Duel.GetMatchingGroup(c98500310.thfilter,tp,LOCATION_DECK,0,nil)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(98500310,7)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local sg=g:Select(tp,1,1,nil)
Duel.SendtoHand(sg,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,sg)
end
elseif op==2 then
local g=Duel.GetMatchingGroup(c98500310.thfilter,tp,LOCATION_HAND+LOCATION_DECK,0,nil)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(98500310,8)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local sg=g:Select(tp,1,1,nil)
Duel.SendtoGrave(sg,nil,REASON_EFFECT)
end
end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetTargetRange(1,0)
e1:SetTarget(c98500310.splimit)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
local op=e:GetLabel()
if op==1 then
local g=Duel.GetMatchingGroup(c98500310.thfilter,tp,LOCATION_DECK,0,nil)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(98500310,7)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local sg=g:Select(tp,1,1,nil)
Duel.SendtoHand(sg,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,sg)
end
elseif op==2 then
local g=Duel.GetMatchingGroup(c98500310.thfilter,tp,LOCATION_HAND+LOCATION_DECK,0,nil)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(98500310,8)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local sg=g:Select(tp,1,1,nil)
Duel.SendtoGrave(sg,nil,REASON_EFFECT)
end
end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetTargetRange(1,0)
e1:SetTarget(c98500310.splimit)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function c98500310.splimit(e,c)
return not c:IsRace(RACE_DIVINE)
return not c:IsRace(RACE_DIVINE)
end
function c98500310.spcostfilter1(c)
return c:IsAbleToDeck() and c:IsLocation(LOCATION_ONFIELD) and c:IsOriginalCodeRule(10000000)
return c:IsAbleToDeck() and c:IsLocation(LOCATION_ONFIELD) and c:IsOriginalCodeRule(10000000)
end
function c98500310.spopfilter1(c,e,tp)
return c:IsCode(98500323) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
return c:IsCode(98500323) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
end
function c98500310.spcostfilter2(c,e,tp,tc)
return c:IsAbleToDeck() and c:IsLocation(LOCATION_ONFIELD) and c:IsOriginalCodeRule(10000010)
return c:IsAbleToDeck() and c:IsLocation(LOCATION_ONFIELD) and c:IsOriginalCodeRule(10000010)
end
function c98500310.spopfilter2(c,e,tp)
return c:IsCode(98500322) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
return c:IsCode(98500322) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
end
function c98500310.spcostfilter3(c,e,tp,tc)
return c:IsAbleToDeck() and c:IsLocation(LOCATION_ONFIELD) and c:IsOriginalCodeRule(10000020)
return c:IsAbleToDeck() and c:IsLocation(LOCATION_ONFIELD) and c:IsOriginalCodeRule(10000020)
end
function c98500310.spopfilter3(c,e,tp)
return c:IsCode(98500324) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
return c:IsCode(98500324) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
end
function c98500310.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return (Duel.IsExistingMatchingCard(c98500310.spcostfilter1,tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsExistingMatchingCard(c98500310.spopfilter1,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,e,tp))
or (Duel.IsExistingMatchingCard(c98500310.spcostfilter2,tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsExistingMatchingCard(c98500310.spopfilter2,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,e,tp))
or (Duel.IsExistingMatchingCard(c98500310.spcostfilter3,tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsExistingMatchingCard(c98500310.spopfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,e,tp)) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK+LOCATION_HAND)
if chk==0 then return (Duel.IsExistingMatchingCard(c98500310.spcostfilter1,tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsExistingMatchingCard(c98500310.spopfilter1,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,e,tp))
or (Duel.IsExistingMatchingCard(c98500310.spcostfilter2,tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsExistingMatchingCard(c98500310.spopfilter2,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,e,tp))
or (Duel.IsExistingMatchingCard(c98500310.spcostfilter3,tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsExistingMatchingCard(c98500310.spopfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,e,tp)) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK+LOCATION_HAND)
end
function c98500310.spop(e,tp,eg,ep,ev,re,r,rp)
local b1=Duel.IsExistingMatchingCard(c98500310.spcostfilter1,tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsExistingMatchingCard(c98500310.spopfilter1,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,e,tp)
local b2=Duel.IsExistingMatchingCard(c98500310.spcostfilter2,tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsExistingMatchingCard(c98500310.spopfilter2,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,e,tp)
local b3=Duel.IsExistingMatchingCard(c98500310.spcostfilter3,tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsExistingMatchingCard(c98500310.spopfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,e,tp)
local op=aux.SelectFromOptions(tp,{b1,aux.Stringid(98500310,4)},{b2,aux.Stringid(98500310,5)},{b3,aux.Stringid(98500310,3)})
if op==1 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,c98500310.spcostfilter1,tp,LOCATION_ONFIELD,0,1,1,nil)
Duel.SendtoDeck(g,nil,SEQ_DECKBOTTOM,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tc2=Duel.SelectMatchingCard(tp,c98500310.spopfilter1,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil,e,tp):GetFirst()
Duel.SpecialSummon(tc2,0,tp,tp,true,false,POS_FACEUP)
tc2:CompleteProcedure()
elseif op==2 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g3=Duel.SelectMatchingCard(tp,c98500310.spcostfilter2,tp,LOCATION_ONFIELD,0,1,1,nil)
Duel.SendtoDeck(g3,nil,SEQ_DECKBOTTOM,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tc4=Duel.SelectMatchingCard(tp,c98500310.spopfilter2,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil,e,tp):GetFirst()
Duel.SpecialSummon(tc4,0,tp,tp,true,false,POS_FACEUP)
tc4:CompleteProcedure()
elseif op==3 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g5=Duel.SelectMatchingCard(tp,c98500310.spcostfilter3,tp,LOCATION_ONFIELD,0,1,1,nil)
Duel.SendtoDeck(g5,nil,SEQ_DECKBOTTOM,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tc6=Duel.SelectMatchingCard(tp,c98500310.spopfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil,e,tp):GetFirst()
Duel.SpecialSummon(tc6,0,tp,tp,true,false,POS_FACEUP)
tc6:CompleteProcedure()
end
local b1=Duel.IsExistingMatchingCard(c98500310.spcostfilter1,tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsExistingMatchingCard(c98500310.spopfilter1,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,e,tp)
local b2=Duel.IsExistingMatchingCard(c98500310.spcostfilter2,tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsExistingMatchingCard(c98500310.spopfilter2,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,e,tp)
local b3=Duel.IsExistingMatchingCard(c98500310.spcostfilter3,tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsExistingMatchingCard(c98500310.spopfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,e,tp)
local op=aux.SelectFromOptions(tp,{b1,aux.Stringid(98500310,4)},{b2,aux.Stringid(98500310,5)},{b3,aux.Stringid(98500310,3)})
if op==1 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,c98500310.spcostfilter1,tp,LOCATION_ONFIELD,0,1,1,nil)
Duel.SendtoDeck(g,nil,SEQ_DECKBOTTOM,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tc2=Duel.SelectMatchingCard(tp,c98500310.spopfilter1,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil,e,tp):GetFirst()
Duel.SpecialSummon(tc2,0,tp,tp,true,false,POS_FACEUP)
tc2:CompleteProcedure()
elseif op==2 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g3=Duel.SelectMatchingCard(tp,c98500310.spcostfilter2,tp,LOCATION_ONFIELD,0,1,1,nil)
Duel.SendtoDeck(g3,nil,SEQ_DECKBOTTOM,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tc4=Duel.SelectMatchingCard(tp,c98500310.spopfilter2,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil,e,tp):GetFirst()
Duel.SpecialSummon(tc4,0,tp,tp,true,false,POS_FACEUP)
tc4:CompleteProcedure()
elseif op==3 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g5=Duel.SelectMatchingCard(tp,c98500310.spcostfilter3,tp,LOCATION_ONFIELD,0,1,1,nil)
Duel.SendtoDeck(g5,nil,SEQ_DECKBOTTOM,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tc6=Duel.SelectMatchingCard(tp,c98500310.spopfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil,e,tp):GetFirst()
Duel.SpecialSummon(tc6,0,tp,tp,true,false,POS_FACEUP)
tc6:CompleteProcedure()
end
end
function c98500310.fsfilter1(c,e)
return c:IsRace(RACE_DIVINE) and c:IsAbleToRemove() and not c:IsImmuneToEffect(e)
return c:IsRace(RACE_DIVINE) and c:IsAbleToRemove() and not c:IsImmuneToEffect(e)
end
function c98500310.fsfilter2(c,e,tp,m,chkf)
return c:IsCanBeSpecialSummoned(e,0,tp,true,false) and c:CheckFusionMaterial(m,nil,chkf,true)
return c:IsCanBeSpecialSummoned(e,0,tp,true,false) and c:CheckFusionMaterial(m,nil,chkf,true)
end
function c98500310.fstg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
local chkf=tp|0x200
local mg=Duel.GetMatchingGroup(c98500310.fsfilter1,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,e)
return Duel.IsExistingMatchingCard(c98500310.fsfilter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,mg,chkf)
end
Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,0,tp,LOCATION_HAND+LOCATION_MZONE)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
if chk==0 then
local chkf=tp|0x200
local mg=Duel.GetMatchingGroup(c98500310.fsfilter1,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,e)
return Duel.IsExistingMatchingCard(c98500310.fsfilter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,mg,chkf)
end
Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,0,tp,LOCATION_HAND+LOCATION_MZONE)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c98500310.fsop(e,tp,eg,ep,ev,re,r,rp)
local chkf=tp|0x200
local mg=Duel.GetMatchingGroup(c98500310.fsfilter1,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,e)
local sg=Duel.GetMatchingGroup(c98500310.fsfilter2,tp,LOCATION_EXTRA,0,nil,e,tp,mg,chkf)
if sg:GetCount()>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tg=sg:Select(tp,1,1,nil)
local tc=tg:GetFirst()
local mat=Duel.SelectFusionMaterial(tp,tc,mg,nil,chkf,true)
Duel.Remove(mat,POS_FACEUP,REASON_EFFECT)
Duel.BreakEffect()
Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP)
end
local chkf=tp|0x200
local mg=Duel.GetMatchingGroup(c98500310.fsfilter1,tp,LOCATION_HAND+LOCATION_MZONE,0,nil,e)
local sg=Duel.GetMatchingGroup(c98500310.fsfilter2,tp,LOCATION_EXTRA,0,nil,e,tp,mg,chkf)
if sg:GetCount()>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tg=sg:Select(tp,1,1,nil)
local tc=tg:GetFirst()
local mat=Duel.SelectFusionMaterial(tp,tc,mg,nil,chkf,true)
Duel.Remove(mat,POS_FACEUP,REASON_EFFECT)
Duel.BreakEffect()
Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP)
end
end
--无名的法老
function c98500320.initial_effect(c)
aux.AddCodeList(c,46986414,985003200,10000010,10000020)
aux.AddCodeList(c,46986414,10000000,10000010,10000020)
--to hand
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(98500320,0))
......@@ -36,7 +36,7 @@ function c98500320.initial_effect(c)
e5:SetCode(EVENT_FREE_CHAIN)
e5:SetHintTiming(0,TIMINGS_CHECK_MONSTER)
e5:SetRange(LOCATION_MZONE)
e5:SetCountLimit(1)
e5:SetCountLimit(1)
e5:SetTarget(c98500320.target)
e5:SetOperation(c98500320.operation)
c:RegisterEffect(e5)
......@@ -81,7 +81,7 @@ function c98500320.operation(e,tp,eg,ep,ev,re,r,rp)
e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetValue(1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
tc:RegisterEffect(e1)
-- 添加免疫效果破坏
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_SINGLE)
......
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