Commit 418a9185 authored by REIKAI's avatar REIKAI 💬

2022.9.13 reikai do

parent addc10e7
No preview for this file type
expansions/pics/10710001.jpg

13.3 KB | W: | H:

expansions/pics/10710001.jpg

65.9 KB | W: | H:

expansions/pics/10710001.jpg
expansions/pics/10710001.jpg
expansions/pics/10710001.jpg
expansions/pics/10710001.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10983003.jpg

150 KB | W: | H:

expansions/pics/10983003.jpg

78.2 KB | W: | H:

expansions/pics/10983003.jpg
expansions/pics/10983003.jpg
expansions/pics/10983003.jpg
expansions/pics/10983003.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10983004.jpg

166 KB | W: | H:

expansions/pics/10983004.jpg

90.2 KB | W: | H:

expansions/pics/10983004.jpg
expansions/pics/10983004.jpg
expansions/pics/10983004.jpg
expansions/pics/10983004.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/14175006.jpg

139 KB | W: | H:

expansions/pics/14175006.jpg

75.7 KB | W: | H:

expansions/pics/14175006.jpg
expansions/pics/14175006.jpg
expansions/pics/14175006.jpg
expansions/pics/14175006.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/17035220.jpg

148 KB | W: | H:

expansions/pics/17035220.jpg

100 KB | W: | H:

expansions/pics/17035220.jpg
expansions/pics/17035220.jpg
expansions/pics/17035220.jpg
expansions/pics/17035220.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/17035310.jpg

56.7 KB | W: | H:

expansions/pics/17035310.jpg

103 KB | W: | H:

expansions/pics/17035310.jpg
expansions/pics/17035310.jpg
expansions/pics/17035310.jpg
expansions/pics/17035310.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/20066024.jpg

152 KB | W: | H:

expansions/pics/20066024.jpg

83.2 KB | W: | H:

expansions/pics/20066024.jpg
expansions/pics/20066024.jpg
expansions/pics/20066024.jpg
expansions/pics/20066024.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/20066025.jpg

182 KB | W: | H:

expansions/pics/20066025.jpg

79.2 KB | W: | H:

expansions/pics/20066025.jpg
expansions/pics/20066025.jpg
expansions/pics/20066025.jpg
expansions/pics/20066025.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/20066026.jpg

159 KB | W: | H:

expansions/pics/20066026.jpg

87.4 KB | W: | H:

expansions/pics/20066026.jpg
expansions/pics/20066026.jpg
expansions/pics/20066026.jpg
expansions/pics/20066026.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/20066036.jpg

163 KB | W: | H:

expansions/pics/20066036.jpg

93.6 KB | W: | H:

expansions/pics/20066036.jpg
expansions/pics/20066036.jpg
expansions/pics/20066036.jpg
expansions/pics/20066036.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865310.jpg

12.3 KB | W: | H:

expansions/pics/24865310.jpg

18.4 KB | W: | H:

expansions/pics/24865310.jpg
expansions/pics/24865310.jpg
expansions/pics/24865310.jpg
expansions/pics/24865310.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865311.jpg

11.8 KB | W: | H:

expansions/pics/24865311.jpg

17.9 KB | W: | H:

expansions/pics/24865311.jpg
expansions/pics/24865311.jpg
expansions/pics/24865311.jpg
expansions/pics/24865311.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865312.jpg

10.6 KB | W: | H:

expansions/pics/24865312.jpg

16 KB | W: | H:

expansions/pics/24865312.jpg
expansions/pics/24865312.jpg
expansions/pics/24865312.jpg
expansions/pics/24865312.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865313.jpg

12.8 KB | W: | H:

expansions/pics/24865313.jpg

19.2 KB | W: | H:

expansions/pics/24865313.jpg
expansions/pics/24865313.jpg
expansions/pics/24865313.jpg
expansions/pics/24865313.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865314.jpg

15.1 KB | W: | H:

expansions/pics/24865314.jpg

22.6 KB | W: | H:

expansions/pics/24865314.jpg
expansions/pics/24865314.jpg
expansions/pics/24865314.jpg
expansions/pics/24865314.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865315.jpg

15.3 KB | W: | H:

expansions/pics/24865315.jpg

22.7 KB | W: | H:

expansions/pics/24865315.jpg
expansions/pics/24865315.jpg
expansions/pics/24865315.jpg
expansions/pics/24865315.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865316.jpg

15.1 KB | W: | H:

expansions/pics/24865316.jpg

22.4 KB | W: | H:

expansions/pics/24865316.jpg
expansions/pics/24865316.jpg
expansions/pics/24865316.jpg
expansions/pics/24865316.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865317.jpg

14.1 KB | W: | H:

expansions/pics/24865317.jpg

21 KB | W: | H:

expansions/pics/24865317.jpg
expansions/pics/24865317.jpg
expansions/pics/24865317.jpg
expansions/pics/24865317.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865318.jpg

14.3 KB | W: | H:

expansions/pics/24865318.jpg

21.3 KB | W: | H:

expansions/pics/24865318.jpg
expansions/pics/24865318.jpg
expansions/pics/24865318.jpg
expansions/pics/24865318.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865320.jpg

14.9 KB | W: | H:

expansions/pics/24865320.jpg

22 KB | W: | H:

expansions/pics/24865320.jpg
expansions/pics/24865320.jpg
expansions/pics/24865320.jpg
expansions/pics/24865320.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865321.jpg

15.1 KB | W: | H:

expansions/pics/24865321.jpg

22.4 KB | W: | H:

expansions/pics/24865321.jpg
expansions/pics/24865321.jpg
expansions/pics/24865321.jpg
expansions/pics/24865321.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865322.jpg

11.6 KB | W: | H:

expansions/pics/24865322.jpg

17.3 KB | W: | H:

expansions/pics/24865322.jpg
expansions/pics/24865322.jpg
expansions/pics/24865322.jpg
expansions/pics/24865322.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865323.jpg

15.8 KB | W: | H:

expansions/pics/24865323.jpg

22.9 KB | W: | H:

expansions/pics/24865323.jpg
expansions/pics/24865323.jpg
expansions/pics/24865323.jpg
expansions/pics/24865323.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865324.jpg

11.7 KB | W: | H:

expansions/pics/24865324.jpg

80.5 KB | W: | H:

expansions/pics/24865324.jpg
expansions/pics/24865324.jpg
expansions/pics/24865324.jpg
expansions/pics/24865324.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865331.jpg

13.4 KB | W: | H:

expansions/pics/24865331.jpg

73.3 KB | W: | H:

expansions/pics/24865331.jpg
expansions/pics/24865331.jpg
expansions/pics/24865331.jpg
expansions/pics/24865331.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/24865340.jpg

13.9 KB | W: | H:

expansions/pics/24865340.jpg

20.5 KB | W: | H:

expansions/pics/24865340.jpg
expansions/pics/24865340.jpg
expansions/pics/24865340.jpg
expansions/pics/24865340.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/30005130.jpg

56.7 KB | W: | H:

expansions/pics/30005130.jpg

95.3 KB | W: | H:

expansions/pics/30005130.jpg
expansions/pics/30005130.jpg
expansions/pics/30005130.jpg
expansions/pics/30005130.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/33381018.jpg

141 KB | W: | H:

expansions/pics/33381018.jpg

93.1 KB | W: | H:

expansions/pics/33381018.jpg
expansions/pics/33381018.jpg
expansions/pics/33381018.jpg
expansions/pics/33381018.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/51300081.jpg

12.9 KB | W: | H:

expansions/pics/51300081.jpg

17.9 KB | W: | H:

expansions/pics/51300081.jpg
expansions/pics/51300081.jpg
expansions/pics/51300081.jpg
expansions/pics/51300081.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/66914000.jpg

53.9 KB | W: | H:

expansions/pics/66914000.jpg

83.3 KB | W: | H:

expansions/pics/66914000.jpg
expansions/pics/66914000.jpg
expansions/pics/66914000.jpg
expansions/pics/66914000.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/66914001.jpg

60.1 KB | W: | H:

expansions/pics/66914001.jpg

90.5 KB | W: | H:

expansions/pics/66914001.jpg
expansions/pics/66914001.jpg
expansions/pics/66914001.jpg
expansions/pics/66914001.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/66914005.jpg

62.6 KB | W: | H:

expansions/pics/66914005.jpg

94.2 KB | W: | H:

expansions/pics/66914005.jpg
expansions/pics/66914005.jpg
expansions/pics/66914005.jpg
expansions/pics/66914005.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/66914009.jpg

64.9 KB | W: | H:

expansions/pics/66914009.jpg

91.8 KB | W: | H:

expansions/pics/66914009.jpg
expansions/pics/66914009.jpg
expansions/pics/66914009.jpg
expansions/pics/66914009.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/67210104.jpg

11.9 KB | W: | H:

expansions/pics/67210104.jpg

15.2 KB | W: | H:

expansions/pics/67210104.jpg
expansions/pics/67210104.jpg
expansions/pics/67210104.jpg
expansions/pics/67210104.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/67210106.jpg

14.4 KB | W: | H:

expansions/pics/67210106.jpg

18.4 KB | W: | H:

expansions/pics/67210106.jpg
expansions/pics/67210106.jpg
expansions/pics/67210106.jpg
expansions/pics/67210106.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/67210108.jpg

13.9 KB | W: | H:

expansions/pics/67210108.jpg

17.8 KB | W: | H:

expansions/pics/67210108.jpg
expansions/pics/67210108.jpg
expansions/pics/67210108.jpg
expansions/pics/67210108.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/81026000.jpg

171 KB | W: | H:

expansions/pics/81026000.jpg

88.4 KB | W: | H:

expansions/pics/81026000.jpg
expansions/pics/81026000.jpg
expansions/pics/81026000.jpg
expansions/pics/81026000.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/81026001.jpg

158 KB | W: | H:

expansions/pics/81026001.jpg

75 KB | W: | H:

expansions/pics/81026001.jpg
expansions/pics/81026001.jpg
expansions/pics/81026001.jpg
expansions/pics/81026001.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/81026002.jpg

151 KB | W: | H:

expansions/pics/81026002.jpg

76.3 KB | W: | H:

expansions/pics/81026002.jpg
expansions/pics/81026002.jpg
expansions/pics/81026002.jpg
expansions/pics/81026002.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/81026003.jpg

144 KB | W: | H:

expansions/pics/81026003.jpg

79.1 KB | W: | H:

expansions/pics/81026003.jpg
expansions/pics/81026003.jpg
expansions/pics/81026003.jpg
expansions/pics/81026003.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/81026004.jpg

52.5 KB | W: | H:

expansions/pics/81026004.jpg

80.2 KB | W: | H:

expansions/pics/81026004.jpg
expansions/pics/81026004.jpg
expansions/pics/81026004.jpg
expansions/pics/81026004.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/81026005.jpg

141 KB | W: | H:

expansions/pics/81026005.jpg

74.9 KB | W: | H:

expansions/pics/81026005.jpg
expansions/pics/81026005.jpg
expansions/pics/81026005.jpg
expansions/pics/81026005.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/81026006.jpg

124 KB | W: | H:

expansions/pics/81026006.jpg

79.3 KB | W: | H:

expansions/pics/81026006.jpg
expansions/pics/81026006.jpg
expansions/pics/81026006.jpg
expansions/pics/81026006.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/81026070.jpg

152 KB | W: | H:

expansions/pics/81026070.jpg

72.8 KB | W: | H:

expansions/pics/81026070.jpg
expansions/pics/81026070.jpg
expansions/pics/81026070.jpg
expansions/pics/81026070.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/81026071.jpg

62.2 KB | W: | H:

expansions/pics/81026071.jpg

77.4 KB | W: | H:

expansions/pics/81026071.jpg
expansions/pics/81026071.jpg
expansions/pics/81026071.jpg
expansions/pics/81026071.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/81026072.jpg

62.7 KB | W: | H:

expansions/pics/81026072.jpg

66.5 KB | W: | H:

expansions/pics/81026072.jpg
expansions/pics/81026072.jpg
expansions/pics/81026072.jpg
expansions/pics/81026072.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/81041046.jpg

71.4 KB | W: | H:

expansions/pics/81041046.jpg

94 KB | W: | H:

expansions/pics/81041046.jpg
expansions/pics/81041046.jpg
expansions/pics/81041046.jpg
expansions/pics/81041046.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/81046021.jpg

115 KB | W: | H:

expansions/pics/81046021.jpg

84.6 KB | W: | H:

expansions/pics/81046021.jpg
expansions/pics/81046021.jpg
expansions/pics/81046021.jpg
expansions/pics/81046021.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/81046024.jpg

122 KB | W: | H:

expansions/pics/81046024.jpg

89.3 KB | W: | H:

expansions/pics/81046024.jpg
expansions/pics/81046024.jpg
expansions/pics/81046024.jpg
expansions/pics/81046024.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/96001060.jpg

11.9 KB | W: | H:

expansions/pics/96001060.jpg

19.5 KB | W: | H:

expansions/pics/96001060.jpg
expansions/pics/96001060.jpg
expansions/pics/96001060.jpg
expansions/pics/96001060.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/96001061.jpg

14.1 KB | W: | H:

expansions/pics/96001061.jpg

23.3 KB | W: | H:

expansions/pics/96001061.jpg
expansions/pics/96001061.jpg
expansions/pics/96001061.jpg
expansions/pics/96001061.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/96001062.jpg

13.6 KB | W: | H:

expansions/pics/96001062.jpg

22.2 KB | W: | H:

expansions/pics/96001062.jpg
expansions/pics/96001062.jpg
expansions/pics/96001062.jpg
expansions/pics/96001062.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/96001063.jpg

13 KB | W: | H:

expansions/pics/96001063.jpg

21.7 KB | W: | H:

expansions/pics/96001063.jpg
expansions/pics/96001063.jpg
expansions/pics/96001063.jpg
expansions/pics/96001063.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/96001064.jpg

12.2 KB | W: | H:

expansions/pics/96001064.jpg

20.5 KB | W: | H:

expansions/pics/96001064.jpg
expansions/pics/96001064.jpg
expansions/pics/96001064.jpg
expansions/pics/96001064.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/96001065.jpg

11.9 KB | W: | H:

expansions/pics/96001065.jpg

19.9 KB | W: | H:

expansions/pics/96001065.jpg
expansions/pics/96001065.jpg
expansions/pics/96001065.jpg
expansions/pics/96001065.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/96001066.jpg

14 KB | W: | H:

expansions/pics/96001066.jpg

23.5 KB | W: | H:

expansions/pics/96001066.jpg
expansions/pics/96001066.jpg
expansions/pics/96001066.jpg
expansions/pics/96001066.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/98609000.jpg

158 KB | W: | H:

expansions/pics/98609000.jpg

93 KB | W: | H:

expansions/pics/98609000.jpg
expansions/pics/98609000.jpg
expansions/pics/98609000.jpg
expansions/pics/98609000.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/98609001.jpg

163 KB | W: | H:

expansions/pics/98609001.jpg

86.6 KB | W: | H:

expansions/pics/98609001.jpg
expansions/pics/98609001.jpg
expansions/pics/98609001.jpg
expansions/pics/98609001.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/field/19000180.jpg

74.7 KB | W: | H:

expansions/pics/field/19000180.jpg

79.4 KB | W: | H:

expansions/pics/field/19000180.jpg
expansions/pics/field/19000180.jpg
expansions/pics/field/19000180.jpg
expansions/pics/field/19000180.jpg
  • 2-up
  • Swipe
  • Onion skin
...@@ -505,9 +505,6 @@ function future.lv4(c,m) ...@@ -505,9 +505,6 @@ function future.lv4(c,m)
e1:SetCondition(future.ntcon) e1:SetCondition(future.ntcon)
e1:SetOperation(future.ntop) e1:SetOperation(future.ntop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_SET_PROC)
c:RegisterEffect(e2)
end end
function future.ntcon(e,c,minc) function future.ntcon(e,c,minc)
if c==nil then return true end if c==nil then return true end
...@@ -550,70 +547,27 @@ function future.effect(c,m) ...@@ -550,70 +547,27 @@ function future.effect(c,m)
end) end)
return e1 return e1
end end
----------------------------------------------------异夕光物-------------------------------------------------- -----------------------------------------black order-------------------------------------------------
yixi={} bo=bo or {}
yixi.loaded_metatable_list={} function bo.base(c,m)
function yixi.load_metatable(code) c:EnableCounterPermit(0x50a)
local m1=_G["c"..code] --act limit
if m1 then return m1 end local e3=Effect.CreateEffect(c)
local m2=yixi.loaded_metatable_list[code] e3:SetType(EFFECT_TYPE_SINGLE)
if m2 then return m2 end e3:SetCode(EFFECT_CANNOT_TRIGGER)
_G["c"..code]={} e3:SetRange(LOCATION_MZONE)
if pcall(function() dofile("expansions/script/c"..code..".lua") end) or pcall(function() dofile("script/c"..code..".lua") end) then e3:SetCondition(bo.base_condition)
local mt=_G["c"..code] e3:SetValue(1)
_G["c"..code]=nil c:RegisterEffect(e3)
if mt then return e3
yixi.loaded_metatable_list[code]=mt
return mt
end
else
_G["c"..code]=nil
end
end
--SpecialSummon self
function yixi.spself(c,m,count)
--cannot special summon
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION)
c:RegisterEffect(e1)
--special summon
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_SPSUMMON_PROC)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e2:SetRange(LOCATION_HAND)
e2:SetLabel(count)
e2:SetCondition(yixi.spcon)
e2:SetOperation(yixi.spop)
c:RegisterEffect(e2)
return e1,e2
end
function yixi.spfilter(c)
return c:IsSetCard(0xa01) and c:IsType(TYPE_MONSTER) and c:IsReleasable() and not c:IsCode(51300051)
end
function yixi.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
local ct=e:GetLabel()
return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(yixi.spfilter,tp,LOCATION_HAND,0,ct,c)
end end
function yixi.spop(e,tp,eg,ep,ev,re,r,rp,c) function bo.base_condition(e,tp,eg,ep,ev,re,r,rp)
local ct=e:GetLabel() return e:GetHandler():GetCounter(0x50a)>0
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local g=Duel.SelectMatchingCard(tp,yixi.spfilter,tp,LOCATION_HAND,0,ct,ct,c)
Duel.Release(g,REASON_COST)
end end
--when Release function bo.base_cost(e,tp,eg,ep,ev,re,r,rp,chk)
function yixi.released(c,m) local c=e:GetHandler()
--cannot special summon if chk==0 then return c:IsCanAddCounter(0x50a,1) end
local e1=Effect.CreateEffect(c) c:AddCounter(0x50a,1)
e1:SetDescription(aux.Stringid(m,1))
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e1:SetCode(EVENT_RELEASE)
return e1
end end
------------------------------------------------------伴生双子------------------------------------------ ------------------------------------------------------伴生双子------------------------------------------
twins=twins or {} twins=twins or {}
......
...@@ -2,132 +2,132 @@ ...@@ -2,132 +2,132 @@
local m=10710001 local m=10710001
local cm=_G["c"..m] local cm=_G["c"..m]
function cm.initial_effect(c) function cm.initial_effect(c)
--ntr --summon self
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0)) e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_SPECIAL_SUMMON)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_DISABLE)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetRange(LOCATION_HAND)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET)
e1:SetRange(LOCATION_HAND)
e1:SetCountLimit(1,m) e1:SetCountLimit(1,m)
e1:SetCondition(cm.ntrcon) e1:SetCost(cm.spcost)
e1:SetCost(cm.ntrcost) e1:SetTarget(cm.sptg)
e1:SetTarget(cm.ntrtg) e1:SetOperation(cm.spop)
e1:SetOperation(cm.ntrop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--lv --to hand
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,1)) e2:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_SPSUMMON_SUCCESS) e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetCountLimit(1,m+1) e2:SetCountLimit(1,m+1)
e2:SetTarget(cm.lvtg) e2:SetTarget(cm.thtg)
e2:SetOperation(cm.lvop) e2:SetOperation(cm.thop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end --draw and Recover
--ntr local e3=Effect.CreateEffect(c)
function cm.cfilter(c,tp) e3:SetDescription(aux.Stringid(m,1))
return c:IsSummonPlayer(1-tp) e3:SetCategory(CATEGORY_DRAW+CATEGORY_RECOVER)
end e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
function cm.ntrcon(e,tp,eg,ep,ev,re,r,rp) e3:SetCode(EVENT_CHAINING)
return eg:IsExists(cm.cfilter,1,nil,tp) e3:SetRange(LOCATION_GRAVE)
end e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_DELAY)
function cm.ntrcost(e,tp,eg,ep,ev,re,r,rp,chk) e3:SetCost(aux.bfgcost)
e3:SetCondition(cm.drcon)
e3:SetTarget(cm.drtg)
e3:SetOperation(cm.drop)
c:RegisterEffect(e3)
end
--tohand or SpecialSummon
function cm.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return c:IsDiscardable() end if chk==0 then return c:IsDiscardable() end
Duel.SendtoGrave(c,REASON_COST+REASON_DISCARD) Duel.SendtoGrave(c,REASON_COST+REASON_DISCARD)
end end
function cm.nfilter(c) function cm.cfilter(c,tp)
return c:IsSummonType(SUMMON_TYPE_SPECIAL) return c:IsControler(tp) and c:IsLocation(LOCATION_MZONE) and c:IsSummonType(SUMMON_TYPE_SPECIAL)
end end
function cm.ntrtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and cm.nfilter(chkc) end if chkc then return eg:IsContains(chkc) and cm.cfilter(chkc,1-tp) end
if chk==0 then return Duel.IsExistingTarget(cm.nfilter,tp,0,LOCATION_MZONE,1,nil) end if chk==0 then return e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false)
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and eg:IsExists(cm.cfilter,1,nil,1-tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_OPERATECARD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_OPERATECARD)
Duel.SelectTarget(tp,cm.nfilter,tp,0,LOCATION_MZONE,1,1,nil) local g=eg:FilterSelect(tp,cm.cfilter,1,1,nil,1-tp)
Duel.SetTargetCard(g)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,2,tp,LOCATION_DECK)
end end
function cm.spfilter(c,e,tp,code) function cm.thcfilter(c,code,tp)
return c:IsCode(code) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP,1-tp) return c:IsAbleToHand(tp) and c:IsCode(code)
end end
function cm.ntrop(e,tp,eg,ep,ev,re,r,rp) function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
local code=tc:GetCode()
if tc:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) then
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(cm.spfilter,1-tp,LOCATION_EXTRA+LOCATION_DECK,0,1,nil,e,1-tp,code) then Duel.Hint(HINT_SELECTMSG,1-tp,HINTMSG_ATOHAND)
Duel.Hint(HINT_SELECTMSG,1-tp,HINTMSG_SPSUMMON) local g=Duel.SelectMatchingCard(1-tp,cm.thcfilter,1-tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_DECK,0,2,2,nil,tc:GetCode(),tp)
local g=Duel.SelectMatchingCard(1-tp,cm.spfilter,1-tp,LOCATION_EXTRA+LOCATION_DECK,0,1,1,nil,e,1-tp,code) if Duel.SendtoHand(g,tp,REASON_EFFECT)==0 and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) then
Duel.SpecialSummon(g,0,1-tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(e:GetHandler(),0,tp,tp,false,false,POS_FACEUP)
else
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_DISABLE)
e1:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e1:SetTarget(cm.distg)
e1:SetLabelObject(tc)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_SOLVING)
e2:SetCondition(cm.discon)
e2:SetOperation(cm.disop)
e2:SetLabelObject(tc)
e2:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e2,tp)
end end
end end
end end
function cm.distg(e,c) --to hand
local tc=e:GetLabelObject() function cm.thfilter(c,tp)
return c:IsOriginalCodeRule(tc:GetOriginalCodeRule()) and (c:IsType(TYPE_EFFECT) or c:GetOriginalType()&TYPE_EFFECT~=0) return c:IsAbleToHand(1-tp) and Duel.IsExistingMatchingCard(cm.thfilter2,tp,LOCATION_DECK,0,1,c,1-tp,c:GetCode())
end end
function cm.discon(e,tp,eg,ep,ev,re,r,rp) function cm.thfilter2(c,tp,code)
local tc=e:GetLabelObject() return c:IsAbleToHand(tp) and c:IsCode(code)
return re:IsActiveType(TYPE_MONSTER) and re:GetHandler():IsOriginalCodeRule(tc:GetOriginalCodeRule()) end
end function cm.ntrfilter(c)
function cm.disop(e,tp,eg,ep,ev,re,r,rp) return c:IsFaceup() and c:IsControlerCanBeChanged()
Duel.NegateEffect(ev) end
end function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
--lv if chk==0 then return Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_DECK,0,1,nil,tp)
function cm.filter(c) and Duel.IsExistingMatchingCard(cm.ntrfilter,tp,0,LOCATION_MZONE,1,nil) end
return c:IsFaceup() and c:GetLevel()>0 and c:IsRace(RACE_FAIRY) and c:IsType(TYPE_TUNER) Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,2,tp,LOCATION_DECK)
end Duel.SetOperationInfo(0,CATEGORY_CONTROL,nil,1,0,LOCATION_MZONE)
function cm.lvtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) end
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and cm.filter(chkc) end function cm.thop(e,tp,eg,ep,ev,re,r,rp)
if chk==0 then return Duel.IsExistingTarget(cm.filter,tp,LOCATION_MZONE,0,1,e:GetHandler()) end Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) if not Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_DECK,0,1,nil,tp) then return end
Duel.SelectTarget(tp,cm.filter,tp,LOCATION_MZONE,0,1,1,e:GetHandler()) local g=Duel.SelectMatchingCard(tp,cm.thfilter,tp,LOCATION_DECK,0,1,1,nil,tp)
end g:AddCard(Duel.GetFirstMatchingCard(cm.thfilter2,tp,LOCATION_DECK,0,nil,1-tp,g:GetFirst():GetCode()))
function cm.lvop(e,tp,eg,ep,ev,re,r,rp) if g:GetCount()>0 then
local c=e:GetHandler() Duel.SendtoHand(g,1-tp,REASON_EFFECT)
local tc=Duel.GetFirstTarget() local tc=g:GetFirst()
if c:IsRelateToEffect(e) and c:IsFaceup() and tc:IsRelateToEffect(e) and tc:IsFaceup() then while tc do
local lv=tc:GetLevel() local e1=Effect.CreateEffect(e:GetHandler())
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CHANGE_LEVEL) e1:SetCode(EFFECT_PUBLIC)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
e1:SetValue(lv) tc:RegisterEffect(e1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) tc=g:GetNext()
c:RegisterEffect(e1) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CONTROL)
local ntc=Duel.SelectMatchingCard(tp,cm.ntrfilter,tp,0,LOCATION_MZONE,1,1,nil):GetFirst()
Duel.GetControl(ntc,tp)
--cannot attack, trigger
local e4=Effect.CreateEffect(e:GetHandler())
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetCode(EFFECT_CANNOT_TRIGGER)
e4:SetRange(LOCATION_MZONE)
e4:SetReset(RESET_EVENT+RESETS_STANDARD)
ntc:RegisterEffect(e4)
end end
end end
--grave --Recover
function cm.tgfilter(c) function cm.drcon(e,tp,eg,ep,ev,re,r,rp)
return c:IsFaceup() and c:IsRace(RACE_FAIRY) and c:IsType(TYPE_TUNER) return re:GetHandler():GetOwner()==1-tp and re:GetActivateLocation(LOCATION_ONFIELD)
end
function cm.tgcon(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(cm.tgfilter,tp,LOCATION_MZONE,0,1,e:GetHandler())
end end
function cm.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,e:GetHandler(),1,0,0) Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(1)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,Duel.GetLP(tp)/2)
end end
function cm.tgop(e,tp,eg,ep,ev,re,r,rp) function cm.drop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
if c:IsRelateToEffect(e) then Duel.Draw(p,d,REASON_EFFECT)
Duel.SendtoGrave(c,REASON_EFFECT) Duel.Recover(tp,Duel.GetLP(tp)/2,REASON_EFFECT)
end
end end
--秋夜少女·本田未央 --
local m=10983003 local m=10983003
local cm=_G["c"..m] local cm=_G["c"..m]
function cm.initial_effect(c) function cm.initial_effect(c)
--special summon --spsummon
local e0=Effect.CreateEffect(c)
e0:SetCategory(CATEGORY_SPECIAL_SUMMON)
e0:SetType(EFFECT_TYPE_IGNITION)
e0:SetRange(LOCATION_HAND)
e0:SetCountLimit(1,m)
e0:SetCondition(cm.spcon)
e0:SetTarget(cm.sptg)
e0:SetOperation(cm.spop)
c:RegisterEffect(e0)
--atkup
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetType(EFFECT_TYPE_IGNITION) e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_HAND) e1:SetRange(LOCATION_MZONE)
e1:SetCost(cm.spcost) e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetTarget(cm.sptg) e1:SetValue(cm.value)
e1:SetOperation(cm.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--indes --
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE) e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE) e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
...@@ -28,57 +37,30 @@ function cm.initial_effect(c) ...@@ -28,57 +37,30 @@ function cm.initial_effect(c)
e4:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN) e4:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN)
e4:SetType(EFFECT_TYPE_IGNITION) e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetRange(LOCATION_MZONE) e4:SetRange(LOCATION_MZONE)
e4:SetCountLimit(1,m) e4:SetCountLimit(1,m+900)
e4:SetCost(cm.spcost2) e4:SetCost(cm.spcost2)
e4:SetTarget(cm.sptg2) e4:SetTarget(cm.sptg2)
e4:SetOperation(cm.spop2) e4:SetOperation(cm.spop2)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function cm.fselect(c,tp,rg,sg) function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
sg:AddCard(c) return Duel.IsExistingMatchingCard(Card.IsType,tp,LOCATION_MZONE,0,1,nil,TYPE_TOKEN)
local res=cm.fgoal(tp,sg) or rg:IsExists(cm.fselect,1,sg,tp,rg,sg)
sg:RemoveCard(c)
return res
end
function cm.relfilter(c,g)
return g:IsContains(c)
end
function cm.fgoal(tp,sg)
if sg:GetCount()>0 and Duel.GetMZoneCount(tp,sg)>0 then
Duel.SetSelectedCard(sg)
return Duel.CheckReleaseGroup(tp,nil,0,nil)
else return false end
end
function cm.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
local rg=Duel.GetReleaseGroup(tp):Filter(Card.IsType,nil,TYPE_TOKEN)
local g=Group.CreateGroup()
if chk==0 then return rg:IsExists(cm.fselect,1,nil,tp,rg,g) end
while true do
local mg=rg:Filter(cm.fselect,g,tp,rg,g)
if mg:GetCount()==0 or (cm.fgoal(tp,g) and not Duel.SelectYesNo(tp,210)) then break end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local sg=Duel.SelectReleaseGroup(tp,cm.relfilter,1,1,nil,mg)
g:Merge(sg)
end
e:SetLabel(g:GetCount())
Duel.Release(g,REASON_COST)
end end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function cm.spop(e,tp,eg,ep,ev,re,r,rp) function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if c:IsRelateToEffect(e) and Duel.SpecialSummonStep(c,0,tp,tp,false,false,POS_FACEUP) then if not c:IsRelateToEffect(e) then return end
local ct=e:GetLabel() Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
local e1=Effect.CreateEffect(c) end
e1:SetType(EFFECT_TYPE_SINGLE) function cm.filter(c)
e1:SetCode(EFFECT_UPDATE_ATTACK) return c:IsType(TYPE_TOKEN)
e1:SetValue(ct*800) end
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE) function cm.value(e,c)
c:RegisterEffect(e1) return Duel.GetMatchingGroupCount(cm.filter,0,LOCATION_MZONE,LOCATION_MZONE,nil)*800
Duel.SpecialSummonComplete()
end
end end
function cm.indcon(e) function cm.indcon(e)
return Duel.IsExistingMatchingCard(Card.IsType,e:GetHandlerPlayer(),LOCATION_MZONE,0,1,nil,TYPE_TOKEN) return Duel.IsExistingMatchingCard(Card.IsType,e:GetHandlerPlayer(),LOCATION_MZONE,0,1,nil,TYPE_TOKEN)
......
--约定兑现·本田未央 --月白五十铃·兔女郎
local m=10983004 local m=10983004
local cm=_G["c"..m] local cm=_G["c"..m]
function cm.initial_effect(c) function cm.initial_effect(c)
--special summon --link summon
local e0=Effect.CreateEffect(c) aux.AddLinkProcedure(c,nil,3,3,cm.lcheck)
e0:SetCategory(CATEGORY_SPECIAL_SUMMON) c:EnableReviveLimit()
e0:SetType(EFFECT_TYPE_IGNITION)
e0:SetRange(LOCATION_HAND)
e0:SetCountLimit(1,m)
e0:SetCondition(cm.spcon)
e0:SetTarget(cm.sptg)
e0:SetOperation(cm.spop)
c:RegisterEffect(e0)
--atkup --atkup
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
...@@ -32,41 +25,64 @@ function cm.initial_effect(c) ...@@ -32,41 +25,64 @@ function cm.initial_effect(c)
local e3=e2:Clone() local e3=e2:Clone()
e3:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) e3:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--token
local e4=Effect.CreateEffect(c)
e4:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN)
e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetProperty(EFFECT_FLAG_BOTH_SIDE)
e4:SetRange(LOCATION_MZONE)
e4:SetCost(cm.spcost)
e4:SetTarget(cm.sptg)
e4:SetOperation(cm.spop)
c:RegisterEffect(e4)
end
function cm.lcheck(g,lc)
return g:IsExists(Card.IsLinkType,1,nil,TYPE_TOKEN)
end end
function cm.filter(c) function cm.filter(c)
return c:IsType(TYPE_TOKEN) return c:IsType(TYPE_TOKEN)
end end
function cm.value(e,c) function cm.value(e,c)
return Duel.GetMatchingGroupCount(cm.filter,0,LOCATION_MZONE,LOCATION_MZONE,nil)*800 return Duel.GetMatchingGroupCount(cm.filter,0,LOCATION_MZONE,LOCATION_MZONE,nil)*1000
end end
function cm.indcon(e) function cm.indcon(e)
return Duel.IsExistingMatchingCard(Card.IsType,e:GetHandlerPlayer(),LOCATION_MZONE,0,1,nil,TYPE_TOKEN) return Duel.IsExistingMatchingCard(Card.IsType,e:GetHandlerPlayer(),LOCATION_MZONE,0,1,nil,TYPE_TOKEN)
end end
function cm.cfilter(c) function cm.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
return c:IsFaceup() and c:IsType(TYPE_TOKEN) if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,nil) end
end Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD)
function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_MZONE,0,1,nil)
end end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return not Duel.IsPlayerAffectedByEffect(tp,59822133) if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.GetLocationCount(1-tp,LOCATION_MZONE)>0
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false)
and Duel.IsPlayerCanSpecialSummonMonster(tp,10983099,0,0x4011,1500,1500,5,RACE_FIEND,ATTRIBUTE_FIRE) end and Duel.IsPlayerCanSpecialSummonMonster(tp,10983099,0,0x4011,1500,1500,5,RACE_FIEND,ATTRIBUTE_FIRE) end
Duel.SetOperationInfo(0,CATEGORY_TOKEN,nil,1,0,0) Duel.SetOperationInfo(0,CATEGORY_TOKEN,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,2,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
end end
function cm.spop(e,tp,eg,ep,ev,re,r,rp) function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local e1=Effect.CreateEffect(e:GetHandler())
if not Duel.IsPlayerAffectedByEffect(tp,59822133) and c:IsRelateToEffect(e) then e1:SetType(EFFECT_TYPE_FIELD)
if Duel.SpecialSummonStep(c,0,tp,tp,false,false,POS_FACEUP) then e1:SetCode(EFFECT_CANNOT_BE_FUSION_MATERIAL)
if Duel.GetLocationCount(1-tp,LOCATION_MZONE,tp)>0 e1:SetTargetRange(0xff,0xff)
and Duel.IsPlayerCanSpecialSummonMonster(tp,10983099,0,0x4011,1500,1500,5,RACE_FIEND,ATTRIBUTE_FIRE) then e1:SetTarget(aux.NOT(aux.TargetBoolFunction(Card.IsType,TYPE_TOKEN)))
local token=Duel.CreateToken(tp,10983099) e1:SetValue(cm.sumlimit)
Duel.SpecialSummonStep(token,0,tp,1-tp,false,false,POS_FACEUP) e1:SetReset(RESET_PHASE+PHASE_END)
end Duel.RegisterEffect(e1,tp)
end local e2=e1:Clone()
Duel.SpecialSummonComplete() e2:SetCode(EFFECT_CANNOT_BE_SYNCHRO_MATERIAL)
Duel.RegisterEffect(e2,tp)
local e3=e1:Clone()
e3:SetCode(EFFECT_CANNOT_BE_XYZ_MATERIAL)
Duel.RegisterEffect(e3,tp)
local e4=e1:Clone()
e4:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
Duel.RegisterEffect(e4,tp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
if Duel.IsPlayerCanSpecialSummonMonster(tp,10983099,0,0x4011,1500,1500,5,RACE_FIEND,ATTRIBUTE_FIRE) then
local token=Duel.CreateToken(tp,10983999)
Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP)
end end
end end
function cm.sumlimit(e,c)
if not c then return false end
return c:IsControler(e:GetHandlerPlayer())
end
--积雨云·椎名咪玉 --不言之中·椎名咪玉
local m=14175006 local m=14175006
local cm=_G["c"..m] local cm=_G["c"..m]
function cm.initial_effect(c) function cm.initial_effect(c)
--link summon --summon success
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkAttribute,ATTRIBUTE_WATER),2)
c:EnableReviveLimit()
--add counter
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0)) e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_COUNTER) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_QUICK_O) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetRange(LOCATION_MZONE) e1:SetTarget(cm.sumtg)
e1:SetCountLimit(1,m) e1:SetOperation(cm.sumop)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE)
e1:SetCost(cm.ctcost)
e1:SetTarget(cm.cttg)
e1:SetOperation(cm.ctop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--to hand --search
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(94243005,1)) e3:SetDescription(aux.Stringid(m,1))
e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) e3:SetCategory(CATEGORY_DRAW+CATEGORY_TODECK)
e3:SetType(EFFECT_TYPE_IGNITION) e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e3:SetCountLimit(1,m+900) e3:SetCode(EVENT_SPSUMMON_SUCCESS)
e3:SetProperty(EFFECT_FLAG_DELAY)
e3:SetRange(LOCATION_MZONE) e3:SetRange(LOCATION_MZONE)
e3:SetTarget(cm.thtg) e3:SetCountLimit(1,m)
e3:SetOperation(cm.thop) e3:SetCondition(cm.drcon)
e3:SetTarget(cm.drtg)
e3:SetOperation(cm.drop)
c:RegisterEffect(e3) c:RegisterEffect(e3)
end end
function cm.costfilter(c) function cm.filter(c,e,tp)
return c:IsType(TYPE_MONSTER) and c:IsAttribute(ATTRIBUTE_WATER) and c:IsLevelAbove(1) and c:IsDiscardable() return c:IsLevel(4) and c:IsAttribute(ATTRIBUTE_LIGHT) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function cm.ctcost(e,tp,eg,ep,ev,re,r,rp,chk) function cm.sumtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.costfilter,tp,LOCATION_HAND,0,1,nil) end if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD) and Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_HAND,0,1,nil,e,tp) end
local g=Duel.SelectMatchingCard(tp,cm.costfilter,tp,LOCATION_HAND,0,1,1,nil) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND)
e:SetLabel(g:GetFirst():GetOriginalLevel())
Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD)
end end
function cm.cttg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.sumop(e,tp,eg,ep,ev,re,r,rp)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsCanAddCounter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil,0x1015,1) end if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.SetOperationInfo(0,CATEGORY_COUNTER,nil,e:GetLabel(),0,0x1015) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
end local g=Duel.SelectMatchingCard(tp,cm.filter,tp,LOCATION_HAND,0,1,1,nil,e,tp)
function cm.ctop(e,tp,eg,ep,ev,re,r,rp)
local ct=e:GetLabel()
local g=Duel.GetMatchingGroup(Card.IsCanAddCounter,tp,LOCATION_MZONE,LOCATION_MZONE,nil,0x1015,1)
if g:GetCount()==0 then return end
for i=1,ct do
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_COUNTER)
local sg=g:Select(tp,1,1,nil)
sg:GetFirst():AddCounter(0x1015,1)
end
end
function cm.thfilter1(c,tp)
local lv=c:GetLevel()
return (c:IsLocation(LOCATION_DECK) or (c:IsFaceup() and c:IsType(TYPE_PENDULUM))) and lv>0 and c:IsAttribute(ATTRIBUTE_WATER)
and Duel.IsCanRemoveCounter(tp,1,1,0x1015,lv,REASON_COST) and c:IsAbleToHand()
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.thfilter1,tp,LOCATION_DECK+LOCATION_EXTRA,0,1,nil,tp) end
local g=Duel.GetMatchingGroup(cm.thfilter1,tp,LOCATION_DECK+LOCATION_EXTRA,0,nil,tp)
local lvt={}
local tc=g:GetFirst()
while tc do
local tlv=tc:GetLevel()
lvt[tlv]=tlv
tc=g:GetNext()
end
local pc=1
for i=1,12 do
if lvt[i] then lvt[i]=nil lvt[pc]=i pc=pc+1 end
end
lvt[pc]=nil
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(m,1))
local lv=Duel.AnnounceNumber(tp,table.unpack(lvt))
Duel.RemoveCounter(tp,1,1,0x1015,lv,REASON_COST)
e:SetLabel(lv)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK+LOCATION_EXTRA)
end
function cm.thfilter2(c,lv)
return (c:IsLocation(LOCATION_DECK) or (c:IsFaceup() and c:IsType(TYPE_PENDULUM))) and c:IsAttribute(ATTRIBUTE_WATER)
and c:IsLevel(lv) and c:IsAbleToHand()
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local lv=e:GetLabel()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.thfilter2,tp,LOCATION_DECK+LOCATION_EXTRA,0,1,1,nil,lv)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT) Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
Duel.ConfirmCards(1-tp,g)
end end
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SUMMON) e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetTargetRange(1,0) e1:SetTargetRange(1,0)
e1:SetTarget(cm.splimit) e1:SetTarget(cm.splimit)
e1:SetReset(RESET_PHASE+PHASE_END) e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
local e2=e1:Clone()
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
Duel.RegisterEffect(e2,tp)
end end
function cm.splimit(e,c) function cm.splimit(e,c,tp,sumtp,sumpos)
return not c:IsAttribute(ATTRIBUTE_WATER) return c:GetAttribute()~=ATTRIBUTE_LIGHT
end
function cm.cfilter(c,tp)
return c:IsPreviousLocation(LOCATION_HAND) and c:GetPreviousControler()==tp
end
function cm.drcon(e,tp,eg,ep,ev,re,r,rp)
return not eg:IsContains(e:GetHandler()) and eg:IsExists(cm.cfilter,1,nil,tp)
end
function cm.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(1)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,0,tp,1)
end
function cm.drop(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
if Duel.Draw(p,d,REASON_EFFECT)==0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,Card.IsAbleToDeck,tp,LOCATION_HAND,0,1,1,nil)
if g:GetCount()>0 then
Duel.BreakEffect()
Duel.SendtoDeck(g,nil,1,REASON_EFFECT)
end
end end
...@@ -44,6 +44,21 @@ local cate_table_for_reikai={ ...@@ -44,6 +44,21 @@ local cate_table_for_reikai={
['ct'] = CATEGORY_COUNTER, ['ct'] = CATEGORY_COUNTER,
['des'] = CATEGORY_DESTROY, ['des'] = CATEGORY_DESTROY,
} }
rk.List_A_Counter = {
1487805,
20985997,
21768554,
24104865,
38468214,
53291093,
57384901,
58012107,
59258334,
62315111,
84491298,
91070115,
99532708
}
function rk.set(code,setcode,rkflag,excode) function rk.set(code,setcode,rkflag,excode)
if not _G["c"..code] then _G["c"..code]={} if not _G["c"..code] then _G["c"..code]={}
setmetatable(_G["c"..code],Card) setmetatable(_G["c"..code],Card)
...@@ -86,6 +101,10 @@ function rk.set(code,setcode,rkflag,excode) ...@@ -86,6 +101,10 @@ function rk.set(code,setcode,rkflag,excode)
end end
return code,ccodem return code,ccodem
end end
function Card.IsListedACounter(c)
local code = c:GetOriginalCode()
return aux.IsCounterAdded(c,0x100e) or IsInTable(code,rk.List_A_Counter) or rk.check(c,"Acounter")
end
function rk.rkcardcheck(c) function rk.rkcardcheck(c)
return c.rkcheck==true return c.rkcheck==true
end end
......
...@@ -22,6 +22,7 @@ function c17032830.initial_effect(c) ...@@ -22,6 +22,7 @@ function c17032830.initial_effect(c)
e2:SetCode(EVENT_RECOVER) e2:SetCode(EVENT_RECOVER)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetProperty(EFFECT_FLAG_DELAY) e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCountLimit(1,17032830)
e2:SetTarget(c17032830.target) e2:SetTarget(c17032830.target)
e2:SetOperation(c17032830.activate) e2:SetOperation(c17032830.activate)
c:RegisterEffect(e2) c:RegisterEffect(e2)
......
--P.C. 可可罗 --P.C. 可可罗
local m=17035020 xpcall(function() require("expansions/script/c17035021") end,function() require("script/c17035021") end)
local cm=_G["c"..m] function c17035020.initial_effect(c)
function cm.initial_effect(c) pcr.Union_Burst(c,nil,pcr.kkrubtg,pcr.kkrubop,1123,Kokkoro)
--draw pcr.Gourmet_Edifice(c,17035020)
local e1=Effect.CreateEffect(c) pcr.Kokkoro(c)
e1:SetDescription(aux.Stringid(17035020,0))
e1:SetCategory(CATEGORY_DRAW)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetRange(LOCATION_HAND)
e1:SetCountLimit(1,17035020)
e1:SetCost(cm.drcost)
e1:SetTarget(cm.drtg)
e1:SetOperation(cm.drop)
c:RegisterEffect(e1)
--destroy and set
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(17035020,1))
e2:SetCategory(CATEGORY_RECOVER+CATEGORY_ATKCHANGE)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCondition(cm.rccon)
e2:SetTarget(cm.rctg)
e2:SetOperation(cm.rcop)
c:RegisterEffect(e2)
--tohand
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(17035020,2))
e3:SetCategory(CATEGORY_TOHAND)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_TO_GRAVE)
e3:SetCountLimit(1,17035021)
e3:SetCondition(cm.thcon)
e3:SetTarget(cm.thtg)
e3:SetOperation(cm.thop)
c:RegisterEffect(e3)
end
function cm.cfilter(c)
return c:IsSetCard(0x7f5) and c:IsDiscardable()
end
function cm.drcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsDiscardable()
and Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_HAND,0,1,e:GetHandler()) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
local g=Duel.SelectMatchingCard(tp,cm.cfilter,tp,LOCATION_HAND,0,1,1,e:GetHandler())
g:AddCard(e:GetHandler())
Duel.SendtoGrave(g,REASON_DISCARD+REASON_COST)
end
function cm.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,2) end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(2)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,2)
end
function cm.drop(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Draw(p,d,REASON_EFFECT)
end
function cm.rccon(e,tp,eg,ep,ev,re,r,rp)
return re and re:IsActiveType(TYPE_MONSTER) and re:GetHandler():IsCode(17035300)
end
function cm.rctg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(2000)
Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,2000)
end
function cm.rcop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Recover(p,d,REASON_EFFECT)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetValue(600)
Duel.RegisterEffect(e1,tp)
local e2=e1:Clone()
e2:SetCode(EFFECT_UPDATE_DEFENSE)
Duel.RegisterEffect(e2,tp)
end
function cm.thcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD)
end
function cm.thfilter(c)
return c:IsSetCard(0x7f5) and c:IsAbleToHand()
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and cm.thfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(cm.thfilter,tp,LOCATION_GRAVE,0,1,e:GetHandler()) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectTarget(tp,cm.thfilter,tp,LOCATION_GRAVE,0,1,1,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.SendtoHand(tc,nil,REASON_EFFECT)
end
end end
\ No newline at end of file
This diff is collapsed.
--P.C. 佩可莉姆/公主形态 --P.C. 佩可莉姆/公主形态
local m=17035210 xpcall(function() require("expansions/script/c17035021") end,function() require("script/c17035021") end)
local cm=_G["c"..m] function c17035210.initial_effect(c)
function cm.initial_effect(c) pcr.Princess_Mode(c)
aux.AddCodeList(c,17035310) pcr.atklimit(c)
--pendulum summon pcr.atkup(c,pcr.atkupval_link)
aux.EnablePendulumAttribute(c)
--Cannot special summon
local e0=Effect.CreateEffect(c)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
c:RegisterEffect(e0)
--extra attack
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_EXTRA_ATTACK)
e1:SetValue(1)
c:RegisterEffect(e1)
--actlimit
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EFFECT_CANNOT_ACTIVATE)
e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(0,1)
e2:SetValue(1)
e2:SetCondition(cm.actcon)
c:RegisterEffect(e2)
--recover
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_RECOVER)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e3:SetCode(EVENT_BATTLE_DESTROYING)
e3:SetCondition(aux.bdocon)
e3:SetTarget(cm.rctg)
e3:SetOperation(cm.rcop)
c:RegisterEffect(e3)
--tohand and destroy
local e4=Effect.CreateEffect(c)
e4:SetCategory(CATEGORY_TOHAND+CATEGORY_DESTROY)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e4:SetCode(EVENT_PHASE+PHASE_END)
e4:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e4:SetRange(LOCATION_MZONE)
e4:SetCountLimit(1)
e4:SetCondition(cm.descon)
e4:SetTarget(cm.destg)
e4:SetOperation(cm.desop)
c:RegisterEffect(e4)
--splimit
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_FIELD)
e5:SetRange(LOCATION_PZONE)
e5:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e5:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e5:SetTargetRange(1,0)
e5:SetCondition(cm.splimcon)
e5:SetTarget(cm.splimit)
c:RegisterEffect(e5)
--tohand
local e6=Effect.CreateEffect(c)
e6:SetDescription(aux.Stringid(17035210,0))
e6:SetCategory(CATEGORY_TODECK+CATEGORY_TOHAND+CATEGORY_SEARCH)
e6:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e6:SetRange(LOCATION_PZONE)
e6:SetCode(EVENT_SPSUMMON_SUCCESS)
e6:SetProperty(EFFECT_FLAG_DELAY)
e6:SetCondition(cm.thcon)
e6:SetTarget(cm.thtg)
e6:SetOperation(cm.thop)
c:RegisterEffect(e6)
end
cm.princess_name=17035320
function cm.actcon(e)
return Duel.GetAttacker()==e:GetHandler() or Duel.GetAttackTarget()==e:GetHandler()
end
function cm.rctg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
local c=e:GetHandler()
local bc=c:GetBattleTarget()
local dam=bc:GetAttack()
if dam<0 then dam=0 end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(dam)
Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,dam)
end
function cm.rcop(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Recover(p,d,REASON_EFFECT)
end
function cm.descon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()~=tp
end
function cm.destg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
local g=Duel.GetMatchingGroup(aux.TRUE,tp,0,LOCATION_ONFIELD,nil)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,e:GetHandler(),1,0,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
end
function cm.desop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local g=Duel.GetMatchingGroup(aux.TRUE,tp,0,LOCATION_ONFIELD,nil)
if c:IsRelateToEffect(e) and Duel.SendtoHand(c,nil,REASON_EFFECT)~=0 and #g>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local sg=g:Select(tp,1,2,nil)
Duel.Destroy(sg,REASON_EFFECT)
end
end
function cm.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function cm.splimit(e,c,tp,sumtp,sumpos)
return not c:IsSetCard(0x7f5) and bit.band(sumtp,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
function cm.cfilter(c,tp)
return c:IsControler(tp) and c:IsType(TYPE_LINK) and c:IsLinkAbove(3) and c:IsFaceup()
end
function cm.thcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(cm.cfilter,1,nil,tp)
end
function cm.thfilter(c)
return c:IsCode(17035320) and c:IsAbleToHand()
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToDeck() and 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)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and Duel.SendtoDeck(c,nil,2,REASON_EFFECT)~=0 then
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
end end
c17035210.princess_name=17035320
--P.C. ɿ/̬ --P.C. ɿ/̬
local m=17035220 xpcall(function() require("expansions/script/c17035021") end,function() require("script/c17035021") end)
local cm=_G["c"..m] function c17035220.initial_effect(c)
function cm.initial_effect(c) pcr.Princess_Mode(c)
aux.AddCodeList(c,17035200) pcr.atkupbuff(c)
--pendulum summon pcr.dissummon(c)
aux.EnablePendulumAttribute(c)
--Cannot special summon
local e0=Effect.CreateEffect(c)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
c:RegisterEffect(e0)
--atk up
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetTarget(cm.atktg)
e1:SetValue(500)
c:RegisterEffect(e1)
--indes
local e2=e1:Clone()
e2:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e2:SetValue(1)
c:RegisterEffect(e2)
--disable spsummon
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(17035220,0))
e3:SetCategory(CATEGORY_DISABLE_SUMMON+CATEGORY_DESTROY)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetRange(LOCATION_MZONE)
e3:SetCode(EVENT_SUMMON)
e3:SetCountLimit(1,17035220)
e3:SetCondition(cm.dscon)
e3:SetTarget(cm.dstg)
e3:SetOperation(cm.dsop)
c:RegisterEffect(e3)
local e4=e3:Clone()
e4:SetCode(EVENT_FLIP_SUMMON)
c:RegisterEffect(e4)
local e5=e3:Clone()
e5:SetCode(EVENT_SPSUMMON)
c:RegisterEffect(e5)
--tohand and draw
local e6=Effect.CreateEffect(c)
e6:SetCategory(CATEGORY_TOHAND+CATEGORY_DRAW)
e6:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e6:SetCode(EVENT_PHASE+PHASE_END)
e6:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e6:SetRange(LOCATION_MZONE)
e6:SetCountLimit(1)
e6:SetCondition(cm.drcon)
e6:SetTarget(cm.drtg)
e6:SetOperation(cm.drop)
c:RegisterEffect(e6)
--splimit
local e7=Effect.CreateEffect(c)
e7:SetType(EFFECT_TYPE_FIELD)
e7:SetRange(LOCATION_PZONE)
e7:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e7:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e7:SetTargetRange(1,0)
e7:SetCondition(cm.splimcon)
e7:SetTarget(cm.splimit)
c:RegisterEffect(e7)
--tohand
local e8=Effect.CreateEffect(c)
e8:SetDescription(aux.Stringid(17035220,1))
e8:SetCategory(CATEGORY_TODECK+CATEGORY_TOHAND+CATEGORY_SEARCH)
e8:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e8:SetRange(LOCATION_PZONE)
e8:SetCode(EVENT_SPSUMMON_SUCCESS)
e8:SetProperty(EFFECT_FLAG_DELAY)
e8:SetCondition(cm.thcon)
e8:SetTarget(cm.thtg)
e8:SetOperation(cm.thop)
c:RegisterEffect(e8)
end
cm.princess_name=17035020
function cm.atktg(e,c)
return c~=e:GetHandler()
end
function cm.dscon(e,tp,eg,ep,ev,re,r,rp)
return tp~=ep and Duel.GetCurrentChain()==0
end
function cm.dstg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_DISABLE_SUMMON,eg,eg:GetCount(),0,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,eg:GetCount(),0,0)
end
function cm.dsop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateSummon(eg)
Duel.Remove(eg,POS_FACEUP,REASON_EFFECT)
end
function cm.drcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()~=tp
end
function cm.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(1)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,e:GetHandler(),1,0,0)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
end
function cm.drop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
if c:IsRelateToEffect(e) and Duel.SendtoHand(c,nil,REASON_EFFECT)~=0 then
Duel.Draw(p,d,REASON_EFFECT)
end
end
function cm.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function cm.splimit(e,c,tp,sumtp,sumpos)
return not c:IsSetCard(0x7f5) and bit.band(sumtp,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
function cm.cfilter(c,tp)
return c:IsControler(tp) and c:IsType(TYPE_LINK) and c:IsLinkAbove(3) and c:IsFaceup()
end
function cm.thcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(cm.cfilter,1,nil,tp)
end
function cm.thfilter(c)
return c:IsCode(17035020) and c:IsAbleToHand()
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToDeck() and Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TODECK,e:GetHandler(),1,0,0)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and Duel.SendtoDeck(c,nil,2,REASON_EFFECT)~=0 then
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
end end
c17035220.princess_name=17035020
\ No newline at end of file
--公主模式 --公主模式
local m=17035310 xpcall(function() require("expansions/script/c17035021") end,function() require("script/c17035021") end)
local cm=_G["c"..m] function c17035310.initial_effect(c)
function cm.initial_effect(c) pcr.Princess_Mode_Magic(c)
aux.AddCodeList(c,m)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(17035310,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMING_END_PHASE)
e1:SetCost(cm.cost)
e1:SetTarget(cm.target)
e1:SetOperation(cm.activate)
c:RegisterEffect(e1)
--spsummon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(17035310,1))
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_GRAVE)
e2:SetCountLimit(1,17035310)
e2:SetCost(cm.thcost)
e2:SetTarget(cm.thtg)
e2:SetOperation(cm.thop)
c:RegisterEffect(e2)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
e:SetLabel(1)
return true
end
function cm.codefilter(c)
return c:IsCode(17035300) and c:IsFaceup()
end
function cm.filter1(c,e,tp)
local loc=LOCATION_HAND
if Duel.IsExistingMatchingCard(cm.codefilter,tp,LOCATION_ONFIELD,0,1,nil) then
loc=loc+LOCATION_DECK
end
return c:IsSetCard(0x7f5) and Duel.GetMZoneCount(tp,c)>0
and Duel.IsExistingMatchingCard(cm.filter2,tp,loc,0,1,nil,e,tp,c:GetCode())
end
function cm.filter2(c,e,tp,tcode)
return c:IsSetCard(0x97f5) and c.princess_name==tcode and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
if e:GetLabel()~=1 then return false end
e:SetLabel(0)
return Duel.CheckReleaseGroup(tp,cm.filter1,1,nil,e,tp)
end
local rg=Duel.SelectReleaseGroup(tp,cm.filter1,1,1,nil,e,tp)
e:SetLabel(rg:GetFirst():GetCode())
Duel.Release(rg,REASON_COST)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_DECK)
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
local loc=LOCATION_HAND
if Duel.IsExistingMatchingCard(cm.codefilter,tp,LOCATION_ONFIELD,0,1,nil) then
loc=loc+LOCATION_DECK
end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tc=Duel.SelectMatchingCard(tp,cm.filter2,tp,loc,0,1,1,nil,e,tp,e:GetLabel()):GetFirst()
if tc and Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP_ATTACK)>0 then
tc:CompleteProcedure()
end
end
function cm.cfilter2(c,tp)
return c:IsSetCard(0x97f5) and not c:IsPublic()
and Duel.IsExistingMatchingCard(cm.cfilter3,tp,LOCATION_DECK,0,1,nil,c:GetCode())
end
function cm.cfilter3(c,code)
return c:IsSetCard(0x97f5) and not c:IsCode(code) and c:IsAbleToHand()
end
function cm.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_HAND,0,1,nil)
and Duel.IsExistingMatchingCard(cm.cfilter2,tp,LOCATION_HAND,0,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CONFIRM)
local g=Duel.SelectMatchingCard(tp,cm.cfilter2,tp,LOCATION_HAND,0,1,1,nil,tp)
e:SetLabel(g:GetFirst():GetCode())
Duel.SetTargetCard(g:GetFirst())
Duel.ConfirmCards(1-tp,g)
Duel.ShuffleHand(tp)
end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,2,REASON_EFFECT)~=0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.cfilter3,tp,LOCATION_DECK,0,1,1,nil,e:GetLabel())
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
Duel.BreakEffect()
Duel.SendtoHand(e:GetHandler(),nil,REASON_EFFECT)
end
end end
\ No newline at end of file
--埃莉丝·科菲 --埃莉丝·科菲
local m=20066024 local m=20066024
local cm=_G["c"..m] local cm=_G["c"..m]
Duel.LoadScript("c81000000.lua")
function cm.initial_effect(c) function cm.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
......
--埃莉丝·科菲 蘑菇头 --埃莉丝·科菲 蘑菇头
local m=20066026 local m=20066026
local cm=_G["c"..m] local cm=_G["c"..m]
Duel.LoadScript("c81000000.lua")
function cm.initial_effect(c) function cm.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
...@@ -70,7 +69,7 @@ function cm.aclimit(e,re,tp) ...@@ -70,7 +69,7 @@ function cm.aclimit(e,re,tp)
return re:IsActiveType(TYPE_MONSTER) return re:IsActiveType(TYPE_MONSTER)
end end
function cm.cfilter(c) function cm.cfilter(c)
return c:IsFaceup() and c:IsType(TYPE_MONSTER) and not (c:IsType(TYPE_TOKEN) or c:IsType(TYPE_EFFECT)) return c:IsFaceup() and c:IsType(TYPE_MONSTER) and not c:IsType(TYPE_EFFECT)
end end
function cm.condition(e,tp,eg,ep,ev,re,r,rp) function cm.condition(e,tp,eg,ep,ev,re,r,rp)
if not Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_MZONE,0,1,nil) then return false end if not Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_MZONE,0,1,nil) then return false end
......
...@@ -71,7 +71,7 @@ function cm.aclimit(e,re,tp) ...@@ -71,7 +71,7 @@ function cm.aclimit(e,re,tp)
return re:IsActiveType(TYPE_MONSTER) return re:IsActiveType(TYPE_MONSTER)
end end
function cm.cfilter(c) function cm.cfilter(c)
return c:IsFaceup() and c:IsType(TYPE_MONSTER) and not (c:IsType(TYPE_TOKEN) or c:IsType(TYPE_EFFECT)) return c:IsFaceup() and c:IsType(TYPE_MONSTER) and not c:IsType(TYPE_EFFECT)
end end
function cm.condition(e,tp,eg,ep,ev,re,r,rp) function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_MZONE,0,1,nil) return Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_MZONE,0,1,nil)
......
...@@ -14,7 +14,6 @@ function c24865310.initial_effect(c) ...@@ -14,7 +14,6 @@ function c24865310.initial_effect(c)
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_GRAVE) e2:SetRange(LOCATION_GRAVE)
e2:SetOperation(c24865310.dtop) e2:SetOperation(c24865310.dtop)
e2:SetCost(c24865310.discost)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c24865310.thfilter(c) function c24865310.thfilter(c)
...@@ -36,14 +35,12 @@ function c24865310.thop(e,tp,eg,ep,ev,re,r,rp) ...@@ -36,14 +35,12 @@ function c24865310.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Destroy(c,REASON_EFFECT) Duel.Destroy(c,REASON_EFFECT)
end end
end end
function c24865310.discost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,nil) end
Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD)
end
function c24865310.dtop(e,tp,eg,ep,ev,re,r,rp) function c24865310.dtop(e,tp,eg,ep,ev,re,r,rp)
Duel.RegisterFlagEffect(tp,24865312,RESET_EVENT+RESET_PHASE+PHASE_END,0,1) Duel.RegisterFlagEffect(tp,24865312,RESET_EVENT+RESET_PHASE+PHASE_END,0,1)
if e:GetHandler():IsRelateToEffect(e) then if e:GetHandler():IsRelateToEffect(e) then
Duel.SendtoDeck(e:GetHandler(),nil,2,REASON_EFFECT) Duel.SendtoDeck(e:GetHandler(),nil,2,REASON_EFFECT)
Duel.Draw(tp,1,REASON_EFFECT)
end end
end end
function c24865310.atcd(e,tp,eg,ep,ev,re,r,rp) function c24865310.atcd(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -55,5 +55,6 @@ function c24865311.drop(e,tp,eg,ep,ev,re,r,rp) ...@@ -55,5 +55,6 @@ function c24865311.drop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,2,REASON_EFFECT)~=0 and tc:IsLocation(LOCATION_DECK) and c:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,2,REASON_EFFECT)~=0 and tc:IsLocation(LOCATION_DECK) and c:IsRelateToEffect(e) then
Duel.SendtoDeck(c,nil,0,REASON_EFFECT) Duel.SendtoDeck(c,nil,0,REASON_EFFECT)
Duel.Draw(tp,1,REASON_EFFECT)
end end
end end
\ No newline at end of file
...@@ -65,5 +65,6 @@ function cm.drop(e,tp,eg,ep,ev,re,r,rp) ...@@ -65,5 +65,6 @@ function cm.drop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,2,REASON_EFFECT)~=0 and tc:IsLocation(LOCATION_DECK) and c:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,2,REASON_EFFECT)~=0 and tc:IsLocation(LOCATION_DECK) and c:IsRelateToEffect(e) then
Duel.SendtoDeck(c,nil,0,REASON_EFFECT) Duel.SendtoDeck(c,nil,0,REASON_EFFECT)
Duel.Draw(tp,1,REASON_EFFECT)
end end
end end
\ No newline at end of file
...@@ -160,5 +160,6 @@ function c24865313.drop(e,tp,eg,ep,ev,re,r,rp) ...@@ -160,5 +160,6 @@ function c24865313.drop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,2,REASON_EFFECT)~=0 and tc:IsLocation(LOCATION_DECK) and c:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,2,REASON_EFFECT)~=0 and tc:IsLocation(LOCATION_DECK) and c:IsRelateToEffect(e) then
Duel.SendtoDeck(c,nil,0,REASON_EFFECT) Duel.SendtoDeck(c,nil,0,REASON_EFFECT)
Duel.Draw(tp,1,REASON_EFFECT)
end end
end end
\ No newline at end of file
...@@ -2,12 +2,6 @@ ...@@ -2,12 +2,6 @@
local m=24865314 local m=24865314
local cm=_G["c"..m] local cm=_G["c"..m]
function c24865314.initial_effect(c) function c24865314.initial_effect(c)
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e0:SetValue(1)
c:RegisterEffect(e0)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(24865314,0)) e1:SetDescription(aux.Stringid(24865314,0))
e1:SetType(EFFECT_TYPE_QUICK_O) e1:SetType(EFFECT_TYPE_QUICK_O)
......
...@@ -2,12 +2,7 @@ ...@@ -2,12 +2,7 @@
local m=24865315 local m=24865315
local cm=_G["c"..m] local cm=_G["c"..m]
function c24865315.initial_effect(c) function c24865315.initial_effect(c)
e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e0:SetValue(1)
c:RegisterEffect(e0)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(24865315,0)) e1:SetDescription(aux.Stringid(24865315,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN) e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN)
......
...@@ -2,12 +2,7 @@ ...@@ -2,12 +2,7 @@
local m=24865316 local m=24865316
local cm=_G["c"..m] local cm=_G["c"..m]
function c24865316.initial_effect(c) function c24865316.initial_effect(c)
e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e0:SetValue(1)
c:RegisterEffect(e0)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(24865316,0)) e1:SetDescription(aux.Stringid(24865316,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN) e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN)
......
...@@ -2,12 +2,7 @@ ...@@ -2,12 +2,7 @@
local m=24865317 local m=24865317
local cm=_G["c"..m] local cm=_G["c"..m]
function c24865317.initial_effect(c) function c24865317.initial_effect(c)
e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e0:SetValue(1)
c:RegisterEffect(e0)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(24865317,0)) e1:SetDescription(aux.Stringid(24865317,0))
e1:SetType(EFFECT_TYPE_QUICK_O) e1:SetType(EFFECT_TYPE_QUICK_O)
......
...@@ -2,12 +2,7 @@ ...@@ -2,12 +2,7 @@
local m=24865318 local m=24865318
local cm=_G["c"..m] local cm=_G["c"..m]
function c24865318.initial_effect(c) function c24865318.initial_effect(c)
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e0:SetValue(1)
c:RegisterEffect(e0)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(24865318,0)) e1:SetDescription(aux.Stringid(24865318,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN) e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN)
......
...@@ -2,12 +2,6 @@ ...@@ -2,12 +2,6 @@
local m=24865321 local m=24865321
local cm=_G["c"..m] local cm=_G["c"..m]
function c24865321.initial_effect(c) function c24865321.initial_effect(c)
e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e0:SetValue(1)
c:RegisterEffect(e0)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(24865321,0)) e1:SetDescription(aux.Stringid(24865321,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN) e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN)
......
...@@ -14,7 +14,7 @@ function c24865322.initial_effect(c) ...@@ -14,7 +14,7 @@ function c24865322.initial_effect(c)
e2:SetCategory(CATEGORY_TODECK) e2:SetCategory(CATEGORY_TODECK)
e2:SetRange(LOCATION_GRAVE) e2:SetRange(LOCATION_GRAVE)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET) e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCountLimit(1,24865323) e2:SetCountLimit(1,24865322)
e2:SetTarget(c24865322.drtg) e2:SetTarget(c24865322.drtg)
e2:SetOperation(c24865322.drop) e2:SetOperation(c24865322.drop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
...@@ -47,6 +47,7 @@ function c24865322.drop(e,tp,eg,ep,ev,re,r,rp) ...@@ -47,6 +47,7 @@ function c24865322.drop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,2,REASON_EFFECT)~=0 and tc:IsLocation(LOCATION_DECK) and c:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,2,REASON_EFFECT)~=0 and tc:IsLocation(LOCATION_DECK) and c:IsRelateToEffect(e) then
Duel.SendtoDeck(c,nil,0,REASON_EFFECT) Duel.SendtoDeck(c,nil,0,REASON_EFFECT)
Duel.Draw(tp,1,REASON_EFFECT)
end end
end end
function c24865322.drtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c24865322.drtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
......
--柏拉图水晶的狂信徒 --量子妖海暴涨
local m=24865331
local cm=_G["c"..m]
function c24865331.initial_effect(c) function c24865331.initial_effect(c)
local e1=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0)) e3:SetDescription(aux.Stringid(24865331,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e3:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetType(EFFECT_TYPE_IGNITION) e3:SetRange(LOCATION_SZONE)
e1:SetRange(LOCATION_HAND) e3:SetProperty(EFFECT_FLAG_CARD_TARGET+CATEGORY_TOGRAVE)
e1:SetCountLimit(1,m) e3:SetCode(EVENT_FREE_CHAIN)
e1:SetCost(cm.spcost) e3:SetCountLimit(1,24865331)
e1:SetTarget(cm.sptg) e3:SetTarget(c24865331.mttg)
e1:SetOperation(cm.spop) e3:SetOperation(c24865331.mtop)
c:RegisterEffect(e1) c:RegisterEffect(e3)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,1)) e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e2:SetCategory(CATEGORY_TODECK)
e2:SetProperty(EFFECT_FLAG_DELAY) e2:SetCountLimit(1,24865331)
e2:SetCountLimit(1,m+100) e2:SetCode(EVENT_FREE_CHAIN)
e2:SetCode(EVENT_SPSUMMON_SUCCESS) e2:SetRange(LOCATION_GRAVE)
e2:SetOperation(cm.lvop) e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetTarget(c24865331.drtg)
e2:SetOperation(c24865331.drop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetCode(EVENT_SUMMON_SUCCESS)
c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(m,0))
e4:SetCategory(CATEGORY_SPECIAL_SUMMON)
e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetRange(LOCATION_MZONE)
e4:SetCountLimit(1,m+200)
e4:SetTarget(cm.spntg)
e4:SetOperation(cm.spnop)
c:RegisterEffect(e4)
end
cm.Plato=true
function cm.spfilter(c)
return c:IsType(TYPE_MONSTER) and not c:IsPublic()
end end
function cm.fselect(g,c) function c24865331.filter1(c,e,tp,ct)
local tp=c:GetControler() return c:IsFaceup() and c:IsType(TYPE_XYZ) and c:IsRank(9)
return g:GetSum(Card.GetLevel)>=20 and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(c24865331.tfilter,tp,0,LOCATION_MZONE,ct,nil,e,tp,c)
end
function cm.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
local g=Duel.GetMatchingGroup(cm.spfilter,tp,LOCATION_HAND,0,nil)
if chk==0 then return g:CheckSubGroup(cm.fselect,1,#g,c) end
local sg=g:SelectWithSumGreater(tp,Card.GetLevel,20)
Duel.ConfirmCards(1-tp,sg)
Duel.ShuffleHand(tp)
end end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c24865331.tfilter(c,e,tp,tc)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 return Duel.IsPlayerCanSendtoGrave(1-tp)
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function cm.spop(e,tp,eg,ep,ev,re,r,rp) function c24865331.mttg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler() local ng=Duel.GetFieldGroup(tp,0,LOCATION_MZONE)
if not c:IsRelateToEffect(e) then return end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c24865331.filter1(chkc,e,tp,e:GetLabel()) end
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) if chk==0 then return Duel.IsExistingTarget(c24865331.filter1,tp,LOCATION_MZONE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
local g=Duel.SelectTarget(tp,c24865331.filter2,tp,LOCATION_MZONE,0,1,1,nil,e,tp)
local ct=ng:GetCount()-g:GetFirst():GetOverlayCount()
g:KeepAlive()
e:SetLabelObject(g:GetFirst())
e:SetLabel(ct)
end end
--特招效果 function c24865331.mtop(e,tp,eg,ep,ev,re,r,rp)
function cm.lvop(e,tp,eg,ep,ev,re,r,rp) if not Duel.IsPlayerCanSendtoGrave(1-tp) then return end
local c=e:GetHandler() local ng=e:GetLabelObject()
if c:IsRelateToEffect(e) and c:IsFaceup() then local g=Duel.GetFieldGroup(tp,0,LOCATION_MZONE)
local e1=Effect.CreateEffect(c) local ct=ng:GetOverlayCount()
e1:SetType(EFFECT_TYPE_SINGLE) if ct>0 and ct<g:GetCount() then
e1:SetCode(EFFECT_CHANGE_LEVEL) Duel.Hint(HINT_SELECTMSG,1-tp,HINTMSG_TOGRAVE)
e1:SetValue(12) local sg=g:Select(1-tp,ct,ct,nil)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE) Duel.SendtoGrave(sg,REASON_RULE)
c:RegisterEffect(e1) Duel.SendtoDeck(ng,nil,0,REASON_EFFECT)
end end
end end
--等级效果
function cm.spnfilter(c,e,tp) function c24865331.texfilter(c)
return c.Plato and not c:IsCode(m) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return (c:IsFaceup() or c:IsLocation(LOCATION_GRAVE)) and c:IsCode(24865310) and c:IsAbleToDeck()
end end
function cm.spntg(e,tp,eg,ep,ev,re,r,rp,chk) function c24865331.drtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 local c=e:GetHandler()
and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c24865331.texfilter(chkc) and chkc~=c end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) if chk==0 then return Duel.IsExistingTarget(c24865331.texfilter,tp,LOCATION_GRAVE,0,1,c) and c:IsAbleToDeck() end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
local g=Duel.SelectTarget(tp,c24865331.texfilter,tp,LOCATION_GRAVE,0,1,1,c)
Duel.SetOperationInfo(0,CATEGORY_TODECK,g,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_TODECK,c,1,0,0)
end end
function cm.spnop(e,tp,eg,ep,ev,re,r,rp) function c24865331.drop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end local c=e:GetHandler()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) local tc=Duel.GetFirstTarget()
local g=Duel.SelectMatchingCard(tp,cm.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,2,REASON_EFFECT)~=0 and tc:IsLocation(LOCATION_DECK) and c:IsRelateToEffect(e) then
if g:GetCount()>0 then Duel.SendtoDeck(c,nil,0,REASON_EFFECT)
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) Duel.Draw(tp,1,REASON_EFFECT)
end 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,0)
e1:SetTarget(cm.splimit)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function cm.splimit(e,c)
return not (c:GetLevel()%2==0) and not (c:GetRank()%2==0) and not (c:GetLink()%2==0)
end end
...@@ -23,8 +23,7 @@ function cm.initial_effect(c) ...@@ -23,8 +23,7 @@ function cm.initial_effect(c)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCondition(cm.spcon) e1:SetCondition(cm.spcon)
e1:SetTarget(cm.sptg) e1:SetTarget(cm.anctg)
e1:SetOperation(cm.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE) e2:SetType(EFFECT_TYPE_SINGLE)
...@@ -39,7 +38,6 @@ function cm.initial_effect(c) ...@@ -39,7 +38,6 @@ function cm.initial_effect(c)
e32:SetType(EFFECT_TYPE_IGNITION) e32:SetType(EFFECT_TYPE_IGNITION)
e32:SetRange(LOCATION_GRAVE) e32:SetRange(LOCATION_GRAVE)
e32:SetCountLimit(1) e32:SetCountLimit(1)
e32:SetCondition(cm.retcon)
e32:SetTarget(cm.rettg) e32:SetTarget(cm.rettg)
e32:SetOperation(cm.retop) e32:SetOperation(cm.retop)
c:RegisterEffect(e32) c:RegisterEffect(e32)
...@@ -55,27 +53,6 @@ function cm.initial_effect(c) ...@@ -55,27 +53,6 @@ function cm.initial_effect(c)
e12:SetTarget(cm.tetg) e12:SetTarget(cm.tetg)
e12:SetOperation(cm.teop) e12:SetOperation(cm.teop)
c:RegisterEffect(e12) c:RegisterEffect(e12)
if not cm.global_check then
cm.global_check=true
local ge1=Effect.CreateEffect(c)
ge1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge1:SetCode(EVENT_TO_GRAVE)
ge1:SetLabel(m)
ge1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
ge1:SetOperation(cm.sumreg)
Duel.RegisterEffect(ge1,0)
end
end
function cm.sumreg(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst()
local code=e:GetLabel()
while tc do
if tc:GetOriginalCode()==code then
tc:RegisterFlagEffect(code,RESET_EVENT+0x1ec0000+RESET_PHASE+PHASE_END,0,1)
tc:RegisterFlagEffect(code,RESET_EVENT+0x1ec0000+RESET_PHASE+PHASE_END,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(code,0))
end
tc=eg:GetNext()
end
end end
function cm.ffilter(c,fc,sub,mg,sg) function cm.ffilter(c,fc,sub,mg,sg)
if not sg then return true end if not sg then return true end
...@@ -94,79 +71,48 @@ function cm.valcheck(e,c) ...@@ -94,79 +71,48 @@ function cm.valcheck(e,c)
e:GetLabelObject():SetLabel(g) e:GetLabelObject():SetLabel(g)
end end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp) function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_FUSION) local g=e:GetLabel()
end return e:GetHandler():IsSummonType(SUMMON_TYPE_FUSION) and g>4
function cm.tg(c,e)
return not c:IsImmuneToEffect(e)
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local ct=e:GetLabel()
local g=Duel.GetMatchingGroup(cm.tg,tp,LOCATION_ONFIELD+LOCATION_GRAVE+LOCATION_REMOVED,LOCATION_ONFIELD+LOCATION_GRAVE+LOCATION_REMOVED,e:GetHandler(),e)
if chk==0 then return ct>0 and #g>=ct end
Duel.SetChainLimit(aux.FALSE)
end end
function cm.spop(e,tp,eg,ep,ev,re,r,rp) function cm.anctg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() if chk==0 then
local ct=e:GetLabel() return true
local sg=Duel.GetMatchingGroup(cm.tg,tp,LOCATION_ONFIELD+LOCATION_GRAVE+LOCATION_REMOVED,LOCATION_ONFIELD+LOCATION_GRAVE+LOCATION_REMOVED,e:GetHandler(),e)
if ct==0 or sg==0 then return end
if c:IsLocation(LOCATION_MZONE) and c:IsFaceup() then
local xg=Group.CreateGroup()
local mg=Group.CreateGroup()
local g=sg:Select(tp,ct,ct,nil)
local tc=g:GetFirst()
while tc do
if tc:IsControler(1-tp) then
tc:RegisterFlagEffect(m+100,RESET_EVENT+RESETS_STANDARD,0,1)
xg:AddCard(tc)
else
tc:RegisterFlagEffect(m+101,RESET_EVENT+RESETS_STANDARD,0,1)
mg:AddCard(tc)
end
tc=g:GetNext()
end
Duel.HintSelection(g)
if #xg>0 or #mg>0 then
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EFFECT_CANNOT_ACTIVATE)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetTargetRange(0,1)
e2:SetValue(cm.aclimit)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e2)
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD)
e4:SetCode(EFFECT_CANNOT_INACTIVATE)
e4:SetRange(LOCATION_MZONE)
e4:SetValue(cm.effectfilter)
e4:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e4)
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_FIELD)
e5:SetCode(EFFECT_CANNOT_DISEFFECT)
e5:SetRange(LOCATION_MZONE)
e5:SetValue(cm.effectfilter)
e5:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e5)
end end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CODE)
local ac1=Duel.AnnounceCard(tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CODE)
local ac2=Duel.AnnounceCard(tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CODE)
local ac3=Duel.AnnounceCard(tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CODE)
local ac4=Duel.AnnounceCard(tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CODE)
local ac5=Duel.AnnounceCard(tp)
e:SetOperation(cm.codeop(ac1,ac2,ac3,ac4,ac5))
end
function cm.codeop(ac1,ac2,ac3,ac4,ac5)
return
function (e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tsp=e:GetHandlerPlayer()
local e12=Effect.CreateEffect(c)
e12:SetType(EFFECT_TYPE_FIELD)
e12:SetRange(LOCATION_MZONE)
e12:SetCode(EFFECT_CANNOT_ACTIVATE)
e12:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e12:SetAbsoluteRange(tsp,0,1)
e12:SetLabel(ac1,ac2,ac3,ac4,ac5)
e12:SetValue(cm.aclimit)
e12:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e12)
end end
end end
function cm.aclimit(e,re) function cm.aclimit(e,re,tp)
local c=re:GetHandler() local ac1,ac2,ac3,ac4,ac5=e:GetLabel()
return c:GetFlagEffect(m+100)>0 local tc=re:GetHandler()
end return tc:IsCode(ac1,ac2,ac3,ac4,ac5)
function cm.effectfilter(e,ct)
local p=e:GetHandler():GetControler()
local te,tp=Duel.GetChainInfo(ct,CHAININFO_TRIGGERING_EFFECT,CHAININFO_TRIGGERING_PLAYER)
local c=te:GetHandler()
return p==tp and c:GetFlagEffect(m+101)>0
end end
--Effect 2 --Effect 2
function cm.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(m)>0
end
function cm.rettg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToExtra() end if chk==0 then return e:GetHandler():IsAbleToExtra() end
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,e:GetHandler(),1,0,0)
...@@ -239,3 +185,4 @@ function cm.teop(e,tp,eg,ep,ev,re,r,rp) ...@@ -239,3 +185,4 @@ function cm.teop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
--白雪安娜·转校生 --白雪安娜·幻舞
local m=33381018 local m=33381018
local cm=_G["c"..m] local cm=_G["c"..m]
function cm.initial_effect(c) function cm.initial_effect(c)
--xyz summon --link summon
aux.AddXyzProcedure(c,nil,2,2,nil,nil,99) aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkAttribute,ATTRIBUTE_WATER),2)
c:EnableReviveLimit() c:EnableReviveLimit()
--spsummon --add counter
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_COUNTER)
e1:SetType(EFFECT_TYPE_QUICK_O) e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCountLimit(1,m) e1:SetCountLimit(1,m)
e1:SetCost(cm.spcost) e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE)
e1:SetTarget(cm.sptg) e1:SetCost(cm.ctcost)
e1:SetOperation(cm.spop) e1:SetTarget(cm.cttg)
e1:SetOperation(cm.ctop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--special summon --to hand
local e2=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) e3:SetDescription(aux.Stringid(m,1))
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e2:SetProperty(EFFECT_FLAG_DELAY) e3:SetType(EFFECT_TYPE_IGNITION)
e2:SetCode(EVENT_TO_GRAVE) e3:SetCountLimit(1,m+900)
e2:SetCountLimit(1,m+900) e3:SetRange(LOCATION_MZONE)
e2:SetCondition(cm.thcon) e3:SetTarget(cm.thtg)
e2:SetTarget(cm.thtg) e3:SetOperation(cm.thop)
e2:SetOperation(cm.thop) c:RegisterEffect(e3)
c:RegisterEffect(e2)
end end
cm.is_named_with_shirayukianna=1 cm.is_named_with_shirayukianna=1
function cm.spcost(e,tp,eg,ep,ev,re,r,rp,chk) function cm.costfilter(c)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end return c:IsType(TYPE_MONSTER) and c:IsAttribute(ATTRIBUTE_WATER) and c:IsLevelAbove(1) and c:IsDiscardable()
e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST)
end end
function cm.spfilter(c,e,tp) function cm.ctcost(e,tp,eg,ep,ev,re,r,rp,chk)
return c:IsLevel(2) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) if chk==0 then return Duel.IsExistingMatchingCard(cm.costfilter,tp,LOCATION_HAND,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
local g=Duel.SelectMatchingCard(tp,cm.costfilter,tp,LOCATION_HAND,0,1,1,nil)
e:SetLabel(g:GetFirst():GetOriginalLevel())
Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD)
end end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function cm.cttg(e,tp,eg,ep,ev,re,r,rp,chk)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and cm.spfilter(chkc,e,tp) end if chk==0 then return Duel.IsExistingMatchingCard(Card.IsCanAddCounter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil,0x1015,1) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 Duel.SetOperationInfo(0,CATEGORY_COUNTER,nil,e:GetLabel(),0,0x1015)
and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,cm.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end end
function cm.spop(e,tp,eg,ep,ev,re,r,rp) function cm.ctop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local ct=e:GetLabel()
if tc:IsRelateToEffect(e) then local g=Duel.GetMatchingGroup(Card.IsCanAddCounter,tp,LOCATION_MZONE,LOCATION_MZONE,nil,0x1015,1)
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP) if g:GetCount()==0 then return end
for i=1,ct do
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_COUNTER)
local sg=g:Select(tp,1,1,nil)
sg:GetFirst():AddCounter(0x1015,1)
end end
end end
function cm.thcon(e,tp,eg,ep,ev,re,r,rp) function cm.thfilter1(c,tp)
local c=e:GetHandler() local lv=c:GetLevel()
return c:IsPreviousLocation(LOCATION_MZONE) and c:IsSummonType(SUMMON_TYPE_XYZ) and rp==1-tp and c:IsPreviousControler(tp) return (c:IsLocation(LOCATION_DECK) or (c:IsFaceup() and c:IsType(TYPE_PENDULUM))) and lv>0 and c:IsAttribute(ATTRIBUTE_WATER)
end and Duel.IsCanRemoveCounter(tp,1,1,0x1015,lv,REASON_COST) and c:IsAbleToHand()
function cm.thfilter(c)
return c:IsLevel(2) and c:IsAbleToHand()
end end
function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk) 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 if chk==0 then return Duel.IsExistingMatchingCard(cm.thfilter1,tp,LOCATION_DECK+LOCATION_EXTRA,0,1,nil,tp) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) local g=Duel.GetMatchingGroup(cm.thfilter1,tp,LOCATION_DECK+LOCATION_EXTRA,0,nil,tp)
local lvt={}
local tc=g:GetFirst()
while tc do
local tlv=tc:GetLevel()
lvt[tlv]=tlv
tc=g:GetNext()
end
local pc=1
for i=1,12 do
if lvt[i] then lvt[i]=nil lvt[pc]=i pc=pc+1 end
end
lvt[pc]=nil
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(m,1))
local lv=Duel.AnnounceNumber(tp,table.unpack(lvt))
Duel.RemoveCounter(tp,1,1,0x1015,lv,REASON_COST)
e:SetLabel(lv)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK+LOCATION_EXTRA)
end
function cm.thfilter2(c,lv)
return (c:IsLocation(LOCATION_DECK) or (c:IsFaceup() and c:IsType(TYPE_PENDULUM))) and c:IsAttribute(ATTRIBUTE_WATER)
and c:IsLevel(lv) and c:IsAbleToHand()
end end
function cm.thop(e,tp,eg,ep,ev,re,r,rp) function cm.thop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local lv=e:GetLabel()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.thfilter,tp,LOCATION_DECK,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,cm.thfilter2,tp,LOCATION_DECK+LOCATION_EXTRA,0,1,1,nil,lv)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT) Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g) Duel.ConfirmCards(1-tp,g)
end end
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SUMMON)
e1:SetTargetRange(1,0)
e1:SetTarget(cm.splimit)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
local e2=e1:Clone()
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
Duel.RegisterEffect(e2,tp)
end
function cm.splimit(e,c)
return not c:IsAttribute(ATTRIBUTE_WATER)
end end
...@@ -3,8 +3,6 @@ local m=33400651 ...@@ -3,8 +3,6 @@ local m=33400651
local cm=_G["c"..m] local cm=_G["c"..m]
function cm.initial_effect(c) function cm.initial_effect(c)
c:SetUniqueOnField(1,0,m) c:SetUniqueOnField(1,0,m)
cm.dfc_front_side=m
cm.dfc_back_side=m+1
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
...@@ -12,18 +10,26 @@ cm.dfc_back_side=m+1 ...@@ -12,18 +10,26 @@ cm.dfc_back_side=m+1
c:RegisterEffect(e1) c:RegisterEffect(e1)
-- --
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_TODECK+CATEGORY_DISABLE+CATEGORY_ATKCHANGE+CATEGORY_SPECIAL_SUMMON) e2:SetDescription(aux.Stringid(m,5))
e2:SetCategory(CATEGORY_REMOVE+CATEGORY_DISABLE)
e2:SetType(EFFECT_TYPE_QUICK_O) e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetRange(LOCATION_SZONE) e2:SetRange(LOCATION_SZONE)
e2:SetCode(EVENT_FREE_CHAIN) e2:SetCode(EVENT_FREE_CHAIN)
e2:SetCondition(cm.con) e2:SetCountLimit(1,m)
e2:SetCost(cm.cost) e2:SetCost(cm.cost)
e2:SetOperation(cm.activate) e2:SetOperation(cm.activate)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end --change code
function cm.con(e,tp,eg,ep,ev,re,r,rp) local e4=Effect.CreateEffect(c)
local c=e:GetHandler() e4:SetDescription(aux.Stringid(m,4))
return not c:IsStatus(STATUS_CHAINING) and (Duel.GetFlagEffect(tp,m+70001)==0 or Duel.GetFlagEffect(tp,m+70002)==0 or Duel.GetFlagEffect(tp,m+70003)==0 or Duel.GetFlagEffect(tp,m+70004)==0 or Duel.GetFlagEffect(tp,m+70005)==0 ) and Duel.GetFlagEffect(tp,m+70006)<3 e4:SetType(EFFECT_TYPE_QUICK_O)
e4:SetCode(EVENT_FREE_CHAIN)
e4:SetRange(LOCATION_SZONE)
e4:SetCountLimit(1,m+10000)
e4:SetCondition(cm.changecon)
e4:SetTarget(cm.changetg)
e4:SetOperation(cm.changeop)
c:RegisterEffect(e4)
end end
function cm.cfilter(c) function cm.cfilter(c)
return c:IsSetCard(0x9342) and c:IsAbleToRemoveAsCost() return c:IsSetCard(0x9342) and c:IsAbleToRemoveAsCost()
...@@ -35,36 +41,19 @@ function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -35,36 +41,19 @@ function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local tc=g:GetFirst() local tc=g:GetFirst()
Duel.Remove(tc,POS_FACEUP,REASON_COST) Duel.Remove(tc,POS_FACEUP,REASON_COST)
end end
function cm.tdfilter(c)
return c:IsSetCard(0x9342) and c:IsAbleToDeck()
end
function cm.spfilter(c,e,tp)
return c:IsSetCard(0x341) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp) function cm.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local op={} local op={}
local i=1 local i=1
if Duel.GetFlagEffect(tp,m+70001)==0 then
op[i]=1 op[i]=1
i=i+1 i=i+1
end if Duel.IsExistingMatchingCard(aux.disfilter1,tp,LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD+LOCATION_GRAVE,1,nil) then
if Duel.GetFlagEffect(tp,m+70002)==0 and Duel.IsExistingMatchingCard(cm.tdfilter,tp,LOCATION_REMOVED,0,2,nil) and Duel.IsExistingMatchingCard(aux.disfilter1,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) then
op[i]=2 op[i]=2
i=i+1 i=i+1
end end
if Duel.GetFlagEffect(tp,m+70003)==0 and Duel.IsExistingMatchingCard(cm.tdfilter,tp,LOCATION_REMOVED,0,4,nil) and Duel.IsExistingMatchingCard(Card.IsFaceup,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) then if Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD+LOCATION_GRAVE,1,nil) then
op[i]=3 op[i]=3
i=i+1 i=i+1
end
if Duel.GetFlagEffect(tp,m+70004)==0 and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_REMOVED,0,1,nil,e,tp) then
op[i]=4
i=i+1
end
if Duel.GetFlagEffect(tp,m+70005)==0 and c.dfc_back_side and c.dfc_front_side==c:GetOriginalCode() then
op[i]=5
i=i+1
end end
if i==2 then if i==2 then
op1=1 op1=1
...@@ -76,26 +65,13 @@ local c=e:GetHandler() ...@@ -76,26 +65,13 @@ local c=e:GetHandler()
if i==4 then if i==4 then
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(m,0)) Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(m,0))
op1=Duel.SelectOption(tp,aux.Stringid(m,op[1]),aux.Stringid(m,op[2]),aux.Stringid(m,op[3]))+1 op1=Duel.SelectOption(tp,aux.Stringid(m,op[1]),aux.Stringid(m,op[2]),aux.Stringid(m,op[3]))+1
end
if i==5 then
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(m,0))
op1=Duel.SelectOption(tp,aux.Stringid(m,op[1]),aux.Stringid(m,op[2]),aux.Stringid(m,op[3]),aux.Stringid(m,op[4]))+1
end
if i==6 then
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(m,0))
op1=Duel.SelectOption(tp,aux.Stringid(m,op[1]),aux.Stringid(m,op[2]),aux.Stringid(m,op[3]),aux.Stringid(m,op[4]),aux.Stringid(m,op[5]))+1
end end
if op[op1]==1 then if op[op1]==1 then
Duel.RegisterFlagEffect(tp,m+60000,RESET_EVENT+RESET_PHASE+PHASE_END,0,0) Duel.RegisterFlagEffect(tp,m+60000,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
Duel.RegisterFlagEffect(tp,m+70001,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
Duel.RegisterFlagEffect(tp,m+70006,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
end end
if op[op1]==2 then if op[op1]==2 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local tdc=Duel.SelectMatchingCard(tp,cm.tdfilter,tp,LOCATION_REMOVED,0,2,2,nil)
Duel.SendtoDeck(tdc,tp,2,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local disg=Duel.SelectMatchingCard(tp,aux.disfilter1,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil) local disg=Duel.SelectMatchingCard(tp,aux.disfilter1,tp,LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD+LOCATION_GRAVE,1,1,nil)
local disc=disg:GetFirst() local disc=disg:GetFirst()
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
...@@ -113,55 +89,11 @@ local c=e:GetHandler() ...@@ -113,55 +89,11 @@ local c=e:GetHandler()
e2:SetLabelObject(disc) e2:SetLabelObject(disc)
e2:SetReset(RESET_PHASE+PHASE_END) e2:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
Duel.RegisterFlagEffect(tp,m+70002,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
Duel.RegisterFlagEffect(tp,m+70006,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
end end
if op[op1]==3 then if op[op1]==3 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local tdc=Duel.SelectMatchingCard(tp,cm.tdfilter,tp,LOCATION_REMOVED,0,4,4,nil) local rg=Duel.SelectMatchingCard(tp,Card.IsAbleToRemove,tp,LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD+LOCATION_GRAVE,1,1,nil)
Duel.SendtoDeck(tdc,tp,2,REASON_EFFECT) Duel.Remove(rg,POS_FACEUP,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local disg=Duel.SelectMatchingCard(tp,Card.IsFaceup,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
local tc=disg:GetFirst()
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_ATTACK_FINAL)
e1:SetValue(tc:GetBaseAttack()*2)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_SET_DEFENSE_FINAL)
e2:SetValue(tc:GetBaseDefense()*2)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e2)
Duel.RegisterFlagEffect(tp,m+70003,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
Duel.RegisterFlagEffect(tp,m+70006,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
end
if op[op1]==4 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tg=Duel.SelectMatchingCard(tp,cm.spfilter,tp,LOCATION_REMOVED,0,1,1,nil,e,tp)
Duel.SpecialSummon(tg,0,tp,tp,false,false,POS_FACEUP)
local tc=tg:GetFirst()
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e2)
Duel.RegisterFlagEffect(tp,m+70004,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
Duel.RegisterFlagEffect(tp,m+70006,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
end
if op[op1]==5 then
local tcode=c.dfc_back_side
c:SetEntityCode(tcode,true)
c:ReplaceEffect(tcode,0,0)
Duel.RegisterFlagEffect(tp,m+70005,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
Duel.RegisterFlagEffect(tp,m+70006,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
end end
end end
function cm.distg(e,c) function cm.distg(e,c)
...@@ -175,3 +107,21 @@ end ...@@ -175,3 +107,21 @@ end
function cm.disop(e,tp,eg,ep,ev,re,r,rp) function cm.disop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateEffect(ev) Duel.NegateEffect(ev)
end end
function cm.filter4(c)
return c:IsFaceup() and c:IsSetCard(0x9342) and c:IsType(TYPE_XYZ)
end
function cm.changecon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.filter4,tp,LOCATION_MZONE,0,1,nil)
end
function cm.changetg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return m+1 and m==c:GetOriginalCode() end
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
end
function cm.changeop(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) or c:IsFacedown() or c:IsImmuneToEffect(e) then return end
c:SetEntityCode(m+1,true)
c:ReplaceEffect(m+1,0,0)
end
\ No newline at end of file
...@@ -3,8 +3,6 @@ local m=33400652 ...@@ -3,8 +3,6 @@ local m=33400652
local cm=_G["c"..m] local cm=_G["c"..m]
function cm.initial_effect(c) function cm.initial_effect(c)
c:SetUniqueOnField(1,0,m) c:SetUniqueOnField(1,0,m)
cm.dfc_front_side=33400651
cm.dfc_back_side=33400652
--Activate --Activate
local e10=Effect.CreateEffect(c) local e10=Effect.CreateEffect(c)
e10:SetType(EFFECT_TYPE_ACTIVATE) e10:SetType(EFFECT_TYPE_ACTIVATE)
...@@ -12,15 +10,25 @@ cm.dfc_back_side=33400652 ...@@ -12,15 +10,25 @@ cm.dfc_back_side=33400652
c:RegisterEffect(e10) c:RegisterEffect(e10)
-- --
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,1)) e2:SetDescription(aux.Stringid(m,4))
e2:SetCategory(CATEGORY_TODECK+CATEGORY_DISABLE+CATEGORY_ATKCHANGE+CATEGORY_SPECIAL_SUMMON) e2:SetCategory(CATEGORY_TODECK+CATEGORY_ATKCHANGE)
e2:SetType(EFFECT_TYPE_QUICK_O) e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetRange(LOCATION_SZONE) e2:SetRange(LOCATION_SZONE)
e2:SetCode(EVENT_FREE_CHAIN) e2:SetCode(EVENT_FREE_CHAIN)
e2:SetCondition(cm.con) e2:SetCountLimit(1,m)
e2:SetCost(cm.cost) e2:SetCost(cm.cost)
e2:SetOperation(cm.activate) e2:SetOperation(cm.activate)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--change code
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(m,3))
e4:SetType(EFFECT_TYPE_QUICK_O)
e4:SetCode(EVENT_FREE_CHAIN)
e4:SetRange(LOCATION_SZONE)
e4:SetCountLimit(1,m+10000)
e4:SetTarget(cm.changetg)
e4:SetOperation(cm.changeop)
c:RegisterEffect(e4)
--back --back
local e9=Effect.CreateEffect(c) local e9=Effect.CreateEffect(c)
e9:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e9:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
...@@ -31,10 +39,6 @@ cm.dfc_back_side=33400652 ...@@ -31,10 +39,6 @@ cm.dfc_back_side=33400652
e9:SetOperation(cm.backop) e9:SetOperation(cm.backop)
c:RegisterEffect(e9) c:RegisterEffect(e9)
end end
function cm.con(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return not c:IsStatus(STATUS_CHAINING) and (Duel.GetFlagEffect(tp,m+80001)==0 or Duel.GetFlagEffect(tp,m+80002)==0 or Duel.GetFlagEffect(tp,m+80003)==0 )
end
function cm.cfilter(c) function cm.cfilter(c)
return c:IsSetCard(0x9342) and c:IsAbleToRemoveAsCost() return c:IsSetCard(0x9342) and c:IsAbleToRemoveAsCost()
end end
...@@ -47,47 +51,21 @@ end ...@@ -47,47 +51,21 @@ end
function cm.tdfilter(c) function cm.tdfilter(c)
return c:IsSetCard(0x9342) and c:IsAbleToDeck() return c:IsSetCard(0x9342) and c:IsAbleToDeck()
end end
function cm.spfilter(c,e,tp)
return c:IsSetCard(0x341) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function cm.stfilter(c) function cm.stfilter(c)
return c:IsSetCard(0x341) and c:IsType(TYPE_XYZ) return c:IsSetCard(0x341) and c:IsFaceup()
end end
function cm.activate(e,tp,eg,ep,ev,re,r,rp) function cm.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local op={} if not (Duel.IsExistingMatchingCard(cm.stfilter,tp,LOCATION_MZONE,0,1,nil) and Duel.IsExistingMatchingCard(cm.tdfilter,tp,LOCATION_REMOVED,0,6,nil)) then return end
local i=1
if Duel.GetFlagEffect(tp,m+80001)==0 and Duel.IsExistingMatchingCard(cm.stfilter,tp,LOCATION_MZONE,0,1,nil) and Duel.IsExistingMatchingCard(cm.tdfilter,tp,LOCATION_REMOVED,0,4,nil) then
op[i]=1
i=i+1
end
if Duel.GetFlagEffect(tp,m+80002)==0 and Duel.IsExistingMatchingCard(cm.stfilter,tp,LOCATION_MZONE,0,1,nil) and Duel.IsExistingMatchingCard(cm.tdfilter,tp,LOCATION_REMOVED,0,4,nil) then
op[i]=2
i=i+1
end
if Duel.GetFlagEffect(tp,m+80003)==0 and 33400651 and c:GetOriginalCode()==33400652 then
op[i]=3
i=i+1
end
if i==2 then
op1=1
end
if i==3 then
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(m,0))
op1=Duel.SelectOption(tp,aux.Stringid(m,op[1]),aux.Stringid(m,op[2]))+1
end
if i==4 then
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(m,0))
op1=Duel.SelectOption(tp,aux.Stringid(m,op[1]),aux.Stringid(m,op[2]),aux.Stringid(m,op[3]))+1
end
if op[op1]==1 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local tdc=Duel.SelectMatchingCard(tp,cm.tdfilter,tp,LOCATION_REMOVED,0,4,4,nil) local tdc=Duel.SelectMatchingCard(tp,cm.tdfilter,tp,LOCATION_REMOVED,0,6,6,nil)
Duel.SendtoDeck(tdc,tp,2,REASON_EFFECT) Duel.SendtoDeck(tdc,tp,2,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local tg=Duel.SelectMatchingCard(tp,cm.stfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) local tg=Duel.SelectMatchingCard(tp,cm.stfilter,tp,LOCATION_MZONE,0,1,1,nil)
local tc=tg:GetFirst() local tc=tg:GetFirst()
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(m,0))
local op1=Duel.SelectOption(tp,aux.Stringid(m,1),aux.Stringid(m,2),aux.Stringid(m,5))+1
if op1==1 then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_ATTACK_FINAL) e1:SetCode(EFFECT_SET_ATTACK_FINAL)
...@@ -100,15 +78,19 @@ local c=e:GetHandler() ...@@ -100,15 +78,19 @@ local c=e:GetHandler()
e2:SetValue(tc:GetDefense()*2) e2:SetValue(tc:GetDefense()*2)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e2) tc:RegisterEffect(e2)
Duel.RegisterFlagEffect(tp,m+80001,RESET_EVENT+RESET_PHASE+PHASE_END,0,0) --actlimit
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)
e3:SetTargetRange(0,1)
e3:SetValue(1)
e3:SetCondition(cm.actcon)
e3:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e3)
end end
if op[op1]==2 then if op1==2 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local tdc=Duel.SelectMatchingCard(tp,cm.tdfilter,tp,LOCATION_REMOVED,0,4,4,nil)
Duel.SendtoDeck(tdc,tp,2,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local tg=Duel.SelectMatchingCard(tp,cm.stfilter,tp,LOCATION_MZONE,0,1,1,nil)
local tc=tg:GetFirst()
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_ATTACK_ALL) e1:SetCode(EFFECT_ATTACK_ALL)
...@@ -122,24 +104,45 @@ Duel.RegisterFlagEffect(tp,m+80001,RESET_EVENT+RESET_PHASE+PHASE_END,0,0) ...@@ -122,24 +104,45 @@ Duel.RegisterFlagEffect(tp,m+80001,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
e2:SetCode(EFFECT_PIERCE) e2:SetCode(EFFECT_PIERCE)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e2) tc:RegisterEffect(e2)
Duel.RegisterFlagEffect(tp,m+80002,RESET_EVENT+RESET_PHASE+PHASE_END,0,0)
end end
if op[op1]==3 then if op1==3 then
c:SetEntityCode(33400651,true) local e1=Effect.CreateEffect(c)
c:ReplaceEffect(33400651,0,0) e1:SetType(EFFECT_TYPE_SINGLE)
Duel.RegisterFlagEffect(tp,m+80003,RESET_EVENT+RESET_PHASE+PHASE_END,0,0) e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE)
e1:SetCode(EFFECT_IMMUNE_EFFECT)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
e1:SetValue(cm.efilter)
e1:SetOwnerPlayer(tp)
tc:RegisterEffect(e1,true)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DIRECT_ATTACK)
e2:SetCondition(cm.dircon)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e2)
end end
end end
function cm.distg(e,c) function cm.actcon(e)
local tc=e:GetLabelObject() return Duel.GetAttacker()==e:GetHandler() or Duel.GetAttackTarget()==e:GetHandler()
return c:IsOriginalCodeRule(tc:GetOriginalCodeRule()) end
function cm.efilter(e,re)
return e:GetOwnerPlayer()~=re:GetOwnerPlayer()
end end
function cm.discon(e,tp,eg,ep,ev,re,r,rp) function cm.dircon(e)
local tc=e:GetLabelObject() return e:GetHandler():GetControler()==e:GetOwnerPlayer()
return re:GetHandler():IsOriginalCodeRule(tc:GetOriginalCodeRule())
end end
function cm.disop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateEffect(ev) function cm.changetg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return m-1 and m==c:GetOriginalCode() end
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
end
function cm.changeop(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) or c:IsFacedown() or c:IsImmuneToEffect(e) then return end
c:SetEntityCode(m-1,true)
c:ReplaceEffect(m-1,0,0)
end end
function cm.backon(e,tp,eg,ep,ev,re,r,rp) function cm.backon(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -2,16 +2,18 @@ ...@@ -2,16 +2,18 @@
local m=33401005 local m=33401005
local cm=_G["c"..m] local cm=_G["c"..m]
function cm.initial_effect(c) function cm.initial_effect(c)
--destroy replace --
local e2=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetDescription(aux.Stringid(m,0))
e2:SetCode(EFFECT_DESTROY_REPLACE) e1:SetCategory(CATEGORY_DESTROY)
e2:SetRange(LOCATION_HAND+LOCATION_MZONE) e1:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCountLimit(1,m) e1:SetCode(EVENT_CHAINING)
e2:SetTarget(cm.reptg) e1:SetRange(LOCATION_MZONE+LOCATION_HAND)
e2:SetValue(cm.repval) e1:SetCountLimit(1,m)
e2:SetOperation(cm.repop) e1:SetCondition(cm.condition)
c:RegisterEffect(e2) e1:SetTarget(cm.target)
e1:SetOperation(cm.activate)
c:RegisterEffect(e1)
--sps --sps
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(m,1)) e3:SetDescription(aux.Stringid(m,1))
...@@ -24,19 +26,40 @@ function cm.initial_effect(c) ...@@ -24,19 +26,40 @@ function cm.initial_effect(c)
e3:SetOperation(cm.srop) e3:SetOperation(cm.srop)
c:RegisterEffect(e3) c:RegisterEffect(e3)
end end
function cm.repfilter(c,tp) function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return c:IsFaceup() and c:IsSetCard(0x9341) return rp==1-tp
and c:IsOnField() and c:IsControler(tp) and c:IsReason(REASON_EFFECT+REASON_BATTLE) and not c:IsReason(REASON_REPLACE)
end end
function cm.reptg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToRemove() and eg:IsExists(cm.repfilter,1,e:GetHandler():IsCode(m),tp) end Duel.SetOperationInfo(0,CATEGORY_DESTROY,e:GetHandler(),1,0,0)
return Duel.SelectEffectYesNo(tp,e:GetHandler(),96)
end end
function cm.repval(e,c) function cm.ckfilter1(c)
return cm.repfilter(c,e:GetHandlerPlayer()) return c:IsSetCard(0x9341) and c:IsFaceup()
end end
function cm.repop(e,tp,eg,ep,ev,re,r,rp) function cm.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.Destroy(e:GetHandler(),REASON_EFFECT) local c=e:GetHandler()
local g2=Duel.GetMatchingGroup(cm.ckfilter1,tp,LOCATION_ONFIELD,0,nil)
local tc=g2:GetFirst()
while tc do
local e4=Effect.CreateEffect(e:GetHandler())
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetCode(EFFECT_IMMUNE_EFFECT)
e4:SetValue(cm.efilter)
e4:SetReset(RESET_EVENT+0x1fe0000+RESET_CHAIN)
e4:SetOwnerPlayer(tp)
tc:RegisterEffect(e4)
tc=g2:GetNext()
end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_REMOVE)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(0,1)
e1:SetValue(1)
e1:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e1,tp)
if c:IsRelateToEffect(e) then
Duel.Destroy(c,REASON_EFFECT)
end
end end
function cm.srtg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.srtg(e,tp,eg,ep,ev,re,r,rp,chk)
......
...@@ -15,12 +15,11 @@ c:EnableReviveLimit() ...@@ -15,12 +15,11 @@ c:EnableReviveLimit()
--Destroy all --Destroy all
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,0)) e1:SetDescription(aux.Stringid(m,0))
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP) e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP)
e1:SetCode(EVENT_DESTROYED) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,m) e1:SetCountLimit(1)
e1:SetCondition(cm.condition)
e1:SetTarget(cm.destg) e1:SetTarget(cm.destg)
e1:SetOperation(cm.desop) e1:SetOperation(cm.desop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
...@@ -64,12 +63,6 @@ function cm.splimit(e,se,sp,st) ...@@ -64,12 +63,6 @@ function cm.splimit(e,se,sp,st)
return not e:GetHandler():IsLocation(LOCATION_EXTRA) or bit.band(st,SUMMON_TYPE_FUSION)==SUMMON_TYPE_FUSION return not e:GetHandler():IsLocation(LOCATION_EXTRA) or bit.band(st,SUMMON_TYPE_FUSION)==SUMMON_TYPE_FUSION
end end
function cm.cfilter(c,tp)
return c:IsReason(REASON_BATTLE+REASON_EFFECT) and c:IsPreviousLocation(LOCATION_ONFIELD)
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(cm.cfilter,1,nil,tp)
end
function cm.destg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.destg(e,tp,eg,ep,ev,re,r,rp,chk)
local g=Duel.GetFieldGroup(tp,0,LOCATION_ONFIELD) local g=Duel.GetFieldGroup(tp,0,LOCATION_ONFIELD)
if chk==0 then return g:GetCount()>0 end if chk==0 then return g:GetCount()>0 end
......
...@@ -9,7 +9,7 @@ function cm.initial_effect(c) ...@@ -9,7 +9,7 @@ function cm.initial_effect(c)
c:RegisterEffect(e0) c:RegisterEffect(e0)
--spsummon --spsummon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,4)) e1:SetDescription(aux.Stringid(m,3))
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP) e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP)
...@@ -18,6 +18,20 @@ function cm.initial_effect(c) ...@@ -18,6 +18,20 @@ function cm.initial_effect(c)
e1:SetTarget(cm.tg) e1:SetTarget(cm.tg)
e1:SetOperation(cm.op) e1:SetOperation(cm.op)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--Remove
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,4))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_DESTROYED)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e2:SetRange(LOCATION_GRAVE)
e2:SetCountLimit(1,m)
e2:SetCost(aux.bfgcost)
e2:SetCondition(cm.dscon)
e2:SetTarget(cm.dstg)
e2:SetOperation(cm.dsop)
c:RegisterEffect(e2)
end end
function cm.spfilter(c,tp) function cm.spfilter(c,tp)
return c:GetSummonLocation()==LOCATION_GRAVE and c:GetPreviousControler()==tp and c:IsSetCard(0x9341) return c:GetSummonLocation()==LOCATION_GRAVE and c:GetPreviousControler()==tp and c:IsSetCard(0x9341)
...@@ -111,3 +125,27 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp) ...@@ -111,3 +125,27 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp)
end end
end end
end end
function cm.cfilter(c,tp)
return c:IsReason(REASON_BATTLE+REASON_EFFECT)
and c:GetPreviousControler()==tp and c:IsPreviousLocation(LOCATION_MZONE)
end
function cm.dscon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(cm.cfilter,1,nil,tp)
end
function cm.filter(c,e,tp)
return c:IsSetCard(0x9341) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE)
end
function cm.dstg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE)
end
function cm.dsop(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.filter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP_DEFENSE)
end
end
\ No newline at end of file
...@@ -41,9 +41,9 @@ function cm.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -41,9 +41,9 @@ function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,1500) Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,1500)
end end
function cm.activate(e,tp,eg,ep,ev,re,r,rp) function cm.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.Recover(tp,1500,REASON_EFFECT) Duel.Recover(tp,1500,REASON_EFFECT)
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then
local tc=Duel.SelectMatchingCard(tp,cm.filter2,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil,e,tp) local tc=Duel.SelectMatchingCard(tp,cm.filter2,tp,LOCATION_DECK+LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil,e,tp)
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end end
local e3=Effect.CreateEffect(e:GetHandler()) local e3=Effect.CreateEffect(e:GetHandler())
...@@ -59,25 +59,44 @@ function cm.ckfilter(c) ...@@ -59,25 +59,44 @@ function cm.ckfilter(c)
return c:IsSetCard(0x9341) and c:IsType(TYPE_FUSION) and c:GetOriginalAttribute()==ATTRIBUTE_FIRE and c:IsAbleToExtra() return c:IsSetCard(0x9341) and c:IsType(TYPE_FUSION) and c:GetOriginalAttribute()==ATTRIBUTE_FIRE and c:IsAbleToExtra()
end end
function cm.tdcon(e,tp,eg,ep,ev,re,r,rp) function cm.tdcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_MZONE,0,1,nil) return Duel.IsExistingMatchingCard(cm.ckfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil)
end end
function cm.ckfilter2(c,e,tp) function cm.ckfilter2(c,e,tp)
return c:IsSetCard(0x9341) and c:IsLevel(4) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsSetCard(0x9341) and c:IsLevel(4) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function cm.tdop(e,tp,eg,ep,ev,re,r,rp) function cm.tdop(e,tp,eg,ep,ev,re,r,rp)
local dg=Duel.GetMatchingGroup(cm.ckfilter,tp,LOCATION_MZONE,0,nil) local dg=Duel.GetMatchingGroup(cm.ckfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil)
if dg:GetCount()>0 then if dg:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(m,2)) then
local ct1=Duel.SendtoDeck(dg,tp,2,REASON_EFFECT) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
Duel.Recover(tp,ct1*500,REASON_EFFECT) local tdg=dg:Select(tp,1,dg:GetCount(),nil)
if Duel.IsExistingMatchingCard(cm.ckfilter2,tp,LOCATION_GRAVE,0,1,nil,e,tp) and Duel.SelectYesNo(tp,aux.Stringid(m,0)) then local tdg2=Duel.SendtoDeck(tdg,tp,2,REASON_EFFECT)
local tc1=tdg2:GetFirst()
local ct1=0
local ct2=0
while tc1 do
if tc1:GetOwner()==tp then ct1=ct1+1 end
if tc1:GetOwner()==1-tp then ct2=ct2+1 end
tc1=tdg2:GetNext()
end
Duel.Recover(tp,ct1*1000,REASON_EFFECT)
Duel.Recover(1-tp,ct2*1000,REASON_EFFECT)
if ct1>0 and Duel.IsExistingMatchingCard(cm.ckfilter2,tp,LOCATION_GRAVE,0,1,nil,e,tp) and Duel.SelectYesNo(tp,aux.Stringid(m,0)) then
local sl=Duel.GetLocationCount(tp,LOCATION_MZONE)
if ct1*2<sl then sl=ct1*2 end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,cm.ckfilter2,tp,LOCATION_GRAVE,0,1,ct1*2,nil,e,tp) local g=Duel.SelectMatchingCard(tp,cm.ckfilter2,tp,LOCATION_GRAVE,0,1,sl,nil,e,tp)
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end end
if ct2>0 and Duel.IsExistingMatchingCard(cm.ckfilter2,1-tp,LOCATION_GRAVE,0,1,nil,e,1-tp) and Duel.SelectYesNo(1-tp,aux.Stringid(m,0)) then
local sl=Duel.GetLocationCount(1-tp,LOCATION_MZONE)
if ct2*2<sl then sl=ct2*2 end
Duel.Hint(HINT_SELECTMSG,1-tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(1-tp,cm.ckfilter2,1-tp,LOCATION_GRAVE,0,1,sl,nil,e,1-tp)
Duel.SpecialSummon(g,0,1-tp,1-tp,false,false,POS_FACEUP)
end
end end
end end
function cm.filter(c,e,tp) function cm.filter(c,e,tp)
return c:GetPreviousControler()==tp and c:IsPreviousLocation(LOCATION_MZONE) return c:GetPreviousControler()==tp and c:IsPreviousLocation(LOCATION_MZONE)
and ((c:IsReason(REASON_EFFECT) and c:GetReasonPlayer()==1-tp) or (c:IsReason(REASON_BATTLE) and Duel.GetAttacker():IsControler(1-tp))) and ((c:IsReason(REASON_EFFECT) and c:GetReasonPlayer()==1-tp) or (c:IsReason(REASON_BATTLE) and Duel.GetAttacker():IsControler(1-tp)))
......
--D.A.L 空间震 --D.A.L 空间震
function c33401304.initial_effect(c) local m=33401304
local cm=_G["c"..m]
function cm.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(33401304,0)) e1:SetCategory(CATEGORY_REMOVE+CATEGORY_SPECIAL_SUMMON)
e1:SetCategory(CATEGORY_DESTROY+CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,33401304+EFFECT_COUNT_CODE_OATH) e1:SetCountLimit(1,m)
e1:SetTarget(c33401304.target) e1:SetTarget(cm.sptg)
e1:SetOperation(c33401304.activate) e1:SetOperation(cm.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--spsummon --lv
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(33401304,0)) e2:SetCategory(CATEGORY_REMOVE+CATEGORY_SPECIAL_SUMMON)
e2:SetCategory(CATEGORY_SPECIAL_SUMMON) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetRange(LOCATION_GRAVE) e2:SetRange(LOCATION_GRAVE)
e2:SetCountLimit(1,33401304+10000) e2:SetCountLimit(1,m)
e2:SetCondition(aux.exccon) e2:SetCost(aux.bfgcost)
e2:SetCost(c33401304.cost) e2:SetTarget(cm.target)
e2:SetTarget(c33401304.sptg) e2:SetOperation(cm.activate)
e2:SetOperation(c33401304.spop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c33401304.chkfilter1(c,e,tp) function cm.filter(c,e,tp)
return (not c:IsSetCard(0xc342)) and c:IsSetCard(0x341) and c:IsType(TYPE_MONSTER) and return c:IsSetCard(0x341) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
not c:IsHasEffect(EFFECT_REVIVE_LIMIT) and Duel.IsPlayerCanSpecialSummon(tp,0,POS_FACEUP,tp,c)
and Duel.IsExistingMatchingCard(c33401304.chkfilter2,tp,LOCATION_DECK,0,1,nil,e,tp,c:GetCode())
end
function c33401304.chkfilter2(c,e,tp,cd)
return (not c:IsSetCard(0xc342)) and c:IsSetCard(0x341) and c:IsType(TYPE_MONSTER) and not c:IsCode(cd)
and not c:IsHasEffect(EFFECT_REVIVE_LIMIT) and Duel.IsPlayerCanSpecialSummon(tp,0,POS_FACEUP,1-tp,c)
end
function c33401304.filter1(c,e,tp)
return (not c:IsSetCard(0xc342)) and c:IsSetCard(0x341) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
and Duel.IsExistingMatchingCard(c33401304.filter2,tp,LOCATION_DECK,0,1,nil,e,tp,c:GetCode())
end
function c33401304.filter2(c,e,tp,cd)
return (not c:IsSetCard(0xc342)) and c:IsSetCard(0x341) and c:IsType(TYPE_MONSTER) and not c:IsCode(cd)
and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_ATTACK,1-tp)
end end
function c33401304.target(e,tp,eg,ep,ev,re,r,rp,chk) function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return not Duel.IsPlayerAffectedByEffect(tp,59822133) if chkc then return chkc:IsLocation(LOCATION_HAND+LOCATION_GRAVE+LOCATION_REMOVED) and chkc:IsControler(tp) and cm.filter(chkc,e,tp) end
and Duel.IsExistingMatchingCard(c33401304.chkfilter1,tp,LOCATION_DECK,0,1,nil,e,tp) end if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
local g=Duel.GetFieldGroup(tp,LOCATION_MZONE,LOCATION_MZONE) and Duel.IsExistingTarget(cm.filter,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_REMOVED,0,1,nil,e,tp) end
if g then Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0) end Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,2,tp,LOCATION_DECK) local g=Duel.SelectTarget(tp,cm.filter,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,g,g:GetCount(),0,0)
end end
function c33401304.activate(e,tp,eg,ep,ev,re,r,rp) function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local dg=Duel.GetFieldGroup(tp,LOCATION_MZONE,LOCATION_MZONE) local tc=Duel.GetFirstTarget()
if dg then Duel.Destroy(dg,REASON_EFFECT) end if tc:IsRelateToEffect(e) and Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)~=0 and Duel.SelectYesNo(tp,aux.Stringid(m,1)) then
local sg=Duel.GetMatchingGroup(c33401304.filter1,tp,LOCATION_DECK,0,nil,e,tp) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
if sg:GetCount()>0 and not Duel.IsPlayerAffectedByEffect(tp,59822133) local g=Duel.SelectMatchingCard(tp,Card.IsAbleToRemove,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.GetLocationCount(1-tp,LOCATION_MZONE)>0 then if g:GetCount()>0 then
Duel.BreakEffect() Duel.Destroy(g,REASON_EFFECT,LOCATION_REMOVED)
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(33401304,2)) end
local g1=sg:Select(tp,1,1,nil)
local tc1=g1:GetFirst()
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(33401304,3))
local g2=Duel.SelectMatchingCard(tp,c33401304.filter2,tp,LOCATION_DECK,0,1,1,nil,e,tp,tc1:GetCode())
local tc2=g2:GetFirst()
Duel.SpecialSummonStep(tc1,0,tp,tp,false,false,POS_FACEUP_ATTACK)
Duel.SpecialSummonStep(tc2,0,tp,1-tp,false,false,POS_FACEUP_ATTACK)
Duel.SpecialSummonComplete()
end end
local e3=Effect.CreateEffect(e:GetHandler())
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e3:SetTargetRange(1,0)
e3:SetTarget(c33401304.splimit)
e3:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e3,tp)
end
function c33401304.splimit(e,c,sump,sumtype,sumpos,targetp,se)
return not c:IsSetCard(0x341)
end end
function c33401304.cfilter(c,e,tp) function cm.cfilter(c)
return c:IsSetCard(0x341) and c:IsAbleToRemoveAsCost() return c:IsSetCard(0x341) and c:IsLevel(4) and c:IsAbleToRemove()
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_DECK)
end end
function c33401304.cost(e,tp,eg,ep,ev,re,r,rp,chk) function cm.activate(e,tp,eg,ep,ev,re,r,rp)
if chk==0 then return e:GetHandler():IsAbleToRemoveAsCost()
and Duel.IsExistingMatchingCard(c33401304.cfilter,tp,LOCATION_GRAVE,0,1,e:GetHandler(),e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c33401304.cfilter,tp,LOCATION_GRAVE,0,1,1,e:GetHandler(),e,tp) local g=Duel.SelectMatchingCard(tp,cm.cfilter,tp,LOCATION_DECK,0,1,1,nil)
g:AddCard(e:GetHandler()) local tc=g:GetFirst()
Duel.Remove(g,POS_FACEUP,REASON_COST) if tc==nil then return end
Duel.Remove(tc,POS_FACEUP,REASON_EFFECT)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetRange(LOCATION_REMOVED)
e1:SetCode(EVENT_PHASE+PHASE_STANDBY)
e1:SetCountLimit(1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_STANDBY+RESET_SELF_TURN)
e1:SetCondition(cm.thcon)
e1:SetOperation(cm.thop)
tc:RegisterEffect(e1)
local e3=Effect.CreateEffect(e:GetHandler())
e3:SetDescription(aux.Stringid(m,2))
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_CANNOT_TRIGGER)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_CLIENT_HINT)
e3:SetRange(LOCATION_REMOVED)
e3:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e3)
end end
function c33401304.spfilter(c,e,tp) function cm.thcon(e,tp,eg,ep,ev,re,r,rp)
return c:IsSetCard(0x341) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return Duel.GetTurnPlayer()==tp
end end
function c33401304.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function cm.thop(e,tp,eg,ep,ev,re,r,rp)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_DECK) and c33401304.spfilter(chkc,e,tp) end local c=e:GetHandler()
if chk==0 then return Duel.GetLocationCount(1-tp,LOCATION_MZONE)>0 if c:IsType(TYPE_RITUAL) then Duel.SpecialSummon(c,SUMMON_TYPE_RITUAL,tp,tp,true,true,POS_FACEUP)
and Duel.IsExistingTarget(c33401304.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end else
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
local g=Duel.SelectTarget(tp,c33401304.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function c33401304.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(1-tp,LOCATION_MZONE)<=0 then return end
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then Duel.SpecialSummon(tc,0,tp,1-tp,false,false,POS_FACEUP) end
end end
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
function c33401306.initial_effect(c) function c33401306.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DESTROY) e1:SetCategory(CATEGORY_REMOVE)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCondition(c33401306.condition) e1:SetCondition(c33401306.condition)
...@@ -28,13 +28,13 @@ function c33401306.condition(e,tp,eg,ep,ev,re,r,rp) ...@@ -28,13 +28,13 @@ function c33401306.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c33401306.cfilter,tp,LOCATION_MZONE,0,1,nil) return Duel.IsExistingMatchingCard(c33401306.cfilter,tp,LOCATION_MZONE,0,1,nil)
end end
function c33401306.target(e,tp,eg,ep,ev,re,r,rp,chk) function c33401306.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(aux.TRUE,tp,0,LOCATION_MZONE+LOCATION_FZONE,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,0,LOCATION_ONFIELD,1,nil) end
local sg=Duel.GetMatchingGroup(aux.TRUE,tp,0,LOCATION_MZONE+LOCATION_FZONE,nil) local sg=Duel.GetMatchingGroup(Card.IsAbleToRemove,tp,0,LOCATION_ONFIELD,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,sg,sg:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_REMOVE,sg,sg:GetCount(),0,0)
end end
function c33401306.activate(e,tp,eg,ep,ev,re,r,rp) function c33401306.activate(e,tp,eg,ep,ev,re,r,rp)
local sg=Duel.GetMatchingGroup(aux.TRUE,tp,0,LOCATION_MZONE+LOCATION_FZONE,nil) local sg=Duel.GetMatchingGroup(aux.TRUE,tp,0,LOCATION_ONFIELD,nil)
Duel.Destroy(sg,REASON_EFFECT) Duel.Remove(sg,POS_FACEUP,REASON_EFFECT)
end end
function c33401306.condition2(e,tp,eg,ep,ev,re,r,rp) function c33401306.condition2(e,tp,eg,ep,ev,re,r,rp)
......
--五河士道 祈福 --五河士道 祈福
function c33401307.initial_effect(c) local m=m
local cm=_G["c"..m]
function cm.initial_effect(c)
--link summon --link summon
aux.AddLinkProcedure(c,nil,2,2,c33401307.lcheck) aux.AddLinkProcedure(c,nil,2,2,cm.lcheck)
c:EnableReviveLimit() c:EnableReviveLimit()
--special summon --special summon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(33401307,0)) e1:SetDescription(aux.Stringid(m,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCountLimit(1,33401307) e1:SetCountLimit(1,m)
e1:SetCondition(c33401307.spcon) e1:SetCondition(cm.spcon)
e1:SetTarget(c33401307.sptg) e1:SetTarget(cm.sptg)
e1:SetOperation(c33401307.spop) e1:SetOperation(cm.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--tohand --spsummon
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetCode(EVENT_CHAINING) e2:SetRange(LOCATION_GRAVE)
e2:SetRange(LOCATION_MZONE) e2:SetCountLimit(1,m+10000)
e2:SetOperation(aux.chainreg) e2:SetCondition(aux.exccon)
e2:SetCost(aux.bfgcost)
e2:SetTarget(cm.sptg2)
e2:SetOperation(cm.spop2)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(33401307,1))
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_CHAIN_SOLVED)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,33401307+10000)
e3:SetCondition(c33401307.thcon)
e3:SetTarget(c33401307.thtg)
e3:SetOperation(c33401307.thop)
c:RegisterEffect(e3)
end end
function c33401307.lcheck(g) function cm.lcheck(g)
return g:IsExists(Card.IsLinkSetCard,1,nil,0xc342) return g:IsExists(Card.IsLinkSetCard,1,nil,0xc342)
end end
function c33401307.spcon(e,tp,eg,ep,ev,re,r,rp) function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_LINK) return e:GetHandler():IsSummonType(SUMMON_TYPE_LINK)
end end
function c33401307.spfilter(c,e,tp) function cm.spfilter(c,e,tp)
return c:IsSetCard(0x341) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE) return c:IsSetCard(0xc342) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE)
end end
function c33401307.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c33401307.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
end end
function c33401307.spop(e,tp,eg,ep,ev,re,r,rp) function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c33401307.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,cm.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp)
local tc=g:GetFirst() local tc=g:GetFirst()
if tc and Duel.SpecialSummonStep(tc,0,tp,tp,false,false,POS_FACEUP_DEFENSE) then if tc then Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP_DEFENSE) end
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e3:SetValue(1)
e3:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e3)
end
Duel.SpecialSummonComplete()
local e3=Effect.CreateEffect(e:GetHandler()) local e3=Effect.CreateEffect(e:GetHandler())
e3:SetType(EFFECT_TYPE_FIELD) e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e3:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e3:SetTargetRange(1,0) e3:SetTargetRange(1,0)
e3:SetTarget(c33401307.splimit) e3:SetTarget(cm.splimit)
e3:SetReset(RESET_PHASE+PHASE_END) e3:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e3,tp) Duel.RegisterEffect(e3,tp)
end end
function c33401307.splimit(e,c,sump,sumtype,sumpos,targetp,se) function cm.splimit(e,c,sump,sumtype,sumpos,targetp,se)
return not (c:IsSetCard(0x341) or c:IsSetCard(0xa342)) return not (c:IsSetCard(0x341) or c:IsSetCard(0xa342))
end end
function c33401307.thcon(e,tp,eg,ep,ev,re,r,rp) function cm.spfilter2(c,e,tp)
local rc=re:GetHandler() return c:IsSetCard(0x341,0xa342) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
return re:IsActiveType(TYPE_XYZ) and rc:IsSetCard(0x341) and rc:IsControler(tp) and e:GetHandler():GetFlagEffect(1)>0
end
function c33401307.thfilter(c)
return c:IsSetCard(0x341) and c:IsSetCard(0x46) and c:IsType(TYPE_SPELL) and c:IsAbleToHand()
end end
function c33401307.thtg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.sptg2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c33401307.thfilter,tp,LOCATION_DECK,0,1,nil) end if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) and Duel.IsExistingMatchingCard(cm.spfilter2,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE)
end end
function c33401307.thop(e,tp,eg,ep,ev,re,r,rp) function cm.spop2(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
local g=Duel.SelectMatchingCard(tp,c33401307.thfilter,tp,LOCATION_DECK,0,1,1,nil) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,cm.spfilter2,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
local tc=g:GetFirst() local tc=g:GetFirst()
if tc then local res=Duel.SpecialSummonStep(tc,0,tp,tp,false,false,POS_FACEUP)
Duel.SendtoHand(tc,tp,REASON_EFFECT) if res then
Duel.ConfirmCards(1-tp,g) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetValue(RESET_TURN_SET)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e2)
end end
local e3=Effect.CreateEffect(e:GetHandler()) Duel.SpecialSummonComplete()
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e3:SetTargetRange(1,0)
e3:SetTarget(c33401307.splimit)
e3:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e3,tp)
end end
--五河士道 暴走形态 --五河士道 暴走形态
function c33401309.initial_effect(c) local m=33401309
aux.AddFusionProcFunFunRep(c,c33401309.matfilter1,c33401309.matfilter,2,2,true) local cm=_G["c"..m]
c:SetUniqueOnField(1,1,c33401309.uqfilter,LOCATION_MZONE) function cm.initial_effect(c)
--search --fusion material
c:EnableReviveLimit()
aux.AddFusionProcMix(c,false,true,cm.fusfilter1,cm.fusfilter2,cm.fusfilter2,cm.fusfilter2,cm.fusfilter5)
--spsummon condition
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(33401309,1)) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetType(EFFECT_TYPE_IGNITION) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION)
e1:SetValue(aux.fuslimit)
c:RegisterEffect(e1)
--activate from hand
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_QP_ACT_IN_NTPHAND)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,33401309) e1:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0x341,0x340))
e1:SetTarget(c33401309.thtg2) e1:SetTargetRange(LOCATION_HAND,0)
e1:SetOperation(c33401309.thop2)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_TRAP_ACT_IN_HAND)
c:RegisterEffect(e2)
--
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(m,1))
e3:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,m)
e3:SetTarget(cm.thtg)
e3:SetOperation(cm.thop)
c:RegisterEffect(e3)
--copy --copy
local e6=Effect.CreateEffect(c) local e6=Effect.CreateEffect(c)
e6:SetType(EFFECT_TYPE_QUICK_O) e6:SetType(EFFECT_TYPE_QUICK_O)
e6:SetDescription(aux.Stringid(33401309,2)) e6:SetDescription(aux.Stringid(m,2))
e6:SetCode(EVENT_FREE_CHAIN) e6:SetCode(EVENT_FREE_CHAIN)
e6:SetRange(LOCATION_MZONE) e6:SetRange(LOCATION_MZONE)
e6:SetCountLimit(1,33401309+10000) e6:SetCountLimit(1,m+10000)
e6:SetTarget(c33401309.cptg) e6:SetTarget(cm.cptg)
e6:SetOperation(c33401309.cpop) e6:SetOperation(cm.cpop)
c:RegisterEffect(e6) c:RegisterEffect(e6)
end end
function c33401309.matfilter1(c) function cm.fusfilter1(c)
return c:IsSetCard(0x341) and c:IsFusionType(TYPE_FUSION) or c:IsFusionType(TYPE_SYNCHRO) or c:IsFusionType(TYPE_XYZ) return c:IsSetCard(0xc342)
end end
function c33401309.matfilter(c) function cm.fusfilter2(c)
return c:IsSetCard(0x341) and (c:IsFusionType(TYPE_SYNCHRO+TYPE_FUSION+TYPE_XYZ) or (c:IsLinkAbove(2) and c:IsFusionType(TYPE_LINK)))
end
function cm.fusfilter5(c)
return c:IsSetCard(0x341) return c:IsSetCard(0x341)
end end
function c33401309.uqfilter(c) function cm.thfilter1(c)
return c:GetOriginalCode()==33401309 return c:IsSetCard(0xc342) and c:IsAbleToHand()
end end
function cm.thfilter2(c)
function c33401309.thfilter2(c)
return c:IsSetCard(0x340) and c:IsType(TYPE_CONTINUOUS) and c:IsType(TYPE_SPELL) and not c:IsForbidden() return c:IsSetCard(0x340) and c:IsType(TYPE_CONTINUOUS) and c:IsType(TYPE_SPELL) and not c:IsForbidden()
end end
function c33401309.thtg2(e,tp,eg,ep,ev,re,r,rp,chk) function cm.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c33401309.thfilter2,tp,LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(cm.thfilter1,tp,LOCATION_GRAVE+LOCATION_DECK+LOCATION_REMOVED,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE+LOCATION_REMOVED)
end end
function c33401309.thop2(e,tp,eg,ep,ev,re,r,rp) function cm.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(33401309,0)) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c33401309.thfilter2,tp,LOCATION_GRAVE,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,cm.thfilter1,tp,LOCATION_DECK+LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil)
local tc=g:GetFirst()
if tc then
Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc)
end
if Duel.IsExistingMatchingCard(cm.thfilter2,tp,LOCATION_GRAVE+LOCATION_DECK+LOCATION_REMOVED,0,1,nil) and Duel.GetLocationCount(tp,LOCATION_SZONE)>0 and Duel.SelectYesNo(tp,aux.Stringid(m,3)) then
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(m,0))
local g=Duel.SelectMatchingCard(tp,cm.thfilter2,tp,LOCATION_GRAVE+LOCATION_DECK+LOCATION_REMOVED,0,1,1,nil)
local tc=g:GetFirst() local tc=g:GetFirst()
if #g>0 then if #g>0 then
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
end end
end end
function c33401309.cptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function cm.matfilter(c)
if chk==0 then return Duel.IsExistingMatchingCard(c33401309.matfilter,tp,LOCATION_EXTRA,0,1,nil) end return c:IsOriginalSetCard(0x341) and c:IsType(TYPE_MONSTER)
end
function cm.cptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingMatchingCard(cm.matfilter,tp,LOCATION_EXTRA+LOCATION_DECK+LOCATION_GRAVE+LOCATION_REMOVED,0,1,nil) end
end end
function c33401309.cpop(e,tp,eg,ep,ev,re,r,rp) function cm.cpop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if not c:IsRelateToEffect(e) or c:IsFacedown() then return end if not c:IsRelateToEffect(e) or c:IsFacedown() then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CONFIRM) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CONFIRM)
local cg=Duel.SelectMatchingCard(tp,c33401309.matfilter,tp,LOCATION_EXTRA,0,1,1,nil,c) local cg=Duel.SelectMatchingCard(tp,cm.matfilter,tp,LOCATION_EXTRA+LOCATION_DECK+LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil)
if cg:GetCount()==0 then return end if cg:GetCount()==0 then return end
Duel.ConfirmCards(1-tp,cg) Duel.ConfirmCards(1-tp,cg)
local code=cg:GetFirst():GetOriginalCode() local code=cg:GetFirst():GetOriginalCode()
local c=e:GetHandler()
if not c:IsOnField() or c:IsFacedown() then return end
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END,2)
e1:SetCode(EFFECT_CHANGE_CODE) e1:SetCode(EFFECT_CHANGE_CODE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(code) e1:SetValue(code)
e1:SetLabel(tp)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
c:RegisterEffect(e1) c:RegisterEffect(e1)
c:CopyEffect(code,RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END,2) c:CopyEffect(code,RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END,1)
c:RegisterFlagEffect(33401301,RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END,0,2) c:RegisterFlagEffect(33401301,RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END,0,1)
end end
\ No newline at end of file
--奥义!瞬闪轰爆破! --奥义!瞬闪轰爆破!
function c33401315.initial_effect(c) local m=33401315
local cm=_G["c"..m]
function cm.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DESTROY) e1:SetCategory(CATEGORY_TOGRAVE+CATEGORY_DAMAGE)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,33401315+EFFECT_COUNT_CODE_OATH) e1:SetCountLimit(1,m)
e1:SetCondition(c33401315.condition) e1:SetCondition(cm.condition)
e1:SetTarget(c33401315.destg) e1:SetTarget(cm.destg)
e1:SetOperation(c33401315.desop) e1:SetOperation(cm.desop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--to hand
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_GRAVE)
e3:SetCountLimit(1,m)
e3:SetCost(aux.bfgcost)
e3:SetTarget(cm.thtg)
e3:SetOperation(cm.thop)
c:RegisterEffect(e3)
end end
function c33401315.cfilter(c,tp) function cm.cfilter(c)
return c:IsFaceup() and c:IsOriginalCodeRule(33401309) return c:IsFaceup() and c:IsOriginalSetCard(0xc342) and c:IsType(TYPE_FUSION)
end end
function c33401315.condition(e,tp,eg,ep,ev,re,r,rp) function cm.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c33401315.cfilter,tp,LOCATION_MZONE,0,1,nil) return Duel.IsExistingMatchingCard(cm.cfilter,tp,LOCATION_MZONE,0,1,nil)
end end
function c33401315.destg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.destg(e,tp,eg,ep,ev,re,r,rp,chk)
local g=Duel.GetFieldGroup(tp,0,LOCATION_ONFIELD) local g=Duel.GetFieldGroup(tp,0,LOCATION_ONFIELD)
if chk==0 then return g:GetCount()>0 end if chk==0 then return g:GetCount()>0 end
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,g,g:GetCount(),0,0)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,500*g:GetCount()) Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,500*g:GetCount())
end end
function c33401315.desop(e,tp,eg,ep,ev,re,r,rp) function cm.desop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetFieldGroup(tp,0,LOCATION_ONFIELD) local g=Duel.GetFieldGroup(tp,0,LOCATION_ONFIELD)
if g:GetCount()>0 then if g:GetCount()>0 then
local ss=Duel.Destroy(g,REASON_EFFECT) local ss=Duel.SendtoGrave(g,REASON_EFFECT)
Duel.Damage(1-tp,500*ss,REASON_EFFECT) Duel.Damage(1-tp,500*ss,REASON_EFFECT)
end end
end end
function cm.thfilter(c)
return c:IsSetCard(0xc342) and c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsAbleToHand()
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
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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