Commit b4beeddd authored by Nemo Ma's avatar Nemo Ma

Proc2

parent 1d137c00
......@@ -813,6 +813,20 @@
33720039 1 --Shiori 只有一个 施展正义非常危险
33720040 1 --Tiki 只有一个 要整顿的东西已经够多了
33720041 1 --Rosemary 只有一个 酒不能多喝
89386000 0
89386001 0
89386002 0
89386003 0
89386004 0
89386005 0
89386006 0
89386007 0
89386008 0
89386009 0
89386010 0
90700049 0
90700033 1
90700037 1
#211128
35300157 0
35301000 0
......
No preview for this file type
--奇妙物语 番茄大师
function c10128001.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10128001,0))
e1:SetCategory(CATEGORY_TOHAND)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMING_END_PHASE)
e1:SetTarget(c10128001.target)
e1:SetOperation(c10128001.activate)
c:RegisterEffect(e1)
--SpecialSummon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10128001,2))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_FIELD)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCountLimit(1)
e2:SetRange(LOCATION_SZONE)
e2:SetTarget(c10128001.sptg)
e2:SetOperation(c10128001.spop)
c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetCode(EVENT_SUMMON_SUCCESS)
c:RegisterEffect(e3)
--remain field
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetCode(EFFECT_REMAIN_FIELD)
c:RegisterEffect(e4)
end
function c10128001.spfilter(c,tp)
return c:IsFaceup() and c:IsSetCard(0x6336) and c:GetSequence()<5 and Duel.IsPlayerCanSpecialSummonMonster(tp,c:GetCode(),0x6336,0x21,0,0,1,RACE_PLANT,ATTRIBUTE_EARTH)
end
function c10128001.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local tc=eg:GetFirst()
if chk==0 then return eg:GetCount()==1 and tc:IsFaceup() and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsPlayerCanSpecialSummonMonster(tp,e:GetHandler():GetCode(),0x6336,0x21,tc:GetBaseAttack(),tc:GetBaseDefense(),1,RACE_PLANT,ATTRIBUTE_EARTH) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,LOCATION_SZONE)
end
function c10128001.spop(e,tp,eg,ep,ev,re,r,rp)
local c,tc=e:GetHandler(),eg:GetFirst()
if not c:IsRelateToEffect(e) or c:IsFacedown() or Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 or not Duel.IsPlayerCanSpecialSummonMonster(tp,c:GetCode(),0x6336,0x21,tc:GetBaseAttack(),tc:GetBaseDefense(),1,RACE_PLANT,ATTRIBUTE_EARTH) then return end
c:AddMonsterAttribute(TYPE_EFFECT,ATTRIBUTE_EARTH,RACE_PLANT,1,tc:GetBaseAttack(),tc:GetBaseDefense())
Duel.SpecialSummonStep(c,1,tp,tp,true,false,POS_FACEUP)
--c:AddMonsterAttributeComplete()
Duel.SpecialSummonComplete()
end
function c10128001.thfilter(c)
return c:IsSetCard(0x6336) and c:IsAbleToHand() and not c:IsCode(10128001) and c:IsFaceup()
end
function c10128001.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,0,tp,LOCATION_ONFIELD)
end
function c10128001.activate(e,tp,eg,ep,ev,re,r,rp)
local tg=Duel.GetMatchingGroup(c10128001.thfilter,tp,LOCATION_ONFIELD,0,e:GetHandler())
if tg:GetCount()<=0 or not Duel.SelectYesNo(tp,aux.Stringid(10128001,1)) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=tg:Select(tp,1,1,nil)
Duel.HintSelection(g)
Duel.SendtoHand(g,nil,REASON_EFFECT)
end
\ No newline at end of file
--奇妙物语 海葵宝宝
function c10128002.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10128002,0))
e1:SetCategory(CATEGORY_TOHAND)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMING_END_PHASE)
e1:SetTarget(c10128002.target)
e1:SetOperation(c10128002.activate)
c:RegisterEffect(e1)
--spsummon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10128002,2))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_FIELD)
e2:SetCode(EVENT_CHAINING)
e2:SetCountLimit(1)
e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET)
e2:SetRange(LOCATION_SZONE)
e2:SetCondition(c10128002.spcon)
e2:SetTarget(c10128002.sptg)
e2:SetOperation(c10128002.spop)
c:RegisterEffect(e2)
--remain field
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_REMAIN_FIELD)
c:RegisterEffect(e3)
end
function c10128002.spcon(e,tp,eg,ep,ev,re,r,rp)
return re:IsActiveType(TYPE_TRAP+TYPE_SPELL) and re:IsHasType(EFFECT_TYPE_ACTIVATE)
end
function c10128002.spfilter(c,tp)
return c:IsFaceup() and c:IsSetCard(0x6336) and c:GetSequence()<5 and Duel.IsPlayerCanSpecialSummonMonster(tp,c:GetCode(),0x6336,0x21,0,0,1,RACE_AQUA,ATTRIBUTE_WATER)
end
function c10128002.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_SZONE) and c10128002.spfilter(chkc,tp) end
if chk==0 then return Duel.IsExistingTarget(c10128002.spfilter,tp,LOCATION_SZONE,0,1,nil,tp) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c10128002.spfilter,tp,LOCATION_SZONE,0,1,1,nil,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,LOCATION_SZONE)
end
function c10128002.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if not tc:IsRelateToEffect(e) or tc:IsFacedown() or Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 or not Duel.IsPlayerCanSpecialSummonMonster(tp,tc:GetCode(),0x6336,0x21,0,0,1,RACE_PLANT,ATTRIBUTE_EARTH) then return end
tc:AddMonsterAttribute(TYPE_EFFECT,ATTRIBUTE_WATER,RACE_AQUA,1,0,0)
Duel.SpecialSummonStep(tc,1,tp,tp,true,false,POS_FACEUP)
--tc:AddMonsterAttributeComplete()
Duel.SpecialSummonComplete()
end
function c10128002.thfilter(c)
return c:IsSetCard(0x6336) and c:IsAbleToHand() and not c:IsCode(10128002)
end
function c10128002.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,0,tp,LOCATION_GRAVE)
end
function c10128002.activate(e,tp,eg,ep,ev,re,r,rp)
local tg=Duel.GetMatchingGroup(c10128002.thfilter,tp,LOCATION_GRAVE,0,nil)
if not Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,nil) or tg:GetCount()<=0 or not Duel.SelectYesNo(tp,aux.Stringid(10128002,1)) then return end
Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_EFFECT+REASON_DISCARD)
tg=Duel.GetMatchingGroup(c10128002.thfilter,tp,LOCATION_GRAVE,0,nil)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=tg:Select(tp,1,1,nil)
Duel.SendtoHand(g,nil,REASON_EFFECT)
end
\ No newline at end of file
--奇妙物语 邪恶小人
function c10128003.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10128003,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMING_END_PHASE)
e1:SetTarget(c10128003.target)
e1:SetOperation(c10128003.activate)
c:RegisterEffect(e1)
--tohand
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10128003,1))
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetRange(LOCATION_SZONE)
e2:SetCode(EVENT_CHAINING)
e2:SetCost(c10128003.thcost)
e2:SetTarget(c10128003.thtg)
e2:SetOperation(c10128003.thop)
c:RegisterEffect(e2)
--remain field
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_REMAIN_FIELD)
c:RegisterEffect(e3)
end
function c10128003.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsReleasable() end
Duel.Release(e:GetHandler(),REASON_COST)
end
function c10128003.thfilter(c,code)
return c:IsAbleToHand() and c:IsCode(code)
end
function c10128003.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
local tc=re:GetHandler()
if chk==0 then return bit.band(tc:GetType(),0x10002)==0x10002 and re:IsHasType(EFFECT_TYPE_ACTIVATE) and Duel.IsExistingMatchingCard(c10128003.thfilter,tp,LOCATION_DECK,0,1,nil,tc:GetCode()) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function c10128003.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c10128003.thfilter,tp,LOCATION_DECK,0,1,1,nil,re:GetHandler():GetCode())
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
function c10128003.spfilter(c,tp)
return ((c:IsFaceup() and c:GetSequence()<5) or c:IsLocation(LOCATION_HAND)) and c:IsSetCard(0x6336) and Duel.IsPlayerCanSpecialSummonMonster(tp,c:GetCode(),0x6336,0x21,0,0,1,RACE_SPELLCASTER,ATTRIBUTE_FIRE) and c:IsType(TYPE_SPELL)
end
function c10128003.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,0,tp,LOCATION_SZONE+LOCATION_HAND)
end
function c10128003.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local sg=Duel.GetMatchingGroup(c10128003.spfilter,tp,LOCATION_SZONE+LOCATION_HAND,0,c,tp)
if sg:GetCount()<=0 or Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 or not Duel.SelectYesNo(tp,aux.Stringid(10128003,2)) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tc=sg:Select(tp,1,1,nil):GetFirst()
tc:AddMonsterAttribute(TYPE_EFFECT,ATTRIBUTE_FIRE,RACE_SPELLCASTER,1,0,0)
Duel.SpecialSummonStep(tc,1,tp,tp,true,false,POS_FACEUP)
--tc:AddMonsterAttributeComplete()
Duel.SpecialSummonComplete()
end
\ No newline at end of file
--奇妙物语 黏黏糖虫
function c10128004.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10128004,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMING_END_PHASE)
e1:SetTarget(c10128004.target)
e1:SetOperation(c10128004.activate)
c:RegisterEffect(e1)
--SpecialSummon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10128004,0))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_SZONE)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetTarget(c10128004.sptg)
e2:SetOperation(c10128004.spop)
c:RegisterEffect(e2)
--remain field
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_REMAIN_FIELD)
c:RegisterEffect(e3)
end
function c10128004.spfilter2(c,tp)
return c:IsFaceup() and c:IsSetCard(0x6336) and c:GetSequence()<5 and Duel.IsPlayerCanSpecialSummonMonster(tp,c:GetCode(),0x6336,0x21,0,0,1,RACE_INSECT,ATTRIBUTE_LIGHT)
end
function c10128004.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_SZONE) and c10128004.spfilter2(chkc,tp) and chkc~=e:GetHandler() end
if chk==0 then return Duel.IsExistingTarget(c10128004.spfilter2,tp,LOCATION_SZONE,0,1,e:GetHandler(),tp) and Duel.GetLocationCount(tp,LOCATION_MZONE)>1 and not Duel.IsPlayerAffectedByEffect(tp,59822133) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c10128004.spfilter2,tp,LOCATION_SZONE,0,1,1,e:GetHandler(),tp)
g:AddCard(e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,2,tp,LOCATION_SZONE)
end
function c10128004.spop(e,tp,eg,ep,ev,re,r,rp)
local tc,c=Duel.GetFirstTarget(),e:GetHandler()
if not tc:IsRelateToEffect(e) or tc:IsFacedown() or Duel.IsPlayerAffectedByEffect(tp,59822133) or Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 or not Duel.IsPlayerCanSpecialSummonMonster(tp,tc:GetCode(),0x6336,0x21,0,0,1,RACE_INSECT,ATTRIBUTE_WIND) or not c:IsRelateToEffect(e) or c:IsFacedown() then return end
local g=Group.FromCards(c,tc)
for rc in aux.Next(g) do
rc:AddMonsterAttribute(TYPE_EFFECT,ATTRIBUTE_WIND,RACE_INSECT,1,0,0)
Duel.SpecialSummonStep(rc,1,tp,tp,true,false,POS_FACEUP)
--rc:AddMonsterAttributeComplete()
end
Duel.SpecialSummonComplete()
end
function c10128004.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_RELEASE,nil,0,tp,LOCATION_ONFIELD)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,0,tp,LOCATION_EXTRA)
end
function c10128004.spfilter(c,e,tp)
return c:IsSetCard(0x6336) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c10128004.cfilter(c,e,tp,rc)
local g=Group.FromCards(c,rc)
return c:IsSetCard(0x6336) and c:IsReleasableByEffect() and Duel.IsExistingMatchingCard(c10128004.cfilter2,tp,LOCATION_ONFIELD,0,1,g,c,tp,e)
end
function c10128004.cfilter2(c,rc,tp,e)
local g=Group.FromCards(c,rc)
return c:IsSetCard(0x6336) and c:IsReleasableByEffect() and Duel.GetLocationCountFromEx(tp,tp,g)>0 and Duel.IsExistingMatchingCard(c10128004.spfilter,tp,LOCATION_EXTRA,0,1,nil,e,tp)
end
function c10128004.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local cg=Duel.GetMatchingGroup(c10128004.cfilter,tp,LOCATION_ONFIELD,0,c,e,tp,c)
if cg:GetCount()<=0 or not Duel.SelectYesNo(tp,aux.Stringid(10128004,1)) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local tc1=cg:Select(tp,1,1,nil):GetFirst()
local g=Group.FromCards(c,tc1)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local rg=Duel.SelectMatchingCard(tp,c10128004.cfilter2,tp,LOCATION_ONFIELD,0,1,1,g,tc1,tp,e)
rg:AddCard(tc1)
Duel.Release(rg,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c10128004.spfilter,tp,LOCATION_EXTRA,0,1,1,nil,e,tp)
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
\ No newline at end of file
--奇妙物语 红烧南瓜
function c10128005.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10128005,0))
e1:SetCategory(CATEGORY_POSITION)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,0x1e0)
e1:SetTarget(c10128005.target)
e1:SetOperation(c10128005.activate)
c:RegisterEffect(e1)
--SpecialSummon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10128005,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_FIELD)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e2:SetCountLimit(1)
e2:SetRange(LOCATION_SZONE)
e2:SetTarget(c10128005.sptg)
e2:SetOperation(c10128005.spop)
c:RegisterEffect(e2)
--remain field
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_REMAIN_FIELD)
c:RegisterEffect(e3)
end
function c10128005.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return eg:IsContains(chkc) and chkc:IsControler(tp) and c10128005.spfilter(chkc,e,tp) end
if chk==0 then return eg:IsExists(c10128005.spfilter,1,nil,e,tp) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=eg:FilterSelect(tp,c10128005.spfilter,1,1,nil,e,tp)
Duel.SetTargetCard(g)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,LOCATION_GRAVE)
end
function c10128005.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if not tc:IsRelateToEffect(e) or tc:IsFacedown() or Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 or not Duel.IsPlayerCanSpecialSummonMonster(tp,tc:GetCode(),0x6336,0x21,0,0,1,RACE_PLANT,ATTRIBUTE_LIGHT) then return end
tc:AddMonsterAttribute(TYPE_EFFECT,ATTRIBUTE_LIGHT,RACE_PLANT,1,0,0)
Duel.SpecialSummonStep(tc,1,tp,tp,true,false,POS_FACEUP)
--tc:AddMonsterAttributeComplete()
Duel.SpecialSummonComplete()
end
function c10128005.spfilter(c,e,tp)
return c:IsControler(tp) and bit.band(c:GetType(),0x10002)==0x10002 and c:IsCanBeEffectTarget(e) and Duel.IsPlayerCanSpecialSummonMonster(tp,c:GetCode(),0x6336,0x21,0,0,1,RACE_PLANT,ATTRIBUTE_LIGHT)
end
function c10128005.filter(c)
return c:IsFaceup() and c:IsSummonType(SUMMON_TYPE_SPECIAL) and c:IsAbleToRemove()
end
function c10128005.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_POSITION,nil,0,0,LOCATION_MZONE)
end
function c10128005.activate(e,tp,eg,ep,ev,re,r,rp)
local pg=Duel.GetMatchingGroup(c10128005.filter,tp,LOCATION_MZONE,LOCATION_MZONE,nil)
if pg:GetCount()<=0 or not Duel.SelectYesNo(tp,aux.Stringid(10128005,2)) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_POSITION)
local tc=pg:Select(tp,1,1,nil):GetFirst()
if Duel.Remove(tc,0,REASON_EFFECT+REASON_TEMPORARY)~=0 then
tc:RegisterFlagEffect(36553319,RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END,0,1)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_PHASE+PHASE_END)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetLabelObject(tc)
e1:SetCountLimit(1)
e1:SetCondition(c10128005.retcon)
e1:SetOperation(c10128005.retop)
Duel.RegisterEffect(e1,tp)
end
end
function c10128005.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetLabelObject():GetFlagEffect(36553319)~=0
end
function c10128005.retop(e,tp,eg,ep,ev,re,r,rp)
Duel.ReturnToField(e:GetLabelObject())
end
--奇妙物语 滚滚胖球
function c10128006.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_RELEASE)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMING_END_PHASE)
e1:SetTarget(c10128006.target)
e1:SetOperation(c10128006.activate)
c:RegisterEffect(e1)
--SpecialSummon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10128006,0))
e2:SetCategory(CATEGORY_TODECK)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_SZONE)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCountLimit(1)
e2:SetTarget(c10128006.tdtg)
e2:SetOperation(c10128006.tdop)
c:RegisterEffect(e2)
--remain field
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_REMAIN_FIELD)
c:RegisterEffect(e3)
end
function c10128006.tdfilter(c)
return bit.band(c:GetType(),0x10002)==0x10002 and c:IsAbleToDeck()
end
function c10128006.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return false end
if chk==0 then return Duel.IsExistingTarget(c10128006.tdfilter,tp,LOCATION_GRAVE,0,2,nil) and Duel.IsExistingTarget(Card.IsAbleToDeck,tp,0,LOCATION_GRAVE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SELF)
local g1=Duel.SelectTarget(tp,c10128006.tdfilter,tp,LOCATION_GRAVE,0,2,2,nil)
local g2=Duel.SelectTarget(tp,Card.IsAbleToDeck,tp,0,LOCATION_GRAVE,1,1,nil)
g1:Merge(g2)
Duel.SetOperationInfo(0,CATEGORY_TODECK,g1,g1:GetCount(),0,LOCATION_GRAVE)
end
function c10128006.tdop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS):Filter(Card.IsRelateToEffect,nil,e)
if g:GetCount()>0 then
Duel.SendtoDeck(g,nil,2,REASON_EFFECT)
end
end
function c10128006.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_RELEASE,nil,0,tp,LOCATION_ONFIELD+LOCATION_HAND)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,0,tp,LOCATION_DECK)
end
function c10128006.rfilter(c,tp)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
if ft<0 or (ft==0 and (not c:IsLocation(LOCATION_MZONE) or c:GetSequence()>4)) then return false end
return c:IsSetCard(0x6336) and c:IsType(TYPE_SPELL) and c:IsReleasableByEffect() and Duel.IsExistingMatchingCard(c10128006.spfilter,tp,LOCATION_DECK,0,1,nil,tp,c:GetCode())
end
function c10128006.spfilter(c,tp,code)
return c:IsCode(code) and Duel.IsPlayerCanSpecialSummonMonster(tp,c:GetCode(),0x6336,0x21,0,0,1,RACE_ZOMBIE,ATTRIBUTE_EARTH)
end
function c10128006.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local rg=Duel.GetMatchingGroup(c10128006.rfilter,tp,LOCATION_ONFIELD+LOCATION_HAND,0,c,tp)
if rg:GetCount()<=0 or not Duel.SelectYesNo(tp,aux.Stringid(10128006,2)) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local rc=rg:Select(tp,1,1,nil):GetFirst()
Duel.SendtoGrave(rc,REASON_EFFECT+REASON_RELEASE)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tc=Duel.SelectMatchingCard(tp,c10128006.spfilter,tp,LOCATION_DECK,0,1,1,nil,tp,rc:GetCode()):GetFirst()
tc:AddMonsterAttribute(TYPE_EFFECT,ATTRIBUTE_EARTH,RACE_ZOMBIE,1,0,0)
Duel.SpecialSummonStep(tc,1,tp,tp,true,false,POS_FACEUP)
--tc:AddMonsterAttributeComplete()
Duel.SpecialSummonComplete()
end
\ No newline at end of file
--奇妙旅行
function c10128007.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10128007,0))
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_RELEASE)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,10128007+EFFECT_COUNT_CODE_OATH)
e1:SetTarget(c10128007.target)
e1:SetOperation(c10128007.activate)
c:RegisterEffect(e1)
--Destroy
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10128007,1))
e2:SetCategory(CATEGORY_DESTROY)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1)
e2:SetCondition(c10128007.descon)
e2:SetTarget(c10128007.destg)
e2:SetOperation(c10128007.desop)
c:RegisterEffect(e2)
--remain field
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_REMAIN_FIELD)
c:RegisterEffect(e3)
end
function c10128007.descon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsType(TYPE_EFFECT)
end
function c10128007.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return false end
if chk==0 then return Duel.IsExistingTarget(c10128007.desfilter,tp,LOCATION_ONFIELD,0,1,nil)
and Duel.IsExistingTarget(aux.TRUE,tp,0,LOCATION_ONFIELD,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g1=Duel.SelectTarget(tp,c10128007.desfilter,tp,LOCATION_ONFIELD,0,1,1,nil)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g2=Duel.SelectTarget(tp,aux.TRUE,tp,0,LOCATION_ONFIELD,1,1,nil)
g1:Merge(g2)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g1,2,0,0)
end
function c10128007.desfilter(c)
return c:IsSetCard(0x6336) and c:IsFaceup()
end
function c10128007.desop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS):Filter(Card.IsRelateToEffect,nil,e)
if g:GetCount()>0 then
Duel.Destroy(g,REASON_EFFECT)
end
end
function c10128007.cfilter(c,tp)
return c:IsSetCard(0x6336) and c:IsFaceup() and c:IsReleasableByEffect() and Duel.IsExistingTarget(c10128007.thfilter,tp,LOCATION_DECK,0,1,nil,c:GetCode())
end
function c10128007.thfilter(c,code)
return c:IsSetCard(0x6336) and not c:IsCode(code) and c:IsAbleToHand()
end
function c10128007.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsOnField() and c10128007.cfilter(chkc,tp) and chkc~=e:GetHandler() end
if chk==0 then return Duel.IsExistingTarget(c10128007.cfilter,tp,LOCATION_ONFIELD,0,1,e:GetHandler(),tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local g=Duel.SelectTarget(tp,c10128007.cfilter,tp,LOCATION_ONFIELD,0,1,1,e:GetHandler(),tp)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function c10128007.activate(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if not tc:IsRelateToEffect(e) or Duel.Release(tc,REASON_EFFECT)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c10128007.thfilter,tp,LOCATION_DECK,0,1,1,nil,tc:GetCode())
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
\ No newline at end of file
--奇妙障壁
function c10128008.initial_effect(c)
--fuck monster
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10128008,0))
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_CHAINING)
e1:SetCondition(c10128008.condition)
e1:SetOperation(c10128008.activate)
c:RegisterEffect(e1)
--battle indestructable
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_INDESTRUCTABLE_BATTLE)
e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(LOCATION_MZONE,0)
e2:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0x6336))
e2:SetValue(1)
c:RegisterEffect(e2)
--remain field
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_REMAIN_FIELD)
c:RegisterEffect(e3)
end
function c10128008.condition(e,tp,eg,ep,ev,re,r,rp)
return rp~=tp
end
function c10128008.activate(e,tp,eg,ep,ev,re,r,rp)
local ie=0x0
if re:IsActiveType(TYPE_MONSTER) then ie=ie+0x1 end
if re:IsActiveType(TYPE_SPELL) then ie=ie+0x2 end
if re:IsActiveType(TYPE_TRAP) then ie=ie+0x4 end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_IMMUNE_EFFECT)
e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetLabel(ie)
e1:SetValue(c10128008.efilter)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function c10128008.efilter(e,re)
return re:IsActiveType(e:GetLabel()) and e:GetHandlerPlayer()~=re:GetHandlerPlayer()
end
\ No newline at end of file
--奇妙物语 奇妙小伙伴
function c10128009.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,nil,2,2)
c:EnableReviveLimit()
--activate from hand
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_QP_ACT_IN_NTPHAND)
e1:SetRange(LOCATION_MZONE)
e1:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0x6336))
e1:SetTargetRange(LOCATION_HAND,0)
c:RegisterEffect(e1)
--replace
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EFFECT_SEND_REPLACE)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_UNCOPYABLE)
e2:SetRange(LOCATION_MZONE)
e2:SetTarget(c10128009.reptg)
e2:SetOperation(c10128009.repop)
c:RegisterEffect(e2)
end
function c10128009.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsFaceup() and c:GetDestination()==LOCATION_GRAVE end
return true
end
function c10128009.repop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if Duel.SendtoDeck(c,nil,2,REASON_EFFECT+REASON_REDIRECT)~=0 and c:IsLocation(LOCATION_EXTRA) and Duel.SelectEffectYesNo(tp,c) then
Duel.Hint(HINT_CARD,0,10128009)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SET_ATTACK)
e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0x6336))
e1:SetValue(3000)
Duel.RegisterEffect(e1,tp)
end
end
\ No newline at end of file
--奇妙穿梭
function c10128010.initial_effect(c)
--Destroy
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10128010,0))
e1:SetCategory(CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_CHAINING)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCondition(c10128010.condition)
e1:SetTarget(c10128010.target)
e1:SetOperation(c10128010.activate)
c:RegisterEffect(e1)
--remove
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10128010,1))
e2:SetCategory(CATEGORY_REMOVE)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EVENT_CHAINING)
e2:SetCountLimit(1)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCondition(c10128010.condition)
e2:SetTarget(c10128010.rmtg)
e2:SetOperation(c10128010.rmop)
c:RegisterEffect(e2)
--remain field
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_REMAIN_FIELD)
c:RegisterEffect(e3)
end
function c10128010.rmtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() and chkc:IsAbleToRemove() end
if chk==0 then return Duel.IsExistingTarget(Card.IsAbleToRemove,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectTarget(tp,Card.IsAbleToRemove,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,g,g:GetCount(),0,LOCATION_ONFIELD)
end
function c10128010.rmop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.Remove(tc,POS_FACEUP,REASON_EFFECT)
end
end
function c10128010.condition(e,tp,eg,ep,ev,re,r,rp)
return bit.band(re:GetActiveType(),0x10002)==0x10002 and re:IsHasType(EFFECT_TYPE_ACTIVATE) and e:GetHandler():IsType(TYPE_EFFECT)
end
function c10128010.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() and chkc~=e:GetHandler() end
if chk==0 then return Duel.IsExistingTarget(aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,e:GetHandler()) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(tp,aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,LOCATION_ONFIELD)
end
function c10128010.activate(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.Destroy(tc,REASON_EFFECT)
end
end
\ No newline at end of file
--奇妙物语 奇妙超大卷
function c10128011.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,c10128011.lfilter,2,2)
c:EnableReviveLimit()
--place
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetRange(LOCATION_MZONE)
e1:SetCode(EFFECT_SEND_REPLACE)
e1:SetTarget(c10128011.reptg)
e1:SetValue(c10128011.repval)
c:RegisterEffect(e1)
local g=Group.CreateGroup()
g:KeepAlive()
e1:SetLabelObject(g)
--replace
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EFFECT_SEND_REPLACE)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_UNCOPYABLE)
e2:SetRange(LOCATION_MZONE)
e2:SetTarget(c10128011.reptg2)
e2:SetOperation(c10128011.repop2)
c:RegisterEffect(e2)
end
function c10128011.lfilter(c)
return bit.band(c:GetOriginalType(),TYPE_SPELL)~=0 or bit.band(c:GetOriginalType(),TYPE_TRAP)~=0
end
function c10128011.repfilter(c,tp)
return c:IsLocation(LOCATION_MZONE) and c:IsFaceup() and c:GetDestination()==LOCATION_GRAVE and c10128011.lfilter(c) and c:IsControler(tp)
end
function c10128011.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then
local count=eg:FilterCount(c10128011.repfilter,nil,tp)
return count>0 and Duel.GetLocationCount(tp,LOCATION_SZONE)>=count and Duel.GetFlagEffect(tp,10128011)<=0
end
if Duel.SelectEffectYesNo(tp,c) then
local container=e:GetLabelObject()
container:Clear()
local g=eg:Filter(c10128011.repfilter,nil,tp)
for tc in aux.Next(g) do
if Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) then
local e1=Effect.CreateEffect(c)
e1:SetCode(EFFECT_CHANGE_TYPE)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+0x1fc0000)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
tc:RegisterEffect(e1)
end
end
container:Merge(g)
Duel.RegisterFlagEffect(tp,10128011,RESET_PHASE+PHASE_END,0,1)
return true
end
return false
end
function c10128011.repval(e,c)
return e:GetLabelObject():IsContains(c)
end
function c10128011.reptg2(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsFaceup() and c:GetDestination()==LOCATION_GRAVE end
return true
end
function c10128011.repop2(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if Duel.SendtoDeck(c,nil,2,REASON_EFFECT+REASON_REDIRECT)~=0 and c:IsLocation(LOCATION_EXTRA) and Duel.IsExistingMatchingCard(c10128011.thfilter,tp,LOCATION_GRAVE,0,1,nil) and Duel.SelectEffectYesNo(tp,c) then
Duel.Hint(HINT_CARD,0,10128011)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local tg=Duel.SelectMatchingCard(tp,c10128011.thfilter,tp,LOCATION_GRAVE,0,1,1,nil)
Duel.HintSelection(tg)
Duel.SendtoHand(tg,nil,REASON_EFFECT)
end
end
\ No newline at end of file
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