Commit 360c64aa authored by 聖園ミカ's avatar 聖園ミカ 🐟

man!

parent d37128ac
No preview for this file type
Scenery_in_Painting = {} or Scenery_in_Painting
SIP = Scenery_in_Painting
function Scenery_in_Painting.spcondition(c)
--画中景不能被其他卡特招自肃
local e0=Effect.CreateEffect(c)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetValue(Scenery_in_Painting.limit)
c:RegisterEffect(e0)
end
function Scenery_in_Painting.limit(e,se,sp,st)
return se:GetHandler():IsSetCard(0xaca3)
end
function Scenery_in_Painting.eff1(c,id)
--画中景通用1效果类型1
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,0))
e1:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_FIELD)
e1:SetCode(EVENT_TO_DECK)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCountLimit(1,id)
e1:SetRange(LOCATION_HAND+LOCATION_GRAVE)
e1:SetCondition(Scenery_in_Painting.eff1con)
e1:SetTarget(Scenery_in_Painting.tftg)
e1:SetOperation(Scenery_in_Painting.tfop)
c:RegisterEffect(e1)
end
function Scenery_in_Painting.tftg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE,tp,LOCATION_REASON_TOFIELD)>0 end
end
function Scenery_in_Painting.tfop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_SZONE,tp,LOCATION_REASON_TOFIELD)<=0 then return end
local c=e:GetHandler()
if c:IsRelateToEffect(e) and not c:IsImmuneToEffect(e) then
Duel.MoveToField(c,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
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+RESETS_STANDARD-RESET_TURN_SET)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
c:RegisterEffect(e1)
end
end
function Scenery_in_Painting.eff1filter(c,tp)
return c:GetPreviousControler()==tp and c:IsLocation(LOCATION_DECK) and c:IsPreviousLocation(LOCATION_ONFIELD)
end
function Scenery_in_Painting.eff1con(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(Scenery_in_Painting.eff1filter,1,nil,tp) and not eg:IsContains(e:GetHandler())
end
function Scenery_in_Painting.eff2(c,id)
--画中景通用2效果
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,1))
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_CHAINING)
e1:SetCountLimit(1,id-1000)
e1:SetRange(LOCATION_ONFIELD)
e1:SetCondition(Scenery_in_Painting.eff2con)
return e1
end
function Scenery_in_Painting.eff2con(e,tp,eg,ep,ev,re,r,rp)
return bit.band(Duel.GetChainInfo(ev,CHAININFO_TRIGGERING_LOCATION),LOCATION_ONFIELD)~=0 and re:GetHandler()~=e:GetHandler()
end
function Scenery_in_Painting.eff3(c,id)
--画中景通用1效果类型2
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,0))
e1:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_FIELD)
e1:SetCode(EVENT_TO_GRAVE)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCountLimit(1,id)
e1:SetRange(LOCATION_HAND+LOCATION_GRAVE)
e1:SetCondition(Scenery_in_Painting.eff3con)
e1:SetTarget(Scenery_in_Painting.tftg)
e1:SetOperation(Scenery_in_Painting.tfop)
c:RegisterEffect(e1)
end
function Scenery_in_Painting.eff3filter(c,tp)
return c:GetPreviousControler()==tp and c:IsReason(REASON_EFFECT) and c:IsLocation(LOCATION_GRAVE) and c:IsPreviousLocation(LOCATION_ONFIELD)
end
function Scenery_in_Painting.eff3con(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(Scenery_in_Painting.eff3filter,1,nil,tp) and not eg:IsContains(e:GetHandler())
end
function Scenery_in_Painting.tdfilter(c,att)
return c:IsRace(RACE_PSYCHO) and c:IsFaceup() and c:IsAttribute(att) and c:IsAbleToDeck()
end
function Scenery_in_Painting.att2deck(e,id,tp,att)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and Duel.SendtoDeck(c,nil,SEQ_DECKSHUFFLE,REASON_EFFECT)>0 then
if Duel.IsExistingMatchingCard(Scenery_in_Painting.tdfilter,tp,LOCATION_REMOVED,0,1,nil,att) and Duel.SelectEffectYesNo(tp,c,aux.Stringid(id,2)) then
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,Scenery_in_Painting.tdfilter,tp,LOCATION_REMOVED,0,1,1,nil,att)
Duel.SendtoDeck(g,nil,SEQ_DECKSHUFFLE,REASON_EFFECT)
end
end
end
function Scenery_in_Painting.s2msp(c,id)
--从魔陷区特招
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,1))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_LEAVE_FIELD)
e1:SetRange(LOCATION_SZONE)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCountLimit(1,id-1000)
e1:SetCondition(Scenery_in_Painting.spcon)
e1:SetTarget(Scenery_in_Painting.sptg)
e1:SetOperation(Scenery_in_Painting.spop)
c:RegisterEffect(e1)
end
function Scenery_in_Painting.confilter(c,tp)
return c:IsPreviousPosition(POS_FACEUP) and c:IsPreviousControler(tp) and c:IsRace(RACE_PSYCHO)
end
function Scenery_in_Painting.spcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return eg:IsExists(Scenery_in_Painting.confilter,1,nil,tp) and not eg:IsContains(c) and c:GetType()==TYPE_SPELL+TYPE_CONTINUOUS
end
function Scenery_in_Painting.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end
function Scenery_in_Painting.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) then
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end
end
function Scenery_in_Painting.xyzlimit(c)
--超量怪兽信息和特招条件
c:EnableReviveLimit()
local e0=Effect.CreateEffect(c)
e0:SetDescription(1165)
e0:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_CANNOT_DISABLE)
e0:SetType(EFFECT_TYPE_FIELD)
e0:SetCode(EFFECT_SPSUMMON_PROC)
e0:SetRange(LOCATION_EXTRA)
e0:SetCondition(Scenery_in_Painting.xyzcon)
e0:SetTarget(Scenery_in_Painting.xyztg)
e0:SetOperation(aux.XyzLevelFreeOperation(Scenery_in_Painting.xyzexfilter,nil,2,2))
e0:SetValue(SUMMON_TYPE_XYZ)
c:RegisterEffect(e0)
end
function Scenery_in_Painting.xyzfilter(c,xc)
return c:IsXyzLevel(xc,7) and c:IsRace(RACE_PSYCHO)
end
function Scenery_in_Painting.xyzexfilter(c,xc)
return c:IsFaceup() and c:IsSetCard(0xaca3) and c:IsCanBeXyzMaterial(xc)
and c:GetOriginalLevel()==7 and bit.band(c:GetOriginalRace(),RACE_PSYCHO)~=0
end
function Scenery_in_Painting.xyzcon(e,c,og,min,max)
if c==nil then return true end
if c:IsType(TYPE_PENDULUM) and c:IsFaceup() then return false end
local tp=c:GetControler()
local minc=2
local maxc=2
if min then
minc=math.max(minc,min)
maxc=math.min(maxc,max)
end
if maxc<minc then return false end
local mg=nil
if og then
mg=og:Filter(aux.XyzLevelFreeFilter,nil,c,Scenery_in_Painting.xyzfilter)
else
mg=Duel.GetMatchingGroup(aux.XyzLevelFreeFilter,tp,LOCATION_MZONE,0,nil,c,Scenery_in_Painting.xyzfilter)
local exg=Duel.GetMatchingGroup(Scenery_in_Painting.xyzexfilter,tp,LOCATION_SZONE,0,nil,c)
mg:Merge(exg)
end
local sg=Duel.GetMustMaterial(tp,EFFECT_MUST_BE_XMATERIAL)
if sg:IsExists(aux.MustMaterialCounterFilter,1,nil,mg) then return false end
Duel.SetSelectedCard(sg)
aux.GCheckAdditional=aux.TuneMagicianCheckAdditionalX(EFFECT_TUNE_MAGICIAN_X)
local res=mg:CheckSubGroup(aux.XyzLevelFreeGoal,minc,maxc,tp,c,nil)
aux.GCheckAdditional=nil
return res
end
function Scenery_in_Painting.xyztg(e,tp,eg,ep,ev,re,r,rp,chk,c,og,min,max)
if og and not min then return true end
local minc=2
local maxc=2
if min then
if min>minc then minc=min end
if max<maxc then maxc=max end
end
local mg=nil
if og then
mg=og:Filter(aux.XyzLevelFreeFilter,nil,c,Scenery_in_Painting.xyzfilter)
else
mg=Duel.GetMatchingGroup(aux.XyzLevelFreeFilter,tp,LOCATION_MZONE,0,nil,c,Scenery_in_Painting.xyzfilter)
local exg=Duel.GetMatchingGroup(Scenery_in_Painting.xyzexfilter,tp,LOCATION_SZONE,0,nil,c)
mg:Merge(exg)
end
local sg=Duel.GetMustMaterial(tp,EFFECT_MUST_BE_XMATERIAL)
Duel.SetSelectedCard(sg)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_XMATERIAL)
local cancel=Duel.IsSummonCancelable()
aux.GCheckAdditional=aux.TuneMagicianCheckAdditionalX(EFFECT_TUNE_MAGICIAN_X)
local g=mg:SelectSubGroup(tp,aux.XyzLevelFreeGoal,cancel,minc,maxc,tp,c,nil)
Auxiliary.GCheckAdditional=nil
if g and g:GetCount()>0 then
g:KeepAlive()
e:SetLabelObject(g)
return true
else return false end
end
\ No newline at end of file
--画中景《梳妆的少女》
Duel.LoadScript("c47340500.lua")
local s,id=GetID()
function s.sp(c)
local e1=SIP.eff2(c,id)
e1:SetCategory(CATEGORY_TOGRAVE+CATEGORY_SPECIAL_SUMMON)
e1:SetTarget(s.sptg)
e1:SetOperation(s.spop)
c:RegisterEffect(e1)
end
function s.spfilter(c,e,tp)
return c:IsSetCard(0xaca3) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsAbleToGrave() and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,c,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
end
function s.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) then
Duel.SendtoGrave(c,REASON_EFFECT)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp)
if #g>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
end
function s.initial_effect(c)
SIP.spcondition(c)
SIP.eff1(c,id)
s.sp(c)
end
--画中景《鹿》
Duel.LoadScript("c47340500.lua")
local s,id=GetID()
function s.sp(c)
local e1=SIP.eff2(c,id)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TODECK)
e1:SetTarget(s.sptg)
e1:SetOperation(s.spop)
c:RegisterEffect(e1)
end
function s.spfilter(c,e,tp)
return c:IsSetCard(0xaca3) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsAbleToDeck() and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND+LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,0)
Duel.SetOperationInfo(0,CATEGORY_TODECK,c,1,0,0)
end
function s.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND+LOCATION_GRAVE,0,1,1,nil,e,tp)
if #g>0 and Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) then
SIP.att2deck(e,id,tp,ATTRIBUTE_EARTH)
end
end
function s.initial_effect(c)
SIP.spcondition(c)
SIP.eff3(c,id)
s.sp(c)
end
--画中景《旷野》
Duel.LoadScript("c47340500.lua")
local s,id=GetID()
function s.sp(c)
local e1=SIP.eff2(c,id)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetTarget(s.sptg)
e1:SetOperation(s.spop)
c:RegisterEffect(e1)
end
function s.mfilter(c)
return c:IsFaceup() and c:IsSetCard(0xaca3) and not c:IsType(TYPE_TOKEN)
end
function s.xyzfilter(c,mg)
return c:IsRace(RACE_PSYCHO) and c:IsRank(7) and c:IsXyzSummonable(mg)
end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
local g=Duel.GetMatchingGroup(s.mfilter,tp,LOCATION_ONFIELD,0,nil)
return Duel.IsExistingMatchingCard(s.xyzfilter,tp,LOCATION_EXTRA,0,1,nil,g)
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function s.spop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(s.mfilter,tp,LOCATION_ONFIELD,0,nil)
local xyzg=Duel.GetMatchingGroup(s.xyzfilter,tp,LOCATION_EXTRA,0,nil,g)
if xyzg:GetCount()>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local xyz=xyzg:Select(tp,1,1,nil):GetFirst()
Duel.XyzSummon(tp,xyz,g,1,5)
end
end
function s.initial_effect(c)
SIP.spcondition(c)
SIP.eff1(c,id)
s.sp(c)
end
--画中景《日出大地》
Duel.LoadScript("c47340500.lua")
local s,id=GetID()
function s.draw(c)
local e1=SIP.eff2(c,id)
e1:SetCategory(CATEGORY_DRAW+CATEGORY_TODECK)
e1:SetTarget(s.sptg)
e1:SetOperation(s.spop)
c:RegisterEffect(e1)
end
function s.spfilter(c,e,tp)
return c:IsSetCard(0xaca3) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
Duel.SetOperationInfo(0,CATEGORY_TODECK,e:GetHandler(),1,0,0)
end
function s.spop(e,tp,eg,ep,ev,re,r,rp)
if not Duel.IsPlayerCanDraw(tp,1) then return end
if Duel.Draw(tp,1,REASON_EFFECT)>0 then
SIP.att2deck(e,id,tp,ATTRIBUTE_WIND)
end
end
function s.initial_effect(c)
SIP.spcondition(c)
SIP.eff3(c,id)
s.draw(c)
end
--画中景《恶魔的角力》
Duel.LoadScript("c47340500.lua")
local s,id=GetID()
function s.destory(c)
local e1=SIP.eff2(c,id)
e1:SetCategory(CATEGORY_DESTROY)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetTarget(s.destg)
e1:SetOperation(s.desop)
c:RegisterEffect(e1)
end
function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() end
local c=e:GetHandler()
if chk==0 then return Duel.IsExistingTarget(nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,c) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(tp,nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,c)
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,c,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
end
function s.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
local c=e:GetHandler()
if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) then
Duel.SendtoGrave(c,REASON_EFFECT)
Duel.Destroy(tc,REASON_EFFECT)
end
end
function s.initial_effect(c)
SIP.spcondition(c)
SIP.eff1(c,id)
s.destory(c)
end
--画中景《夕阳下的街道》
Duel.LoadScript("c47340500.lua")
local s,id=GetID()
function s.sp(c)
local e1=SIP.eff2(c,id)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TODECK)
e1:SetTarget(s.sptg)
e1:SetOperation(s.spop)
c:RegisterEffect(e1)
end
function s.spfilter(c,e,tp,tid)
return c:IsReason(REASON_DESTROY) and c:GetTurnID()==id and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsAbleToDeck() and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil,e,tp,Duel.GetTurnCount()) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,LOCATION_GRAVE)
Duel.SetOperationInfo(0,CATEGORY_TODECK,c,1,0,0)
end
function s.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,nil,e,tp,Duel.GetTurnCount())
if #g>0 and Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) then
SIP.att2deck(e,id,tp,ATTRIBUTE_FIRE)
end
end
function s.initial_effect(c)
SIP.spcondition(c)
SIP.eff3(c,id)
s.sp(c)
end
--画中景《雪中小屋》
Duel.LoadScript("c47340500.lua")
local s,id=GetID()
function s.tg(c)
local e1=SIP.eff2(c,id)
e1:SetCategory(CATEGORY_TOGRAVE)
e1:SetTarget(s.sptg)
e1:SetOperation(s.spop)
c:RegisterEffect(e1)
end
function s.tgfilter(c,e,tp)
return c:IsRace(RACE_PSYCHO) and c:IsLevel(7) and c:IsAbleToGrave()
end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsAbleToGrave()
and Duel.IsExistingMatchingCard(s.tgfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,2,0,0)
end
function s.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) then
Duel.SendtoGrave(c,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,s.tgfilter,tp,LOCATION_DECK,0,1,1,nil)
if #g>0 then
Duel.SendtoGrave(g,REASON_EFFECT)
end
end
end
function s.initial_effect(c)
SIP.spcondition(c)
SIP.eff1(c,id)
s.tg(c)
end
--画中景《浪涌》
Duel.LoadScript("c47340500.lua")
local s,id=GetID()
function s.disable(c)
local e1=SIP.eff2(c,id)
e1:SetCategory(CATEGORY_DISABLE+CATEGORY_TODECK)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetTarget(s.distg)
e1:SetOperation(s.disop)
c:RegisterEffect(e1)
end
function s.distg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler()
if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_MZONE) and aux.NegateEffectMonsterFilter(chkc) end
if chk==0 then return c:IsAbleToDeck() and Duel.IsExistingTarget(aux.NegateEffectMonsterFilter,tp,0,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISABLE)
Duel.SelectTarget(tp,aux.NegateEffectMonsterFilter,tp,0,LOCATION_MZONE,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_TODECK,c,1,0,0)
end
function s.disop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if tc:IsFaceup() and tc:IsRelateToEffect(e) then
Duel.NegateRelatedChain(tc,RESET_TURN_SET)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetValue(RESET_TURN_SET)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e2)
SIP.att2deck(e,id,tp,ATTRIBUTE_WATER)
end
end
function s.initial_effect(c)
SIP.spcondition(c)
SIP.eff3(c,id)
s.disable(c)
end
--画中景《虔信者》
Duel.LoadScript("c47340500.lua")
local s,id=GetID()
function s.tofield(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,0))
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,id)
e1:SetRange(LOCATION_HAND+LOCATION_GRAVE)
e1:SetCost(s.tfcost)
e1:SetTarget(SIP.tftg)
e1:SetOperation(SIP.tfop)
c:RegisterEffect(e1)
end
function s.cfilter(c)
return c:IsRace(RACE_PSYCHO) and c:IsLevel(7) and c:IsAbleToRemoveAsCost()
end
function s.tfcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_HAND,0,1,c) end
local g=Duel.SelectMatchingCard(tp,s.cfilter,tp,LOCATION_HAND,0,1,1,c)
Duel.Remove(g,POS_FACEUP,REASON_COST)
end
function s.spother(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,2))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCountLimit(1,id-2000)
e1:SetTarget(s.sptg2)
e1:SetOperation(s.spop2)
c:RegisterEffect(e1)
end
function s.spfilter(c,e,tp)
return c:IsSetCard(0xaca3) and c:GetOriginalType()&TYPE_MONSTER~=0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function s.sptg2(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_SZONE) end
if chk==0 then return Duel.IsExistingTarget(s.spfilter,tp,LOCATION_SZONE,0,1,nil,e,tp)
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,s.spfilter,tp,LOCATION_SZONE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function s.spop2(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end
end
function s.initial_effect(c)
SIP.spcondition(c)
s.tofield(c)
SIP.s2msp(c,id)
s.spother(c)
end
--画中景《湖色月影》
Duel.LoadScript("c47340500.lua")
local s,id=GetID()
function s.tofield(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,0))
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,id)
e1:SetRange(LOCATION_HAND+LOCATION_GRAVE)
e1:SetCost(s.tfcost)
e1:SetTarget(SIP.tftg)
e1:SetOperation(SIP.tfop)
c:RegisterEffect(e1)
end
function s.cfilter(c)
return c:IsRace(RACE_PSYCHO) and c:IsLevel(7) and c:IsAbleToRemoveAsCost()
end
function s.tfcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_GRAVE,0,1,c) end
local g=Duel.SelectMatchingCard(tp,s.cfilter,tp,LOCATION_GRAVE,0,1,1,c)
Duel.Remove(g,POS_FACEUP,REASON_COST)
end
function s.tg(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,2))
e1:SetCategory(CATEGORY_TOGRAVE+CATEGORY_TOHAND)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCountLimit(1,id-2000)
e1:SetTarget(s.tgtg)
e1:SetOperation(s.tgop)
c:RegisterEffect(e1)
end
function s.tgfilter(c)
return c:IsSetCard(0xaca3) and c:GetOriginalType()&TYPE_MONSTER~=0 and c:IsAbleToGrave()
end
function s.thfilter(c)
return c:IsSetCard(0xaca3) and c:IsAbleToHand()
end
function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_SZONE) end
if chk==0 then return Duel.IsExistingTarget(s.tgfilter,tp,LOCATION_SZONE,0,1,nil) and
Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectTarget(tp,s.tgfilter,tp,LOCATION_SZONE,0,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,g,1,0,0)
end
function s.tgop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoGrave(tc,REASON_EFFECT)>0 then
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_GRAVE,0,1,1,nil)
if #g>0 then
Duel.SendtoHand(g,tp,REASON_EFFECT)
end
end
end
function s.initial_effect(c)
SIP.spcondition(c)
s.tofield(c)
SIP.s2msp(c,id)
s.tg(c)
end
--画中景《白日都市》
Duel.LoadScript("c47340500.lua")
local s,id=GetID()
function s.tofiled(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,0))
e1:SetCategory(CATEGORY_TOGRAVE)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCountLimit(1,id)
e1:SetCondition(s.tfcon)
e1:SetTarget(SIP.tftg)
e1:SetOperation(s.tfop)
c:RegisterEffect(e1)
end
function s.tfcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ)
end
function s.tffilter(c)
return c:IsType(TYPE_MONSTER) and c:IsSetCard(0xaca3)
and not c:IsForbidden()
end
function s.tfop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local g=Duel.SelectMatchingCard(tp,s.tffilter,tp,LOCATION_DECK,0,1,1,nil,tp)
if #g>0 then
local tc=g:GetFirst()
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetCode(EFFECT_CHANGE_TYPE)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD-RESET_TURN_SET)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
tc:RegisterEffect(e1)
end
end
function s.tofiled2(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,1))
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,id-1000)
e1:SetRange(LOCATION_MZONE)
e1:SetTarget(s.tftg2)
e1:SetOperation(s.tfop2)
c:RegisterEffect(e1)
end
function s.filter(c,tp)
local r=LOCATION_REASON_TOFIELD
if not c:IsControler(c:GetOwner()) then r=LOCATION_REASON_CONTROL end
return c:IsFaceup() and Duel.GetLocationCount(c:GetOwner(),LOCATION_SZONE,tp,r)>0
end
function s.tftg2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
return Duel.CheckRemoveOverlayCard(tp,1,0,1,REASON_EFFECT) and
Duel.IsExistingMatchingCard(s.filter,tp,0,LOCATION_MZONE,1,nil,tp)
end
end
function s.tfop2(e,tp,eg,ep,ev,re,r,rp)
if not (Duel.IsExistingMatchingCard(s.filter,tp,0,LOCATION_MZONE,1,nil,tp) or Duel.CheckRemoveOverlayCard(tp,1,0,1,REASON_EFFECT)) then return end
if Duel.RemoveOverlayCard(tp,1,0,1,1,REASON_COST)>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local tc=Duel.SelectMatchingCard(tp,s.filter,tp,0,LOCATION_MZONE,1,1,nil,tp):GetFirst()
if not tc:IsImmuneToEffect(e) and Duel.MoveToField(tc,tp,tc:GetOwner(),LOCATION_SZONE,POS_FACEUP,true) then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetCode(EFFECT_CHANGE_TYPE)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD-RESET_TURN_SET)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
tc:RegisterEffect(e1)
end
end
end
function s.initial_effect(c)
SIP.xyzlimit(c)
s.tofiled(c)
s.tofiled2(c)
end
--画中景《夜幕流辉》
Duel.LoadScript("c47340500.lua")
local s,id=GetID()
function s.kang(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,0))
e1:SetCategory(CATEGORY_NEGATE)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e1:SetCode(EVENT_CHAINING)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,id)
e1:SetCondition(s.negcon)
e1:SetCost(s.negcost)
e1:SetTarget(s.negtg)
e1:SetOperation(s.negop)
c:RegisterEffect(e1)
end
function s.negcon(e,tp,eg,ep,ev,re,r,rp)
return not e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED)
and ep~=tp and re:IsActiveType(TYPE_SPELL+TYPE_TRAP) and Duel.IsChainNegatable(ev)
end
function s.cfilter(c)
return c:IsSetCard(0x114) and c:IsDiscardable()
end
function s.negcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:CheckRemoveOverlayCard(tp,1,REASON_COST) end
c:RemoveOverlayCard(tp,1,1,REASON_COST)
end
function s.negtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE,tp,LOCATION_REASON_TOFIELD)>0 end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
end
function s.tffilter(c)
return c:IsType(TYPE_MONSTER) and c:IsFaceup()
end
function s.negop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local g=Duel.SelectMatchingCard(tp,s.tffilter,tp,LOCATION_MZONE,0,1,1,nil)
if #g>0 then
local tc=g:GetFirst()
if Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetCode(EFFECT_CHANGE_TYPE)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD-RESET_TURN_SET)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
tc:RegisterEffect(e1)
Duel.NegateActivation(ev)
end
end
end
function s.sp(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,1))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_GRAVE)
e1:SetCountLimit(1,id-1000)
e1:SetCost(s.cost)
e1:SetTarget(s.sptg)
e1:SetOperation(s.spop)
c:RegisterEffect(e1)
end
function s.costfilter(c)
return c:IsRace(RACE_PSYCHO) and c:IsAbleToRemoveAsCost()
end
function s.fselect(g,tp)
return Duel.GetMZoneCount(tp,g)>0 and g:GetClassCount(Card.GetAttribute)==#g
end
function s.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local gr=Duel.GetMatchingGroup(s.costfilter,tp,LOCATION_MZONE+LOCATION_GRAVE,0,e:GetHandler())
if chk==0 then
return gr:CheckSubGroup(s.fselect,2,2,tp)
end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local sg=gr:SelectSubGroup(tp,s.fselect,true,2,2,tp)
Duel.Remove(sg,POS_FACEUP,REASON_COST)
end
function s.ofilter(c)
return c:IsFaceup() and c:IsRace(RACE_PSYCHO) and c:IsType(TYPE_MONSTER) and c:IsCanOverlay()
end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end
function s.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) then
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_LEAVE_FIELD_REDIRECT)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_REDIRECT)
e1:SetValue(LOCATION_REMOVED)
c:RegisterEffect(e1,true)
if not Duel.IsExistingMatchingCard(s.ofilter,tp,LOCATION_REMOVED,0,1,nil) then return end
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_XMATERIAL)
local g=Duel.SelectMatchingCard(tp,s.ofilter,tp,LOCATION_REMOVED,0,1,1,nil)
if g:GetCount()>0 then
Duel.Overlay(c,g)
end
end
end
function s.initial_effect(c)
SIP.xyzlimit(c)
s.kang(c)
s.sp(c)
end
......@@ -282,7 +282,6 @@
!setname 0xaca2 旅界
!setname 0x3ca3 N×M
!setname 0x9ca3 仿华
!setname 0xaca3 画中景
!setname 0xcca3 黄金螺旋
!setname 0x5ca4 花标本
!setname 0x6ca4 妖精乡
......
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