Commit 22e7fa38 authored by Nemo Ma's avatar Nemo Ma

wild

parent 8bb6b986
expansions/pics/25000000.jpg

161 KB | W: | H:

expansions/pics/25000000.jpg

165 KB | W: | H:

expansions/pics/25000000.jpg
expansions/pics/25000000.jpg
expansions/pics/25000000.jpg
expansions/pics/25000000.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700001.jpg

10.7 KB | W: | H:

expansions/pics/90700001.jpg

722 KB | W: | H:

expansions/pics/90700001.jpg
expansions/pics/90700001.jpg
expansions/pics/90700001.jpg
expansions/pics/90700001.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700002.jpg

11.4 KB | W: | H:

expansions/pics/90700002.jpg

736 KB | W: | H:

expansions/pics/90700002.jpg
expansions/pics/90700002.jpg
expansions/pics/90700002.jpg
expansions/pics/90700002.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700003.jpg

11.9 KB | W: | H:

expansions/pics/90700003.jpg

759 KB | W: | H:

expansions/pics/90700003.jpg
expansions/pics/90700003.jpg
expansions/pics/90700003.jpg
expansions/pics/90700003.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700004.jpg

12.2 KB | W: | H:

expansions/pics/90700004.jpg

768 KB | W: | H:

expansions/pics/90700004.jpg
expansions/pics/90700004.jpg
expansions/pics/90700004.jpg
expansions/pics/90700004.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700005.jpg

12.1 KB | W: | H:

expansions/pics/90700005.jpg

753 KB | W: | H:

expansions/pics/90700005.jpg
expansions/pics/90700005.jpg
expansions/pics/90700005.jpg
expansions/pics/90700005.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700006.jpg

11.8 KB | W: | H:

expansions/pics/90700006.jpg

749 KB | W: | H:

expansions/pics/90700006.jpg
expansions/pics/90700006.jpg
expansions/pics/90700006.jpg
expansions/pics/90700006.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700007.jpg

11.9 KB | W: | H:

expansions/pics/90700007.jpg

747 KB | W: | H:

expansions/pics/90700007.jpg
expansions/pics/90700007.jpg
expansions/pics/90700007.jpg
expansions/pics/90700007.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700008.jpg

11.9 KB | W: | H:

expansions/pics/90700008.jpg

750 KB | W: | H:

expansions/pics/90700008.jpg
expansions/pics/90700008.jpg
expansions/pics/90700008.jpg
expansions/pics/90700008.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700009.jpg

11.2 KB | W: | H:

expansions/pics/90700009.jpg

735 KB | W: | H:

expansions/pics/90700009.jpg
expansions/pics/90700009.jpg
expansions/pics/90700009.jpg
expansions/pics/90700009.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700010.jpg

12 KB | W: | H:

expansions/pics/90700010.jpg

990 KB | W: | H:

expansions/pics/90700010.jpg
expansions/pics/90700010.jpg
expansions/pics/90700010.jpg
expansions/pics/90700010.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700021.jpg

11.2 KB | W: | H:

expansions/pics/90700021.jpg

742 KB | W: | H:

expansions/pics/90700021.jpg
expansions/pics/90700021.jpg
expansions/pics/90700021.jpg
expansions/pics/90700021.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700030.jpg

373 KB | W: | H:

expansions/pics/90700030.jpg

1.51 MB | W: | H:

expansions/pics/90700030.jpg
expansions/pics/90700030.jpg
expansions/pics/90700030.jpg
expansions/pics/90700030.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700031.jpg

9.33 KB | W: | H:

expansions/pics/90700031.jpg

626 KB | W: | H:

expansions/pics/90700031.jpg
expansions/pics/90700031.jpg
expansions/pics/90700031.jpg
expansions/pics/90700031.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700032.jpg

9.11 KB | W: | H:

expansions/pics/90700032.jpg

620 KB | W: | H:

expansions/pics/90700032.jpg
expansions/pics/90700032.jpg
expansions/pics/90700032.jpg
expansions/pics/90700032.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700033.jpg

8.35 KB | W: | H:

expansions/pics/90700033.jpg

544 KB | W: | H:

expansions/pics/90700033.jpg
expansions/pics/90700033.jpg
expansions/pics/90700033.jpg
expansions/pics/90700033.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700034.jpg

8.84 KB | W: | H:

expansions/pics/90700034.jpg

598 KB | W: | H:

expansions/pics/90700034.jpg
expansions/pics/90700034.jpg
expansions/pics/90700034.jpg
expansions/pics/90700034.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700035.jpg

8.89 KB | W: | H:

expansions/pics/90700035.jpg

610 KB | W: | H:

expansions/pics/90700035.jpg
expansions/pics/90700035.jpg
expansions/pics/90700035.jpg
expansions/pics/90700035.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700036.jpg

9.15 KB | W: | H:

expansions/pics/90700036.jpg

616 KB | W: | H:

expansions/pics/90700036.jpg
expansions/pics/90700036.jpg
expansions/pics/90700036.jpg
expansions/pics/90700036.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700037.jpg

9.22 KB | W: | H:

expansions/pics/90700037.jpg

612 KB | W: | H:

expansions/pics/90700037.jpg
expansions/pics/90700037.jpg
expansions/pics/90700037.jpg
expansions/pics/90700037.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700038.jpg

9.21 KB | W: | H:

expansions/pics/90700038.jpg

617 KB | W: | H:

expansions/pics/90700038.jpg
expansions/pics/90700038.jpg
expansions/pics/90700038.jpg
expansions/pics/90700038.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700039.jpg

9.28 KB | W: | H:

expansions/pics/90700039.jpg

618 KB | W: | H:

expansions/pics/90700039.jpg
expansions/pics/90700039.jpg
expansions/pics/90700039.jpg
expansions/pics/90700039.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700040.jpg

8.86 KB | W: | H:

expansions/pics/90700040.jpg

607 KB | W: | H:

expansions/pics/90700040.jpg
expansions/pics/90700040.jpg
expansions/pics/90700040.jpg
expansions/pics/90700040.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700041.jpg

9.01 KB | W: | H:

expansions/pics/90700041.jpg

566 KB | W: | H:

expansions/pics/90700041.jpg
expansions/pics/90700041.jpg
expansions/pics/90700041.jpg
expansions/pics/90700041.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700042.jpg

9.56 KB | W: | H:

expansions/pics/90700042.jpg

579 KB | W: | H:

expansions/pics/90700042.jpg
expansions/pics/90700042.jpg
expansions/pics/90700042.jpg
expansions/pics/90700042.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700048.jpg

8.58 KB | W: | H:

expansions/pics/90700048.jpg

711 KB | W: | H:

expansions/pics/90700048.jpg
expansions/pics/90700048.jpg
expansions/pics/90700048.jpg
expansions/pics/90700048.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700049.jpg

9.35 KB | W: | H:

expansions/pics/90700049.jpg

719 KB | W: | H:

expansions/pics/90700049.jpg
expansions/pics/90700049.jpg
expansions/pics/90700049.jpg
expansions/pics/90700049.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700050.jpg

8.89 KB | W: | H:

expansions/pics/90700050.jpg

671 KB | W: | H:

expansions/pics/90700050.jpg
expansions/pics/90700050.jpg
expansions/pics/90700050.jpg
expansions/pics/90700050.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700051.jpg

8.26 KB | W: | H:

expansions/pics/90700051.jpg

626 KB | W: | H:

expansions/pics/90700051.jpg
expansions/pics/90700051.jpg
expansions/pics/90700051.jpg
expansions/pics/90700051.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700054.jpg

11 KB | W: | H:

expansions/pics/90700054.jpg

770 KB | W: | H:

expansions/pics/90700054.jpg
expansions/pics/90700054.jpg
expansions/pics/90700054.jpg
expansions/pics/90700054.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700056.jpg

55.8 KB | W: | H:

expansions/pics/90700056.jpg

428 KB | W: | H:

expansions/pics/90700056.jpg
expansions/pics/90700056.jpg
expansions/pics/90700056.jpg
expansions/pics/90700056.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700057.jpg

48.8 KB | W: | H:

expansions/pics/90700057.jpg

378 KB | W: | H:

expansions/pics/90700057.jpg
expansions/pics/90700057.jpg
expansions/pics/90700057.jpg
expansions/pics/90700057.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700058.jpg

57.2 KB | W: | H:

expansions/pics/90700058.jpg

427 KB | W: | H:

expansions/pics/90700058.jpg
expansions/pics/90700058.jpg
expansions/pics/90700058.jpg
expansions/pics/90700058.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700059.jpg

42.4 KB | W: | H:

expansions/pics/90700059.jpg

390 KB | W: | H:

expansions/pics/90700059.jpg
expansions/pics/90700059.jpg
expansions/pics/90700059.jpg
expansions/pics/90700059.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700061.jpg

12.8 KB | W: | H:

expansions/pics/90700061.jpg

914 KB | W: | H:

expansions/pics/90700061.jpg
expansions/pics/90700061.jpg
expansions/pics/90700061.jpg
expansions/pics/90700061.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700062.jpg

52.9 KB | W: | H:

expansions/pics/90700062.jpg

891 KB | W: | H:

expansions/pics/90700062.jpg
expansions/pics/90700062.jpg
expansions/pics/90700062.jpg
expansions/pics/90700062.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700063.jpg

48 KB | W: | H:

expansions/pics/90700063.jpg

727 KB | W: | H:

expansions/pics/90700063.jpg
expansions/pics/90700063.jpg
expansions/pics/90700063.jpg
expansions/pics/90700063.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700064.jpg

54 KB | W: | H:

expansions/pics/90700064.jpg

907 KB | W: | H:

expansions/pics/90700064.jpg
expansions/pics/90700064.jpg
expansions/pics/90700064.jpg
expansions/pics/90700064.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700065.jpg

60.2 KB | W: | H:

expansions/pics/90700065.jpg

926 KB | W: | H:

expansions/pics/90700065.jpg
expansions/pics/90700065.jpg
expansions/pics/90700065.jpg
expansions/pics/90700065.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700066.jpg

55.3 KB | W: | H:

expansions/pics/90700066.jpg

882 KB | W: | H:

expansions/pics/90700066.jpg
expansions/pics/90700066.jpg
expansions/pics/90700066.jpg
expansions/pics/90700066.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700067.jpg

51.8 KB | W: | H:

expansions/pics/90700067.jpg

897 KB | W: | H:

expansions/pics/90700067.jpg
expansions/pics/90700067.jpg
expansions/pics/90700067.jpg
expansions/pics/90700067.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700068.jpg

57.1 KB | W: | H:

expansions/pics/90700068.jpg

961 KB | W: | H:

expansions/pics/90700068.jpg
expansions/pics/90700068.jpg
expansions/pics/90700068.jpg
expansions/pics/90700068.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700069.jpg

57 KB | W: | H:

expansions/pics/90700069.jpg

864 KB | W: | H:

expansions/pics/90700069.jpg
expansions/pics/90700069.jpg
expansions/pics/90700069.jpg
expansions/pics/90700069.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700071.jpg

49.8 KB | W: | H:

expansions/pics/90700071.jpg

851 KB | W: | H:

expansions/pics/90700071.jpg
expansions/pics/90700071.jpg
expansions/pics/90700071.jpg
expansions/pics/90700071.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700072.jpg

42.5 KB | W: | H:

expansions/pics/90700072.jpg

683 KB | W: | H:

expansions/pics/90700072.jpg
expansions/pics/90700072.jpg
expansions/pics/90700072.jpg
expansions/pics/90700072.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700073.jpg

14.4 KB | W: | H:

expansions/pics/90700073.jpg

1.84 MB | W: | H:

expansions/pics/90700073.jpg
expansions/pics/90700073.jpg
expansions/pics/90700073.jpg
expansions/pics/90700073.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700078.jpg

14.1 KB | W: | H:

expansions/pics/90700078.jpg

2.05 MB | W: | H:

expansions/pics/90700078.jpg
expansions/pics/90700078.jpg
expansions/pics/90700078.jpg
expansions/pics/90700078.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700079.jpg

14 KB | W: | H:

expansions/pics/90700079.jpg

2.85 MB | W: | H:

expansions/pics/90700079.jpg
expansions/pics/90700079.jpg
expansions/pics/90700079.jpg
expansions/pics/90700079.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700080.jpg

9.74 KB | W: | H:

expansions/pics/90700080.jpg

668 KB | W: | H:

expansions/pics/90700080.jpg
expansions/pics/90700080.jpg
expansions/pics/90700080.jpg
expansions/pics/90700080.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700081.jpg

9.23 KB | W: | H:

expansions/pics/90700081.jpg

538 KB | W: | H:

expansions/pics/90700081.jpg
expansions/pics/90700081.jpg
expansions/pics/90700081.jpg
expansions/pics/90700081.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700084.jpg

46.3 KB | W: | H:

expansions/pics/90700084.jpg

721 KB | W: | H:

expansions/pics/90700084.jpg
expansions/pics/90700084.jpg
expansions/pics/90700084.jpg
expansions/pics/90700084.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/90700085.jpg

502 KB | W: | H:

expansions/pics/90700085.jpg

769 KB | W: | H:

expansions/pics/90700085.jpg
expansions/pics/90700085.jpg
expansions/pics/90700085.jpg
expansions/pics/90700085.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/field/90700048.jpg

63.1 KB | W: | H:

expansions/pics/field/90700048.jpg

992 KB | W: | H:

expansions/pics/field/90700048.jpg
expansions/pics/field/90700048.jpg
expansions/pics/field/90700048.jpg
expansions/pics/field/90700048.jpg
  • 2-up
  • Swipe
  • Onion skin
......@@ -115,14 +115,14 @@ function cm.econ2(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFlagEffect(tp,m)==0 and Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE)>0 and (ph==PHASE_MAIN1 or ph==PHASE_MAIN2) and Duel.GetCurrentChain()==0 and Duel.GetTurnPlayer()==tp
end
function cm.ceoperation(e,tp,eg,ep,ev,re,r,rp)
if rp==tp then return end
if rp==tp or not re:IsActiveType(TYPE_MONSTER) then return end
local g=Group.CreateGroup()
Duel.ChangeTargetCard(ev,g)
Duel.ChangeChainOperation(ev,cm.repop)
end
function cm.repop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) then Duel.Destroy(c,REASON_EFFECT) end
if c:IsFaceup() and c:IsRelateToEffect(e) then Duel.Destroy(c,REASON_EFFECT) end
end
function cm.tgop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,0,m)
......
--卫星闪灵 怒焰精灵
local m=60002084
local cm=_G["c"..m]
cm.name="卫星闪灵 怒焰精灵"
function cm.initial_effect(c)
--synchro summon
aux.AddSynchroProcedure(c,nil,aux.NonTuner(nil),1)
c:EnableReviveLimit()
--spsummon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_EXTRA)
e1:SetCountLimit(1,m+EFFECT_COUNT_CODE_OATH)
e1:SetCondition(cm.spcon)
c:RegisterEffect(e1)
--disable
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,1))
e2:SetCategory(CATEGORY_DESTROY+CATEGORY_DISABLE)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_CHAINING)
e2:SetCountLimit(1,m+10000000)
e2:SetRange(LOCATION_MZONE)
e2:SetCondition(cm.discon)
e2:SetCost(cm.discost)
e2:SetTarget(cm.distg)
e2:SetOperation(cm.disop)
c:RegisterEffect(e2)
end
function cm.filter(c)
return (c:IsLevel(2) or c:IsLink(2)) and c:IsFaceup()
end
function cm.spcon(e,c)
if c==nil then return true end
return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(cm.filter,c:GetControler(),LOCATION_MZONE,0,1,nil)
end
function cm.discon(e,tp,eg,ep,ev,re,r,rp)
return ep~=tp and Duel.IsChainDisablable(ev)
end
function cm.cfilter(c)
return c:IsLevel(2) or c:IsRank(2) or c:IsLink(2)
end
function cm.discost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckReleaseGroup(tp,cm.cfilter,1,e:GetHandler()) end
local g=Duel.SelectReleaseGroup(tp,cm.cfilter,1,1,e:GetHandler())
Duel.Release(g,REASON_COST)
local tc=Duel.GetOperatedGroup():GetFirst()
e:SetLabelObject(tc)
end
function cm.distg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,0,0)
end
function cm.disop(e,tp,eg,ep,ev,re,r,rp)
local rc=re:GetHandler()
if Duel.NegateEffect(ev) and rc:IsRelateToEffect(re) and rc:IsDestructable()
and (e:GetLabelObject():IsRank(2) or e:GetLabelObject():IsLink(2))
and Duel.SelectYesNo(tp,aux.Stringid(m,2)) then
Duel.BreakEffect()
Duel.Destroy(rc,REASON_EFFECT)
end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetTargetRange(1,1)
e1:SetTarget(cm.splimit)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function cm.splimit(e,c)
return not c:IsLevel(2) and not c:IsRank(2) and not c:IsLink(2)
end
\ No newline at end of file
......@@ -45,7 +45,7 @@ function cm.actop(e,tp,eg,ep,ev,re,r,rp)
Duel.SendtoGrave(field,REASON_RULE)
end
local tc=e:GetHandler()
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
Duel.MoveToField(tc,tp,tp,LOCATION_FZONE,POS_FACEUP,true)
end
function cm.atktgfilter(e,c)
return c:IsSetCard(0x5ac0)
......
......@@ -65,8 +65,8 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp)
if op==0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local g=Duel.SelectMatchingCard(tp,cm.gravemtfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil)
local tc=g:GetFirst()
local m=_G["c"..tc:GetCode()]
local tc=g:GetFirst()
local m=_G["c"..tc:GetOriginalCode()]
local te=m.act
local op=te:GetOperation()
te:SetLabel(1)
......
......@@ -338,7 +338,7 @@ end
function cm.spcostfliter(c)
return c:IsSetCard(0x8d) and c:IsAbleToGraveAsCost()
end
function cm.spfilter(c)
function cm.spfliter(c)
return c:IsSetCard(0x8d) and c:IsDiscardable() and c:IsType(TYPE_MONSTER) and Duel.GetMatchingGroupCount(cm.spcostfilter,tp,LOCATION_DECK+LOCATION_EXTRA,0,nil)>=c:GetLevel()
end
function cm.spcon(e,c)
......@@ -352,7 +352,8 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp,c)
local tc=g:GetFirst()
local lv=tc:GetLevel()
Duel.SendtoGrave(g,REASON_DISCARD+REASON_COST)
e:GetHandler():RegisterFlagEffect(m+100,RESET_EVENT+RESETS_STANDARD-RESET_TOFIELD,0,1,lv)
local g2=Duel.SelectMatchingCard(tp,cm.spcostfilter,tp,LOCATION_DECK+LOCATION_EXTRA,0,lv,lv,nil)
Duel.SendtoGrave(g2,REASON_COST)
end
function cm.serstfilter(c)
return c:IsSetCard(0x8d) and c:IsType(TYPE_SPELL+TYPE_TRAP)
......@@ -361,16 +362,19 @@ function cm.serstfilter2(c)
return c:IsSetCard(0x8d) and c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsPosition(POS_FACEUP)
end
function cm.serstcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonLocation()==LOCATION_EXTRA and e:GetHandler():GetFlagEffect(m+100)>0
return e:GetHandler():GetSummonLocation()==LOCATION_EXTRA and Duel.GetMatchingGroupCount(cm.serstfilter2,tp,LOCATION_ONFIELD,0,nil)==0
end
function cm.sersttg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
if chk==0 then return Duel.IsExistingMatchingCard(cm.serstfilter,tp,LOCATION_DECK,0,1,nil) end
end
function cm.serstop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(90700010,1))
local lv=e:GetHandler():GetFlagEffectLabel(m+100)
local g2=Duel.SelectMatchingCard(tp,cm.spcostfilter,tp,LOCATION_DECK+LOCATION_EXTRA,0,lv,lv,nil)
Duel.Overlay(e:GetHandler(),g2)
local g=Duel.SelectMatchingCard(tp,cm.serstfilter,tp,LOCATION_DECK,0,1,2,nil)
local tc=g:GetFirst()
while tc do
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
tc=g:GetNext()
end
end
function cm.sermfilter1(c)
return c:IsPosition(POS_FACEUP) and c:IsSetCard(0x8d) and c:IsAbleToGraveAsCost()
......
local m=90700011
local cm=_G["c"..m]
cm.name="鬼计妖魔·德拉古拉"
function cm.initial_effect(c)
c:EnableReviveLimit()
aux.AddLinkProcedure(c,cm.linkfilter,1)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(90700011,0))
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetRange(LOCATION_EXTRA)
e1:SetCondition(cm.spcon)
e1:SetOperation(cm.spop)
e1:SetValue(SUMMON_TYPE_LINK)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TOHAND)
e2:SetDescription(aux.Stringid(90700011,1))
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_TO_GRAVE)
e2:SetTarget(cm.rectg)
e2:SetOperation(cm.recop)
c:RegisterEffect(e2)
if c90700011.counter==nil then
c90700011.counter=true
c90700011[0]=0
c90700011[1]=0
c90700011[2]=0
c90700011[3]=0
local ec1=Effect.CreateEffect(c)
ec1:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
ec1:SetCode(EVENT_PHASE_START+PHASE_DRAW)
ec1:SetOperation(cm.resetcount)
Duel.RegisterEffect(ec1,0)
local ec2=Effect.CreateEffect(c)
ec2:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
ec2:SetCode(EVENT_FLIP)
ec2:SetOperation(cm.addcount1)
Duel.RegisterEffect(ec2,0)
local ec3=Effect.CreateEffect(c)
ec3:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
ec3:SetCode(EVENT_CHAINING)
ec3:SetOperation(cm.addcount2)
Duel.RegisterEffect(ec3,0)
end
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetDescription(aux.Stringid(90700011,2))
e3:SetCondition(cm.con)
e3:SetTarget(cm.tg)
e3:SetLabel(1)
e3:SetOperation(cm.op)
e3:SetRange(LOCATION_MZONE)
c:RegisterEffect(e3)
local e4=e3:Clone()
e3:SetDescription(aux.Stringid(90700011,3))
e3:SetLabel(2)
c:RegisterEffect(e4)
local e5=e3:Clone()
e3:SetDescription(aux.Stringid(90700011,4))
e3:SetLabel(3)
c:RegisterEffect(e5)
local e6=Effect.CreateEffect(c)
e6:SetType(EFFECT_TYPE_FIELD)
e6:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e6:SetCode(EFFECT_CANNOT_ACTIVATE)
e6:SetRange(LOCATION_MZONE)
e6:SetTargetRange(1,1)
e6:SetValue(cm.actlimit)
c:RegisterEffect(e6)
end
function cm.resetcount(e,tp,eg,ep,ev,re,r,rp)
c90700011[0]=0
c90700011[1]=0
c90700011[2]=0
c90700011[3]=0
end
function cm.addcount1(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst()
while tc do
if tc:IsSetCard(0x8d) then
local p=tc:GetControler()
c90700011[p]=c90700011[p]+1
end
tc=eg:GetNext()
end
end
function cm.addcount2(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst()
while tc do
if tc:IsType(TYPE_SPELL+TYPE_TRAP) and tc:IsPreviousPosition(POS_FACEDOWN) then
local p=tc:GetControler()
c90700011[p]=c90700011[p]+1
end
tc=eg:GetNext()
end
end
function cm.linkfilter(c)
return c:IsAttribute(ATTRIBUTE_DARK) and not c:IsType(TYPE_FLIP) and not c:IsType(TYPE_LINK)
end
function cm.spfilter(c,tp)
return c:IsReleasable() and c:IsAttribute(ATTRIBUTE_DARK) and c:IsPosition(POS_FACEDOWN_DEFENSE) and Duel.GetLocationCountFromEx(tp,tp,c)>0
end
function cm.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
return Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_MZONE,0,1,nil,tp)
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp,c)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local g=Duel.SelectMatchingCard(tp,cm.spfilter,tp,LOCATION_MZONE,0,1,1,nil,tp)
if g then
Duel.Release(g,REASON_COST)
end
end
function cm.recfilter(c)
return c:IsSetCard(0x8d) and c:IsAbleToHand()
end
function cm.rectg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and cm.recfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(cm.recfilter,tp,LOCATION_GRAVE,0,1,e:GetHandler()) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectTarget(tp,cm.recfilter,tp,LOCATION_GRAVE,0,1,1,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end
function cm.recop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc)
end
end
function cm.con(e,tp,eg,ep,ev,re,r,rp)
local p=e:GetHandlerPlayer()
return c90700011[p+2]<c90700011[p]
end
function cm.rectg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
if e:GetLabel()==1 then return Duel.IsExistingTarget(cm.recfilter,tp,LOCATION_GRAVE,0,1,e:GetHandler()) end
if e:GetLabel()==2 then return Duel.IsExistingTarget(cm.recfilter,tp,LOCATION_GRAVE,0,1,e:GetHandler()) end
if e:GetLabel()==3 then return Duel.IsExistingTarget(cm.recfilter,tp,LOCATION_GRAVE,0,1,e:GetHandler()) end
end
if e:GetLabel()==1 then
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end
if e:GetLabel()==2 then
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end
if e:GetLabel()==3 then
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end
end
function cm.op(e,tp,eg,ep,ev,re,r,rp)
if e:GetLabel()==1 then
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end
if e:GetLabel()==2 then
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end
if e:GetLabel()==3 then
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end
local p=e:GetHandlerPlayer()
c90700011[p+2]=c90700011[p+2]+1
end
function cm.actfilter(c)
return c:IsSetCard(0x8d) and c:GetSequence()<5
end
function cm.actlimit(e,re,tp)
return Duel.IsExistingMatchingCard(cm.actfilter,tp,LOCATION_MZONE,0,1,nil) and not re:GetHandler():IsSetCard(0x8d) and e:GetHandler():GetSequence()>=5
end
\ No newline at end of file
local m=90700013
local cm=_G["c"..m]
cm.name="钟楼使徒 乌洛恩"
if not pcall(function() require("expansions/script/c90700019") end) then require("expansions/script/c90700019") end
function cm.initial_effect(c)
Seine_clock_tower.enable(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_ACTIVATE)
e1:SetRange(LOCATION_HAND)
e1:SetTargetRange(1,0)
e1:SetCondition(cm.actcon)
e1:SetValue(cm.actlimit)
c:RegisterEffect(e1)
end
function cm.actcon(e)
return e:GetHandler():IsPublic()
end
function cm.actlimit(e,re,tp)
return re:IsActiveType(TYPE_SPELL) or re:IsActiveType(TYPE_TRAP)
end
\ No newline at end of file
local m=90700014
local cm=_G["c"..m]
cm.name="钟楼使徒 纳姆卡里"
if not pcall(function() require("expansions/script/c90700019") end) then require("expansions/script/c90700019") end
function cm.initial_effect(c)
Seine_clock_tower.enable(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_ACTIVATE)
e1:SetRange(LOCATION_HAND)
e1:SetTargetRange(1,0)
e1:SetCondition(cm.actcon)
e1:SetValue(cm.actlimit)
c:RegisterEffect(e1)
end
function cm.actcon(e)
return e:GetHandler():IsPublic()
end
function cm.actlimit(e,re,tp)
return re:IsActiveType(TYPE_MONSTER)
end
\ No newline at end of file
local m=90700015
local cm=_G["c"..m]
cm.name="钟楼使徒 伊东"
if not pcall(function() require("expansions/script/c90700019") end) then require("expansions/script/c90700019") end
function cm.initial_effect(c)
Seine_clock_tower.enable(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SUMMON)
e1:SetRange(LOCATION_HAND)
e1:SetTargetRange(1,0)
e1:SetCondition(cm.actcon)
e1:SetValue(1)
c:RegisterEffect(e1)
local e2=Effect.Clone(e1)
e2:SetCode(EFFECT_CANNOT_FLIP_SUMMON)
c:RegisterEffect(e2)
local e3=Effect.Clone(e1)
e3:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
c:RegisterEffect(e3)
end
function cm.actcon(e)
return e:GetHandler():IsPublic()
end
\ No newline at end of file
local m=90700016
local cm=_G["c"..m]
cm.name="钟楼使徒 雷诺亚"
if not pcall(function() require("expansions/script/c90700019") end) then require("expansions/script/c90700019") end
function cm.initial_effect(c)
Seine_clock_tower.enable(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetRange(LOCATION_HAND)
e1:SetCode(EFFECT_CANNOT_TO_HAND)
e1:SetTarget(aux.TargetBoolFunction(Card.IsLocation,LOCATION_DECK))
e1:SetTargetRange(1,0)
e1:SetCondition(cm.actcon)
c:RegisterEffect(e1)
end
function cm.actcon(e)
return e:GetHandler():IsPublic()
end
\ No newline at end of file
local m=90700017
local cm=_G["c"..m]
cm.name="钟楼使徒 泣"
if not pcall(function() require("expansions/script/c90700019") end) then require("expansions/script/c90700019") end
function cm.initial_effect(c)
Seine_clock_tower.enable(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetRange(LOCATION_HAND)
e1:SetCode(EFFECT_SKIP_BP)
e1:SetTargetRange(1,0)
e1:SetCondition(cm.actcon)
c:RegisterEffect(e1)
end
function cm.actcon(e)
return e:GetHandler():IsPublic()
end
\ No newline at end of file
local m=90700018
local cm=_G["c"..m]
cm.name="钟楼使徒 玛夏"
if not pcall(function() require("expansions/script/c90700019") end) then require("expansions/script/c90700019") end
function cm.initial_effect(c)
Seine_clock_tower.enable(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE+EFFECT_FLAG_IGNORE_RANGE+EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetRange(LOCATION_HAND)
e1:SetCode(EFFECT_TO_GRAVE_REDIRECT)
e1:SetTargetRange(0xff,0xfe)
e1:SetValue(LOCATION_REMOVED)
e1:SetCondition(cm.actcon)
e1:SetTarget(cm.rmtg)
c:RegisterEffect(e1)
end
function cm.actcon(e)
return e:GetHandler():IsPublic()
end
function cm.rmtg(e,c)
return c:GetOwner()==e:GetHandlerPlayer()
end
\ No newline at end of file
--last upd 2022-7-2
Seine_clock_tower={}
local zl=_G["Seine_clock_tower"]
zl.wind_code=90700013
zl.dark_code=90700014
zl.light_code=90700015
zl.fire_code=90700016
zl.water_code=90700017
zl.earth_code=90700018
zl.field=90700019
zl.link_code=90700020
function zl.enable(c)
aux.AddCodeList(c,zl.field)
if c:IsType(TYPE_FUSION+TYPE_SYNCHRO+TYPE_XYZ+TYPE_LINK) then
aux.EnablePendulumAttribute(c,false)
else
aux.EnablePendulumAttribute(c)
end
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetRange(LOCATION_PZONE)
e2:SetCode(EFFECT_CHANGE_LSCALE)
e2:SetValue(5)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetRange(LOCATION_PZONE)
e3:SetCode(EFFECT_CHANGE_RSCALE)
e3:SetValue(7)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetProperty(EFFECT_FLAG_SET_AVAILABLE+EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_CANNOT_DISABLE)
e4:SetRange(0x1ff)
e4:SetCode(c:GetOriginalCodeRule())
c:RegisterEffect(e4)
if not zl.global_enable then
zl.global_enable=true
zl.global_enable_op(c)
end
end
function zl.pubcon(e)
return e:GetHandler():IsPublic()
end
function zl.global_enable_op(c)
local e_win=Effect.CreateEffect(c)
e_win:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e_win:SetCode(EVENT_ADJUST)
e_win:SetProperty(EFFECT_FLAG_DELAY)
e_win:SetCondition(zl.wincon)
e_win:SetOperation(zl.winop)
Duel.RegisterEffect(e_win,0)
local e_wind=Effect.CreateEffect(c)
e_wind:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e_wind:SetCode(EVENT_CHAIN_SOLVING)
e_wind:SetOperation(zl.wind_op)
Duel.RegisterEffect(e_wind,0)
local e_dark=Effect.CreateEffect(c)
e_dark:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e_dark:SetCode(EVENT_CHAIN_SOLVING)
e_dark:SetOperation(zl.dark_op)
Duel.RegisterEffect(e_dark,0)
local e_light_1=Effect.CreateEffect(c)
e_light_1:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e_light_1:SetCode(EVENT_SUMMON)
e_light_1:SetOperation(zl.light_op)
Duel.RegisterEffect(e_light_1,0)
local e_light_2=Effect.Clone(e_light_1)
e_light_2:SetCode(EVENT_FLIP_SUMMON)
Duel.RegisterEffect(e_light_2,0)
local e_light_3=Effect.Clone(e_light_1)
e_light_3:SetCode(EVENT_SPSUMMON)
Duel.RegisterEffect(e_light_3,0)
local e_th=Effect.CreateEffect(c)
e_th:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e_th:SetCode(EVENT_TO_HAND)
e_th:SetCondition(zl.th_con)
e_th:SetOperation(zl.th_op)
Duel.RegisterEffect(e_th,0)
local e_water=Effect.CreateEffect(c)
e_water:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e_water:SetCode(EVENT_PHASE_START+PHASE_END)
e_water:SetOperation(zl.water_op)
Duel.RegisterEffect(e_water,0)
end
function zl.winfilter(c)
return aux.IsCodeListed(c,zl.field) and c:IsType(TYPE_MONSTER)
end
function zl.win_check(g)
return g:Filter(zl.winfilter,nil):GetClassCount(Card.GetOriginalAttribute)==6
end
function zl.wincon(e,tp,eg,ep,ev,re,r,rp)
return zl.win_check(Duel.GetFieldGroup(0,LOCATION_HAND,0)) or zl.win_check(Duel.GetFieldGroup(1,LOCATION_HAND,0))
end
function zl.winop(e,tp,eg,ep,ev,re,r,rp)
local winmessage=0x60
local gp0=Duel.GetFieldGroup(0,LOCATION_HAND,0)
local gp1=Duel.GetFieldGroup(1,LOCATION_HAND,0)
local wp0=zl.win_check(gp0)
local wp1=zl.win_check(gp1)
if wp0 and not wp1 then
Duel.ConfirmCards(1,gp0)
Duel.Win(0,winmessage)
elseif not wp0 and wp1 then
Duel.ConfirmCards(0,gp1)
Duel.Win(1,winmessage)
elseif wp0 and wp1 then
Duel.ConfirmCards(0,gp0)
Duel.ConfirmCards(1,gp1)
Duel.Win(PLAYER_NONE,winmessage)
end
end
function zl.th_filter(c,code)
local con1=c:IsAbleToHandAsCost()
local con2=c:IsLocation(LOCATION_DECK)
local con3=c:IsLocation(LOCATION_ONFIELD) and c:IsPosition(POS_FACEUP)
local con4=c:IsHasEffect(code)
return con1 and (con2 or con3) and con4
end
function zl.wind_op(e,tp,eg,ep,ev,re,r,rp)
local actp=re:GetHandlerPlayer()
local oppp=1-actp
local check1=re:IsActiveType(TYPE_SPELL)
local check2=re:IsActiveType(TYPE_TRAP)
local check3=Duel.IsPlayerCanDraw(actp,1)
if not ((check1 or check2) and check3) then return end
local solve=false
local thc
local actg=Duel.GetMatchingGroup(zl.th_filter,actp,LOCATION_ONFIELD+LOCATION_DECK,0,nil,zl.wind_code)
if actg and #actg>0 and Duel.SelectYesNo(actp,aux.Stringid(zl.field,1)) then
Duel.Hint(HINT_SELECTMSG,actp,HINTMSG_ATOHAND)
thc=actg:Select(actp,1,1,nil):GetFirst()
solve=true
end
local oppg=Duel.GetMatchingGroup(zl.th_filter,oppp,LOCATION_ONFIELD+LOCATION_DECK,0,nil,zl.wind_code)
if not solve and oppg and #oppg>0 and Duel.SelectYesNo(oppp,aux.Stringid(zl.field,1)) then
Duel.Hint(HINT_SELECTMSG,oppp,HINTMSG_ATOHAND)
thc=oppg:Select(oppp,1,1,nil):GetFirst()
solve=true
end
if solve then
Duel.Hint(HINT_CARD,0,zl.wind_code)
Duel.SendtoHand(thc,nil,REASON_COST)
if thc:IsPreviousLocation(LOCATION_DECK) then
local e1=Effect.CreateEffect(thc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetDescription(aux.Stringid(zl.field,9))
e1:SetProperty(EFFECT_FLAG_CLIENT_HINT)
e1:SetCode(EFFECT_PUBLIC)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
thc:RegisterEffect(e1)
end
Duel.BreakEffect()
Duel.Draw(actp,1,REASON_EFFECT)
Duel.NegateEffect(ev)
local rc=re:GetHandler()
local e1=Effect.CreateEffect(thc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
rc:RegisterEffect(e1)
local e2=Effect.CreateEffect(thc)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
rc:RegisterEffect(e2)
end
end
function zl.dark_op(e,tp,eg,ep,ev,re,r,rp)
local actp=re:GetHandlerPlayer()
local oppp=1-actp
local check1=re:IsActiveType(TYPE_MONSTER)
local check2=Duel.IsPlayerCanDraw(actp,1)
if not (check1 and check2) then return end
local solve=false
local thc
local actg=Duel.GetMatchingGroup(zl.th_filter,actp,LOCATION_ONFIELD+LOCATION_DECK,0,nil,zl.dark_code)
if actg and #actg>0 and Duel.SelectYesNo(actp,aux.Stringid(zl.field,2)) then
Duel.Hint(HINT_SELECTMSG,actp,HINTMSG_ATOHAND)
thc=actg:Select(actp,1,1,nil):GetFirst()
solve=true
end
local oppg=Duel.GetMatchingGroup(zl.th_filter,oppp,LOCATION_ONFIELD+LOCATION_DECK,0,nil,zl.dark_code)
if not solve and oppg and #oppg>0 and Duel.SelectYesNo(oppp,aux.Stringid(zl.field,2)) then
Duel.Hint(HINT_SELECTMSG,oppp,HINTMSG_ATOHAND)
thc=oppg:Select(oppp,1,1,nil):GetFirst()
solve=true
end
if solve then
Duel.Hint(HINT_CARD,0,zl.dark_code)
Duel.SendtoHand(thc,nil,REASON_COST)
if thc:IsPreviousLocation(LOCATION_DECK) then
local e1=Effect.CreateEffect(thc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_PUBLIC)
e1:SetDescription(aux.Stringid(zl.field,9))
e1:SetProperty(EFFECT_FLAG_CLIENT_HINT)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
thc:RegisterEffect(e1)
end
Duel.BreakEffect()
Duel.Draw(actp,1,REASON_EFFECT)
Duel.NegateEffect(ev)
local rc=re:GetHandler()
local e1=Effect.CreateEffect(thc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
rc:RegisterEffect(e1)
local e2=Effect.CreateEffect(thc)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
rc:RegisterEffect(e2)
end
end
function zl.light_op(e,tp,eg,ep,ev,re,r,rp)
local actp=rp
local oppp=1-actp
local solve=false
local thc
local actg=Duel.GetMatchingGroup(zl.th_filter,actp,LOCATION_ONFIELD+LOCATION_DECK,0,nil,zl.light_code)
if actg and #actg>0 and Duel.SelectYesNo(actp,aux.Stringid(zl.field,3)) then
Duel.Hint(HINT_SELECTMSG,actp,HINTMSG_ATOHAND)
thc=actg:Select(actp,1,1,nil):GetFirst()
solve=true
end
local oppg=Duel.GetMatchingGroup(zl.th_filter,oppp,LOCATION_ONFIELD+LOCATION_DECK,0,nil,zl.light_code)
if not solve and oppg and #oppg>0 and Duel.SelectYesNo(oppp,aux.Stringid(zl.field,3)) then
Duel.Hint(HINT_SELECTMSG,oppp,HINTMSG_ATOHAND)
thc=oppg:Select(oppp,1,1,nil):GetFirst()
solve=true
end
if solve then
Duel.Hint(HINT_CARD,0,zl.light_code)
Duel.SendtoHand(thc,nil,REASON_COST)
if thc:IsPreviousLocation(LOCATION_DECK) then
local e1=Effect.CreateEffect(thc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetDescription(aux.Stringid(zl.field,9))
e1:SetProperty(EFFECT_FLAG_CLIENT_HINT)
e1:SetCode(EFFECT_PUBLIC)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
thc:RegisterEffect(e1)
end
Duel.BreakEffect()
Duel.Remove(eg,POS_FACEDOWN,REASON_RULE)
end
end
function zl.th_trigger_filter(c)
local con1=aux.IsCodeListed(c,zl.field)
local con2=c:IsPreviousLocation(LOCATION_DECK) and not c:IsReason(REASON_DRAW)
local con3=c:IsPreviousLocation(LOCATION_ONFIELD) and c:IsPreviousPosition(POS_FACEUP)
local con4=c:IsCode(zl.fire_code,zl.water_code,zl.earth_code)
return con1 and (con2 or con3) and not con4
end
function zl.th_con_filter(c,code)
return c:IsPublic() and c:IsCode(code)
end
function zl.sel_thc_op_attr(p,code)
local g=Duel.GetMatchingGroup(zl.th_filter,p,LOCATION_ONFIELD+LOCATION_DECK,0,nil,code)
local con=Duel.GetMatchingGroupCount(zl.th_con_filter,actp,LOCATION_HAND,0,nil,code)==0
if con and g and #g>0 and Duel.SelectYesNo(p,aux.Stringid(zl.field,code-zl.wind_code+1)) then
Duel.Hint(HINT_SELECTMSG,p,HINTMSG_ATOHAND)
local c=g:Select(p,1,1,nil):GetFirst()
return c
end
return nil
end
function zl.sel_thc_op(p)
local g=Group.CreateGroup()
local fire_card=zl.sel_thc_op_attr(p,zl.fire_code)
if fire_card then g:AddCard(fire_card) end
local earth_card=zl.sel_thc_op_attr(p,zl.earth_code)
if earth_card then g:AddCard(earth_card) end
g:KeepAlive()
return g
end
zl.tod_sel_g=Group.CreateGroup()
function zl.fire_count_filter(c)
return not c:IsPublic()
end
function zl.th_fire_solve(p,card)
local g=Duel.GetMatchingGroup(Card.IsAbleToDeck,p,LOCATION_HAND,0,zl.tod_sel_g)
if g and #g>0 and Duel.SelectYesNo(p,aux.Stringid(zl.field,7)) then
Duel.Hint(HINT_CARD,0,zl.fire_code)
Duel.Hint(HINT_SELECTMSG,p,HINTMSG_TODECK)
local tdg=g:Select(p,1,#g-1,card)
zl.tod_sel_g:Merge(tdg)
local num=tdg:FilterCount(zl.fire_count_filter,nil)
local opg=Duel.GetMatchingGroup(Card.IsAbleToDeck,1-p,LOCATION_HAND,0,zl.tod_sel_g):Filter(zl.fire_count_filter,nil)
if num>#opg then num=#opg end
local sg=opg:Select(1-p,num,num,nil)
zl.tod_sel_g:Merge(sg)
end
end
zl.ban_sel_g=Group.CreateGroup()
function zl.earth_count_filter(c)
return aux.IsCodeListed(c,90700019) and c:IsType(TYPE_MONSTER)
end
function zl.th_earth_solve(p)
local g=Duel.GetMatchingGroup(Card.IsAbleToRemove,p,LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD+LOCATION_GRAVE,zl.ban_sel_g,p)
if g and #g>0 and Duel.SelectYesNo(p,aux.Stringid(zl.field,8)) then
Duel.Hint(HINT_CARD,0,zl.earth_code)
local hand=Duel.GetFieldGroup(p,LOCATION_HAND,0)
Duel.ConfirmCards(1-p,hand)
local num=hand:Filter(zl.earth_count_filter,nil):GetClassCount(Card.GetAttribute)
Duel.Hint(HINT_SELECTMSG,p,HINTMSG_REMOVE)
local sg=Duel.SelectMatchingCard(p,aux.NecroValleyFilter(Card.IsAbleToRemove),p,LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD+LOCATION_GRAVE,1,num,zl.ban_sel_g,p)
zl.ban_sel_g:Merge(sg)
end
end
function zl.th_solve(p,g)
Duel.SendtoHand(g,nil,REASON_COST)
local flag=0
local fire_card
g:ForEach(
function(thc)
Duel.Hint(HINT_CARD,0,thc:GetCode())
if thc:IsCode(zl.fire_code) then
flag=bit.bor(flag,0x2)
fire_card=thc
end
if thc:IsCode(zl.earth_code) then flag=bit.bor(flag,0x1) end
if thc:IsPreviousLocation(LOCATION_DECK) then
local e1=Effect.CreateEffect(thc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_PUBLIC)
e1:SetDescription(aux.Stringid(zl.field,9))
e1:SetProperty(EFFECT_FLAG_CLIENT_HINT)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
thc:RegisterEffect(e1)
end
end
)
g:DeleteGroup()
if bit.band(flag,0x2)~=0 then
zl.th_fire_solve(p,fire_card)
end
if bit.band(flag,0x1)~=0 then
zl.th_earth_solve(p)
end
end
function zl.th_con(e,tp,eg,ep,ev,re,r,rp)
return eg:FilterCount(zl.th_trigger_filter,nil)>0
end
function zl.th_op(e,tp,eg,ep,ev,re,r,rp)
local actp=Duel.GetTurnPlayer()
local oppp=1-actp
local actp_th_g=zl.sel_thc_op(actp)
local oppp_th_g=zl.sel_thc_op(oppp)
if #actp_th_g>0 then zl.th_solve(actp,actp_th_g) end
if #oppp_th_g>0 then zl.th_solve(oppp,oppp_th_g) end
if zl.tod_sel_g:GetCount()>0 or zl.ban_sel_g:GetCount()>0 then
Duel.BreakEffect()
Duel.SendtoDeck(zl.tod_sel_g,nil,SEQ_DECKSHUFFLE,REASON_EFFECT)
Duel.Remove(zl.ban_sel_g,POS_FACEDOWN,REASON_EFFECT)
zl.tod_sel_g:Clear()
zl.ban_sel_g:Clear()
end
end
function zl.water_op(e,tp,eg,ep,ev,re,r,rp)
local actp=Duel.GetTurnPlayer()
local oppp=1-actp
local actg=Duel.GetMatchingGroup(zl.th_filter,actp,LOCATION_ONFIELD+LOCATION_DECK,0,nil,zl.water_code)
if actg and #actg>0 and Duel.SelectYesNo(actp,aux.Stringid(zl.field,5)) then
Duel.Hint(HINT_CARD,0,zl.water_code)
Duel.Hint(HINT_SELECTMSG,actp,HINTMSG_ATOHAND)
local thc=actg:Select(actp,1,1,nil):GetFirst()
Duel.SendtoHand(thc,nil,REASON_COST)
if thc:IsPreviousLocation(LOCATION_DECK) then
local e1=Effect.CreateEffect(thc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_PUBLIC)
e1:SetDescription(aux.Stringid(zl.field,9))
e1:SetProperty(EFFECT_FLAG_CLIENT_HINT)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
thc:RegisterEffect(e1)
end
end
local oppg=Duel.GetMatchingGroup(zl.th_filter,oppp,LOCATION_ONFIELD+LOCATION_DECK,0,nil,zl.water_code)
if oppg and #oppg>0 and Duel.SelectYesNo(oppp,aux.Stringid(zl.field,5)) then
Duel.Hint(HINT_CARD,0,zl.water_code)
Duel.Hint(HINT_SELECTMSG,oppp,HINTMSG_ATOHAND)
local thc=oppg:Select(oppp,1,1,nil):GetFirst()
Duel.SendtoHand(thc,nil,REASON_COST)
if thc:IsPreviousLocation(LOCATION_DECK) then
local e1=Effect.CreateEffect(thc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetDescription(aux.Stringid(zl.field,9))
e1:SetProperty(EFFECT_FLAG_CLIENT_HINT)
e1:SetCode(EFFECT_PUBLIC)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
thc:RegisterEffect(e1)
end
end
end
\ No newline at end of file
local m=90700020
local cm=_G["c"..m]
cm.name="钟楼使徒 海斗"
function cm.initial_effect(c)
aux.AddCodeList(c,90700019)
aux.EnablePendulumAttribute(c,false)
c:EnableReviveLimit()
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_EXTRA)
e1:SetTarget(cm.acttg)
e1:SetOperation(cm.actop)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetRange(LOCATION_PZONE)
e2:SetCode(EFFECT_CHANGE_LSCALE)
e2:SetValue(5)
c:RegisterEffect(e2)
local e3=Effect.Clone(e2)
e3:SetCode(EFFECT_CHANGE_RSCALE)
e3:SetValue(7)
c:RegisterEffect(e3)
end
function cm.acttg(e,tp,eg,ep,ev,re,r,rp,chk)
local con1=Duel.CheckLocation(tp,LOCATION_PZONE,0) or Duel.CheckLocation(tp,LOCATION_PZONE,1)
local con2=e:GetHandler():IsForbidden()
local con3=Duel.GetTurnPlayer()==tp
local con4=Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2
local con5=Duel.GetFieldGroup(tp,LOCATION_HAND,0):Filter(Card.IsPublic,nil):FilterCount(aux.IsCodeListed,nil,90700019)>0
return con1 and not con2 and con3 and con4 and con5
end
function cm.actop(e,tp,eg,ep,ev,re,r,rp)
Duel.MoveToField(e:GetHandler(),tp,tp,LOCATION_PZONE,POS_FACEUP,true)
end
\ No newline at end of file
local m=90700021
local cm=_G["c"..m]
cm.name="魔轰神兽 卡尔卡丹"
cm.name="未界域的魔轰神兽 尤尼科"
function cm.initial_effect(c)
c:EnableReviveLimit()
local e0=Effect.CreateEffect(c)
......@@ -21,14 +21,13 @@ function cm.initial_effect(c)
e1:SetLabelObject(e0)
c:RegisterEffect(e1)
--aux.AddSynchroProcedure(c,aux.FilterBoolFunction(Card.IsSetCard,0x35),aux.NonTuner(nil),1)
c:EnableReviveLimit()
local egain=Effect.CreateEffect(c)
egain:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
egain:SetCode(EVENT_ADJUST)
egain:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_CANNOT_DISABLE)
egain:SetRange(LOCATION_EXTRA)
egain:SetOperation(cm.egainop)
egain:SetCountLimit(1,EFFECT_COUNT_CODE_DUEL)
egain:SetCountLimit(1,m+EFFECT_COUNT_CODE_DUEL)
c:RegisterEffect(egain)
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_FIELD)
......
local m=90700022
local cm=_G["c"..m]
cm.name="多元霜火要塞"
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(90700022,4))
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e2:SetRange(LOCATION_HAND)
--e2:SetCondition(cm.actcon)
e2:SetOperation(cm.actop)
c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetRange(LOCATION_DECK)
e3:SetTarget(cm.acttg)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e4:SetCode(EVENT_MOVE)
e4:SetProperty(EFFECT_FLAG_DELAY)
e4:SetRange(LOCATION_FZONE)
e4:SetOperation(cm.addcop)
c:RegisterEffect(e4)
end
function cm.actcon(e,tp,eg,ep,ev,re,r,rp,chk)
return not e:GetHandler():IsForbidden() and Duel.GetTurnPlayer()==tp and (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2)
end
function cm.dtoffilter(c)
return c:IsAbleToDeckAsCost()
end
function cm.acttg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.dtoffilter,tp,LOCATION_HAND,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,cm.dtoffilter,tp,LOCATION_HAND,0,1,1,nil)
Duel.SendtoDeck(g,tp,-1,REASON_COST)
end
function cm.actop(e,tp,eg,ep,ev,re,r,rp)
local field=Duel.GetFieldGroup(tp,LOCATION_FZONE,0):GetFirst()
if field then
Duel.SendtoGrave(field,REASON_RULE)
end
local tc=e:GetHandler()
Duel.MoveToField(tc,tp,tp,LOCATION_FZONE,POS_FACEUP,true)
end
function cm.atktgfilter(e,c)
return c:IsSetCard(0x5ac0)
end
function cm.cfilter(c)
return c:IsPosition(POS_FACEUP)
end
function cm.serfilter(c)
return c:IsSetCard(0x5ac0) and c:IsAbleToHand()
end
function cm.addcop(e,tp,eg,ep,ev,re,r,rp)
local c=eg:GetFirst()
while c do
if not c:IsLocation(LOCATION_FZONE) and c:IsLocation(LOCATION_ONFIELD) and c:IsPosition(POS_FACEUP) and c:IsSetCard(0x5ac0) then
e:GetHandler():AddCounter(0x5ac0,1)
c:AddCounter(0x5ac0,3)
e:GetHandler():AddCounter(0x5ac0,3)
local Counters=Duel.GetCounter(tp,1,0,0x5ac0)
local adcon=Counters>0
local countercon=Counters>2 and Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_ONFIELD,0,1,nil)
local sercon=Counters>5 and Duel.IsExistingMatchingCard(cm.serfilter,tp,LOCATION_DECK,0,1,nil)
if (adcon or countercon or sercon) and Duel.SelectYesNo(tp,aux.Stringid(90700022,5)) then
local ope=-1
if adcon then
if countercon then
if sercon then
ope=Duel.SelectOption(tp,aux.Stringid(90700022,0),aux.Stringid(90700022,1),aux.Stringid(90700022,2))
else
ope=Duel.SelectOption(tp,aux.Stringid(90700022,0),aux.Stringid(90700022,1))
end
else
if sercon then
ope=Duel.SelectOption(tp,aux.Stringid(90700022,0),aux.Stringid(90700022,2))
if ope==1 then
ope=2
end
else
ope=0
end
end
else
if countercon then
if sercon then
ope=Duel.SelectOption(tp,aux.Stringid(90700022,1),aux.Stringid(90700022,2))
ope=ope+1
else
ope=2
end
else
ope=2
end
end
if ope==0 then
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(90700022,3))
local opt={}
for i=1,Counters do
opt[i]=i
end
opt[Counters+1]=nil
local adnum=Duel.AnnounceNumber(tp,table.unpack(opt))
Duel.RemoveCounter(tp,1,0,0x5ac0,adnum,REASON_EFFECT)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetTarget(cm.atktgfilter)
e1:SetValue(100*adnum)
e1:SetReset(RESET_PHASE+PHASE_END,2)
Duel.RegisterEffect(e1,tp)
local e2=e1:Clone()
e2:SetCode(EFFECT_UPDATE_DEFENSE)
Duel.RegisterEffect(e2,tp)
end
if ope==1 then
Duel.RemoveCounter(tp,1,0,0x5ac0,3,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SELF)
local g=Duel.SelectMatchingCard(tp,cm.cfilter,tp,LOCATION_ONFIELD,0,1,1,nil)
if g then
local tc=g:GetFirst()
tc:AddCounter(0x5ac0,1)
end
end
if ope==2 then
Duel.RemoveCounter(tp,1,0,0x5ac0,6,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.serfilter,tp,LOCATION_DECK,0,1,1,nil)
if g then
Duel.SendtoHand(g,tp,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
end
end
c=eg:GetNext()
end
end
\ No newline at end of file
local m=90700023
local cm=_G["c"..m]
cm.name="多元霜火公爵"
function cm.initial_effect(c)
c:EnableReviveLimit()
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetRange(LOCATION_HAND)
e1:SetTarget(cm.acttg)
e1:SetOperation(cm.actop)
c:RegisterEffect(e1)
c90700023.act=e1
local e2=e1:Clone()
e2:SetCondition(cm.actcon)
e2:SetRange(LOCATION_DECK)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e3:SetCode(EFFECT_SPSUMMON_PROC)
e3:SetRange(LOCATION_SZONE)
e3:SetValue(SUMMON_TYPE_RITUAL)
e3:SetCondition(cm.spcon)
e3:SetOperation(cm.spop)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e4:SetCategory(CATEGORY_SPECIAL_SUMMON)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e4:SetCode(EVENT_SPSUMMON_SUCCESS)
e4:SetProperty(EFFECT_FLAG_DELAY)
e4:SetTarget(cm.sertg)
e4:SetOperation(cm.serop)
c:RegisterEffect(e4)
end
function cm.acttg(e,tp,eg,ep,ev,re,r,rp,chk)
return Duel.GetLocationCount(tp,LOCATION_SZONE,tp,LOCATION_REASON_TOFIELD)>0-- and not e:GetHandler():IsForbidden() and Duel.GetTurnPlayer()==tp and (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2)
end
function cm.actcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFieldGroupCount(tp,LOCATION_HAND,0)==0
end
function cm.actfilter(c)
return c:IsSetCard(0x5ac0) and c:IsAbleToHand() and not c:IsCode(90700002)
end
function cm.actop(e,tp,eg,ep,ev,re,r,rp)
local tc
if e:GetLabel()==1 then
tc=eg:GetFirst()
else
tc=e:GetHandler()
end
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
local e1=Effect.CreateEffect(tc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetCode(EFFECT_ADD_TYPE)
e1:SetRange(LOCATION_SZONE)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD-RESET_TEMP_REMOVE-RESET_TURN_SET)
tc:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_REMOVE_TYPE)
e2:SetValue(TYPE_MONSTER+TYPE_EFFECT)
tc:RegisterEffect(e2)
tc:AddCounter(0x5ac0,4)
Duel.BreakEffect()
local ffcount=Duel.GetCounter(tp,LOCATION_SZONE,0,0x5ac0)
local field=Duel.GetFieldGroup(tp,LOCATION_FZONE,0):GetFirst()
if field then
ffcount=ffcount-field:GetCounter(0x5ac0)
end
if ffcount>=7 and Duel.IsExistingMatchingCard(cm.actfilter,tp,LOCATION_DECK,0,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(90700023,0)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.actfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,tp,REASON_EFFECT)
Duel.RegisterFlagEffect(tp,90700023,RESET_PHASE+PHASE_END,0,1)
end
end
end
function cm.spcon(e,c)
if c==nil then return true end
return Duel.IsCanRemoveCounter(e:GetHandlerPlayer(),1,0,0x5ac0,9,REASON_COST) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp,c)
Duel.RemoveCounter(tp,1,0,0x5ac0,9,REASON_COST)
end
function cm.serfilter(c)
return c:IsCode(90700009) and c:IsAbleToHand() and (c:IsPosition(POS_FACEUP) or not c:IsLocation(LOCATION_REMOVED))
end
function cm.sertg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.serfilter,tp,LOCATION_DECK+LOCATION_GRAVE+LOCATION_REMOVED,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND+CATEGORY_SEARCH,nil,1,tp,0)
end
function cm.serop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.serfilter,tp,LOCATION_DECK+LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil)
if g then
Duel.SendtoHand(g,tp,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
\ No newline at end of file
local m=90700024
local cm=_G["c"..m]
cm.name="多元霜火导师"
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(cm.actcon)
e1:SetOperation(cm.actop)
c:RegisterEffect(e1)
c90700024.act=e1
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_MOVE)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetRange(LOCATION_SZONE+LOCATION_MZONE)
e2:SetOperation(cm.spop)
c:RegisterEffect(e2)
end
function cm.actcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetLocationCount(tp,LOCATION_SZONE,tp,LOCATION_REASON_TOFIELD)>0-- and not e:GetHandler():IsForbidden() and Duel.GetTurnPlayer()==tp and (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2)
end
function cm.actfilter(c)
return c:IsCode(90700004) and not c:IsForbidden()
end
function cm.actop(e,tp,eg,ep,ev,re,r,rp)
local tc
if e:GetLabel()==1 then
tc=eg:GetFirst()
else
tc=e:GetHandler()
end
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
local e1=Effect.CreateEffect(tc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetCode(EFFECT_ADD_TYPE)
e1:SetRange(LOCATION_SZONE)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD-RESET_TEMP_REMOVE-RESET_TURN_SET)
tc:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_REMOVE_TYPE)
e2:SetValue(TYPE_MONSTER+TYPE_EFFECT)
tc:RegisterEffect(e2)
tc:AddCounter(0x5ac0,2)
Duel.BreakEffect()
if Duel.GetLocationCount(tp,LOCATION_SZONE,tp,LOCATION_REASON_TOFIELD)>0 and Duel.IsExistingMatchingCard(cm.actfilter,tp,LOCATION_DECK,0,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(90700024,0)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local g=Duel.SelectMatchingCard(tp,cm.actfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
local mc=g:GetFirst()
Duel.MoveToField(mc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
local e1=Effect.CreateEffect(tc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetCode(EFFECT_ADD_TYPE)
e1:SetRange(LOCATION_SZONE)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD-RESET_TEMP_REMOVE-RESET_TURN_SET)
mc:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_REMOVE_TYPE)
e2:SetValue(TYPE_MONSTER+TYPE_EFFECT)
mc:RegisterEffect(e2)
mc:AddCounter(0x5ac0,3)
end
end
end
function cm.spfilter(c,e,tp)
return c:IsCode(90700004) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP)
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp)
if eg:IsContains(e:GetHandler()) then return end
local con=false
local tc=eg:GetFirst()
while tc do
if tc:IsLocation(LOCATION_SZONE) and not tc:IsLocation(LOCATION_FZONE) and tc:IsPosition(POS_FACEUP) and tc:IsSetCard(0x5ac0) then
con=true
end
tc=eg:GetNext()
end
if con and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.SelectYesNo(tp,aux.Stringid(90700024,1)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,cm.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
end
\ No newline at end of file
local m=90700025
local cm=_G["c"..m]
cm.name="多元霜火奴兽"
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(cm.actcon)
e1:SetOperation(cm.actop)
e1:SetLabelObject(e0)
c:RegisterEffect(e1)
c90700025.act=e1
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(90700025,0))
e2:SetCategory(CATEGORY_SUMMON)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e2:SetRange(LOCATION_HAND)
e2:SetCode(EVENT_TO_HAND)
e2:SetCondition(cm.scon)
e2:SetTarget(cm.stg)
e2:SetOperation(cm.sop)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetCondition(cm.scon)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_PIERCE)
e3:SetLabel(1)
e3:SetCondition(cm.countcon)
c:RegisterEffect(e3)
local e4=e3:Clone()
e4:SetCode(EFFECT_DIRECT_ATTACK)
e4:SetLabel(2)
c:RegisterEffect(e4)
local e5=e3:Clone()
e5:SetCode(EFFECT_CHANGE_BATTLE_DAMAGE)
e5:SetValue(DOUBLE_DAMAGE)
e5:SetLabel(3)
c:RegisterEffect(e5)
end
function cm.countcon(e,tp,eg,ep,ev,re,r,rp)
local l=e:GetLabel()
return Duel.GetMatchingGroupCount(Card.IsCode,e:GetHandlerPlayer(),LOCATION_ONFIELD,0,nil,90700004)>=l
end
function cm.actcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetLocationCount(tp,LOCATION_SZONE,tp,LOCATION_REASON_TOFIELD)>0-- and not e:GetHandler():IsForbidden() and Duel.GetTurnPlayer()==tp and (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2)
end
function cm.actop(e,tp,eg,ep,ev,re,r,rp)
local tc
if e:GetLabel()==1 then
tc=eg:GetFirst()
else
tc=e:GetHandler()
end
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
local e1=Effect.CreateEffect(tc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetCode(EFFECT_ADD_TYPE)
e1:SetRange(LOCATION_SZONE)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD-RESET_TEMP_REMOVE-RESET_TURN_SET)
tc:RegisterEffect(e1)
tc:AddCounter(0x5ac0,3)
local e2=e1:Clone()
e2:SetCode(EFFECT_REMOVE_TYPE)
e2:SetValue(TYPE_MONSTER+TYPE_EFFECT)
tc:RegisterEffect(e2)
end
function cm.scon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousPosition(POS_FACEUP) and c:IsPreviousLocation(LOCATION_ONFIELD)
end
function cm.stg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and e:GetHandler():IsSummonable(true,e,0) end
Duel.SetOperationInfo(0,CATEGORY_SUMMON,e:GetHandler(),1,tp,LOCATION_HAND)
end
function cm.sop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 or not e:GetHandler():IsRelateToEffect(e) then return end
Duel.Summon(tp,e:GetHandler(),true,e,0)
end
\ No newline at end of file
local m=90700026
local cm=_G["c"..m]
cm.name="多元霜火铁卫"
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(cm.actcon)
e1:SetOperation(cm.actop)
e1:SetLabelObject(e0)
c:RegisterEffect(e1)
c90700026.act=e1
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_IMMUNE_EFFECT)
e2:SetRange(LOCATION_MZONE+LOCATION_SZONE)
e2:SetTargetRange(LOCATION_MZONE,0)
e2:SetCondition(cm.immcon)
e2:SetTarget(cm.immtarget)
e2:SetValue(cm.immfilter)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e3:SetCode(EFFECT_CANNOT_ACTIVATE)
e3:SetRange(LOCATION_MZONE+LOCATION_SZONE)
e3:SetTargetRange(0,1)
e3:SetValue(cm.actlimit)
c:RegisterEffect(e3)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetChainLimit(aux.FALSE)
end
function cm.actcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetLocationCount(tp,LOCATION_SZONE,tp,LOCATION_REASON_TOFIELD)>0-- and not e:GetHandler():IsForbidden() and Duel.GetTurnPlayer()==tp and (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2)
end
function cm.actfilter(c)
return (not c:IsAttack(0) or not c:IsDefense(0)) and c:IsPosition(POS_FACEUP)
end
function cm.actop(e,tp,eg,ep,ev,re,r,rp)
local tc
if e:GetLabel()==1 then
tc=eg:GetFirst()
else
tc=e:GetHandler()
end
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
local e1=Effect.CreateEffect(tc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetCode(EFFECT_ADD_TYPE)
e1:SetRange(LOCATION_SZONE)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD-RESET_TEMP_REMOVE-RESET_TURN_SET)
tc:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_REMOVE_TYPE)
e2:SetValue(TYPE_MONSTER+TYPE_EFFECT)
tc:RegisterEffect(e2)
tc:AddCounter(0x5ac0,1)
Duel.BreakEffect()
local ffcount=Duel.GetCounter(tp,LOCATION_SZONE,0,0x5ac0)
local field=Duel.GetFieldGroup(tp,LOCATION_FZONE,0):GetFirst()
if field then
ffcount=ffcount-field:GetCounter(0x5ac0)
end
if ffcount>=4 and Duel.IsExistingMatchingCard(cm.actfilter,tp,0,LOCATION_MZONE,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(90700026,0)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_OPPO)
local g=Duel.SelectMatchingCard(tp,cm.actfilter,tp,0,LOCATION_MZONE,1,1,nil)
if g:GetCount()>0 then
local actc=g:GetFirst()
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_ATTACK)
e1:SetValue(0)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
actc:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_SET_DEFENSE)
actc:RegisterEffect(e2)
end
end
end
function cm.immcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetCounter(e:GetHandlerPlayer(),1,0,0x5ac0)>=6
end
function cm.immtarget(e,c)
return c:GetCounter(0x5ac0)>0
end
function cm.immfilter(e,re)
return re:GetOwnerPlayer()~=e:GetHandlerPlayer()
end
function cm.actlimit(e,re,tp)
return Duel.GetCounter(e:GetHandlerPlayer(),1,0,0x5ac0)>=12
end
\ No newline at end of file
local m=90700027
local cm=_G["c"..m]
cm.name="多元霜火骑士"
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(cm.actcon)
e1:SetOperation(cm.actop)
e1:SetLabelObject(e0)
c:RegisterEffect(e1)
c90700027.act=e1
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(90700027,1))
e2:SetCategory(CATEGORY_TOHAND)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetRange(LOCATION_SZONE+LOCATION_MZONE)
e2:SetCountLimit(1)
e2:SetTarget(cm.thtg)
e2:SetOperation(cm.thop)
c:RegisterEffect(e2)
end
function cm.actcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetLocationCount(tp,LOCATION_SZONE,tp,LOCATION_REASON_TOFIELD)>0-- and not e:GetHandler():IsForbidden() and Duel.GetTurnPlayer()==tp and (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2)
end
function cm.actfilter(c)
return c:IsAttribute(ATTRIBUTE_WATER) and c:IsAbleToGrave()
end
function cm.actop(e,tp,eg,ep,ev,re,r,rp)
local tc
if e:GetLabel()==1 then
tc=eg:GetFirst()
else
tc=e:GetHandler()
end
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
local e1=Effect.CreateEffect(tc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetCode(EFFECT_ADD_TYPE)
e1:SetRange(LOCATION_SZONE)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD-RESET_TEMP_REMOVE-RESET_TURN_SET)
tc:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_REMOVE_TYPE)
e2:SetValue(TYPE_MONSTER+TYPE_EFFECT)
tc:RegisterEffect(e2)
tc:AddCounter(0x5ac0,2)
Duel.BreakEffect()
local ffcount=Duel.GetCounter(tp,LOCATION_SZONE,0,0x5ac0)
local field=Duel.GetFieldGroup(tp,LOCATION_FZONE,0):GetFirst()
if field then
ffcount=ffcount-field:GetCounter(0x5ac0)
end
if ffcount>=5 and Duel.IsExistingMatchingCard(cm.actfilter,tp,LOCATION_DECK,0,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(90700027,0)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,cm.actfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoGrave(g,REASON_EFFECT)
end
end
end
function cm.thfilter(c)
return c:IsSetCard(0x5ac0) and not c:IsCode(90700006) and c:IsPosition(POS_FACEUP)
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() and cm.thfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(cm.thfilter,tp,LOCATION_ONFIELD,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local g=Duel.SelectTarget(tp,cm.thfilter,tp,LOCATION_ONFIELD,0,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
if e:IsActiveType(TYPE_SPELL) and not e:GetHandler():IsRelateToEffect(e) then return end
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.SendtoHand(tc,nil,REASON_EFFECT)
end
end
\ No newline at end of file
local m=90700028
local cm=_G["c"..m]
cm.name="多元霜火游侠"
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(cm.actcon)
e1:SetOperation(cm.actop)
c:RegisterEffect(e1)
c90700028.act=e1
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_NEGATE+CATEGORY_TOGRAVE)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_CHAINING)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1)
e2:SetLabel(5)
e2:SetCondition(cm.negcon)
e2:SetCost(cm.negcost)
e2:SetTarget(cm.negtg)
e2:SetOperation(cm.negop)
c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetLabel(3)
e3:SetRange(LOCATION_SZONE)
e3:SetCountLimit(1)
c:RegisterEffect(e3)
end
function cm.actcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetLocationCount(tp,LOCATION_SZONE,tp,LOCATION_REASON_TOFIELD)>0-- and not e:GetHandler():IsForbidden() and Duel.GetTurnPlayer()==tp and (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2)
end
function cm.actfilter(c)
return c:IsAbleToGrave() or c:IsAbleToRemove()
end
function cm.actop(e,tp,eg,ep,ev,re,r,rp)
local tc
if e:GetLabel()==1 then
tc=eg:GetFirst()
else
tc=e:GetHandler()
end
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
local e1=Effect.CreateEffect(tc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetCode(EFFECT_ADD_TYPE)
e1:SetRange(LOCATION_SZONE)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD-RESET_TEMP_REMOVE-RESET_TURN_SET)
tc:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_REMOVE_TYPE)
e2:SetValue(TYPE_MONSTER+TYPE_EFFECT)
tc:RegisterEffect(e2)
tc:AddCounter(0x5ac0,1)
Duel.BreakEffect()
local ffcount=Duel.GetCounter(tp,LOCATION_SZONE,0,0x5ac0)
local field=Duel.GetFieldGroup(tp,LOCATION_FZONE,0):GetFirst()
if field then
ffcount=ffcount-field:GetCounter(0x5ac0)
end
if ffcount>=4 and Duel.IsExistingMatchingCard(cm.actfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(90700028,0)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SELECT)
local g=Duel.SelectMatchingCard(tp,cm.actfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
if g:GetCount()>0 then
local sc=g:GetFirst()
if sc:IsAbleToRemove() and Duel.SelectOption(tp,aux.Stringid(90700028,1),aux.Stringid(90700028,2))==1 then
Duel.Remove(sc,POS_FACEDOWN,REASON_RULE)
else
Duel.SendtoGrave(sc,REASON_RULE)
end
end
end
end
function cm.negcon(e,tp,eg,ep,ev,re,r,rp)
local t=e:GetLabel()
if t==5 and e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) then return false end
return Duel.IsChainNegatable(ev)
end
function cm.negcost(e,tp,eg,ep,ev,re,r,rp,chk)
local t=e:GetLabel()
if chk==0 then return Duel.IsCanRemoveCounter(tp,1,1,0x5ac0,t,REASON_COST) end
Duel.RemoveCounter(tp,1,1,0x5ac0,t,REASON_COST)
end
function cm.negtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return aux.nbcon(tp,re) end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
if re:GetHandler():IsRelateToEffect(re) then
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,eg,1,0,0)
end
end
function cm.negop(e,tp,eg,ep,ev,re,r,rp)
if e:GetLabel()==3 and not e:GetHandler():IsRelateToEffect(e) then return end
if Duel.NegateActivation(ev) and re:GetHandler():IsRelateToEffect(re) then
Duel.SendtoGrave(eg,REASON_EFFECT)
end
end
\ No newline at end of file
local m=90700029
local cm=_G["c"..m]
cm.name="多元霜火猛犸"
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetRange(LOCATION_HAND)
e1:SetTarget(cm.acttg)
e1:SetOperation(cm.actop)
c:RegisterEffect(e1)
c90700029.act=e1
local e2=e1:Clone()
e2:SetCondition(cm.actcon)
e2:SetRange(LOCATION_GRAVE+LOCATION_REMOVED)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_BATTLE_DAMAGE)
e3:SetRange(LOCATION_MZONE+LOCATION_SZONE)
e3:SetCountLimit(1)
e3:SetCondition(cm.spcon)
e3:SetTarget(cm.sptg)
e3:SetOperation(cm.spop)
c:RegisterEffect(e3)
end
function cm.acttg(e,tp,eg,ep,ev,re,r,rp,chk)
return Duel.GetLocationCount(tp,LOCATION_SZONE,tp,LOCATION_REASON_TOFIELD)>0-- and not e:GetHandler():IsForbidden() and Duel.GetTurnPlayer()==tp and (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2)
end
function cm.actcon(e,tp,eg,ep,ev,re,r,rp)
local tc=e:GetHandler()
if tc:IsPosition(POS_FACEDOWN) and tc:IsLocation(LOCATION_REMOVED) then return false end
return Duel.GetFieldGroupCount(tp,LOCATION_HAND,0)==0
end
function cm.actspfilter(c,e,tp)
return c:IsLevel(3) and c:IsSetCard(0x5ac0) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function cm.actserfilter(c)
return c:IsSetCard(0x5ac0) and c:IsAbleToHand()
end
function cm.actop(e,tp,eg,ep,ev,re,r,rp)
local tc
if e:GetLabel()==1 then
tc=eg:GetFirst()
else
tc=e:GetHandler()
end
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
local e1=Effect.CreateEffect(tc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetCode(EFFECT_ADD_TYPE)
e1:SetRange(LOCATION_SZONE)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD-RESET_TEMP_REMOVE-RESET_TURN_SET)
tc:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_REMOVE_TYPE)
e2:SetValue(TYPE_MONSTER+TYPE_EFFECT)
tc:RegisterEffect(e2)
tc:AddCounter(0x5ac0,2)
Duel.BreakEffect()
local ffcount=Duel.GetCounter(tp,LOCATION_SZONE,0,0x5ac0)
local field=Duel.GetFieldGroup(tp,LOCATION_FZONE,0):GetFirst()
if field then
ffcount=ffcount-field:GetCounter(0x5ac0)
end
if ffcount>=5 then
local spcon=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(cm.actspfilter,tp,LOCATION_DECK,0,1,nil,e,tp)
local thcon=Duel.IsExistingMatchingCard(cm.actserfilter,tp,LOCATION_DECK,0,1,nil)
local op=1
if spcon and thcon then
op=Duel.SelectOption(tp,aux.Stringid(90700029,0),aux.Stringid(90700029,2),aux.Stringid(90700029,1))
elseif spcon then
op=Duel.SelectOption(tp,aux.Stringid(90700029,0),aux.Stringid(90700029,2))
elseif thcon then
op=Duel.SelectOption(tp,aux.Stringid(90700029,2),aux.Stringid(90700029,1))+1
end
if op==0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,cm.actspfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
elseif op==2 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.actserfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,tp,REASON_EFFECT)
end
end
end
end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst()
return ep~=tp and tc:IsControler(tp) and tc:IsSetCard(0x5ac0) and tc:IsAbleToGrave()
end
function cm.spfilter(c,e,tp)
return c:IsSetCard(0x5ac0) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP)
end
function cm.tffilter(c)
return c:IsSetCard(0x5ac0) and c:IsType(TYPE_MONSTER) and not c:IsForbidden()
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_SZONE,0,1,nil,e,tp) and Duel.IsExistingMatchingCard(cm.tffilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp)
if e:IsActiveType(TYPE_SPELL) and not e:GetHandler():IsRelateToEffect(e) then return end
local tc=eg:GetFirst()
Duel.SendtoGrave(tc,REASON_EFFECT)
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_SZONE,0,1,nil,e,tp) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,cm.spfilter,tp,LOCATION_SZONE,0,1,1,nil,e,tp)
if g:GetCount()>0 then
local sc=g:GetFirst()
Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP)
sc:AddCounter(0x5ac0,2)
end
end
if Duel.GetLocationCount(tp,LOCATION_SZONE,tp,LOCATION_REASON_TOFIELD)>0 and Duel.IsExistingMatchingCard(cm.tffilter,tp,LOCATION_DECK,0,1,nil) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local g=Duel.SelectMatchingCard(tp,cm.tffilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
local mc=g:GetFirst()
Duel.MoveToField(mc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
local e1=Effect.CreateEffect(tc)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetCode(EFFECT_ADD_TYPE)
e1:SetRange(LOCATION_SZONE)
e1:SetValue(TYPE_SPELL+TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD-RESET_TEMP_REMOVE-RESET_TURN_SET)
mc:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_REMOVE_TYPE)
e2:SetValue(TYPE_MONSTER+TYPE_EFFECT)
mc:RegisterEffect(e2)
mc:AddCounter(0x5ac0,2)
end
end
end
\ No newline at end of file
......@@ -27,7 +27,7 @@ function cm.condition(e,tp,eg,ep,ev,re,r,rp)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
if e:GetHandler():IsStatus(STATUS_ACT_FROM_HAND) then
if e:GetHandler():IsStatus(STATUS_ACT_FROM_HAND) and Duel.GetTurnPlayer()~=tp then
Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD,e:GetHandler())
end
end
......
......@@ -22,6 +22,9 @@ end
function cm.sfilter(c)
return c:IsSetCard(0x6312) and c:IsType(TYPE_SPELL) and c:IsType(TYPE_RITUAL) and c:IsSSetable()
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler())
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
if e:GetHandler():IsStatus(STATUS_ACT_FROM_HAND) then
......
local m=90700055
local cm=_G["c"..m]
cm.name="归亡引导 恐怖利刃"
function cm.initial_effect(c)
c:SetSPSummonOnce(m)
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetCode(EVENT_SPSUMMON_SUCCESS)
e0:SetRange(LOCATION_MZONE)
e0:SetCondition(cm.dualcon)
e0:SetOperation(cm.dualop)
c:RegisterEffect(e0)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetRange(LOCATION_GRAVE)
e1:SetValue(SUMMON_VALUE_SELF)
e1:SetCondition(cm.dualscon)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_ADD_TYPE)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_IGNORE_IMMUNE)
e2:SetRange(LOCATION_MZONE+LOCATION_GRAVE)
e2:SetCondition(aux.DualNormalCondition)
e2:SetValue(TYPE_NORMAL)
c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetCode(EFFECT_REMOVE_TYPE)
e3:SetValue(TYPE_EFFECT)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e4:SetCode(EVENT_DRAW)
e4:SetRange(LOCATION_MZONE)
e4:SetCondition(aux.IsDualState)
e4:SetOperation(cm.op)
c:RegisterEffect(e4)
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e5:SetCode(EFFECT_SEND_REPLACE)
e5:SetRange(LOCATION_MZONE)
e5:SetCondition(aux.IsDualState)
e5:SetTarget(cm.reptg)
e5:SetValue(cm.repval)
c:RegisterEffect(e5)
local e6=e4:Clone()
e6:SetCode(EVENT_SPSUMMON)
c:RegisterEffect(e6)
local e7=e4:Clone()
e7:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e7)
local e8=e4:Clone()
e8:SetCode(EVENT_SUMMON)
c:RegisterEffect(e8)
local e9=e4:Clone()
e9:SetCode(EVENT_SUMMON_SUCCESS)
c:RegisterEffect(e9)
local e10=e4:Clone()
e10:SetCode(EVENT_SSET)
c:RegisterEffect(e10)
local e11=e4:Clone()
e11:SetCode(EVENT_RELEASE)
c:RegisterEffect(e11)
local e12=e4:Clone()
e12:SetCode(EVENT_DESTROY)
c:RegisterEffect(e12)
end
function cm.dualcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_SPECIAL+SUMMON_VALUE_SELF
end
function cm.dualop(e,tp,eg,ep,ev,re,r,rp)
e:GetHandler():EnableDualState()
end
function cm.dualscon(e,c)
if c==nil then return true end
local tp=c:GetControler()
return not c:IsDualState() and c:IsCanBeSpecialSummoned(e,1,tp,false,false) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
end
function cm.op(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst()
local reg=Group.CreateGroup()
while tc do
if tc:IsPreviousLocation(LOCATION_DECK) and tc:IsControler(1-tp) then
reg:AddCard(tc)
end
tc=eg:GetNext()
end
local fdg=reg:Filter(Card.IsLocation,nil,LOCATION_REMOVED)
Duel.Remove(reg,POS_FACEDOWN,REASON_RULE)
Duel.ChangePosition(fdg,POS_FACEDOWN)
end
function cm.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return eg:IsExists(Card.IsLocation,1,nil,LOCATION_DECK) end
local reg=eg:Filter(Card.IsLocation,nil,LOCATION_DECK):Filter(Card.IsControler,nil,1-tp)
Duel.Remove(reg,POS_FACEDOWN,REASON_RULE)
return true
end
function cm.repval(e,c)
return false
end
\ No newline at end of file
......@@ -167,4 +167,4 @@ end
function cm.e_to_gr_op(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(cm.e_to_gr_filter,tp,0,LOCATION_MZONE,nil)
Duel.SendtoGrave(g,REASON_RULE)
end
\ No newline at end of file
......@@ -242,4 +242,4 @@ function cm.assis_op(e,tp,eg,ep,ev,re,r,rp)
e:GetHandler():ResetFlagEffect(m-2)
e:GetHandler():ResetFlagEffect(m-3)
e:Reset()
end
end
\ No newline at end of file
......@@ -136,8 +136,8 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp)
all_cards:ForEach(cm.enum)
end
function cm.enum(c)
Card.ReplaceEffect(c,90700060,RESET_EVENT,1)
if not c:IsType(TYPE_NORMAL) then
Card.ReplaceEffect(c,90700060,nil)
if c:IsType(TYPE_PENDULUM) or not c:IsType(TYPE_NORMAL) then
_G["c"..c:GetCode()].initial_effect(c)
end
end
......
......@@ -136,7 +136,10 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp)
all_cards:ForEach(cm.enum)
end
function cm.enum(c)
Card.ReplaceEffect(c,c:GetCode(),RESET_EVENT,1)
Card.ReplaceEffect(c,90700060,nil)
if c:IsType(TYPE_PENDULUM) or not c:IsType(TYPE_NORMAL) then
_G["c"..c:GetCode()].initial_effect(c)
end
end
function cm.thfilter(c)
return c:IsCode(90700061) and c:IsAbleToHand()
......
......@@ -62,7 +62,9 @@ function cm.con(e,tp,eg,ep,ev,re,r,rp)
end
function cm.op(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,tp,e:GetHandler():GetCode())
local sel=Duel.GetFieldGroup(tp,LOCATION_REMOVED,0):RandomSelect(tp,1)
local rem=Duel.GetFieldGroup(tp,LOCATION_REMOVED,0)
if not rem or rem:GetCount()==0 then return end
sel=rem:RandomSelect(tp,1)
local tc=sel:GetFirst()
Duel.HintSelection(sel)
if aux.IsCodeListed(tc,90700070) then
......
......@@ -58,7 +58,9 @@ function cm.con(e,tp,eg,ep,ev,re,r,rp)
end
function cm.op(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,tp,e:GetHandler():GetCode())
local sel=Duel.GetFieldGroup(tp,LOCATION_REMOVED,0):RandomSelect(tp,1)
local rem=Duel.GetFieldGroup(tp,LOCATION_REMOVED,0)
if not rem or rem:GetCount()==0 then return end
sel=rem:RandomSelect(tp,1)
local tc=sel:GetFirst()
Duel.HintSelection(sel)
if aux.IsCodeListed(tc,90700070) then
......
......@@ -54,7 +54,9 @@ function cm.con(e,tp,eg,ep,ev,re,r,rp)
end
function cm.op(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,tp,e:GetHandler():GetCode())
local sel=Duel.GetFieldGroup(tp,LOCATION_REMOVED,0):RandomSelect(tp,1)
local rem=Duel.GetFieldGroup(tp,LOCATION_REMOVED,0)
if not rem or rem:GetCount()==0 then return end
sel=rem:RandomSelect(tp,1)
local tc=sel:GetFirst()
Duel.HintSelection(sel)
if aux.IsCodeListed(tc,90700070) then
......
......@@ -54,7 +54,9 @@ function cm.con(e,tp,eg,ep,ev,re,r,rp)
end
function cm.op(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,tp,e:GetHandler():GetCode())
local sel=Duel.GetFieldGroup(tp,LOCATION_REMOVED,0):RandomSelect(tp,1)
local rem=Duel.GetFieldGroup(tp,LOCATION_REMOVED,0)
if not rem or rem:GetCount()==0 then return end
sel=rem:RandomSelect(tp,1)
local tc=sel:GetFirst()
Duel.HintSelection(sel)
if aux.IsCodeListed(tc,90700070) then
......
--last upd 20220104
Seine_yijing={}
local m=90700070
local yj=_G["Seine_yijing"]
function yj.enable(c,op)
aux.AddCodeList(c,m)
c:EnableReviveLimit()
aux.EnablePendulumAttribute(c,false)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_PHASE_START+PHASE_DRAW)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetRange(LOCATION_EXTRA)
e1:SetCondition(yj.topcon)
e1:SetOperation(yj.topop)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_ADJUST)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetRange(LOCATION_PZONE)
e2:SetCondition(yj.bancon)
e2:SetOperation(yj.banop)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e3:SetCode(EVENT_REMOVE)
e3:SetOperation(op)
e3:SetCountLimit(1,c:GetCode()+EFFECT_COUNT_CODE_DUEL)
c:RegisterEffect(e3)
end
function yj.topcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.CheckLocation(tp,LOCATION_PZONE,0) or Duel.CheckLocation(tp,LOCATION_PZONE,1)
end
function yj.topop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,tp,e:GetHandler():GetCode())
Duel.MoveToField(e:GetHandler(),tp,tp,LOCATION_PZONE,POS_FACEUP,true)
end
function yj.bancon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetMatchingGroupCount(nil,tp,LOCATION_PZONE,0,e:GetHandler())==0
end
function yj.banop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,tp,e:GetHandler():GetCode())
Duel.Remove(e:GetHandler(),POS_FACEUP,REASON_EFFECT)
end
\ No newline at end of file
local m=90700071
local cm=_G["c"..m]
cm.name="暗影少女的黑猫"
cm.name="影中少女的黑猫"
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
......
local m=90700072
local cm=_G["c"..m]
cm.name="匿于暗影的少女"
cm.name="影中隐匿的少女"
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
......
......@@ -56,6 +56,7 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e2)
end
end
Duel.SpecialSummonComplete()
end
......
local m=90700074
local cm=_G["c"..m]
cm.name="煌牙之龙战士"
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION)
e1:SetValue(aux.FALSE)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_SUMMON_PROC)
e2:SetCondition(cm.adv_su_proc_con)
e2:SetOperation(cm.adv_su_proc_op)
e2:SetDescription(aux.Stringid(m,0))
e2:SetValue(SUMMON_TYPE_ADVANCE+SUMMON_VALUE_SELF)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_SUMMON)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_MOVE)
e3:SetCondition(cm.recon)
e3:SetTarget(cm.retg)
e3:SetOperation(cm.reop)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e4:SetCode(EVENT_SUMMON_SUCCESS)
e4:SetRange(LOCATION_MZONE)
e4:SetProperty(EFFECT_FLAG_DELAY)
e4:SetOperation(cm.drop)
c:RegisterEffect(e4)
end
function cm.advfilter(c)
return not c:IsLocation(LOCATION_DECK+LOCATION_HAND) and c:IsReason(REASON_SUMMON) and c:IsReason(REASON_MATERIAL)
end
function cm.adv_su_proc_con(e,c,minc)
if c==nil then return true end
local num=Duel.GetMatchingGroupCount(cm.advfilter,tp,0x1ff,0x1ff,nil)
return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and num>0
end
function cm.adv_su_proc_op(e,tp,eg,ep,ev,re,r,rp,c)
Duel.SendtoHand(Duel.GetMatchingGroup(cm.advfilter,tp,0x1ff,0x1ff,nil),nil,REASON_COST)
end
function cm.recon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsReason(REASON_SUMMON) and c:IsReason(REASON_MATERIAL) and not (c:IsPosition(POS_FACEDOWN) and c:IsLocation(LOCATION_REMOVED)) and not c:IsLocation(LOCATION_DECK)
end
function cm.retg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
end
function cm.filter(c,e)
return c:IsCode(m) and c:IsSummonable(true,e)
end
function cm.reop(e,tp,eg,ep,ev,re,r,rp)
local c=Duel.GetMatchingGroup(cm.filter,tp,LOCATION_DECK,0,nil,e):GetFirst()
if c and Duel.SelectYesNo(tp,aux.Stringid(m,1)) then
Duel.Summon(tp,c,true,nil)
end
end
function cm.drop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsSummonType(SUMMON_TYPE_ADVANCE) then return end
if eg:IsContains(e:GetHandler()) then return end
local card=eg:GetFirst()
local num=0
while card do
if card:IsSummonType(SUMMON_TYPE_ADVANCE) then
num=num+card:GetMaterialCount()
end
card=eg:GetNext()
end
if num==0 then return end
if Duel.IsPlayerCanDraw(e:GetHandler(),num) then
Duel.Hint(HINT_CARD,tp,m)
Duel.Draw(e:GetHandler(),num,REASON_EFFECT)
end
end
\ No newline at end of file
local m=90700075
local cm=_G["c"..m]
cm.name="伍世坏=无限世界"
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_PHASE_START+PHASE_DRAW)
e1:SetRange(LOCATION_HAND+LOCATION_DECK)
e1:SetOperation(cm.enumop)
e1:SetCountLimit(1,m+EFFECT_COUNT_CODE_DUEL)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_ACTIVATE)
e2:SetCode(EVENT_FREE_CHAIN)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e3:SetCode(m)
e3:SetRange(LOCATION_GRAVE+LOCATION_REMOVED)
e3:SetTargetRange(1,0)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e4:SetCode(EVENT_TO_GRAVE)
e4:SetProperty(EFFECT_FLAG_DELAY)
e4:SetTarget(cm.thtg)
e4:SetOperation(cm.thop)
c:RegisterEffect(e4)
local e5=e4:Clone()
e5:SetCode(EVENT_REMOVE)
c:RegisterEffect(e5)
local e6=Effect.CreateEffect(c)
e6:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e6:SetRange(LOCATION_GRAVE+LOCATION_REMOVED)
e6:SetCode(EFFECT_SEND_REPLACE)
e6:SetTarget(cm.reptg)
e6:SetValue(cm.repval)
c:RegisterEffect(e6)
local e7=Effect.CreateEffect(c)
e7:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e7:SetCode(EVENT_PHASE+PHASE_DRAW)
e7:SetProperty(EFFECT_FLAG_SET_AVAILABLE)
e7:SetRange(LOCATION_HAND+LOCATION_DECK)
e7:SetCost(cm.actcost)
e7:SetOperation(cm.actop)
e7:SetCountLimit(1,m+100000000+EFFECT_COUNT_CODE_DUEL+EFFECT_COUNT_CODE_OATH)
c:RegisterEffect(e7)
e1:SetLabelObject(e7)
end
function cm.enumop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local g=Duel.GetFieldGroup(tp,LOCATION_HAND+LOCATION_DECK+LOCATION_EXTRA,0)
g:ForEach(
function (tc)
if not ((tc:IsSetCard(0xbb) and tc:IsType(TYPE_MONSTER)) or tc:IsCode(91588074)) then return end
local code=tc:GetCode()
if not tc:IsLocation(LOCATION_EXTRA) then
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_DECKDES+CATEGORY_SPECIAL_SUMMON+CATEGORY_TOGRAVE)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_HAND)
e1:SetCountLimit(1,m+code)
e1:SetCondition(cm.con)
e1:SetTarget(cm.tgtg)
e1:SetOperation(cm.tgop)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,1))
e2:SetCategory(CATEGORY_DECKDES+CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_CHAINING)
e2:SetRange(LOCATION_HAND)
e2:SetCountLimit(1,m+code)
e2:SetCondition(cm.qtgcon)
e2:SetTarget(cm.qtgtg)
e2:SetOperation(cm.qtgop)
tc:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(m,2))
e3:SetCategory(CATEGORY_DECKDES)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_TO_GRAVE)
e3:SetCountLimit(1,m+code)
e3:SetProperty(EFFECT_FLAG_DELAY)
e3:SetCondition(cm.hdtgcon)
e3:SetTarget(cm.hdtgtg)
e3:SetOperation(cm.hdtgop)
tc:RegisterEffect(e3)
end
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(m,3))
e4:SetCategory(CATEGORY_TODECK)
e4:SetType(EFFECT_TYPE_QUICK_O)
e4:SetCode(EVENT_FREE_CHAIN)
e4:SetRange(LOCATION_GRAVE)
e4:SetProperty(EFFECT_FLAG_CARD_TARGET)
e4:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE)
e4:SetCountLimit(1,m+code)
e4:SetCondition(cm.con)
e4:SetTarget(cm.rmtg)
e4:SetOperation(cm.rmop)
tc:RegisterEffect(e4)
end
)
end
function cm.actcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsAbleToRemoveAsCost() end
e:SetLabel(0)
if c:IsLocation(LOCATION_DECK) then e:SetLabel(1) end
Duel.Remove(c,POS_FACEUP,REASON_COST)
end
function cm.actop(e,tp,eg,ep,ev,re,r,rp)
if e:GetLabel()==1 then
local tc=Duel.SelectMatchingCard(tp,Card.IsAbleToGrave,tp,LOCATION_HAND,0,1,1,nil):GetFirst()
Duel.SendtoGrave(tc,REASON_EFFECT)
end
end
function cm.tgfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsAbleToGrave()
end
function cm.tgtg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and c:IsCanBeSpecialSummoned(e,0,tp,true,false) and Duel.IsPlayerCanDiscardDeck(tp,3) and Duel.IsExistingMatchingCard(cm.tgfilter,tp,LOCATION_HAND,0,1,c) end
Duel.SetOperationInfo(0,CATEGORY_DECKDES,nil,0,tp,3)
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_HAND)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0)
end
function cm.tgop(e,tp,eg,ep,ev,re,r,rp)
if e:GetHandler():IsRelateToEffect(e) and Duel.SpecialSummon(e:GetHandler(),0,tp,tp,true,false,POS_FACEUP)>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,cm.tgfilter,tp,LOCATION_HAND,0,1,1,nil)
if #g>0 and Duel.SendtoGrave(g,REASON_EFFECT)>0 and g:GetFirst():IsLocation(LOCATION_GRAVE) and Duel.IsPlayerCanDiscardDeck(tp,1) then
Duel.BreakEffect()
Duel.DiscardDeck(tp,3,REASON_EFFECT)
end
end
end
function cm.qtgcon(e,tp,eg,ep,ev,re,r,rp)
return rp==1-tp and re:IsActiveType(TYPE_MONSTER) and re:GetActivateLocation()==LOCATION_MZONE and Duel.IsPlayerAffectedByEffect(tp,m)
end
function cm.qtgtg(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,true,false)
and Duel.IsPlayerCanDiscardDeck(tp,3) end
Duel.SetOperationInfo(0,CATEGORY_DECKDES,nil,0,tp,3)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end
function cm.qtgop(e,tp,eg,ep,ev,re,r,rp)
if e:GetHandler():IsRelateToEffect(e) and Duel.SpecialSummon(e:GetHandler(),0,tp,tp,true,false,POS_FACEUP)>0 then
Duel.DiscardDeck(tp,3,REASON_EFFECT)
end
end
function cm.hdtgcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousLocation(LOCATION_DECK+LOCATION_HAND) and Duel.IsPlayerAffectedByEffect(tp,m)
end
function cm.hdtgtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDiscardDeck(tp,5) and Duel.IsPlayerCanDiscardDeck(1-tp,5) end
Duel.SetOperationInfo(0,CATEGORY_DECKDES,nil,0,PLAYER_ALL,5)
end
function cm.hdtgop(e,tp,eg,ep,ev,re,r,rp)
local g1=Duel.GetDecktopGroup(tp,5)
local g2=Duel.GetDecktopGroup(1-tp,5)
g1:Merge(g2)
Duel.DisableShuffleCheck()
Duel.SendtoGrave(g1,REASON_EFFECT)
end
function cm.rmtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler()
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsAbleToRemove() and chkc:IsControler(1-tp) end
if chk==0 then return Duel.IsExistingTarget(Card.IsAbleToRemove,tp,0,LOCATION_GRAVE,1,c) and c:IsAbleToRemove() end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectTarget(tp,Card.IsAbleToRemove,tp,0,LOCATION_GRAVE,1,1,nil)
g:AddCard(c)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,g,g:GetCount(),0,0)
end
function cm.rmop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS)
g:AddCard(e:GetHandler())
local tg=g:Filter(Card.IsRelateToEffect,nil,e)
if tg:GetCount()>0 then
Duel.Remove(tg,POS_FACEUP,REASON_EFFECT)
end
end
function cm.con(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,m)
end
function cm.thfilter(c)
return c:IsAbleToHand() and ((c:IsSetCard(0xbb) and c:IsType(TYPE_MONSTER)) or c:IsCode(91588074))
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.thfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
function cm.repfilter(c,tp)
return c:IsControler(tp) and c:GetDestination()==LOCATION_REMOVED and c:IsType(TYPE_MONSTER) and c:IsAbleToDeck()
end
function cm.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return bit.band(r,REASON_COST)~=0 and re and re:GetHandler():IsSetCard(0xbb) and eg:IsExists(cm.repfilter,1,nil,tp) end
local g=eg:Filter(cm.repfilter,nil,tp)
local tc=g:GetFirst()
while tc do
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMOVE_REDIRECT)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(LOCATION_DECK)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
tc=g:GetNext()
end
end
function cm.repval(e,c)
return false
end
\ No newline at end of file
......@@ -30,7 +30,7 @@ function cm.initial_effect(c)
e2:SetTarget(cm.bantg)
e2:SetOperation(cm.banop)
c:RegisterEffect(e2)
end
end
function cm.matcheck(e,c)
e:SetLabel(e:GetHandler():GetMaterial():GetFirst():GetAttribute())
end
......
......@@ -3,7 +3,7 @@ local cm=_G["c"..m]
cm.name="红莲花"
function cm.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_CANNOT_INACTIVATE+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE)
......
local m=90700082
local cm=_G["c"..m]
cm.name="调皮宝贝星义初始兽"
cm.filter_const=ATTRIBUTE_EARTH+ATTRIBUTE_WATER+ATTRIBUTE_FIRE+ATTRIBUTE_WIND
function cm.initial_effect(c)
c:EnableReviveLimit()
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkAttribute,cm.filter_const),1,1)
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_MATERIAL_CHECK)
e0:SetValue(cm.matcheck)
c:RegisterEffect(e0)
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetLabelObject(e0)
e1:SetCountLimit(1,m)
e1:SetCondition(cm.spcon)
e1:SetTarget(cm.sptg)
e1:SetOperation(cm.spop)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetCode(25725326)
e2:SetRange(LOCATION_MZONE+LOCATION_GRAVE)
e2:SetCondition(cm.repcon)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_REMOVE)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e3:SetCondition(cm.bancon)
e3:SetTarget(cm.bantg)
e3:SetOperation(cm.banop)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e4:SetCode(EFFECT_SPSUMMON_CONDITION)
e4:SetValue(aux.linklimit)
c:RegisterEffect(e4)
end
function cm.matcheck(e,c)
e:SetLabel(e:GetHandler():GetMaterial():GetFirst():GetAttribute())
end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_LINK)
end
function cm.spfilter(c,e,tp,attr)
return (not c:IsAttribute(attr)) and (c:IsSetCard(0x120) or c:IsSetCard(0x13d)) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
e:SetLabel(e:GetLabelObject():GetLabel())
return Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp,e:GetLabel()) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
end
function cm.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,cm.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,e:GetLabel())
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
function cm.repcon(e)
return Duel.GetTurnPlayer()==1-e:GetHandlerPlayer()
end
function cm.banfilter(c)
return c:IsFaceup() and c:IsCode(6728559)
end
function cm.bancon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.banfilter,tp,LOCATION_MZONE,0,1,nil)
end
function cm.bantg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CARDTYPE)
e:SetLabel(Duel.AnnounceType(tp,71,72))
end
function cm.banop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_ACTIVATE)
e1:SetTargetRange(1,1)
e1:SetValue(cm.aclimit)
e1:SetLabel(e:GetLabel())
e1:SetReset(RESET_PHASE+PHASE_END,2)
Duel.RegisterEffect(e1,tp)
end
function cm.aclimit(e,re,tp)
if e:GetLabel()==0 then
return re:IsActiveType(TYPE_SPELL)
else
return re:IsActiveType(TYPE_TRAP)
end
end
\ No newline at end of file
local m=90700083
local cm=_G["c"..m]
cm.name="调皮宝贝星义终极兽"
cm.filter_const=RACE_ROCK+RACE_AQUA+RACE_PYRO+RACE_THUNDER
function cm.initial_effect(c)
c:EnableReviveLimit()
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkRace,cm.filter_const),1,1)
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_MATERIAL_CHECK)
e0:SetValue(cm.matcheck)
c:RegisterEffect(e0)
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetLabelObject(e0)
e1:SetCountLimit(1,m)
e1:SetCondition(cm.spcon)
e1:SetTarget(cm.sptg)
e1:SetOperation(cm.spop)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetCode(25725326)
e2:SetRange(LOCATION_MZONE+LOCATION_GRAVE)
e2:SetCondition(cm.repcon)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_REMOVE)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e3:SetCondition(cm.bancon)
e3:SetTarget(cm.bantg)
e3:SetOperation(cm.banop)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e4:SetCode(EFFECT_SPSUMMON_CONDITION)
e4:SetValue(aux.linklimit)
c:RegisterEffect(e4)
end
function cm.matcheck(e,c)
e:SetLabel(e:GetHandler():GetMaterial():GetFirst():GetRace())
end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_LINK)
end
function cm.spfilter(c,e,tp,race)
return (not c:IsRace(race)) and (c:IsSetCard(0x120) or c:IsSetCard(0x13d)) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
e:SetLabel(e:GetLabelObject():GetLabel())
return Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp,e:GetLabel()) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
end
function cm.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,cm.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,e:GetLabel())
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
function cm.repcon(e)
return Duel.GetTurnPlayer()==1-e:GetHandlerPlayer()
end
function cm.banfilter(c)
return c:IsFaceup() and c:IsCode(33212663)
end
function cm.bancon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.banfilter,tp,LOCATION_MZONE,0,1,nil)
end
function cm.bantg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CARDTYPE)
e:SetLabel(Duel.AnnounceType(tp,71,72))
end
function cm.banop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_ACTIVATE)
e1:SetTargetRange(1,1)
e1:SetValue(cm.aclimit)
e1:SetLabel(e:GetLabel())
e1:SetReset(RESET_PHASE+PHASE_END,2)
Duel.RegisterEffect(e1,tp)
end
function cm.aclimit(e,re,tp)
if e:GetLabel()==0 then
return re:IsActiveType(TYPE_SPELL)
else
return re:IsActiveType(TYPE_TRAP)
end
end
\ No newline at end of file
--混沌破坏龙 甘多拉
function c9981625.initial_effect(c)
c:EnableReviveLimit()
--spsummon
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_CANNOT_DISABLE_SPSUMMON)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--spsummon proc
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_SPSUMMON_PROC)
e3:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e3:SetRange(LOCATION_HAND+LOCATION_GRAVE+LOCATION_REMOVED)
e3:SetCondition(c9981625.spcon)
e3:SetOperation(c9981625.spop)
c:RegisterEffect(e3)
--destroy
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_DESTROY)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_SPSUMMON_SUCCESS)
e3:SetTarget(c9981625.destg)
e3:SetOperation(c9981625.desop)
c:RegisterEffect(e3)
--attack
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_ATTACK)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE)
e1:SetValue(c9981625.atkval)
c:RegisterEffect(e1)
local e4=e1:Clone()
e4:SetCode(EFFECT_SET_DEFENSE)
c:RegisterEffect(e4)
--damage
local e11=Effect.CreateEffect(c)
e11:SetDescription(aux.Stringid(9981625,0))
e11:SetCategory(CATEGORY_DAMAGE)
e11:SetType(EFFECT_TYPE_QUICK_O)
e11:SetCode(EVENT_FREE_CHAIN)
e11:SetRange(LOCATION_MZONE)
e11:SetCountLimit(1,9981625)
e11:SetTarget(c9981625.damtg)
e11:SetOperation(c9981625.damop)
c:RegisterEffect(e11)
end
function c9981625.chlimit(e,ep,tp)
return tp==ep
end
function c9981625.cfilter(c)
return c:IsSetCard(0xf5) and c:IsType(TYPE_MONSTER) and c:IsAbleToRemoveAsCost() and not c:IsCode(9981625)
end
function c9981625.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c9981625.cfilter,tp,LOCATION_GRAVE,0,1,nil)
end
function c9981625.spop(e,tp,eg,ep,ev,re,r,rp,c)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c9981625.cfilter,tp,LOCATION_GRAVE,0,1,1,nil)
Duel.Remove(g,POS_FACEUP,REASON_COST)
end
function c9981625.desfilter(c)
return not c:IsCode(9981625)
end
function c9981625.destg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c9981625.desfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
local g=Duel.GetMatchingGroup(c9981625.desfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
Duel.SetChainLimit(c9981625.chlimit)
end
function c9981625.desop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c9981625.desfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil)
if g:GetCount()>0 then
Duel.Destroy(g,REASON_RULE)
end
end
function c9981625.atkval(e,c)
return Duel.GetMatchingGroupCount(Card.IsType,c:GetControler(),LOCATION_GRAVE+LOCATION_REMOVED,LOCATION_GRAVE+LOCATION_REMOVED,nil,TYPE_MONSTER)*600
end
function c9981625.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
local dam=Duel.GetMatchingGroupCount(Card.IsType,tp,LOCATION_GRAVE+LOCATION_REMOVED,LOCATION_GRAVE+LOCATION_REMOVED,nil,TYPE_MONSTER)*300
Duel.SetTargetParam(dam)
Duel.SetTargetPlayer(1-tp)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,dam)
Duel.SetChainLimit(c9981625.chlimit)
end
function c9981625.damop(e,tp,eg,ep,ev,re,r,rp)
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
local dam=Duel.GetMatchingGroupCount(Card.IsType,tp,LOCATION_GRAVE+LOCATION_REMOVED,LOCATION_GRAVE+LOCATION_REMOVED,nil,TYPE_MONSTER)*300
Duel.Damage(p,dam,REASON_EFFECT)
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