Commit f0b1157c authored by mercury233's avatar mercury233

fix

parent be99e704
...@@ -29,8 +29,7 @@ function c100200229.initial_effect(c) ...@@ -29,8 +29,7 @@ function c100200229.initial_effect(c)
c:RegisterEffect(e3) c:RegisterEffect(e3)
end end
function c100200229.thfilter(c) function c100200229.thfilter(c)
if c:IsFacedown() or not c:IsType(TYPE_PENDULUM) then return false end return c:IsFaceup() and c:IsRace(RACE_MACHINE) and c:IsType(TYPE_PENDULUM) and c:IsAbleToHand()
return c:IsRace(RACE_MACHINE) and c:IsAbleToHand()
end end
function c100200229.thtg(e,tp,eg,ep,ev,re,r,rp,chk) function c100200229.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c100200229.thfilter,tp,LOCATION_EXTRA,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c100200229.thfilter,tp,LOCATION_EXTRA,0,1,nil) end
...@@ -52,12 +51,12 @@ function c100200229.spcost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -52,12 +51,12 @@ function c100200229.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.Release(c,REASON_COST) Duel.Release(c,REASON_COST)
end end
function c100200229.spfilter(c,e,tp) function c100200229.spfilter(c,e,tp)
if c:IsCode(100200229) then return false end return c:IsAttackBelow(1500) and c:IsRace(RACE_MACHINE) and c:IsAttribute(ATTRIBUTE_EARTH)
return c:IsAttackBelow(1500) and c:IsRace(RACE_MACHINE) and c:IsAttribute(ATTRIBUTE_EARTH) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and not c:IsCode(100200229) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function c100200229.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c100200229.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c100200229.spfilter,tp,LOCATION_HAND+LOCATION_GRAVE,0,1,nil,e,tp) end if chk==0 then return Duel.IsExistingMatchingCard(c100200229.spfilter,tp,LOCATION_HAND+LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_GRAVE)
end end
function c100200229.spop(e,tp,eg,ep,ev,re,r,rp) function c100200229.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetMZoneCount(tp)>0 then if Duel.GetMZoneCount(tp)>0 then
......
...@@ -52,7 +52,7 @@ function s.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -52,7 +52,7 @@ function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function s.operation(e,tp,eg,ep,ev,re,r,rp) function s.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if c:IsRelateToEffect(e) then Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) if c:IsRelateToEffect(e) then Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) end
end end
function s.filter(c,e,tp) function s.filter(c,e,tp)
return not c:IsRace(RACE_WARRIOR) and c:IsSetCard(0x290) return not c:IsRace(RACE_WARRIOR) and c:IsSetCard(0x290)
......
...@@ -38,14 +38,12 @@ end ...@@ -38,14 +38,12 @@ end
function c101112002.thop(e,tp,eg,ep,ev,re,r,rp) function c101112002.thop(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,c101112002.thfilter,tp,LOCATION_DECK,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c101112002.thfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 and Duel.SendtoHand(g,nil,REASON_EFFECT)~=0 then if g:GetCount()>0 and Duel.SendtoHand(g,nil,REASON_EFFECT)~=0 and g:GetFirst():IsLocation(LOCATION_HAND) then
Duel.ConfirmCards(1-tp,g) Duel.ConfirmCards(1-tp,g)
if g:GetFirst():IsLocation(LOCATION_HAND) and Duel.GetFieldGroupCount(tp,LOCATION_HAND,0)>0 then
Duel.BreakEffect() Duel.BreakEffect()
Duel.ShuffleHand(tp) Duel.ShuffleHand(tp)
Duel.DiscardHand(tp,aux.TRUE,1,1,REASON_EFFECT+REASON_DISCARD,nil) Duel.DiscardHand(tp,aux.TRUE,1,1,REASON_EFFECT+REASON_DISCARD,nil)
end end
end
end end
function c101112002.op(e,tp,eg,ep,ev,re,r,rp) function c101112002.op(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
......
...@@ -61,6 +61,7 @@ function c101112003.lvop(e,tp,eg,ep,ev,re,r,rp) ...@@ -61,6 +61,7 @@ function c101112003.lvop(e,tp,eg,ep,ev,re,r,rp)
if tc:IsRelateToEffect(e) and tc:IsFaceup() then if tc:IsRelateToEffect(e) and tc:IsFaceup() then
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EFFECT_UPDATE_LEVEL) e1:SetCode(EFFECT_UPDATE_LEVEL)
e1:SetValue(2) e1:SetValue(2)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
......
...@@ -37,15 +37,14 @@ function c101112004.setcost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -37,15 +37,14 @@ function c101112004.setcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return c:IsReleasable() end if chk==0 then return c:IsReleasable() end
Duel.Release(c,REASON_COST) Duel.Release(c,REASON_COST)
end end
function c101112004.setfilter(c,tp) function c101112004.setfilter(c)
return c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsSSetable(true) return c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsSSetable()
and (c:IsType(TYPE_FIELD) or Duel.GetLocationCount(tp,LOCATION_SZONE)>0)
end end
function c101112004.settg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c101112004.settg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_GRAVE) and c101112004.setfilter(chkc,tp) end if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_GRAVE) and c101112004.setfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c101112004.setfilter,tp,0,LOCATION_GRAVE,1,nil,tp) end if chk==0 then return Duel.IsExistingTarget(c101112004.setfilter,tp,0,LOCATION_GRAVE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local g=Duel.SelectTarget(tp,c101112004.setfilter,tp,0,LOCATION_GRAVE,1,1,nil,tp) local g=Duel.SelectTarget(tp,c101112004.setfilter,tp,0,LOCATION_GRAVE,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,g,1,0,0)
end end
function c101112004.setop(e,tp,eg,ep,ev,re,r,rp) function c101112004.setop(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -70,7 +70,7 @@ function c101112005.sptg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -70,7 +70,7 @@ function c101112005.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0)
end end
function c101112005.spop(e,tp,eg,ep,ev,re,r,rp) function c101112005.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
......
...@@ -57,7 +57,7 @@ function c101112006.pcop(e,tp,eg,ep,ev,re,r,rp) ...@@ -57,7 +57,7 @@ function c101112006.pcop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local g=Duel.SelectMatchingCard(tp,c101112006.pcfilter,tp,LOCATION_DECK,0,1,1,nil,tp) local g=Duel.SelectMatchingCard(tp,c101112006.pcfilter,tp,LOCATION_DECK,0,1,1,nil,tp)
if #g==0 or not Duel.MoveToField(g:GetFirst(),tp,tp,LOCATION_PZONE,POS_FACEUP,true) then return end if #g==0 or not Duel.MoveToField(g:GetFirst(),tp,tp,LOCATION_PZONE,POS_FACEUP,true) then return end
if not c:IsRelateToEffect(e) then return end if not c:IsRelateToEffect(e) or Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.BreakEffect() Duel.BreakEffect()
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end end
...@@ -65,13 +65,13 @@ function c101112006.costfilter(c,e,tp) ...@@ -65,13 +65,13 @@ function c101112006.costfilter(c,e,tp)
return c:IsType(TYPE_MONSTER) and c:IsDiscardable() return c:IsType(TYPE_MONSTER) and c:IsDiscardable()
and Duel.IsExistingMatchingCard(c101112006.spfilter,tp,LOCATION_HAND+LOCATION_DECK,0,1,c,e,tp) and Duel.IsExistingMatchingCard(c101112006.spfilter,tp,LOCATION_HAND+LOCATION_DECK,0,1,c,e,tp)
end end
function c101112006.spfilter(c,e,tp)
return c:IsSetCard(0x9a) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE)
end
function c101112006.spcost(e,tp,eg,ep,ev,re,r,rp,chk) function c101112006.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c101112006.costfilter,tp,LOCATION_HAND,0,1,nil,e,tp) end if chk==0 then return Duel.IsExistingMatchingCard(c101112006.costfilter,tp,LOCATION_HAND,0,1,nil,e,tp) end
Duel.DiscardHand(tp,c101112006.costfilter,1,1,REASON_COST+REASON_DISCARD,nil,e,tp) Duel.DiscardHand(tp,c101112006.costfilter,1,1,REASON_COST+REASON_DISCARD,nil,e,tp)
end end
function c101112006.spfilter(c,e,tp)
return c:IsSetCard(0x9a) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE)
end
function c101112006.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c101112006.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c101112006.spfilter,tp,LOCATION_HAND+LOCATION_DECK,0,1,nil,e,tp) end and Duel.IsExistingMatchingCard(c101112006.spfilter,tp,LOCATION_HAND+LOCATION_DECK,0,1,nil,e,tp) end
......
...@@ -34,7 +34,7 @@ function c101112010.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -34,7 +34,7 @@ function c101112010.spop(e,tp,eg,ep,ev,re,r,rp)
if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE) local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
if ft>0 and Duel.IsPlayerCanSpecialSummonMonster(tp,101112110,0x16c,TYPES_TOKEN_MONSTER,0,0,3,RACE_AQUA,ATTRIBUTE_WATER) if ft>0 and Duel.IsPlayerCanSpecialSummonMonster(tp,101112110,0x16c,TYPES_TOKEN_MONSTER,0,0,3,RACE_AQUA,ATTRIBUTE_WATER)
and Duel.SelectYesNo(tp,aux.Stringid(101112010,2)) then and Duel.SelectYesNo(tp,aux.Stringid(101112010,1)) then
Duel.BreakEffect() Duel.BreakEffect()
local token=Duel.CreateToken(tp,101112110) local token=Duel.CreateToken(tp,101112110)
Duel.SpecialSummonStep(token,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummonStep(token,0,tp,tp,false,false,POS_FACEUP)
......
...@@ -49,7 +49,8 @@ function c101112011.spcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -49,7 +49,8 @@ function c101112011.spcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(Card.IsPreviousLocation,1,nil,LOCATION_EXTRA) return eg:IsExists(Card.IsPreviousLocation,1,nil,LOCATION_EXTRA)
end end
function c101112011.spfilter(c,e,tp) function c101112011.spfilter(c,e,tp)
return (c:IsCode(68468459) or aux.IsCodeListed(c,68468459)) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return (c:IsCode(68468459) or aux.IsCodeListed(c,68468459)) and not c:IsCode(101112011)
and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function c101112011.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c101112011.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c101112011.spfilter(chkc,e,tp) end if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c101112011.spfilter(chkc,e,tp) end
......
...@@ -25,14 +25,14 @@ function s.initial_effect(c) ...@@ -25,14 +25,14 @@ function s.initial_effect(c)
end end
function s.filter(c) function s.filter(c)
local b1=c:IsCode(56099748) local b1=c:IsCode(56099748)
local b2=c:IsAttack(1500) and c:IsDefense(2100) local b2=c:IsAttack(1500) and c:IsDefense(2100) and c:IsType(TYPE_MONSTER)
return c:IsFaceup() and (b1 or b2) return c:IsFaceup() and (b1 or b2)
end end
function s.sprcon(e,c) function s.sprcon(e,c)
if c==nil then return true end if c==nil then return true end
local tp=c:GetControler() local tp=c:GetControler()
return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(s.filter,tp,LOCATION_MZONE,0,1,nil) and Duel.IsExistingMatchingCard(s.filter,tp,LOCATION_ONFIELD,0,1,nil)
end end
function s.spcon(e,tp,eg,ep,ev,re,r,rp) function s.spcon(e,tp,eg,ep,ev,re,r,rp)
return bit.band(r,REASON_EFFECT+REASON_BATTLE)~=0 return bit.band(r,REASON_EFFECT+REASON_BATTLE)~=0
...@@ -46,7 +46,6 @@ function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -46,7 +46,6 @@ function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
end end
function s.spop(e,tp,eg,ep,ev,re,r,rp) function s.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetFlagEffect(tp,id)==0 then
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetCode(EFFECT_UPDATE_ATTACK)
...@@ -56,8 +55,6 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -56,8 +55,6 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
e1:SetTarget(s.atktg) e1:SetTarget(s.atktg)
e1:SetValue(500) e1:SetValue(500)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
Duel.RegisterFlagEffect(tp,id,RESET_PHASE+PHASE_END,0,1)
end
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp)
...@@ -67,7 +64,7 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -67,7 +64,7 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
end end
function s.atkcon(e) function s.atkcon(e)
local ph=Duel.GetCurrentPhase() local ph=Duel.GetCurrentPhase()
return Duel.GetFlagEffect(e:GetHandlerPlayer(),id)>0 and (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE) return ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE
end end
function s.atktg(e,c) function s.atktg(e,c)
return c:IsType(TYPE_SYNCHRO) and c:IsFaceup() return c:IsType(TYPE_SYNCHRO) and c:IsFaceup()
......
...@@ -27,14 +27,14 @@ function s.initial_effect(c) ...@@ -27,14 +27,14 @@ function s.initial_effect(c)
end end
function s.filter(c) function s.filter(c)
local b1=c:IsCode(56099748) local b1=c:IsCode(56099748)
local b2=c:IsAttack(1500) and c:IsDefense(2100) local b2=c:IsAttack(1500) and c:IsDefense(2100) and c:IsType(TYPE_MONSTER)
return c:IsFaceup() and (b1 or b2) return c:IsFaceup() and (b1 or b2)
end end
function s.sprcon(e,c) function s.sprcon(e,c)
if c==nil then return true end if c==nil then return true end
local tp=c:GetControler() local tp=c:GetControler()
return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(s.filter,tp,LOCATION_MZONE,0,1,nil) and Duel.IsExistingMatchingCard(s.filter,tp,LOCATION_ONFIELD,0,1,nil)
end end
function s.spcon(e,tp,eg,ep,ev,re,r,rp) function s.spcon(e,tp,eg,ep,ev,re,r,rp)
return bit.band(r,REASON_EFFECT+REASON_BATTLE)~=0 return bit.band(r,REASON_EFFECT+REASON_BATTLE)~=0
...@@ -51,13 +51,13 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -51,13 +51,13 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp)
if #g==0 then return end
local tc=g:GetFirst() local tc=g:GetFirst()
if Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)>0 and tc:IsLevelAbove(1) if tc and Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)>0 and tc:IsLevelAbove(1)
and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then
Duel.BreakEffect() Duel.BreakEffect()
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EFFECT_UPDATE_LEVEL) e1:SetCode(EFFECT_UPDATE_LEVEL)
e1:SetValue(2) e1:SetValue(2)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
......
--夢見るネムレリア --夢見るネムレリア
--Script by 奥克斯 --Script by 奥克斯
function c101112015.initial_effect(c) function c101112015.initial_effect(c)
c:EnableReviveLimit()
c:SetSPSummonOnce(101112015) c:SetSPSummonOnce(101112015)
--pendulum summon --pendulum summon
aux.EnablePendulumAttribute(c) aux.EnablePendulumAttribute(c)
...@@ -63,21 +64,22 @@ end ...@@ -63,21 +64,22 @@ end
function c101112015.splimit(e,c,sump,sumtype,sumpos,targetp,se) function c101112015.splimit(e,c,sump,sumtype,sumpos,targetp,se)
return c:IsCode(101112015) return c:IsCode(101112015)
end end
function c101112015.mvfilter(c) function c101112015.mvfilter(c,tp)
return not c:IsForbidden() and c:IsSetCard(0x292) and c:GetType()==TYPE_CONTINUOUS+TYPE_SPELL and c:CheckUniqueOnField(tp) return not c:IsForbidden() and c:IsSetCard(0x292) and c:GetType()==TYPE_CONTINUOUS+TYPE_SPELL and c:CheckUniqueOnField(tp)
end end
function c101112015.mvtg(e,tp,eg,ep,ev,re,r,rp,chk) function c101112015.mvtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return not e:GetHandler():IsForbidden() if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0
and Duel.IsExistingMatchingCard(c101112015.mvfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil,e,tp) end and Duel.IsExistingMatchingCard(c101112015.mvfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil,tp) end
end end
function c101112015.mvop(e,tp,eg,ep,ev,re,r,rp) function c101112015.mvop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local g=Duel.GetMatchingGroup(aux.NecroValleyFilter(c101112015.mvfilter),tp,LOCATION_DECK+LOCATION_GRAVE,0,nil,e,tp) local g=Duel.GetMatchingGroup(aux.NecroValleyFilter(c101112015.mvfilter),tp,LOCATION_DECK+LOCATION_GRAVE,0,nil,tp)
if #g==0 or not c:IsRelateToEffect(e) then return end if #g==0 or Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local tc=g:Select(tp,1,1,nil):GetFirst() local tc=g:Select(tp,1,1,nil):GetFirst()
if not Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) then return end if Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) and c:IsRelateToEffect(e) then
Duel.SendtoExtraP(c,nil,REASON_EFFECT) Duel.SendtoExtraP(c,nil,REASON_EFFECT)
end
end end
function c101112015.rmfilter(c) function c101112015.rmfilter(c)
return c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT) return c:IsLocation(LOCATION_REMOVED) and not c:IsReason(REASON_REDIRECT)
......
...@@ -18,7 +18,7 @@ function c101112016.initial_effect(c) ...@@ -18,7 +18,7 @@ function c101112016.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP) e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP)
e2:SetCode(EVENT_FREE_CHAIN) e2:SetCode(EVENT_FREE_CHAIN)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE+TIMING_DAMAGE_STEP) e2:SetHintTiming(TIMING_DAMAGE_STEP,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE+TIMING_DAMAGE_STEP)
e2:SetCountLimit(1,101112016+100) e2:SetCountLimit(1,101112016+100)
e2:SetCondition(c101112016.atkcon) e2:SetCondition(c101112016.atkcon)
e2:SetCost(c101112016.atkcost) e2:SetCost(c101112016.atkcost)
...@@ -48,7 +48,7 @@ end ...@@ -48,7 +48,7 @@ end
function c101112016.atkop(e,tp,eg,ep,ev,re,r,rp) function c101112016.atkop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local ct=Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE) local ct=Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE)
if c:IsRelateToEffect(e) and ct>0 then if c:IsFaceup() and c:IsRelateToEffect(e) and ct>0 then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetCode(EFFECT_UPDATE_ATTACK)
......
...@@ -54,7 +54,8 @@ function s.sptgfilter(c,e,tp) ...@@ -54,7 +54,8 @@ function s.sptgfilter(c,e,tp)
end end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and s.sptgfilter(chkc,e,tp) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and s.sptgfilter(chkc,e,tp) end
if chk==0 then return Duel.IsExistingTarget(s.sptgfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end if chk==0 then return aux.MustMaterialCheck(e:GetHandler(),tp,EFFECT_MUST_BE_XMATERIAL)
and Duel.IsExistingTarget(s.sptgfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
local g=Duel.SelectTarget(tp,s.sptgfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) local g=Duel.SelectTarget(tp,s.sptgfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
...@@ -62,6 +63,7 @@ function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -62,6 +63,7 @@ function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
end end
function s.spop(e,tp,eg,ep,ev,re,r,rp) function s.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if not aux.MustMaterialCheck(c,tp,EFFECT_MUST_BE_XMATERIAL) then return end
local sc=Duel.GetFirstTarget() local sc=Duel.GetFirstTarget()
if not c:IsRelateToChain() or c:IsImmuneToEffect(e) or c:IsFacedown() or c:IsControler(1-tp) then return end if not c:IsRelateToChain() or c:IsImmuneToEffect(e) or c:IsFacedown() or c:IsControler(1-tp) then return end
if not sc:IsRelateToChain() then return end if not sc:IsRelateToChain() then return end
......
--星騎士 アルテア --星騎士 アルテア
--Script by 奥克斯 --Script by 奥克斯
function c101112020.initial_effect(c) function c101112020.initial_effect(c)
--same effect send this card to grave and spsummon another card check
local e0=aux.AddThisCardInGraveAlreadyCheck(c)
--Destroy --Destroy
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DESTROY) e1:SetCategory(CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e1:SetCountLimit(1,101112020) e1:SetCountLimit(1,101112020)
e1:SetTarget(c101112020.destg) e1:SetTarget(c101112020.destg)
e1:SetOperation(c101112020.desop) e1:SetOperation(c101112020.desop)
...@@ -28,7 +26,6 @@ function c101112020.initial_effect(c) ...@@ -28,7 +26,6 @@ function c101112020.initial_effect(c)
e4:SetCode(EVENT_SPSUMMON_SUCCESS) e4:SetCode(EVENT_SPSUMMON_SUCCESS)
e4:SetRange(LOCATION_GRAVE) e4:SetRange(LOCATION_GRAVE)
e4:SetCountLimit(1,101112020+100) e4:SetCountLimit(1,101112020+100)
e4:SetLabelObject(e0)
e4:SetCondition(c101112020.spcon) e4:SetCondition(c101112020.spcon)
e4:SetTarget(c101112020.sptg) e4:SetTarget(c101112020.sptg)
e4:SetOperation(c101112020.spop) e4:SetOperation(c101112020.spop)
...@@ -50,13 +47,12 @@ function c101112020.desop(e,tp,eg,ep,ev,re,r,rp) ...@@ -50,13 +47,12 @@ function c101112020.desop(e,tp,eg,ep,ev,re,r,rp)
if #g==0 then return end if #g==0 then return end
Duel.Destroy(g,REASON_EFFECT) Duel.Destroy(g,REASON_EFFECT)
end end
function c101112020.cfilter(c,tp,se) function c101112020.cfilter(c,tp)
return not c:IsCode(101112020) and c:IsFaceup() and c:IsControler(tp) return not c:IsCode(101112020) and c:IsFaceup() and c:IsControler(tp)
and c:IsSetCard(0x9c,0x53) and (se==nil or c:GetReasonEffect()~=se) and c:IsSetCard(0x9c,0x53)
end end
function c101112020.spcon(e,tp,eg,ep,ev,re,r,rp) function c101112020.spcon(e,tp,eg,ep,ev,re,r,rp)
local se=e:GetLabelObject():GetLabelObject() return eg:IsExists(c101112020.cfilter,1,nil,tp)
return eg:IsExists(c101112020.cfilter,1,nil,tp,se)
end end
function c101112020.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c101112020.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
...@@ -68,7 +64,7 @@ function c101112020.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -68,7 +64,7 @@ function c101112020.spop(e,tp,eg,ep,ev,re,r,rp)
if c:IsRelateToEffect(e) then if c:IsRelateToEffect(e) then
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end end
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_ATTACK_ANNOUNCE) e1:SetCode(EFFECT_CANNOT_ATTACK_ANNOUNCE)
e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE) e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
function c101112021.initial_effect(c) function c101112021.initial_effect(c)
--special summon --special summon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY)
...@@ -18,7 +18,7 @@ function c101112021.initial_effect(c) ...@@ -18,7 +18,7 @@ function c101112021.initial_effect(c)
e2:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND) e2:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_SUMMON_SUCCESS) e2:SetCode(EVENT_SUMMON_SUCCESS)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY) e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCountLimit(1,101112021+100) e2:SetCountLimit(1,101112021+100)
e2:SetTarget(c101112021.thtg) e2:SetTarget(c101112021.thtg)
e2:SetOperation(c101112021.thop) e2:SetOperation(c101112021.thop)
......
...@@ -8,7 +8,7 @@ function c101112022.initial_effect(c) ...@@ -8,7 +8,7 @@ function c101112022.initial_effect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_RELEASE) e1:SetCode(EVENT_RELEASE)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetRange(LOCATION_HAND) e1:SetRange(LOCATION_HAND+LOCATION_GRAVE)
e1:SetCountLimit(1,101112022) e1:SetCountLimit(1,101112022)
e1:SetCondition(c101112022.spcon) e1:SetCondition(c101112022.spcon)
e1:SetTarget(c101112022.sptg) e1:SetTarget(c101112022.sptg)
...@@ -34,11 +34,12 @@ function c101112022.initial_effect(c) ...@@ -34,11 +34,12 @@ function c101112022.initial_effect(c)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c101112022.cfilter(c,tp) function c101112022.cfilter(c,tp)
return c:IsRace(RACE_MACHINE) and c:IsAttribute(ATTRIBUTE_EARTH) return c:GetPreviousAttributeOnField()&ATTRIBUTE_EARTH>0 and c:GetPreviousRaceOnField()&RACE_MACHINE>0
and c:IsPreviousControler(tp) and c:IsPreviousLocation(LOCATION_MZONE) and c:IsPreviousControler(tp) and c:IsPreviousLocation(LOCATION_MZONE)
and (c:IsReason(REASON_RELEASE) or c:IsFaceup())
end end
function c101112022.spcon(e,tp,eg,ep,ev,re,r,rp) function c101112022.spcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c101112022.cfilter,1,nil,tp) return eg:IsExists(c101112022.cfilter,1,nil,tp) and not eg:IsContains(e:GetHandler())
end end
function c101112022.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c101112022.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
......
...@@ -35,6 +35,9 @@ function c101112023.sptg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -35,6 +35,9 @@ function c101112023.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0)
end end
function c101112023.thfilter(c)
return c:IsCode(20989253) and c:IsAbleToHand()
end
function c101112023.spop(e,tp,eg,ep,ev,re,r,rp) function c101112023.spop(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
...@@ -48,11 +51,8 @@ function c101112023.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -48,11 +51,8 @@ function c101112023.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.ConfirmCards(1-tp,tag) Duel.ConfirmCards(1-tp,tag)
end end
end end
function c101112023.thfilter(c)
return c:IsCode(20989253) and c:IsAbleToHand()
end
function c101112023.dhcon(e,tp,eg,ep,ev,re,r,rp) function c101112023.dhcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==1-tp return Duel.GetTurnPlayer()==1-tp and aux.dscon()
end end
function c101112023.xfilter(c) function c101112023.xfilter(c)
return c:IsFaceup() and c:IsType(TYPE_EFFECT) and c:GetAttack()>0 return c:IsFaceup() and c:IsType(TYPE_EFFECT) and c:GetAttack()>0
...@@ -63,8 +63,8 @@ end ...@@ -63,8 +63,8 @@ end
function c101112023.dhtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c101112023.dhtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler() local c=e:GetHandler()
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc~=c and c101112023.xfilter(chkc) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc~=c and c101112023.xfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c101112023.xfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,c) if chk==0 then return c:IsAbleToDeck() and Duel.GetMZoneCount(tp,c)>0
and c:IsAbleToDeck() and Duel.GetMZoneCount(tp,c)>0 and Duel.IsExistingTarget(c101112023.xfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,c)
and Duel.IsExistingMatchingCard(c101112023.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end and Duel.IsExistingMatchingCard(c101112023.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
Duel.SelectTarget(tp,c101112023.xfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,c) Duel.SelectTarget(tp,c101112023.xfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,c)
...@@ -82,7 +82,7 @@ function c101112023.dhop(e,tp,eg,ep,ev,re,r,rp) ...@@ -82,7 +82,7 @@ function c101112023.dhop(e,tp,eg,ep,ev,re,r,rp)
if Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP)==0 if Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP)==0
or not tc:IsRelateToEffect(e) or tc:IsFacedown() then return end or not tc:IsRelateToEffect(e) or tc:IsFacedown() then return end
Duel.BreakEffect() Duel.BreakEffect()
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_ATTACK_FINAL) e1:SetCode(EFFECT_SET_ATTACK_FINAL)
e1:SetValue(0) e1:SetValue(0)
......
...@@ -56,7 +56,8 @@ end ...@@ -56,7 +56,8 @@ end
function c101112024.op(e,tp,eg,ep,ev,re,r,rp) function c101112024.op(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local g=Duel.GetMatchingGroup(Card.IsAbleToGrave,1-tp,LOCATION_ONFIELD,0,nil) local g=Duel.GetMatchingGroup(Card.IsAbleToGrave,1-tp,LOCATION_ONFIELD,0,nil)
if #g>0 and Duel.IsPlayerCanDraw(tp) and Duel.IsPlayerCanDraw(1-tp) and Duel.SelectYesNo(1-tp,aux.Stringid(101112024,2)) then if #g>0 and Duel.IsPlayerCanDraw(tp) and Duel.IsPlayerCanDraw(1-tp)
and Duel.SelectYesNo(1-tp,aux.Stringid(101112024,2)) then
Duel.Hint(HINT_SELECTMSG,1-tp,HINTMSG_TOGRAVE) Duel.Hint(HINT_SELECTMSG,1-tp,HINTMSG_TOGRAVE)
local tg=g:Select(1-tp,1,#g,nil) local tg=g:Select(1-tp,1,#g,nil)
if #tg>0 and Duel.SendtoGrave(tg,REASON_EFFECT) and tg:IsExists(Card.IsLocation,1,nil,LOCATION_GRAVE) then if #tg>0 and Duel.SendtoGrave(tg,REASON_EFFECT) and tg:IsExists(Card.IsLocation,1,nil,LOCATION_GRAVE) then
......
...@@ -17,7 +17,7 @@ function s.initial_effect(c) ...@@ -17,7 +17,7 @@ function s.initial_effect(c)
e2:SetDescription(aux.Stringid(id,0)) e2:SetDescription(aux.Stringid(id,0))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON) e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_HAND)
e2:SetCountLimit(1,id) e2:SetCountLimit(1,id)
e2:SetCost(s.cost) e2:SetCost(s.cost)
e2:SetTarget(s.sptg) e2:SetTarget(s.sptg)
...@@ -28,9 +28,9 @@ function s.initial_effect(c) ...@@ -28,9 +28,9 @@ function s.initial_effect(c)
e3:SetDescription(aux.Stringid(id,1)) e3:SetDescription(aux.Stringid(id,1))
e3:SetCategory(CATEGORY_ATKCHANGE) e3:SetCategory(CATEGORY_ATKCHANGE)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET)
e3:SetCode(EVENT_TO_GRAVE) e3:SetCode(EVENT_TO_GRAVE)
e3:SetCountLimit(1,id+o) e3:SetCountLimit(1,id+o)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetTarget(s.target) e3:SetTarget(s.target)
e3:SetOperation(s.operation) e3:SetOperation(s.operation)
c:RegisterEffect(e3) c:RegisterEffect(e3)
......
...@@ -4,43 +4,45 @@ function c101112026.initial_effect(c) ...@@ -4,43 +4,45 @@ function c101112026.initial_effect(c)
--pendulum summon --pendulum summon
aux.EnablePendulumAttribute(c) aux.EnablePendulumAttribute(c)
--black horn of heaven search --black horn of heaven search
local e0=Effect.CreateEffect(c)
e0:SetDescription(aux.Stringid(101112026,0))
e0:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND)
e0:SetType(EFFECT_TYPE_IGNITION)
e0:SetRange(LOCATION_PZONE)
e0:SetCountLimit(1,101112026)
e0:SetTarget(c101112026.thtg1)
e0:SetOperation(c101112026.thop1)
c:RegisterEffect(e0)
--horn of heaven search
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) e1:SetDescription(aux.Stringid(101112026,0))
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetCategory(CATEGORY_DESTROY+CATEGORY_SEARCH+CATEGORY_TOHAND)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetRange(LOCATION_PZONE)
e1:SetCountLimit(1,101112026+100) e1:SetCountLimit(1,101112026)
e1:SetTarget(c101112026.thtg2) e1:SetTarget(c101112026.thtg1)
e1:SetOperation(c101112026.thop2) e1:SetOperation(c101112026.thop1)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone() --horn of heaven search
e2:SetCode(EVENT_SPSUMMON_SUCCESS) local e2=Effect.CreateEffect(c)
e2:SetCondition(c101112026.thcon) e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_SUMMON_SUCCESS)
e2:SetCountLimit(1,101112026+100)
e2:SetTarget(c101112026.thtg2)
e2:SetOperation(c101112026.thop2)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--pzone move local e3=e2:Clone()
local e3=Effect.CreateEffect(c) e3:SetCode(EVENT_SPSUMMON_SUCCESS)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e3:SetCondition(c101112026.thcon)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_RELEASE)
e3:SetTarget(c101112026.pentg)
e3:SetOperation(c101112026.penop)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--pzone move
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e4:SetProperty(EFFECT_FLAG_DELAY)
e4:SetCode(EVENT_RELEASE)
e4:SetCountLimit(1,101112026+200)
e4:SetTarget(c101112026.pentg)
e4:SetOperation(c101112026.penop)
c:RegisterEffect(e4)
end end
function c101112026.thfilter(c,code) function c101112026.thfilter(c,code)
return c:IsCode(code) and c:IsAbleToHand() return c:IsCode(code) and c:IsAbleToHand()
end end
function c101112026.thtg1(e,tp,eg,ep,ev,re,r,rp,chk) function c101112026.thtg1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c101112026.thfilter,tp,LOCATION_DECK,0,1,nil,50323155) end if chk==0 then return Duel.IsExistingMatchingCard(c101112026.thfilter,tp,LOCATION_DECK,0,1,nil,50323155) end
Duel.SetOperationInfo(0,CATEGORY_DESTROY,e:GetHandler(),1,0,0)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end end
function c101112026.thop1(e,tp,eg,ep,ev,re,r,rp) function c101112026.thop1(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -9,19 +9,20 @@ function c101112027.initial_effect(c) ...@@ -9,19 +9,20 @@ function c101112027.initial_effect(c)
e1:SetValue(aux.FALSE) e1:SetValue(aux.FALSE)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--summon --summon
local e1=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SUMMON) e2:SetCategory(CATEGORY_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_HAND) e2:SetRange(LOCATION_HAND)
e1:SetCountLimit(1,101112027) e2:SetCountLimit(1,101112027)
e1:SetCost(c101112027.sumcost) e2:SetCost(c101112027.sumcost)
e1:SetTarget(c101112027.sumtg) e2:SetTarget(c101112027.sumtg)
e1:SetOperation(c101112027.sumop) e2:SetOperation(c101112027.sumop)
c:RegisterEffect(e1) c:RegisterEffect(e2)
--spirit return --spirit return
aux.EnableSpiritReturn(c,EVENT_SUMMON_SUCCESS,EVENT_FLIP) aux.EnableSpiritReturn(c,EVENT_SUMMON_SUCCESS,EVENT_FLIP)
--to hand --to hand
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TOHAND)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F) e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET) e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetCode(EVENT_RELEASE) e3:SetCode(EVENT_RELEASE)
......
...@@ -9,7 +9,6 @@ function s.initial_effect(c) ...@@ -9,7 +9,6 @@ function s.initial_effect(c)
e1:SetCode(EFFECT_CHANGE_ATTRIBUTE) e1:SetCode(EFFECT_CHANGE_ATTRIBUTE)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e1:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e1:SetTarget(aux.TargetBoolFunction(Card.IsFaceup))
e1:SetValue(ATTRIBUTE_FIRE) e1:SetValue(ATTRIBUTE_FIRE)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--spsummon --spsummon
......
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