Commit 53695650 authored by POLYMER's avatar POLYMER

fix

parent 54561730
--死汰ガエル --死汰ガエル
function c112538374.initial_effect(c) function c112538374.initial_effect(c)
--spsummon --spsummon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(112538374,0)) e1:SetDescription(aux.Stringid(112538374,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION) e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_HAND) e1:SetRange(LOCATION_HAND)
e1:SetCountLimit(1,112538374) e1:SetCountLimit(1,112538374)
e1:SetCost(c112538374.spcost) e1:SetCost(c112538374.spcost)
e1:SetTarget(c112538374.sptg) e1:SetTarget(c112538374.sptg)
e1:SetOperation(c112538374.spop) e1:SetOperation(c112538374.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--special summon --special summon
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(112538374,1)) e2:SetDescription(aux.Stringid(112538374,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON) e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_HAND+LOCATION_GRAVE) e2:SetRange(LOCATION_HAND+LOCATION_GRAVE)
e2:SetCountLimit(1,112538375) e2:SetCountLimit(1,112538375)
e2:SetCost(c112538374.hspcost) e2:SetCost(c112538374.hspcost)
e2:SetTarget(c112538374.hsptg) e2:SetTarget(c112538374.hsptg)
e2:SetOperation(c112538374.hspop) e2:SetOperation(c112538374.hspop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--return --return
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(112538374,2)) e2:SetDescription(aux.Stringid(112538374,2))
e2:SetCategory(CATEGORY_TODECK) e2:SetCategory(CATEGORY_TODECK)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetRange(LOCATION_REMOVED) e2:SetRange(LOCATION_REMOVED)
e2:SetCountLimit(1,112538376) e2:SetCountLimit(1,112538376)
e2:SetCode(EVENT_PHASE+PHASE_END) e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCondition(c112538374.retcon) e2:SetCondition(c112538374.retcon)
e2:SetTarget(c112538374.rettg) e2:SetTarget(c112538374.rettg)
e2:SetOperation(c112538374.retop) e2:SetOperation(c112538374.retop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--search --search
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(112538374,3)) e4:SetDescription(aux.Stringid(112538374,3))
e4:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) e4:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e4:SetCode(EVENT_REMOVE) e4:SetCode(EVENT_REMOVE)
e4:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY) e4:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e4:SetCountLimit(1,112538377) e4:SetCountLimit(1,112538377)
e4:SetTarget(c112538374.thtg) e4:SetTarget(c112538374.thtg)
e4:SetOperation(c112538374.thop) e4:SetOperation(c112538374.thop)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c112538374.costfilter(c) function c112538374.costfilter(c)
return c:IsRace(RACE_AQUA) and c:IsDiscardable() return c:IsRace(RACE_AQUA) and c:IsDiscardable()
end end
function c112538374.spcost(e,tp,eg,ep,ev,re,r,rp,chk) function c112538374.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return c:IsDiscardable() if chk==0 then return c:IsDiscardable()
and Duel.IsExistingMatchingCard(c112538374.costfilter,tp,LOCATION_HAND,0,1,c) end and Duel.IsExistingMatchingCard(c112538374.costfilter,tp,LOCATION_HAND,0,1,c) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
local g=Duel.SelectMatchingCard(tp,c112538374.costfilter,tp,LOCATION_HAND,0,1,1,c) local g=Duel.SelectMatchingCard(tp,c112538374.costfilter,tp,LOCATION_HAND,0,1,1,c)
g:AddCard(c) g:AddCard(c)
Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD) Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD)
end end
function c112538374.spfilter(c,e,tp) function c112538374.spfilter(c,e,tp)
return c:IsSetCard(0x12) and not c:IsCode(112538374) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsSetCard(0x12) and not c:IsCode(112538374) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function c112538374.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c112538374.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(c112538374.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end and Duel.IsExistingMatchingCard(c112538374.spfilter,tp,LOCATION_DECK,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_DECK)
end end
function c112538374.spop(e,tp,eg,ep,ev,re,r,rp) function c112538374.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,c112538374.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,c112538374.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end end
end end
function c112538374.rfilter(c) function c112538374.rfilter(c)
return c:IsLevelBelow(2) and c:IsAttribute(ATTRIBUTE_WATER) and c:IsRace(RACE_AQUA) return c:IsLevelBelow(2) and c:IsAttribute(ATTRIBUTE_WATER) and c:IsRace(RACE_AQUA)
and not c:IsCode(112538374) and c:IsAbleToGraveAsCost() and not c:IsCode(112538374) and c:IsAbleToGraveAsCost()
end end
function c112538374.hspcost(e,tp,eg,ep,ev,re,r,rp,chk) function c112538374.hspcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c112538374.rfilter,tp,LOCATION_DECK,0,2,e:GetHandler()) end if chk==0 then return Duel.IsExistingMatchingCard(c112538374.rfilter,tp,LOCATION_DECK,0,2,e:GetHandler()) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,c112538374.rfilter,tp,LOCATION_DECK,0,2,2,e:GetHandler()) local g=Duel.SelectMatchingCard(tp,c112538374.rfilter,tp,LOCATION_DECK,0,2,2,e:GetHandler())
Duel.SendtoGrave(g,REASON_COST) Duel.SendtoGrave(g,REASON_COST)
end end
function c112538374.hsptg(e,tp,eg,ep,ev,re,r,rp,chk) function c112538374.hsptg(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 e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function c112538374.hspop(e,tp,eg,ep,ev,re,r,rp) function c112538374.hspop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
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
end end
function c112538374.retcon(e,tp,eg,ep,ev,re,r,rp) function c112538374.retcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()~=tp return Duel.GetTurnPlayer()~=tp
end end
function c112538374.dffilter(c) function c112538374.dffilter(c)
return c:IsRace(RACE_AQUA) and c:IsAbleToDeck() return c:IsRace(RACE_AQUA) and c:IsAbleToDeck()
end end
function c112538374.rettg(e,tp,eg,ep,ev,re,r,rp,chk) function c112538374.rettg(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_TODECK,nil,2,tp,LOCATION_GRAVE+LOCATION_REMOVED) Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,2,tp,LOCATION_GRAVE+LOCATION_REMOVED)
end end
function c112538374.retop(e,tp,eg,ep,ev,re,r,rp) function c112538374.retop(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.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,c112538374.dffilter,tp,LOCATION_GRAVE,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c112538374.dffilter,tp,LOCATION_GRAVE,0,1,1,nil)
if g:GetCount()>0 then if g:GetCount()>0 then
local tc=g:GetFirst() local tc=g:GetFirst()
local gg=Group.FromCards(c,tc) local gg=Group.FromCards(c,tc)
Duel.SetTargetCard(g) Duel.HintSelection(g)
Duel.SendtoDeck(gg,nil,2,REASON_EFFECT) Duel.SendtoDeck(gg,nil,2,REASON_EFFECT)
end end
end end
function c112538374.thfilter(c) function c112538374.thfilter(c)
return c:IsRace(RACE_AQUA) and not c:IsCode(112538374) and c:IsAbleToHand() return c:IsRace(RACE_AQUA) and not c:IsCode(112538374) and c:IsAbleToHand()
end end
function c112538374.thtg(e,tp,eg,ep,ev,re,r,rp,chk) function c112538374.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c112538374.thfilter,tp,LOCATION_DECK,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c112538374.thfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end end
function c112538374.thop(e,tp,eg,ep,ev,re,r,rp) function c112538374.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,c112538374.thfilter,tp,LOCATION_DECK,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c112538374.thfilter,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
...@@ -68,12 +68,12 @@ function s.spfilter(c,e,tp) ...@@ -68,12 +68,12 @@ function s.spfilter(c,e,tp)
return c:IsSetCard(0x5a7d) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsSetCard(0x5a7d) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function s.desfilter(c,p) function s.desfilter(c,p)
return c:IsSetCard(0x5a7d) and not c:IsCode(id) and not s.MujicaDestroyedRecords[p][c:GetCode()] return c:IsSetCard(0x5a7d) and not c:IsCode(id) and not s.MujicaDestroyedRecords[p][c:GetCode()] and c:IsFaceupEx()
end end
function s.target(e,tp,eg,ep,ev,re,r,rp,chk) function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then if chk==0 then
return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND,0,1,nil,e,tp) return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND,0,1,nil,e,tp)
and Duel.IsExistingMatchingCard(s.desfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,1,nil,tp) end and Duel.IsExistingMatchingCard(s.desfilter,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,nil,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,1,tp,LOCATION_HAND+LOCATION_MZONE) Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,1,tp,LOCATION_HAND+LOCATION_MZONE)
end end
...@@ -84,7 +84,7 @@ function s.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -84,7 +84,7 @@ function s.operation(e,tp,eg,ep,ev,re,r,rp)
if #sg==0 then return end if #sg==0 then return end
if Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP)>0 then if Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP)>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local dg=Duel.SelectMatchingCard(tp,s.desfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,1,1,nil,tp) local dg=Duel.SelectMatchingCard(tp,s.desfilter,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,1,nil,tp)
if #dg>0 then if #dg>0 then
Duel.HintSelection(dg) Duel.HintSelection(dg)
Duel.Destroy(dg,REASON_EFFECT) Duel.Destroy(dg,REASON_EFFECT)
......
...@@ -21,7 +21,7 @@ function s.initial_effect(c) ...@@ -21,7 +21,7 @@ function s.initial_effect(c)
e2:SetOperation(s.setop) e2:SetOperation(s.setop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function s.repfilter(c,tp) function s.repfilter(c)
return c:IsOnField() and c:IsReason(REASON_EFFECT) and not c:IsReason(REASON_REPLACE) return c:IsOnField() and c:IsReason(REASON_EFFECT) and not c:IsReason(REASON_REPLACE)
end end
function s.reptg(e,tp,eg,ep,ev,re,r,rp,chk) function s.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
...@@ -29,7 +29,8 @@ function s.reptg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -29,7 +29,8 @@ function s.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return c:IsCanBeSpecialSummoned(e,0,tp,false,false) and eg:IsExists(s.repfilter,1,nil,tp) if chk==0 then return c:IsCanBeSpecialSummoned(e,0,tp,false,false) and eg:IsExists(s.repfilter,1,nil,tp)
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
if Duel.SelectEffectYesNo(tp,e:GetHandler(),96) then if Duel.SelectEffectYesNo(tp,e:GetHandler(),96) then
local g=eg:Filter(s.repfilter,nil,tp) local g=eg:Filter(s.repfilter,nil)
Duel.HintSelection(g)
if g:GetCount()==1 then if g:GetCount()==1 then
e:SetLabelObject(g:GetFirst()) e:SetLabelObject(g:GetFirst())
else else
......
...@@ -77,7 +77,6 @@ function s.regop(e,tp,eg,ep,ev,re,r,rp) ...@@ -77,7 +77,6 @@ function s.regop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_CHAINING) e1:SetCode(EVENT_CHAINING)
e1:SetCountLimit(1)
e1:SetCondition(s.repcon) e1:SetCondition(s.repcon)
e1:SetOperation(s.repop2) e1:SetOperation(s.repop2)
e1:SetReset(RESET_PHASE+PHASE_END) e1:SetReset(RESET_PHASE+PHASE_END)
...@@ -94,7 +93,7 @@ end ...@@ -94,7 +93,7 @@ end
function s.repcon(e,tp,eg,ep,ev,re,r,rp) function s.repcon(e,tp,eg,ep,ev,re,r,rp)
local ex,tg,tc=Duel.GetOperationInfo(ev,CATEGORY_DESTROY) local ex,tg,tc=Duel.GetOperationInfo(ev,CATEGORY_DESTROY)
local rc=re:GetHandler() local rc=re:GetHandler()
return ex and re:IsActiveType(TYPE_MONSTER+TYPE_SPELL+TYPE_TRAP) and rc:IsRelateToEffect(re) and Duel.IsExistingMatchingCard(aux.TRUE,rp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,rc) and rp==tp and rc:IsDestructable() return ex and re:IsActiveType(TYPE_MONSTER+TYPE_SPELL+TYPE_TRAP) and rc:IsRelateToEffect(re) and Duel.IsExistingMatchingCard(aux.TRUE,rp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,rc) and rp==tp and rc:IsDestructable() and Duel.GetFlagEffect(tp,id)==0
end end
function s.repop2(e,tp,eg,ep,ev,re,r,rp) function s.repop2(e,tp,eg,ep,ev,re,r,rp)
if Duel.SelectYesNo(tp,aux.Stringid(id,2)) then if Duel.SelectYesNo(tp,aux.Stringid(id,2)) then
...@@ -102,7 +101,7 @@ function s.repop2(e,tp,eg,ep,ev,re,r,rp) ...@@ -102,7 +101,7 @@ function s.repop2(e,tp,eg,ep,ev,re,r,rp)
local g=Group.CreateGroup() local g=Group.CreateGroup()
Duel.ChangeTargetCard(ev,g) Duel.ChangeTargetCard(ev,g)
Duel.ChangeChainOperation(ev,s.repop) Duel.ChangeChainOperation(ev,s.repop)
e:Reset() Duel.RegisterFlagEffect(tp,id,RESET_PHASE+PHASE_END,0,1)
end end
end end
function s.tdfilter(c) function s.tdfilter(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