Commit 1841671e authored by 大崎甜花's avatar 大崎甜花 Committed by GitHub

Merge pull request #2 from purerosefallen/master

06-27 Backup
parents e14b1425 8030a2ec
No preview for this file type
...@@ -14,7 +14,6 @@ ...@@ -14,7 +14,6 @@
01000411 0 --纯真无邪~空白少女 01000411 0 --纯真无邪~空白少女
01000416 1 --梦幻游戏 01000416 1 --梦幻游戏
01000427 1 --疯狂的少女 小兔姬 01000427 1 --疯狂的少女 小兔姬
01007007 0 --稀世的魔女·久远寺有珠
01000376 1 --美丽的公主·姬丝秀忒 01000376 1 --美丽的公主·姬丝秀忒
01000369 1 --怪异杀手·姬丝秀忒 01000369 1 --怪异杀手·姬丝秀忒
#11 #11
...@@ -44,12 +43,17 @@ ...@@ -44,12 +43,17 @@
04200110 0 --安藤麻幌的蛋包饭 04200110 0 --安藤麻幌的蛋包饭
04210018 1 --猫耳天堂-幼猫的约定 04210018 1 --猫耳天堂-幼猫的约定
04210020 1 --猫耳天堂-幼猫的梦想 04210020 1 --猫耳天堂-幼猫的梦想
04210031 0 --猫耳天堂-偶像红豆 04210028 2 --猫耳天堂-猫耳的仪式
04210031 1 --猫耳天堂-偶像红豆
04210035 1 --猫耳天堂-偶像巧克力
04210036 2 --猫耳天堂-偶像香草
04212301 2 --罗罗娜的工作室-罗罗娜 04212301 2 --罗罗娜的工作室-罗罗娜
04212306 2 --罗罗娜的工作室 04212306 2 --罗罗娜的工作室
04212307 1 --托托莉的工作室 04212307 1 --托托莉的工作室
04212312 1 --不可思议的炼金工作室 04212312 1 --不可思议的炼金工作室
04212325 1 --星辰魔女工作室-梅露露 04212325 1 --星辰魔女工作室-梅露露
04212331 0 --时钟机关工作室-琉紫
04212334 0 --时钟机关工作室-安可儿
#50 #50
05012607 1 --第10032次轮回 05012607 1 --第10032次轮回
...@@ -100,8 +104,11 @@ ...@@ -100,8 +104,11 @@
09980440 0 --降临卡片·防御降临 09980440 0 --降临卡片·防御降临
09980444 0 --降临卡片·抢夺降临 09980444 0 --降临卡片·抢夺降临
09980237 1 --物语纪录·北白蛇神社 09980237 1 --物语纪录·北白蛇神社
09980232 2 --物语纪录·迷路之真宵 09980232 1 --物语纪录·迷路之真宵
09980231 1 --物语纪录·冷傲之绯多木 09980231 1 --物语纪录·冷傲之绯多木
09980234 1 --物语纪录·暴力之骏河
09980235 1 --物语纪录·焦心之翼
09980236 1 --物语纪录·不死之忍
#101 #101
10102004 1 --圣谕舞姬 珍妮丝 10102004 1 --圣谕舞姬 珍妮丝
...@@ -149,8 +156,7 @@ ...@@ -149,8 +156,7 @@
12001011 2 --六曜的友引 12001011 2 --六曜的友引
12001015 1 --六曜 则吉的西米尔 12001015 1 --六曜 则吉的西米尔
12001016 1 --六曜的先导 12001016 1 --六曜的先导
12001018 2 --六曜 赤口的完红丘依儿 12001018 2 --六曜 赤口的完红丘依
12004004 0 --原罪机械 Greed 席维
12005001 0 --真神的末裔 丘依儿 12005001 0 --真神的末裔 丘依儿
12003006 1 --水歌 圆奏龙爱迷尔 12003006 1 --水歌 圆奏龙爱迷尔
12003013 1 --无眠的海底之都 12003013 1 --无眠的海底之都
...@@ -163,8 +169,7 @@ ...@@ -163,8 +169,7 @@
12003029 0 --水歌 深奏的米塔罗斯 12003029 0 --水歌 深奏的米塔罗斯
12004002 1 --原罪机械 Envy 普灵思 12004002 1 --原罪机械 Envy 普灵思
12005001 1 --真神的末裔 丘依儿 12005001 1 --真神的末裔 丘依儿
12005015 1 --新起的虹神 完红的丘依儿 12005015 1 --新起的虹神 完红的丘依
12005021 0 --三色的幻境
12006004 1 --失落王国 美丽的丘依儿 12006004 1 --失落王国 美丽的丘依儿
12006006 2 --失落王国 智慧的拉结尔 12006006 2 --失落王国 智慧的拉结尔
12006009 1 --失落王国 王国的尚达凤 12006009 1 --失落王国 王国的尚达凤
...@@ -176,7 +181,6 @@ ...@@ -176,7 +181,6 @@
12008002 2 --潜入机械的暗影 波恋达斯 12008002 2 --潜入机械的暗影 波恋达斯
12008005 2 --暗黑的质点,波恋达斯 12008005 2 --暗黑的质点,波恋达斯
12008011 2 --双色的轮舞 12008011 2 --双色的轮舞
12008030 0 --双色的心绘
12008014 2 --回转的悲凉 波恋达斯 12008014 2 --回转的悲凉 波恋达斯
12008025 1 --极限的螺旋 波恋达斯 12008025 1 --极限的螺旋 波恋达斯
12017002 0 --忍妖 玉雪 12017002 0 --忍妖 玉雪
......
--魔法决战! --魔法决战!
function c1000417.initial_effect(c) function c1000417.initial_effect(c)
c:SetUniqueOnField(1,1,1000417) c:SetUniqueOnField(1,1,1000417)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCost(c1000417.cost) e1:SetCost(c1000417.cost)
e1:SetOperation(c1000417.activate) e1:SetOperation(c1000417.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--act in hand --act in hand
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE) e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_TRAP_ACT_IN_HAND) e2:SetCode(EFFECT_TRAP_ACT_IN_HAND)
e2:SetCondition(c1000417.handcon) e2:SetCondition(c1000417.handcon)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--activate limit --activate limit
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD) e3:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e3:SetCode(EVENT_CHAINING) e3:SetCode(EVENT_CHAINING)
e3:SetRange(LOCATION_SZONE) e3:SetRange(LOCATION_SZONE)
e3:SetOperation(c1000417.aclimit1) e3:SetOperation(c1000417.aclimit1)
c:RegisterEffect(e3) c:RegisterEffect(e3)
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD) e4:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e4:SetCode(EVENT_CHAIN_NEGATED) e4:SetCode(EVENT_CHAIN_NEGATED)
e4:SetRange(LOCATION_SZONE) e4:SetRange(LOCATION_SZONE)
e4:SetOperation(c1000417.aclimit2) e4:SetOperation(c1000417.aclimit2)
c:RegisterEffect(e4) c:RegisterEffect(e4)
local e5=Effect.CreateEffect(c) local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_FIELD) e5:SetType(EFFECT_TYPE_FIELD)
e5:SetCode(EFFECT_CANNOT_ACTIVATE) e5:SetCode(EFFECT_CANNOT_ACTIVATE)
e5:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e5:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e5:SetRange(LOCATION_SZONE) e5:SetRange(LOCATION_SZONE)
e5:SetTargetRange(0,1) e5:SetTargetRange(0,1)
e5:SetCondition(c1000417.econ) e5:SetCondition(c1000417.econ)
e5:SetValue(c1000417.elimit) e5:SetValue(c1000417.elimit)
c:RegisterEffect(e5) c:RegisterEffect(e5)
end end
function c1000417.filter1(c) function c1000417.filter1(c)
return c:IsType(TYPE_CONTINUOUS) and c:IsFaceup() and c:IsAbleToGrave() and not c:IsCode(1000417) return c:IsType(TYPE_CONTINUOUS) and c:IsFaceup() and c:IsAbleToGrave() and not c:IsCode(1000417)
end end
function c1000417.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c1000417.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c1000417.filter1,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c1000417.filter1,tp,LOCATION_SZONE,LOCATION_SZONE,1,nil,e,tp) end
local g=Duel.GetMatchingGroup(c1000417.filter1,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) local g=Duel.GetMatchingGroup(c1000417.filter1,tp,LOCATION_SZONE,LOCATION_SZONE,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0) Duel.SendtoGrave(g,REASON_COST)
local g=Duel.GetMatchingGroup(c1000417.filter1,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) end
Duel.SendtoGrave(g,REASON_EFFECT) function c1000417.activate(e,tp,eg,ep,ev,re,r,rp)
end --destroy
function c1000417.activate(e,tp,eg,ep,ev,re,r,rp) local c=e:GetHandler()
--destroy local e1=Effect.CreateEffect(c)
local c=e:GetHandler() e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
local e1=Effect.CreateEffect(c) e1:SetRange(LOCATION_SZONE)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetCode(EVENT_PHASE+PHASE_STANDBY)
e1:SetRange(LOCATION_SZONE) e1:SetCountLimit(1)
e1:SetCode(EVENT_PHASE+PHASE_STANDBY) if Duel.GetCurrentPhase()==PHASE_STANDBY and Duel.GetTurnPlayer()==tp then
e1:SetCountLimit(1) e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_STANDBY+RESET_SELF_TURN,2)
if Duel.GetCurrentPhase()==PHASE_STANDBY and Duel.GetTurnPlayer()==tp then else
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_STANDBY+RESET_SELF_TURN,2) e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_STANDBY+RESET_SELF_TURN)
else end
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_STANDBY+RESET_SELF_TURN) if Duel.GetTurnPlayer()==tp and Duel.GetCurrentPhase()==PHASE_DRAW then
end e1:SetLabel(0)
if Duel.GetTurnPlayer()==tp and Duel.GetCurrentPhase()==PHASE_DRAW then else
e1:SetLabel(0) e1:SetLabel(Duel.GetTurnCount())
else end
e1:SetLabel(Duel.GetTurnCount()) e1:SetCondition(c1000417.descon)
end e1:SetOperation(c1000417.desop)
e1:SetCondition(c1000417.descon) Duel.RegisterEffect(e1,tp)
e1:SetOperation(c1000417.desop) end
Duel.RegisterEffect(e1,tp) function c1000417.descon(e,tp,eg,ep,ev,re,r,rp)
end return Duel.GetTurnPlayer()==tp and Duel.GetTurnCount()~=e:GetLabel()
function c1000417.descon(e,tp,eg,ep,ev,re,r,rp) end
return Duel.GetTurnPlayer()==tp and Duel.GetTurnCount()~=e:GetLabel() function c1000417.desop(e,tp,eg,ep,ev,re,r,rp)
end local c=e:GetHandler()
function c1000417.desop(e,tp,eg,ep,ev,re,r,rp) Duel.Destroy(c,REASON_RULE)
local c=e:GetHandler() end
Duel.Destroy(c,REASON_RULE) function c1000417.cfilter(c)
end return c:IsCode(1000406) and c:IsFaceup() and c:IsType(TYPE_MONSTER)
function c1000417.cfilter(c) end
return c:IsCode(1000406) and c:IsFaceup() and c:IsType(TYPE_MONSTER) function c1000417.handcon(e)
end local g=Duel.GetFieldGroup(e:GetHandlerPlayer(),LOCATION_MZONE,0)
function c1000417.handcon(e) return g:IsExists(c1000417.cfilter,1,nil)
local g=Duel.GetFieldGroup(e:GetHandlerPlayer(),LOCATION_MZONE,0) end
return g:IsExists(c1000417.cfilter,1,nil) function c1000417.aclimit1(e,tp,eg,ep,ev,re,r,rp)
end if ep==tp or not re:IsHasType(EFFECT_TYPE_ACTIVATE) then return end
function c1000417.aclimit1(e,tp,eg,ep,ev,re,r,rp) e:GetHandler():RegisterFlagEffect(1000417,RESET_EVENT+0x3ff0000+RESET_PHASE+PHASE_END,0,1)
if ep==tp or not re:IsHasType(EFFECT_TYPE_ACTIVATE) then return end end
e:GetHandler():RegisterFlagEffect(1000417,RESET_EVENT+0x3ff0000+RESET_PHASE+PHASE_END,0,1) function c1000417.aclimit2(e,tp,eg,ep,ev,re,r,rp)
end if ep==tp or not re:IsHasType(EFFECT_TYPE_ACTIVATE) then return end
function c1000417.aclimit2(e,tp,eg,ep,ev,re,r,rp) e:GetHandler():ResetFlagEffect(1000417)
if ep==tp or not re:IsHasType(EFFECT_TYPE_ACTIVATE) then return end end
e:GetHandler():ResetFlagEffect(1000417) function c1000417.econ(e)
end return e:GetHandler():GetFlagEffect(1000417)~=0
function c1000417.econ(e) end
return e:GetHandler():GetFlagEffect(1000417)~=0 function c1000417.elimit(e,te,tp)
end return te:IsHasType(EFFECT_TYPE_ACTIVATE)
function c1000417.elimit(e,te,tp)
return te:IsHasType(EFFECT_TYPE_ACTIVATE)
end end
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
--虚构之炎 --虚构之炎
function c11200112.initial_effect(c) function c11200112.initial_effect(c)
local e1=aux.AddRitualProcGreater2(c,c11200112.filter,LOCATION_HAND+LOCATION_GRAVE+LOCATION_DECK+LOCATION_REMOVED,c11200112.mfilter) local e1=aux.AddRitualProcGreater2Code2(c,11200103,11200104,LOCATION_HAND+LOCATION_GRAVE+LOCATION_DECK+LOCATION_REMOVED,c11200112.mfilter)
e1:SetHintTiming(0,TIMING_END_PHASE) e1:SetHintTiming(0,TIMING_END_PHASE)
e1:SetCost(c11200112.cost) e1:SetCost(c11200112.cost)
e1:SetCountLimit(1,11200112) e1:SetCountLimit(1,11200112+EFFECT_COUNT_CODE_OATH)
end end
function c11200112.filter(c) function c11200112.mfilter(c)
return c:IsCode(11200103,11200104) return c:IsType(TYPE_MONSTER)
end end
function c11200112.mfilter(c) function c11200112.cost(e,tp,eg,ep,ev,re,r,rp,chk)
return c:IsType(TYPE_MONSTER) if chk==0 then return Duel.GetActivityCount(tp,ACTIVITY_SUMMON)==0
end and Duel.GetActivityCount(tp,ACTIVITY_FLIPSUMMON)==0 and Duel.GetActivityCount(tp,ACTIVITY_SPSUMMON)==0 end
function c11200112.cost(e,tp,eg,ep,ev,re,r,rp,chk) local e1=Effect.CreateEffect(e:GetHandler())
if chk==0 then return Duel.GetActivityCount(tp,ACTIVITY_SUMMON)==0 and Duel.GetActivityCount(tp,ACTIVITY_SPSUMMON)==0 end e1:SetType(EFFECT_TYPE_FIELD)
local e1=Effect.CreateEffect(e:GetHandler()) e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH)
e1:SetType(EFFECT_TYPE_FIELD) e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetCode(EFFECT_CANNOT_SUMMON) e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH) e1:SetLabelObject(e)
e1:SetTargetRange(1,0) e1:SetTargetRange(1,0)
e1:SetReset(RESET_PHASE+PHASE_END) e1:SetTarget(c11200112.sumlimit)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
local e2=e1:Clone() local e2=Effect.CreateEffect(e:GetHandler())
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetLabelObject(e) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH)
e2:SetTarget(c11200112.splimit) e2:SetCode(EFFECT_CANNOT_SUMMON)
Duel.RegisterEffect(e2,tp) e2:SetReset(RESET_PHASE+PHASE_END)
end e2:SetTargetRange(1,0)
function c11200112.splimit(e,c,sump,sumtype,sumpos,targetp,se) Duel.RegisterEffect(e2,tp)
return se~=e:GetLabelObject() local e3=e2:Clone()
end e3:SetCode(EFFECT_CANNOT_FLIP_SUMMON)
Duel.RegisterEffect(e3,tp)
end
function c11200112.sumlimit(e,c,sump,sumtype,sumpos,targetp,se)
return e:GetLabelObject()~=se
end
...@@ -36,8 +36,8 @@ function c12009101.initial_effect(c) ...@@ -36,8 +36,8 @@ function c12009101.initial_effect(c)
end end
function c12009101.disop(e,tp) function c12009101.disop(e,tp)
local c=e:GetHandler() local c=e:GetHandler()
-- return 285217024 return 285217024
return 69600000 -- return 69600000
end end
function c12009101.efilter(e,te) function c12009101.efilter(e,te)
return te:GetOwner()~=e:GetOwner() return te:GetOwner()~=e:GetOwner()
......
...@@ -65,31 +65,19 @@ function c12026024.copytg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -65,31 +65,19 @@ function c12026024.copytg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel.SelectTarget(tp,c12026024.copyfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,c) Duel.SelectTarget(tp,c12026024.copyfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,c)
end end
function c12026024.copyop(e,tp,eg,ep,ev,re,r,rp) function c12026024.copyop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc and c:IsRelateToEffect(e) and c:IsFaceup() and tc:IsRelateToEffect(e) and tc:IsLocation(LOCATION_GRAVE) then if tc and c:IsRelateToEffect(e) and c:IsFaceup() and tc:IsRelateToEffect(e) and tc:IsFaceup() and not tc:IsType(TYPE_TOKEN) then
local code=tc:GetOriginalCodeRule() local code=tc:GetOriginalCodeRule()
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:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EFFECT_CHANGE_CODE) e1:SetCode(EFFECT_CHANGE_CODE)
e1:SetValue(code) e1:SetValue(code)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
c:RegisterEffect(e1) c:RegisterEffect(e1)
if not tc:IsType(TYPE_TRAPMONSTER) then if not tc:IsType(TYPE_TRAPMONSTER) then
local cid=c:CopyEffect(code,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,1) c:CopyEffect(code,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,1)
local e3=Effect.CreateEffect(c) end
e3:SetDescription(aux.Stringid(12026024,1)) end
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) end
e3:SetCode(EVENT_PHASE+PHASE_END)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e3:SetCountLimit(1)
e3:SetRange(LOCATION_MZONE)
e3:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
e3:SetLabelObject(e1)
e3:SetLabel(cid)
e3:SetOperation(c12026024.rstop)
c:RegisterEffect(e3)
end
end
end
\ No newline at end of file
--三位一体的女神 拉结尔 --三位一体的女神 拉结尔
xpcall(function() require("expansions/script/c37564765") end,function() require("script/c37564765") end) xpcall(function() require("expansions/script/c37564765") end,function() require("script/c37564765") end)
function c12026032.initial_effect(c) function c12026032.initial_effect(c)
--synchro summon --synchro summon
aux.AddSynchroProcedure2(c,nil,aux.NonTuner(nil)) aux.AddSynchroProcedure2(c,nil,aux.NonTuner(nil))
c:EnableReviveLimit() c:EnableReviveLimit()
--special summon rule --special summon rule
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC) e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_EXTRA) e1:SetRange(LOCATION_EXTRA)
e1:SetCountLimit(1,12026032) e1:SetCountLimit(1,12026032)
e1:SetCondition(c12026032.spcon) e1:SetCondition(c12026032.spcon)
e1:SetOperation(c12026032.spop) e1:SetOperation(c12026032.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--atk up --atk up
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(12026032,0)) e2:SetDescription(aux.Stringid(12026032,0))
e2:SetCategory(CATEGORY_TOHAND) e2:SetCategory(CATEGORY_TOHAND)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_SPSUMMON_SUCCESS) e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP) e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP)
e2:SetCountLimit(1,12026032+100) e2:SetCountLimit(1,12026032+100)
e2:SetTarget(c12026032.thtg) e2:SetCost(c12026032.thcost)
e2:SetOperation(c12026032.thop) e2:SetTarget(c12026032.thtg)
c:RegisterEffect(e1) e2:SetOperation(c12026032.thop)
--leave field c:RegisterEffect(e2)
local e2=Effect.CreateEffect(c) --leave field
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) local e2=Effect.CreateEffect(c)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_LEAVE_FIELD) e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetOperation(c12026032.regop) e2:SetCode(EVENT_LEAVE_FIELD)
c:RegisterEffect(e2) e2:SetOperation(c12026032.regop)
end c:RegisterEffect(e2)
function c12026032.confilter(c,ec) end
return c:IsCanBeSynchroMaterial(ec) and c:IsSetCard(0x1fbd) and c:IsFaceup() and c:IsAbleToGraveAsCost() and c:GetLevel()>0 and c:IsSummonableCard() function c12026032.confilter(c,ec)
end return c:IsCanBeSynchroMaterial(ec) and c:IsSetCard(0x1fbd) and c:IsFaceup() and c:IsAbleToGraveAsCost() and c:GetLevel()>0 and c:IsSummonableCard()
function c12026032.gcheck(g,tp,fc) end
return Duel.GetLocationCountFromEx(tp,tp,g,fc)>0 and g:GetSum(Card.GetLevel)==3 function c12026032.gcheck(g,tp,fc)
end return Duel.GetLocationCountFromEx(tp,tp,g,fc)>0 and g:GetSum(Card.GetLevel)==3
function c12026032.spcon(e,c) end
if c==nil then return true end function c12026032.spcon(e,c)
local tp=c:GetControler() if c==nil then return true end
local mg=Duel.GetMatchingGroup(c12026032.confilter,tp,LOCATION_MZONE,0,nil,c) local tp=c:GetControler()
return Senya.CheckGroup(mg,c12026032.gcheck,nil,1,4,tp,c) local mg=Duel.GetMatchingGroup(c12026032.confilter,tp,LOCATION_MZONE,0,nil,c)
end return Senya.CheckGroup(mg,c12026032.gcheck,nil,1,4,tp,c)
function c12026032.spop(e,tp,eg,ep,ev,re,r,rp,c) end
local mg=Duel.GetMatchingGroup(c12026032.confilter,tp,LOCATION_MZONE,0,nil,c) function c12026032.spop(e,tp,eg,ep,ev,re,r,rp,c)
local g=Senya.SelectGroup(tp,HINTMSG_TOGRAVE,mg,c12026032.gcheck,nil,1,3,tp,c) local mg=Duel.GetMatchingGroup(c12026032.confilter,tp,LOCATION_MZONE,0,nil,c)
Duel.SendtoGrave(g,REASON_COST) local g=Senya.SelectGroup(tp,HINTMSG_TOGRAVE,mg,c12026032.gcheck,nil,1,3,tp,c)
end Duel.SendtoGrave(g,REASON_COST)
end
function c12026032.thfilter1(c)
return c:IsType(TYPE_MONSTER) and c:IsAttribute(ATTRIBUTE_LIGHT) and c:IsAbleToDeck() function c12026032.thfilter1(c)
end return c:IsType(TYPE_MONSTER) and c:IsAttribute(ATTRIBUTE_LIGHT) and c:IsAbleToDeck()
function c12026032.thcost(c) end
if chk==0 then return Duel.IsExistingMatchingCard(c12026032.thfilter1,tp,LOCATION_GRAVE,0,3,nil) end function c12026032.thcost(c)
local tc=Duel.SelectMatchingCard(tp,c12026032.thfilter1,tp,LOCATION_GRAVE,0,3,3,nil) if chk==0 then return Duel.IsExistingMatchingCard(c12026032.thfilter1,tp,LOCATION_GRAVE,0,3,nil) end
Duel.SendtoDeck(tc,nil,2,REASON_COST) local tc=Duel.SelectMatchingCard(tp,c12026032.thfilter1,tp,LOCATION_GRAVE,0,3,3,nil)
end Duel.SendtoDeck(tc,nil,2,REASON_COST)
function c12026032.thfilter(c) end
return c:IsType(TYPE_MONSTER) and c:IsAttribute(ATTRIBUTE_LIGHT) and c:IsAbleToHand() function c12026032.thfilter(c)
end return c:IsType(TYPE_MONSTER) and c:IsAttribute(ATTRIBUTE_LIGHT) and c:IsAbleToHand()
function c12026032.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) end
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c12026032.thfilter(chkc) end function c12026032.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingMatchingCard(c12026032.thfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c12026032.thfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end end
function c12026032.thop(e,tp,eg,ep,ev,re,r,rp) function c12026032.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c12026032.thfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,nil) local g=Duel.SelectMatchingCard(tp,c12026032.thfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,nil)
if g:GetCount() then if g:GetCount() then
Duel.SendtoHand(g,tp,REASON_EFFECT) Duel.SendtoHand(g,tp,REASON_EFFECT)
Duel.ConfirmCards(g,1-tp) Duel.ConfirmCards(g,1-tp)
end end
end end
function c12026032.regop(e,tp,eg,ep,ev,re,r,rp) function c12026032.regop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
-- --
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EFFECT_HAND_LIMIT) e2:SetCode(EFFECT_HAND_LIMIT)
e2:SetReset(RESET_PHASE+PHASE_END) e2:SetReset(RESET_PHASE+PHASE_END)
e2:SetValue(99) e2:SetValue(99)
e2:SetTargetRange(1,0) e2:SetTargetRange(1,0)
Duel.RegisterEffect(tp,e2) Duel.RegisterEffect(e2,tp)
end end
\ No newline at end of file
--C.T.C --C.T.C
local scard=c26807032 local scard=c26807032
local id=26807032 local id=26807032
function c26807032.initial_effect(c) function c26807032.initial_effect(c)
--Activate --Activate
local e0=Effect.CreateEffect(c) local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_ACTIVATE) e0:SetType(EFFECT_TYPE_ACTIVATE)
e0:SetCode(EVENT_FREE_CHAIN) e0:SetCode(EVENT_FREE_CHAIN)
e0:SetCost(c26807032.cost) e0:SetCost(c26807032.cost)
e0:SetTarget(c26807032.regtg) e0:SetTarget(c26807032.regtg)
e0:SetOperation(c26807032.bgmop) e0:SetOperation(c26807032.bgmop)
c:RegisterEffect(e0) c:RegisterEffect(e0)
--cannot be destroyed --cannot be destroyed
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) e1:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_FZONE) e1:SetRange(LOCATION_FZONE)
e1:SetValue(1) e1:SetValue(1)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--cannot set/activate --cannot set/activate
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_CANNOT_SSET) e2:SetCode(EFFECT_CANNOT_SSET)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE)
e2:SetRange(LOCATION_FZONE) e2:SetRange(LOCATION_FZONE)
e2:SetTargetRange(1,0) e2:SetTargetRange(1,0)
e2:SetTarget(c26807032.setlimit) e2:SetTarget(c26807032.setlimit)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD) e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_CANNOT_ACTIVATE) e3:SetCode(EFFECT_CANNOT_ACTIVATE)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE) e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE)
e3:SetRange(LOCATION_FZONE) e3:SetRange(LOCATION_FZONE)
e3:SetTargetRange(1,0) e3:SetTargetRange(1,0)
e3:SetValue(c26807032.actlimit) e3:SetValue(c26807032.actlimit)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--cannot release --cannot release
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD) e4:SetType(EFFECT_TYPE_FIELD)
e4:SetCode(EFFECT_CANNOT_RELEASE) e4:SetCode(EFFECT_CANNOT_RELEASE)
e4:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e4:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e4:SetRange(LOCATION_FZONE) e4:SetRange(LOCATION_FZONE)
e4:SetTargetRange(0,1) e4:SetTargetRange(0,1)
e4:SetTarget(c26807032.rellimit) e4:SetTarget(c26807032.rellimit)
c:RegisterEffect(e4) c:RegisterEffect(e4)
--spsummon --spsummon
local e5=Effect.CreateEffect(c) local e5=Effect.CreateEffect(c)
e5:SetDescription(aux.Stringid(26807032,1)) e5:SetDescription(aux.Stringid(26807032,1))
e5:SetCategory(CATEGORY_SPECIAL_SUMMON) e5:SetCategory(CATEGORY_SPECIAL_SUMMON)
e5:SetType(EFFECT_TYPE_QUICK_O) e5:SetType(EFFECT_TYPE_QUICK_O)
e5:SetCode(EVENT_FREE_CHAIN) e5:SetCode(EVENT_FREE_CHAIN)
e5:SetRange(LOCATION_FZONE) e5:SetRange(LOCATION_FZONE)
e5:SetProperty(EFFECT_FLAG_CARD_TARGET) e5:SetProperty(EFFECT_FLAG_CARD_TARGET)
e5:SetCountLimit(1,26807032) e5:SetCountLimit(1,26807032)
e5:SetCost(c26807032.spcost) e5:SetCost(c26807032.spcost)
e5:SetTarget(c26807032.sptg) e5:SetTarget(c26807032.sptg)
e5:SetOperation(c26807032.spop) e5:SetOperation(c26807032.spop)
c:RegisterEffect(e5) c:RegisterEffect(e5)
--todeck --todeck
local e6=Effect.CreateEffect(c) local e6=Effect.CreateEffect(c)
e6:SetDescription(aux.Stringid(26807032,2)) e6:SetDescription(aux.Stringid(26807032,2))
e6:SetCategory(CATEGORY_TOGRAVE) e6:SetCategory(CATEGORY_TOGRAVE)
e6:SetType(EFFECT_TYPE_QUICK_O) e6:SetType(EFFECT_TYPE_QUICK_O)
e6:SetCode(EVENT_FREE_CHAIN) e6:SetCode(EVENT_FREE_CHAIN)
e6:SetRange(LOCATION_FZONE) e6:SetRange(LOCATION_FZONE)
e6:SetProperty(EFFECT_FLAG_CARD_TARGET) e6:SetProperty(EFFECT_FLAG_CARD_TARGET)
e6:SetCountLimit(1,26807932) e6:SetCountLimit(1,26807932)
e6:SetCost(c26807032.spcost) e6:SetCost(c26807032.spcost)
e6:SetTarget(c26807032.tdtg) e6:SetTarget(c26807032.tdtg)
e6:SetOperation(c26807032.tdop) e6:SetOperation(c26807032.tdop)
c:RegisterEffect(e6) c:RegisterEffect(e6)
if scard.counter==nil then if scard.counter==nil then
scard.counter=true scard.counter=true
scard[0]=0 scard[0]=0
scard[1]=0 scard[1]=0
local ea=Effect.CreateEffect(c) local ea=Effect.CreateEffect(c)
ea:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD) ea:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
ea:SetCode(EVENT_PHASE_START+PHASE_DRAW) ea:SetCode(EVENT_PHASE_START+PHASE_DRAW)
ea:SetOperation(scard.resetcount) ea:SetOperation(scard.resetcount)
Duel.RegisterEffect(ea,0) Duel.RegisterEffect(ea,0)
local eb=Effect.CreateEffect(c) local eb=Effect.CreateEffect(c)
eb:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD) eb:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
eb:SetCode(EVENT_RELEASE) eb:SetCode(EVENT_RELEASE)
eb:SetOperation(scard.addcount) eb:SetOperation(scard.addcount)
Duel.RegisterEffect(eb,0) Duel.RegisterEffect(eb,0)
end end
end end
function scard.resetcount(e,tp,eg,ep,ev,re,r,rp) function scard.resetcount(e,tp,eg,ep,ev,re,r,rp)
scard[0]=0 scard[0]=0
scard[1]=0 scard[1]=0
end end
function scard.addcount(e,tp,eg,ep,ev,re,r,rp) function scard.addcount(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst() local tc=eg:GetFirst()
while tc do while tc do
local p=tc:GetReasonPlayer() local p=tc:GetReasonPlayer()
scard[p]=scard[p]+1 scard[p]=scard[p]+1
tc=eg:GetNext() tc=eg:GetNext()
end end
end end
function c26807032.cfilter(c,tp) function c26807032.cfilter(c,tp)
return c:GetOwner()==1-tp and c:IsAbleToRemoveAsCost() return c:GetOwner()==1-tp and c:IsAbleToRemoveAsCost()
end end
function c26807032.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c26807032.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c26807032.cfilter,tp,LOCATION_ONFIELD,0,1,nil,tp) end if chk==0 then return Duel.IsExistingMatchingCard(c26807032.cfilter,tp,LOCATION_ONFIELD,0,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c26807032.cfilter,tp,LOCATION_ONFIELD,0,1,1,nil,tp) local g=Duel.SelectMatchingCard(tp,c26807032.cfilter,tp,LOCATION_ONFIELD,0,1,1,nil,tp)
Duel.Remove(g,POS_FACEDOWN,REASON_COST) Duel.Remove(g,POS_FACEDOWN,REASON_COST)
end end
function c26807032.setlimit(e,c,tp) function c26807032.setlimit(e,c,tp)
return c:IsType(TYPE_FIELD) return c:IsType(TYPE_FIELD)
end end
function c26807032.actlimit(e,re,tp) function c26807032.actlimit(e,re,tp)
return re:IsActiveType(TYPE_FIELD) and re:IsHasType(EFFECT_TYPE_ACTIVATE) return re:IsActiveType(TYPE_FIELD) and re:IsHasType(EFFECT_TYPE_ACTIVATE)
end end
function c26807032.regtg(e,tp,eg,ep,ev,re,r,rp,chk) function c26807032.regtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then if chk==0 then
return true return true
end end
local c=e:GetHandler() local c=e:GetHandler()
--to grave --to grave
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EVENT_PHASE+PHASE_END) e1:SetCode(EVENT_PHASE+PHASE_END)
e1:SetCountLimit(1) e1:SetCountLimit(1)
e1:SetRange(LOCATION_FZONE) e1:SetRange(LOCATION_FZONE)
e1:SetCondition(c26807032.gycon) e1:SetCondition(c26807032.gycon)
e1:SetOperation(c26807032.gyop) e1:SetOperation(c26807032.gyop)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:SetTurnCounter(0) c:SetTurnCounter(0)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function c26807032.gycon(e,tp,eg,ep,ev,re,r,rp) function c26807032.gycon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp return Duel.GetTurnPlayer()==tp
end end
function c26807032.gyop(e,tp,eg,ep,ev,re,r,rp) function c26807032.gyop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local ct=c:GetTurnCounter() local ct=c:GetTurnCounter()
ct=ct+1 ct=ct+1
c:SetTurnCounter(ct) c:SetTurnCounter(ct)
if ct==4 then if ct==4 then
Duel.SendtoGrave(c,REASON_RULE) Duel.SendtoGrave(c,REASON_RULE)
end end
end end
function c26807032.bgmop(e,tp,eg,ep,ev,re,r,rp) function c26807032.bgmop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_MUSIC,0,aux.Stringid(26807032,0)) Duel.Hint(HINT_MUSIC,0,aux.Stringid(26807032,0))
end end
function c26807032.rellimit(e,c,tp,sumtp) function c26807032.rellimit(e,c,tp,sumtp)
return c:GetOwner()==e:GetHandler():GetOwner() and c:IsType(TYPE_MONSTER) return c:GetOwner()==e:GetHandler():GetOwner() and c:IsType(TYPE_MONSTER)
end end
function c26807032.spcost(e,tp,eg,ep,ev,re,r,rp,chk) function c26807032.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c26807032.cfilter,tp,LOCATION_ONFIELD,0,1,nil,tp) end if chk==0 then return Duel.IsExistingMatchingCard(c26807032.cfilter,tp,LOCATION_ONFIELD,0,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c26807032.cfilter,tp,LOCATION_ONFIELD,0,1,1,nil,tp) local g=Duel.SelectMatchingCard(tp,c26807032.cfilter,tp,LOCATION_ONFIELD,0,1,1,nil,tp)
Duel.Remove(g,POS_FACEUP,REASON_COST) if Duel.IsPlayerAffectedByEffect(tp,26807041) then
end Duel.Remove(g,POS_FACEDOWN,REASON_COST)
function c26807032.spfilter(c,e,tp) else
return c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) Duel.Remove(g,POS_FACEUP,REASON_COST)
end end
function c26807032.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) end
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c26807032.spfilter(chkc,e,tp) end function c26807032.spfilter(c,e,tp)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 return c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
and Duel.IsExistingMatchingCard(c26807032.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) function c26807032.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local g=Duel.SelectTarget(tp,c26807032.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c26807032.spfilter(chkc,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0) if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
end and Duel.IsExistingMatchingCard(c26807032.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
function c26807032.spop(e,tp,eg,ep,ev,re,r,rp) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tc=Duel.GetFirstTarget() local g=Duel.SelectTarget(tp,c26807032.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
if tc:IsRelateToEffect(e) then Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP) end
end function c26807032.spop(e,tp,eg,ep,ev,re,r,rp)
end local tc=Duel.GetFirstTarget()
function c26807032.tdfilter(c) if tc:IsRelateToEffect(e) then
return c:IsAbleToGrave() Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end end
function c26807032.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) end
if chkc then return chkc:IsOnField() and c26807032.tdfilter(chkc) end function c26807032.tdfilter(c)
if chk==0 then return Duel.IsExistingTarget(c26807032.tdfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end return c:IsAbleToGrave()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) end
local g=Duel.SelectTarget(tp,c26807032.tdfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil) function c26807032.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,g,1,0,0) if chkc then return chkc:IsOnField() and c26807032.tdfilter(chkc) end
Duel.SetChainLimit(c26807032.limit(g:GetFirst())) if chk==0 then return Duel.IsExistingTarget(c26807032.tdfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
end Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
function c26807032.tdop(e,tp,eg,ep,ev,re,r,rp) local g=Duel.SelectTarget(tp,c26807032.tdfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
local tc=Duel.GetFirstTarget() Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,g,1,0,0)
if tc:IsRelateToEffect(e) then Duel.SetChainLimit(c26807032.limit(g:GetFirst()))
Duel.SendtoGrave(tc,REASON_EFFECT) end
end function c26807032.tdop(e,tp,eg,ep,ev,re,r,rp)
end local tc=Duel.GetFirstTarget()
function c26807032.limit(c) if tc:IsRelateToEffect(e) then
return function (e,lp,tp) Duel.SendtoGrave(tc,REASON_EFFECT)
return e:GetHandler()~=c end
end end
end function c26807032.limit(c)
return function (e,lp,tp)
return e:GetHandler()~=c
end
end
--炼狱骑士团 暗刃龙 --炼狱骑士团 暗刃龙
function c40008674.initial_effect(c) function c40008674.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(40008674,0)) e1:SetDescription(aux.Stringid(40008674,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_EQUIP) e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_EQUIP)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,40008674) e1:SetCountLimit(1,40008674)
e1:SetCost(c40008674.cost1) e1:SetCost(c40008674.cost1)
e1:SetCondition(c40008674.spcon1) e1:SetCondition(c40008674.spcon1)
e1:SetTarget(c40008674.target) e1:SetTarget(c40008674.target)
e1:SetOperation(c40008674.activate) e1:SetOperation(c40008674.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--to hand --to hand
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(40008674,2)) e4:SetDescription(aux.Stringid(40008674,2))
e4:SetCategory(CATEGORY_DRAW) e4:SetCategory(CATEGORY_DRAW)
e4:SetType(EFFECT_TYPE_IGNITION) e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetRange(LOCATION_GRAVE) e4:SetRange(LOCATION_GRAVE)
e4:SetCost(c40008674.thcost) e4:SetCost(c40008674.thcost)
e4:SetCountLimit(1,40008675) e4:SetCountLimit(1,40008675)
e4:SetTarget(c40008674.thtg) e4:SetTarget(c40008674.thtg)
e4:SetOperation(c40008674.thop) e4:SetOperation(c40008674.thop)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c40008674.spcon1(e,tp,eg,ep,ev,re,r,rp) function c40008674.spcon1(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsPlayerAffectedByEffect(tp,40008677) return not Duel.IsPlayerAffectedByEffect(tp,40008677)
end end
function c40008674.spcon2(e,tp,eg,ep,ev,re,r,rp) function c40008674.spcon2(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()~=e:GetHandlerPlayer() return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()~=e:GetHandlerPlayer()
end end
function c40008674.spcon3(e,tp,eg,ep,ev,re,r,rp) function c40008674.spcon3(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()==e:GetHandlerPlayer() return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()==e:GetHandlerPlayer()
end end
function c40008674.cosfilter3(c) function c40008674.cosfilter3(c)
return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost() return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost()
end end
function c40008674.cost3(e,tp,eg,ep,ev,re,r,rp,chk) function c40008674.cost3(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c40008674.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c40008674.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c40008674.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c40008674.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil)
Duel.SendtoGrave(g,REASON_COST) Duel.SendtoGrave(g,REASON_COST)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008674.tgop) e2:SetOperation(c40008674.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008674.cost1(e,tp,eg,ep,ev,re,r,rp,chk) function c40008674.cost1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler()) end if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler()) end
Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD) Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008674.tgop) e2:SetOperation(c40008674.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008674.cosfilter1(c,tp) function c40008674.cosfilter1(c,tp)
if c:IsLocation(LOCATION_HAND) then return c:IsDiscardable() end if c:IsLocation(LOCATION_HAND) then return c:IsDiscardable() end
return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost() return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost()
end end
function c40008674.cosfilter2(c) function c40008674.cosfilter2(c)
return c:IsCode(40008674) and c:IsAbleToRemoveAsCost() return c:IsCode(40008674) and c:IsAbleToRemoveAsCost()
end end
function c40008674.cost2(e,tp,eg,ep,ev,re,r,rp,chk) function c40008674.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c40008674.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,1,nil,tp) and Duel.IsExistingMatchingCard(c40008674.cosfilter2,tp,LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c40008674.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,1,nil,tp) and Duel.IsExistingMatchingCard(c40008674.cosfilter2,tp,LOCATION_GRAVE,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c40008674.cosfilter2,tp,LOCATION_GRAVE,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c40008674.cosfilter2,tp,LOCATION_GRAVE,0,1,1,nil)
local g1=Duel.GetMatchingGroup(c40008674.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,nil,tp) local g1=Duel.GetMatchingGroup(c40008674.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,nil,tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
local tc=g1:Select(tp,1,1,nil):GetFirst() local tc=g1:Select(tp,1,1,nil):GetFirst()
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
Duel.SendtoGrave(tc,REASON_COST) Duel.SendtoGrave(tc,REASON_COST)
else else
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
Duel.SendtoGrave(tc,REASON_COST+REASON_DISCARD) Duel.SendtoGrave(tc,REASON_COST+REASON_DISCARD)
end end
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008674.tgop) e2:SetOperation(c40008674.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
end end
function c40008674.tgop(e,tp,eg,ep,ev,re,r,rp) function c40008674.tgop(e,tp,eg,ep,ev,re,r,rp)
local cid=Duel.GetChainInfo(ev,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(ev,CHAININFO_CHAIN_ID)
if cid~=e:GetLabel() then return end if cid~=e:GetLabel() then return end
if e:GetOwner():IsRelateToChain(ev) then if e:GetOwner():IsRelateToChain(ev) then
e:GetOwner():CancelToGrave(false) e:GetOwner():CancelToGrave(false)
end end
end end
function c40008674.target(e,tp,eg,ep,ev,re,r,rp,chk) function c40008674.target(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.IsPlayerCanSpecialSummonMonster(tp,40008676,0,0x4011,1100,0,2,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) end and Duel.IsPlayerCanSpecialSummonMonster(tp,40008676,0,0x4011,1100,0,2,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) 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,1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
end end
function c40008674.activate(e,tp,eg,ep,ev,re,r,rp) function c40008674.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0
or not Duel.IsPlayerCanSpecialSummonMonster(tp,40008676,0,0x4011,1100,0,2,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) then return end or not Duel.IsPlayerCanSpecialSummonMonster(tp,40008676,0,0x4011,1100,0,2,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) then return end
local token=Duel.CreateToken(tp,40008676) local token=Duel.CreateToken(tp,40008676)
if Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP) if Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP)
then then
Duel.Equip(tp,c,token) Duel.Equip(tp,c,token)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_EQUIP_LIMIT) e1:SetCode(EFFECT_EQUIP_LIMIT)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(c40008674.eqlimit) e1:SetValue(c40008674.eqlimit)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(40008674,1)) e2:SetDescription(aux.Stringid(40008674,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON) e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O) e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN) e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0,TIMING_BATTLE_START+TIMING_BATTLE_END) e2:SetHintTiming(0,TIMING_BATTLE_START+TIMING_BATTLE_END)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1) e2:SetReset(RESET_EVENT+RESETS_STANDARD)
e2:SetCondition(c40008674.sccon) e2:SetCountLimit(1)
e2:SetTarget(c40008674.sctg) e2:SetCondition(c40008674.sccon)
e2:SetOperation(c40008674.scop) e2:SetTarget(c40008674.sctg)
c:RegisterEffect(e2) e2:SetOperation(c40008674.scop)
local e3=Effect.CreateEffect(c) c:RegisterEffect(e2)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT) local e3=Effect.CreateEffect(c)
e3:SetRange(LOCATION_SZONE) e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT)
e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e3:SetRange(LOCATION_SZONE)
e3:SetTarget(c40008674.eftg) e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e3:SetLabelObject(e2) e3:SetTarget(c40008674.eftg)
c:RegisterEffect(e3) e3:SetLabelObject(e2)
else c:RegisterEffect(e3)
c:CancelToGrave(false) else
Duel.SpecialSummonComplete() c:CancelToGrave(false)
end Duel.SpecialSummonComplete()
end end
function c40008674.eqlimit(e,c) end
return c:GetControler()==e:GetHandlerPlayer() or e:GetHandler():GetEquipTarget()==c function c40008674.eqlimit(e,c)
end return c:GetControler()==e:GetHandlerPlayer() or e:GetHandler():GetEquipTarget()==c
function c40008674.eftg(e,c) end
return e:GetHandler():GetEquipTarget()==c function c40008674.eftg(e,c)
end return e:GetHandler():GetEquipTarget()==c
function c40008674.sccon(e,tp,eg,ep,ev,re,r,rp) end
local ph=Duel.GetCurrentPhase() function c40008674.sccon(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetTurnPlayer()==tp then local ph=Duel.GetCurrentPhase()
return (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE) if Duel.GetTurnPlayer()==tp then
else return (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE)
return (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE) or ph==PHASE_MAIN1 or ph==PHASE_MAIN2 else
end return (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE) or ph==PHASE_MAIN1 or ph==PHASE_MAIN2
end end
function c40008674.sctg(e,tp,eg,ep,ev,re,r,rp,chk) end
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,1,nil,e:GetHandler()) end function c40008674.sctg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) if chk==0 then return Duel.IsExistingMatchingCard(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,1,nil,e:GetHandler()) end
end Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
function c40008674.scop(e,tp,eg,ep,ev,re,r,rp) end
local c=e:GetHandler() function c40008674.scop(e,tp,eg,ep,ev,re,r,rp)
if c:GetControler()~=tp or not c:IsRelateToEffect(e) then return end local c=e:GetHandler()
local g=Duel.GetMatchingGroup(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,nil,c) if c:GetControler()~=tp or not c:IsRelateToEffect(e) then return end
if g:GetCount()>0 then local g=Duel.GetMatchingGroup(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,nil,c)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) if g:GetCount()>0 then
local sg=g:Select(tp,1,1,nil) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
Duel.SynchroSummon(tp,sg:GetFirst(),c) local sg=g:Select(tp,1,1,nil)
end Duel.SynchroSummon(tp,sg:GetFirst(),c)
end end
function c40008674.cfilter(c,tp) end
return c:IsSetCard(0xf14) and c:IsAbleToRemoveAsCost() function c40008674.cfilter(c,tp)
end return c:IsSetCard(0xf14) and c:IsAbleToRemoveAsCost()
function c40008674.thcost(e,tp,eg,ep,ev,re,r,rp,chk) end
local c=e:GetHandler() function c40008674.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return c:IsAbleToRemoveAsCost() local c=e:GetHandler()
and Duel.IsExistingMatchingCard(c40008674.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end if chk==0 then return c:IsAbleToRemoveAsCost()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) and Duel.IsExistingMatchingCard(c40008674.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end
local g=Duel.SelectMatchingCard(tp,c40008674.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
g:AddCard(c) local g=Duel.SelectMatchingCard(tp,c40008674.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp)
Duel.Remove(g,POS_FACEUP,REASON_COST) g:AddCard(c)
end Duel.Remove(g,POS_FACEUP,REASON_COST)
function c40008674.thtg(e,tp,eg,ep,ev,re,r,rp,chk) end
if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end function c40008674.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetTargetPlayer(tp) if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetTargetParam(1) Duel.SetTargetPlayer(tp)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1) Duel.SetTargetParam(1)
end Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
function c40008674.thop(e,tp,eg,ep,ev,re,r,rp) end
if Duel.Draw(tp,1,REASON_EFFECT)==0 then return end function c40008674.thop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetOperatedGroup():GetFirst() if Duel.Draw(tp,1,REASON_EFFECT)==0 then return end
if tc:IsSetCard(0xf14) then local tc=Duel.GetOperatedGroup():GetFirst()
if Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(40008674,3)) then if tc:IsSetCard(0xf14) then
Duel.ConfirmCards(1-tp,tc) if Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(40008674,3)) then
Duel.BreakEffect() Duel.ConfirmCards(1-tp,tc)
Duel.Draw(tp,1,REASON_EFFECT) Duel.BreakEffect()
end Duel.Draw(tp,1,REASON_EFFECT)
end end
end end
end
--炼狱骑士团 十字弓弩龙 --炼狱骑士团 十字弓弩龙
function c40008680.initial_effect(c) function c40008680.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(40008680,0)) e1:SetDescription(aux.Stringid(40008680,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_EQUIP) e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_EQUIP)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,40008680) e1:SetCountLimit(1,40008680)
e1:SetCost(c40008680.cost1) e1:SetCost(c40008680.cost1)
e1:SetCondition(c40008680.spcon1) e1:SetCondition(c40008680.spcon1)
e1:SetTarget(c40008680.target) e1:SetTarget(c40008680.target)
e1:SetOperation(c40008680.activate) e1:SetOperation(c40008680.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--to hand --to hand
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(40008680,2)) e4:SetDescription(aux.Stringid(40008680,2))
e4:SetCategory(CATEGORY_DRAW) e4:SetCategory(CATEGORY_DRAW)
e4:SetType(EFFECT_TYPE_IGNITION) e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetRange(LOCATION_GRAVE) e4:SetRange(LOCATION_GRAVE)
e4:SetCost(c40008680.thcost) e4:SetCost(c40008680.thcost)
e4:SetCountLimit(1,40008681) e4:SetCountLimit(1,40008681)
e4:SetTarget(c40008680.destg) e4:SetTarget(c40008680.destg)
e4:SetOperation(c40008680.desop) e4:SetOperation(c40008680.desop)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c40008680.spcon1(e,tp,eg,ep,ev,re,r,rp) function c40008680.spcon1(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsPlayerAffectedByEffect(tp,40008677) return not Duel.IsPlayerAffectedByEffect(tp,40008677)
end end
function c40008680.spcon2(e,tp,eg,ep,ev,re,r,rp) function c40008680.spcon2(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()~=e:GetHandlerPlayer() return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()~=e:GetHandlerPlayer()
end end
function c40008680.spcon3(e,tp,eg,ep,ev,re,r,rp) function c40008680.spcon3(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()==e:GetHandlerPlayer() return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()==e:GetHandlerPlayer()
end end
function c40008680.cosfilter3(c) function c40008680.cosfilter3(c)
return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost() return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost()
end end
function c40008680.cost3(e,tp,eg,ep,ev,re,r,rp,chk) function c40008680.cost3(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c40008680.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c40008680.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c40008680.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c40008680.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil)
Duel.SendtoGrave(g,REASON_COST) Duel.SendtoGrave(g,REASON_COST)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008680.tgop) e2:SetOperation(c40008680.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008680.cost1(e,tp,eg,ep,ev,re,r,rp,chk) function c40008680.cost1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler()) end if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler()) end
Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD) Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008680.tgop) e2:SetOperation(c40008680.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008680.cosfilter1(c,tp) function c40008680.cosfilter1(c,tp)
if c:IsLocation(LOCATION_HAND) then return c:IsDiscardable() end if c:IsLocation(LOCATION_HAND) then return c:IsDiscardable() end
return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost() return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost()
end end
function c40008680.cosfilter2(c) function c40008680.cosfilter2(c)
return c:IsCode(40008680) and c:IsAbleToRemoveAsCost() return c:IsCode(40008680) and c:IsAbleToRemoveAsCost()
end end
function c40008680.cost2(e,tp,eg,ep,ev,re,r,rp,chk) function c40008680.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c40008680.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,1,nil,tp) and Duel.IsExistingMatchingCard(c40008680.cosfilter2,tp,LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c40008680.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,1,nil,tp) and Duel.IsExistingMatchingCard(c40008680.cosfilter2,tp,LOCATION_GRAVE,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c40008680.cosfilter2,tp,LOCATION_GRAVE,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c40008680.cosfilter2,tp,LOCATION_GRAVE,0,1,1,nil)
local g1=Duel.GetMatchingGroup(c40008680.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,nil,tp) local g1=Duel.GetMatchingGroup(c40008680.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,nil,tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
local tc=g1:Select(tp,1,1,nil):GetFirst() local tc=g1:Select(tp,1,1,nil):GetFirst()
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
Duel.SendtoGrave(tc,REASON_COST) Duel.SendtoGrave(tc,REASON_COST)
else else
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
Duel.SendtoGrave(tc,REASON_COST+REASON_DISCARD) Duel.SendtoGrave(tc,REASON_COST+REASON_DISCARD)
end end
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008680.tgop) e2:SetOperation(c40008680.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
end end
function c40008680.tgop(e,tp,eg,ep,ev,re,r,rp) function c40008680.tgop(e,tp,eg,ep,ev,re,r,rp)
local cid=Duel.GetChainInfo(ev,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(ev,CHAININFO_CHAIN_ID)
if cid~=e:GetLabel() then return end if cid~=e:GetLabel() then return end
if e:GetOwner():IsRelateToChain(ev) then if e:GetOwner():IsRelateToChain(ev) then
e:GetOwner():CancelToGrave(false) e:GetOwner():CancelToGrave(false)
end end
end end
function c40008680.target(e,tp,eg,ep,ev,re,r,rp,chk) function c40008680.target(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.IsPlayerCanSpecialSummonMonster(tp,40008682,0,0x4011,1300,0,3,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) end and Duel.IsPlayerCanSpecialSummonMonster(tp,40008682,0,0x4011,1300,0,3,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) 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,1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
end end
function c40008680.activate(e,tp,eg,ep,ev,re,r,rp) function c40008680.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0
or not Duel.IsPlayerCanSpecialSummonMonster(tp,40008682,0,0x4011,1300,0,3,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) then return end or not Duel.IsPlayerCanSpecialSummonMonster(tp,40008682,0,0x4011,1300,0,3,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) then return end
local token=Duel.CreateToken(tp,40008682) local token=Duel.CreateToken(tp,40008682)
if Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP) if Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP)
then then
Duel.Equip(tp,c,token) Duel.Equip(tp,c,token)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_EQUIP_LIMIT) e1:SetCode(EFFECT_EQUIP_LIMIT)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(c40008680.eqlimit) e1:SetValue(c40008680.eqlimit)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(40008680,1)) e2:SetDescription(aux.Stringid(40008680,1))
e2:SetCategory(CATEGORY_TOHAND) e2:SetCategory(CATEGORY_TOHAND)
e2:SetType(EFFECT_TYPE_QUICK_O) e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN) e2:SetCode(EVENT_FREE_CHAIN)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET) e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1) e2:SetReset(RESET_EVENT+RESETS_STANDARD)
e2:SetTarget(c40008680.thtg) e2:SetCountLimit(1)
e2:SetOperation(c40008680.thop) e2:SetTarget(c40008680.thtg)
c:RegisterEffect(e2) e2:SetOperation(c40008680.thop)
local e3=Effect.CreateEffect(c) c:RegisterEffect(e2)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT) local e3=Effect.CreateEffect(c)
e3:SetRange(LOCATION_SZONE) e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT)
e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e3:SetRange(LOCATION_SZONE)
e3:SetTarget(c40008680.eftg) e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e3:SetLabelObject(e2) e3:SetTarget(c40008680.eftg)
c:RegisterEffect(e3) e3:SetLabelObject(e2)
else c:RegisterEffect(e3)
c:CancelToGrave(false) else
Duel.SpecialSummonComplete() c:CancelToGrave(false)
end Duel.SpecialSummonComplete()
end end
function c40008680.eqlimit(e,c) end
return c:GetControler()==e:GetHandlerPlayer() or e:GetHandler():GetEquipTarget()==c function c40008680.eqlimit(e,c)
end return c:GetControler()==e:GetHandlerPlayer() or e:GetHandler():GetEquipTarget()==c
function c40008680.eftg(e,c) end
return e:GetHandler():GetEquipTarget()==c function c40008680.eftg(e,c)
end return e:GetHandler():GetEquipTarget()==c
function c40008680.thfilter(c) end
return c:IsFaceup() and c:IsAbleToHand() function c40008680.thfilter(c)
end return c:IsFaceup() and c:IsAbleToHand()
function c40008680.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) end
if chkc then return chkc:IsOnField() and chkc:IsControler(1-tp) and c40008680.thfilter(chkc) end function c40008680.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingTarget(c40008680.thfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end if chkc then return chkc:IsOnField() and chkc:IsControler(1-tp) and c40008680.thfilter(chkc) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) if chk==0 then return Duel.IsExistingTarget(c40008680.thfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
local g=Duel.SelectTarget(tp,c40008680.thfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0) local g=Duel.SelectTarget(tp,c40008680.thfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
end Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
function c40008680.thop(e,tp,eg,ep,ev,re,r,rp) end
local tc=Duel.GetFirstTarget() function c40008680.thop(e,tp,eg,ep,ev,re,r,rp)
if tc:IsRelateToEffect(e) then local tc=Duel.GetFirstTarget()
Duel.SendtoHand(tc,nil,REASON_EFFECT) if tc:IsRelateToEffect(e) then
end Duel.SendtoHand(tc,nil,REASON_EFFECT)
end end
function c40008680.cfilter(c,tp) end
return c:IsSetCard(0xf14) and c:IsAbleToRemoveAsCost() function c40008680.cfilter(c,tp)
end return c:IsSetCard(0xf14) and c:IsAbleToRemoveAsCost()
function c40008680.thcost(e,tp,eg,ep,ev,re,r,rp,chk) end
local c=e:GetHandler() function c40008680.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return c:IsAbleToRemoveAsCost() local c=e:GetHandler()
and Duel.IsExistingMatchingCard(c40008680.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end if chk==0 then return c:IsAbleToRemoveAsCost()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) and Duel.IsExistingMatchingCard(c40008680.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end
local g=Duel.SelectMatchingCard(tp,c40008680.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
g:AddCard(c) local g=Duel.SelectMatchingCard(tp,c40008680.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp)
Duel.Remove(g,POS_FACEUP,REASON_COST) g:AddCard(c)
end Duel.Remove(g,POS_FACEUP,REASON_COST)
function c40008680.filter(c) end
return c:IsFacedown() function c40008680.filter(c)
end return c:IsFacedown()
function c40008680.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) end
if chkc then return chkc:IsOnField() and c40008680.filter(chkc) end function c40008680.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingTarget(c40008680.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end if chkc then return chkc:IsOnField() and c40008680.filter(chkc) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) if chk==0 then return Duel.IsExistingTarget(c40008680.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
local g=Duel.SelectTarget(tp,c40008680.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0) local g=Duel.SelectTarget(tp,c40008680.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
end Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
function c40008680.desop(e,tp,eg,ep,ev,re,r,rp) end
local tc=Duel.GetFirstTarget() function c40008680.desop(e,tp,eg,ep,ev,re,r,rp)
if tc:IsRelateToEffect(e) then local tc=Duel.GetFirstTarget()
if Duel.Destroy(tc,REASON_EFFECT)==0 then return end if tc:IsRelateToEffect(e) then
local tc=Duel.GetOperatedGroup():GetFirst() if Duel.Destroy(tc,REASON_EFFECT)==0 then return end
if tc:IsType(TYPE_SPELL) then local tc=Duel.GetOperatedGroup():GetFirst()
if Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(40008680,3)) then if tc:IsType(TYPE_SPELL) then
Duel.ConfirmCards(1-tp,tc) if Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(40008680,3)) then
Duel.BreakEffect() Duel.ConfirmCards(1-tp,tc)
Duel.Draw(tp,1,REASON_EFFECT) Duel.BreakEffect()
end Duel.Draw(tp,1,REASON_EFFECT)
end end
end end
end end
end
--炼狱骑士团 银杖龙 --炼狱骑士团 银杖龙
function c40008683.initial_effect(c) function c40008683.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(40008683,0)) e1:SetDescription(aux.Stringid(40008683,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_EQUIP) e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_EQUIP)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,40008683) e1:SetCountLimit(1,40008683)
e1:SetCost(c40008683.cost1) e1:SetCost(c40008683.cost1)
e1:SetCondition(c40008683.spcon1) e1:SetCondition(c40008683.spcon1)
e1:SetTarget(c40008683.target) e1:SetTarget(c40008683.target)
e1:SetOperation(c40008683.activate) e1:SetOperation(c40008683.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--to hand --to hand
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(40008683,2)) e4:SetDescription(aux.Stringid(40008683,2))
e4:SetType(EFFECT_TYPE_IGNITION) e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetProperty(EFFECT_FLAG_CARD_TARGET) e4:SetProperty(EFFECT_FLAG_CARD_TARGET)
e4:SetRange(LOCATION_GRAVE) e4:SetRange(LOCATION_GRAVE)
e4:SetCost(c40008683.thcost) e4:SetCost(c40008683.thcost)
e4:SetCountLimit(1,40008684) e4:SetCountLimit(1,40008684)
e2:SetCondition(c40008683.dbcon) e2:SetCondition(c40008683.dbcon)
e4:SetTarget(c40008683.dbtg) e4:SetTarget(c40008683.dbtg)
e4:SetOperation(c40008683.dbop) e4:SetOperation(c40008683.dbop)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c40008683.spcon1(e,tp,eg,ep,ev,re,r,rp) function c40008683.spcon1(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsPlayerAffectedByEffect(tp,40008677) return not Duel.IsPlayerAffectedByEffect(tp,40008677)
end end
function c40008683.spcon2(e,tp,eg,ep,ev,re,r,rp) function c40008683.spcon2(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()~=tp return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()~=tp
end end
function c40008683.spcon3(e,tp,eg,ep,ev,re,r,rp) function c40008683.spcon3(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,40008677) and not Duel.GetTurnPlayer()~=tp return Duel.IsPlayerAffectedByEffect(tp,40008677) and not Duel.GetTurnPlayer()~=tp
end end
function c40008683.cosfilter3(c) function c40008683.cosfilter3(c)
return c:IsSetCard(0xf14) and (c:IsAbleToGraveAsCost() or c:IsDiscardable()) return c:IsSetCard(0xf14) and (c:IsAbleToGraveAsCost() or c:IsDiscardable())
end end
function c40008683.cost3(e,tp,eg,ep,ev,re,r,rp,chk) function c40008683.cost3(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c40008683.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c40008683.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c40008683.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c40008683.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil)
Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD) Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008683.tgop) e2:SetOperation(c40008683.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008683.cost1(e,tp,eg,ep,ev,re,r,rp,chk) function c40008683.cost1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler()) end if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler()) end
Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD) Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008683.tgop) e2:SetOperation(c40008683.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008683.cosfilter1(c) function c40008683.cosfilter1(c)
return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost() return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost()
end end
function c40008683.cosfilter2(c) function c40008683.cosfilter2(c)
return c:IsCode(40008683) and c:IsAbleToRemoveAsCost() return c:IsCode(40008683) and c:IsAbleToRemoveAsCost()
end end
function c40008683.cost2(e,tp,eg,ep,ev,re,r,rp,chk) function c40008683.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c40008683.cosfilter1,tp,LOCATION_DECK,0,1,nil) and Duel.IsExistingMatchingCard(c40008683.cosfilter2,tp,LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c40008683.cosfilter1,tp,LOCATION_DECK,0,1,nil) and Duel.IsExistingMatchingCard(c40008683.cosfilter2,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c40008683.cosfilter2,tp,LOCATION_GRAVE,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c40008683.cosfilter2,tp,LOCATION_GRAVE,0,1,1,nil)
local g1=Duel.SelectMatchingCard(tp,c40008683.cosfilter1,tp,LOCATION_DECK,0,1,1,nil) local g1=Duel.SelectMatchingCard(tp,c40008683.cosfilter1,tp,LOCATION_DECK,0,1,1,nil)
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
Duel.SendtoGrave(g1,REASON_COST) Duel.SendtoGrave(g1,REASON_COST)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008683.tgop) e2:SetOperation(c40008683.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008683.tgop(e,tp,eg,ep,ev,re,r,rp) function c40008683.tgop(e,tp,eg,ep,ev,re,r,rp)
local cid=Duel.GetChainInfo(ev,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(ev,CHAININFO_CHAIN_ID)
if cid~=e:GetLabel() then return end if cid~=e:GetLabel() then return end
if e:GetOwner():IsRelateToChain(ev) then if e:GetOwner():IsRelateToChain(ev) then
e:GetOwner():CancelToGrave(false) e:GetOwner():CancelToGrave(false)
end end
end end
function c40008683.target(e,tp,eg,ep,ev,re,r,rp,chk) function c40008683.target(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.IsPlayerCanSpecialSummonMonster(tp,40008685,0,0x4011,700,0,1,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) end and Duel.IsPlayerCanSpecialSummonMonster(tp,40008685,0,0x4011,700,0,1,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) 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,1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
end end
function c40008683.activate(e,tp,eg,ep,ev,re,r,rp) function c40008683.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0
or not Duel.IsPlayerCanSpecialSummonMonster(tp,40008685,0,0x4011,700,0,1,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) then return end or not Duel.IsPlayerCanSpecialSummonMonster(tp,40008685,0,0x4011,700,0,1,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) then return end
local token=Duel.CreateToken(tp,40008685) local token=Duel.CreateToken(tp,40008685)
if Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP) if Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP)
then then
Duel.Equip(tp,c,token) Duel.Equip(tp,c,token)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_EQUIP_LIMIT) e1:SetCode(EFFECT_EQUIP_LIMIT)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(c40008683.eqlimit) e1:SetValue(c40008683.eqlimit)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(40008683,1)) e2:SetDescription(aux.Stringid(40008683,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON) e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O) e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN) e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0,TIMING_BATTLE_START+TIMING_BATTLE_END) e2:SetHintTiming(0,TIMING_BATTLE_START+TIMING_BATTLE_END)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1) e2:SetReset(RESET_EVENT+RESETS_STANDARD)
e2:SetCondition(c40008683.sccon) e2:SetCountLimit(1)
e2:SetTarget(c40008683.sctg) e2:SetCondition(c40008683.sccon)
e2:SetOperation(c40008683.scop) e2:SetTarget(c40008683.sctg)
c:RegisterEffect(e2) e2:SetOperation(c40008683.scop)
local e3=Effect.CreateEffect(c) c:RegisterEffect(e2)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT) local e3=Effect.CreateEffect(c)
e3:SetRange(LOCATION_SZONE) e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT)
e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e3:SetRange(LOCATION_SZONE)
e3:SetTarget(c40008683.eftg) e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e3:SetLabelObject(e2) e3:SetTarget(c40008683.eftg)
c:RegisterEffect(e3) e3:SetLabelObject(e2)
else c:RegisterEffect(e3)
c:CancelToGrave(false) else
Duel.SpecialSummonComplete() c:CancelToGrave(false)
end Duel.SpecialSummonComplete()
end end
function c40008683.eqlimit(e,c) end
return c:GetControler()==e:GetHandlerPlayer() or e:GetHandler():GetEquipTarget()==c function c40008683.eqlimit(e,c)
end return c:GetControler()==e:GetHandlerPlayer() or e:GetHandler():GetEquipTarget()==c
function c40008683.eftg(e,c) end
return e:GetHandler():GetEquipTarget()==c function c40008683.eftg(e,c)
end return e:GetHandler():GetEquipTarget()==c
function c40008683.sccon(e,tp,eg,ep,ev,re,r,rp) end
local ph=Duel.GetCurrentPhase() function c40008683.sccon(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetTurnPlayer()==tp then local ph=Duel.GetCurrentPhase()
return (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE) if Duel.GetTurnPlayer()==tp then
else return (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE)
return (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE) or ph==PHASE_MAIN1 or ph==PHASE_MAIN2 else
end return (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE) or ph==PHASE_MAIN1 or ph==PHASE_MAIN2
end end
function c40008683.sctg(e,tp,eg,ep,ev,re,r,rp,chk) end
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,1,nil,e:GetHandler()) end function c40008683.sctg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) if chk==0 then return Duel.IsExistingMatchingCard(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,1,nil,e:GetHandler()) end
end Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
function c40008683.scop(e,tp,eg,ep,ev,re,r,rp) end
local c=e:GetHandler() function c40008683.scop(e,tp,eg,ep,ev,re,r,rp)
if c:GetControler()~=tp or not c:IsRelateToEffect(e) then return end local c=e:GetHandler()
local g=Duel.GetMatchingGroup(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,nil,c) if c:GetControler()~=tp or not c:IsRelateToEffect(e) then return end
if g:GetCount()>0 then local g=Duel.GetMatchingGroup(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,nil,c)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) if g:GetCount()>0 then
local sg=g:Select(tp,1,1,nil) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
Duel.SynchroSummon(tp,sg:GetFirst(),c) local sg=g:Select(tp,1,1,nil)
end Duel.SynchroSummon(tp,sg:GetFirst(),c)
end end
function c40008683.cfilter(c,tp) end
return c:IsSetCard(0xf14) and c:IsAbleToRemoveAsCost() function c40008683.cfilter(c,tp)
end return c:IsSetCard(0xf14) and c:IsAbleToRemoveAsCost()
function c40008683.thcost(e,tp,eg,ep,ev,re,r,rp,chk) end
local c=e:GetHandler() function c40008683.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return c:IsAbleToRemoveAsCost() local c=e:GetHandler()
and Duel.IsExistingMatchingCard(c40008683.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end if chk==0 then return c:IsAbleToRemoveAsCost()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) and Duel.IsExistingMatchingCard(c40008683.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end
local g=Duel.SelectMatchingCard(tp,c40008683.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
g:AddCard(c) local g=Duel.SelectMatchingCard(tp,c40008683.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp)
Duel.Remove(g,POS_FACEUP,REASON_COST) g:AddCard(c)
end Duel.Remove(g,POS_FACEUP,REASON_COST)
function c40008683.dbcon(e,tp,eg,ep,ev,re,r,rp) end
return Duel.IsAbleToEnterBP() function c40008683.dbcon(e,tp,eg,ep,ev,re,r,rp)
end return Duel.IsAbleToEnterBP()
function c40008683.dbfilter(c) end
return c:IsFaceup() and c:GetFlagEffect(40008683)==0 function c40008683.dbfilter(c)
end return c:IsFaceup() and c:GetFlagEffect(40008683)==0
function c40008683.dbtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) end
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c40008683.dbfilter(chkc) end function c40008683.dbtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingTarget(c40008683.dbfilter,tp,LOCATION_MZONE,0,1,nil) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c40008683.dbfilter(chkc) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) if chk==0 then return Duel.IsExistingTarget(c40008683.dbfilter,tp,LOCATION_MZONE,0,1,nil) end
Duel.SelectTarget(tp,c40008683.dbfilter,tp,LOCATION_MZONE,0,1,1,nil) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
end Duel.SelectTarget(tp,c40008683.dbfilter,tp,LOCATION_MZONE,0,1,1,nil)
function c40008683.dbop(e,tp,eg,ep,ev,re,r,rp) end
local c=e:GetHandler() function c40008683.dbop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local c=e:GetHandler()
local e1=Effect.CreateEffect(c) local tc=Duel.GetFirstTarget()
e1:SetType(EFFECT_TYPE_FIELD) local e1=Effect.CreateEffect(c)
e1:SetCode(EFFECT_CANNOT_ATTACK) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetTargetRange(LOCATION_MZONE,0) e1:SetCode(EFFECT_CANNOT_ATTACK)
e1:SetTarget(c40008683.ftarget) e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetLabel(tc:GetFieldID()) e1:SetTarget(c40008683.ftarget)
e1:SetReset(RESET_PHASE+PHASE_END) e1:SetLabel(tc:GetFieldID())
Duel.RegisterEffect(e1,tp) e1:SetReset(RESET_PHASE+PHASE_END)
if tc:IsRelateToEffect(e) then Duel.RegisterEffect(e1,tp)
local e2=Effect.CreateEffect(c) if tc:IsRelateToEffect(e) then
e2:SetType(EFFECT_TYPE_SINGLE) local e2=Effect.CreateEffect(c)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DIRECT_ATTACK) e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e2:SetCode(EFFECT_DIRECT_ATTACK)
tc:RegisterEffect(e2) e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
end tc:RegisterEffect(e2)
if tc:IsSetCard(0xf14) then end
if Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(40008683,3)) then if tc:IsSetCard(0xf14) then
Duel.ConfirmCards(1-tp,tc) if Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(40008683,3)) then
Duel.BreakEffect() Duel.ConfirmCards(1-tp,tc)
Duel.Draw(tp,1,REASON_EFFECT) Duel.BreakEffect()
end Duel.Draw(tp,1,REASON_EFFECT)
end end
end end
function c40008683.ftarget(e,c) end
return e:GetLabel()~=c:GetFieldID() function c40008683.ftarget(e,c)
end return e:GetLabel()~=c:GetFieldID()
end
--炼狱骑士团 血斧龙 --炼狱骑士团 血斧龙
function c40008688.initial_effect(c) function c40008688.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(40008688,0)) e1:SetDescription(aux.Stringid(40008688,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_EQUIP) e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_EQUIP)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,40008688) e1:SetCountLimit(1,40008688)
e1:SetCost(c40008688.cost1) e1:SetCost(c40008688.cost1)
e1:SetCondition(c40008688.spcon1) e1:SetCondition(c40008688.spcon1)
e1:SetTarget(c40008688.target) e1:SetTarget(c40008688.target)
e1:SetOperation(c40008688.activate) e1:SetOperation(c40008688.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--to hand --to hand
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(40008688,2)) e4:SetDescription(aux.Stringid(40008688,2))
e4:SetCategory(CATEGORY_DRAW) e4:SetCategory(CATEGORY_DRAW)
e4:SetType(EFFECT_TYPE_IGNITION) e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetRange(LOCATION_GRAVE) e4:SetRange(LOCATION_GRAVE)
e4:SetCost(c40008688.thcost) e4:SetCost(c40008688.thcost)
e4:SetCountLimit(1,40008689) e4:SetCountLimit(1,40008689)
e4:SetTarget(c40008688.destg) e4:SetTarget(c40008688.destg)
e4:SetOperation(c40008688.desop) e4:SetOperation(c40008688.desop)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c40008688.spcon1(e,tp,eg,ep,ev,re,r,rp) function c40008688.spcon1(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsPlayerAffectedByEffect(tp,40008677) return not Duel.IsPlayerAffectedByEffect(tp,40008677)
end end
function c40008688.spcon2(e,tp,eg,ep,ev,re,r,rp) function c40008688.spcon2(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()~=e:GetHandlerPlayer() return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()~=e:GetHandlerPlayer()
end end
function c40008688.spcon3(e,tp,eg,ep,ev,re,r,rp) function c40008688.spcon3(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()==e:GetHandlerPlayer() return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()==e:GetHandlerPlayer()
end end
function c40008688.cosfilter3(c) function c40008688.cosfilter3(c)
return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost() return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost()
end end
function c40008688.cost3(e,tp,eg,ep,ev,re,r,rp,chk) function c40008688.cost3(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c40008688.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c40008688.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c40008688.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c40008688.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil)
Duel.SendtoGrave(g,REASON_COST) Duel.SendtoGrave(g,REASON_COST)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008688.tgop) e2:SetOperation(c40008688.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008688.cost1(e,tp,eg,ep,ev,re,r,rp,chk) function c40008688.cost1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler()) end if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler()) end
Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD) Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008688.tgop) e2:SetOperation(c40008688.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008688.cosfilter1(c,tp) function c40008688.cosfilter1(c,tp)
if c:IsLocation(LOCATION_HAND) then return c:IsDiscardable() end if c:IsLocation(LOCATION_HAND) then return c:IsDiscardable() end
return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost() return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost()
end end
function c40008688.cosfilter2(c) function c40008688.cosfilter2(c)
return c:IsCode(40008688) and c:IsAbleToRemoveAsCost() return c:IsCode(40008688) and c:IsAbleToRemoveAsCost()
end end
function c40008688.cost2(e,tp,eg,ep,ev,re,r,rp,chk) function c40008688.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c40008688.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,1,nil,tp) and Duel.IsExistingMatchingCard(c40008688.cosfilter2,tp,LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c40008688.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,1,nil,tp) and Duel.IsExistingMatchingCard(c40008688.cosfilter2,tp,LOCATION_GRAVE,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c40008688.cosfilter2,tp,LOCATION_GRAVE,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c40008688.cosfilter2,tp,LOCATION_GRAVE,0,1,1,nil)
local g1=Duel.GetMatchingGroup(c40008688.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,nil,tp) local g1=Duel.GetMatchingGroup(c40008688.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,nil,tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
local tc=g1:Select(tp,1,1,nil):GetFirst() local tc=g1:Select(tp,1,1,nil):GetFirst()
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
Duel.SendtoGrave(tc,REASON_COST) Duel.SendtoGrave(tc,REASON_COST)
else else
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
Duel.SendtoGrave(tc,REASON_COST+REASON_DISCARD) Duel.SendtoGrave(tc,REASON_COST+REASON_DISCARD)
end end
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008688.tgop) e2:SetOperation(c40008688.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
end end
function c40008688.tgop(e,tp,eg,ep,ev,re,r,rp) function c40008688.tgop(e,tp,eg,ep,ev,re,r,rp)
local cid=Duel.GetChainInfo(ev,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(ev,CHAININFO_CHAIN_ID)
if cid~=e:GetLabel() then return end if cid~=e:GetLabel() then return end
if e:GetOwner():IsRelateToChain(ev) then if e:GetOwner():IsRelateToChain(ev) then
e:GetOwner():CancelToGrave(false) e:GetOwner():CancelToGrave(false)
end end
end end
function c40008688.target(e,tp,eg,ep,ev,re,r,rp,chk) function c40008688.target(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.IsPlayerCanSpecialSummonMonster(tp,40008690,0,0x4011,1500,0,4,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) end and Duel.IsPlayerCanSpecialSummonMonster(tp,40008690,0,0x4011,1500,0,4,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) 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,1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
end end
function c40008688.activate(e,tp,eg,ep,ev,re,r,rp) function c40008688.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0
or not Duel.IsPlayerCanSpecialSummonMonster(tp,40008690,0,0x4011,1500,0,4,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) then return end or not Duel.IsPlayerCanSpecialSummonMonster(tp,40008690,0,0x4011,1500,0,4,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) then return end
local token=Duel.CreateToken(tp,40008690) local token=Duel.CreateToken(tp,40008690)
if Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP) if Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP)
then then
Duel.Equip(tp,c,token) Duel.Equip(tp,c,token)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_EQUIP_LIMIT) e1:SetCode(EFFECT_EQUIP_LIMIT)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(c40008688.eqlimit) e1:SetValue(c40008688.eqlimit)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(40008688,1)) e2:SetDescription(aux.Stringid(40008688,1))
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1) e2:SetReset(RESET_EVENT+RESETS_STANDARD)
e2:SetTarget(c40008688.thtg) e2:SetCountLimit(1)
e2:SetOperation(c40008688.thop) e2:SetTarget(c40008688.thtg)
c:RegisterEffect(e2) e2:SetOperation(c40008688.thop)
local e3=Effect.CreateEffect(c) c:RegisterEffect(e2)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT) local e3=Effect.CreateEffect(c)
e3:SetRange(LOCATION_SZONE) e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT)
e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e3:SetRange(LOCATION_SZONE)
e3:SetTarget(c40008688.eftg) e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e3:SetLabelObject(e2) e3:SetTarget(c40008688.eftg)
c:RegisterEffect(e3) e3:SetLabelObject(e2)
else c:RegisterEffect(e3)
c:CancelToGrave(false) else
Duel.SpecialSummonComplete() c:CancelToGrave(false)
end Duel.SpecialSummonComplete()
end end
function c40008688.eqlimit(e,c) end
return c:GetControler()==e:GetHandlerPlayer() or e:GetHandler():GetEquipTarget()==c function c40008688.eqlimit(e,c)
end return c:GetControler()==e:GetHandlerPlayer() or e:GetHandler():GetEquipTarget()==c
function c40008688.eftg(e,c) end
return e:GetHandler():GetEquipTarget()==c function c40008688.eftg(e,c)
end return e:GetHandler():GetEquipTarget()==c
function c40008688.thfilter(c) end
return c:IsSetCard(0xf14) and not c:IsCode(40008688) and c:IsAbleToHand() function c40008688.thfilter(c)
end return c:IsSetCard(0xf14) and not c:IsCode(40008688) and c:IsAbleToHand()
function c40008688.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) end
if chk==0 then return true end function c40008688.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) if chk==0 then return true end
end Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
function c40008688.thop(e,tp,eg,ep,ev,re,r,rp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) function c40008688.thop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.SelectMatchingCard(tp,c40008688.thfilter,tp,LOCATION_DECK,0,1,1,nil) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
if g:GetCount()>0 then local g=Duel.SelectMatchingCard(tp,c40008688.thfilter,tp,LOCATION_DECK,0,1,1,nil)
Duel.SendtoHand(g,nil,REASON_EFFECT) if g:GetCount()>0 then
Duel.ConfirmCards(1-tp,g) Duel.SendtoHand(g,nil,REASON_EFFECT)
end Duel.ConfirmCards(1-tp,g)
end end
function c40008688.cfilter(c,tp) end
return c:IsSetCard(0xf14) and c:IsAbleToRemoveAsCost() function c40008688.cfilter(c,tp)
end return c:IsSetCard(0xf14) and c:IsAbleToRemoveAsCost()
function c40008688.thcost(e,tp,eg,ep,ev,re,r,rp,chk) end
local c=e:GetHandler() function c40008688.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return c:IsAbleToRemoveAsCost() local c=e:GetHandler()
and Duel.IsExistingMatchingCard(c40008688.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end if chk==0 then return c:IsAbleToRemoveAsCost()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) and Duel.IsExistingMatchingCard(c40008688.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end
local g=Duel.SelectMatchingCard(tp,c40008688.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
g:AddCard(c) local g=Duel.SelectMatchingCard(tp,c40008688.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp)
Duel.Remove(g,POS_FACEUP,REASON_COST) g:AddCard(c)
end Duel.Remove(g,POS_FACEUP,REASON_COST)
function c40008688.filter(c) end
return c:IsFaceup() function c40008688.filter(c)
end return c:IsFaceup()
function c40008688.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) end
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c40008688.filter(chkc) end function c40008688.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingTarget(c40008688.filter,tp,LOCATION_MZONE,0,1,nil) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c40008688.filter(chkc) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) if chk==0 then return Duel.IsExistingTarget(c40008688.filter,tp,LOCATION_MZONE,0,1,nil) end
Duel.SelectTarget(tp,c40008688.filter,tp,LOCATION_MZONE,0,1,1,nil) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
end Duel.SelectTarget(tp,c40008688.filter,tp,LOCATION_MZONE,0,1,1,nil)
end end
function c40008688.desop(e,tp,eg,ep,ev,re,r,rp) end
local c=e:GetHandler() function c40008688.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local c=e:GetHandler()
if tc:IsRelateToEffect(e) and tc:IsFaceup() and tc:IsControler(tp) then local tc=Duel.GetFirstTarget()
local e1=Effect.CreateEffect(c) if tc:IsRelateToEffect(e) and tc:IsFaceup() and tc:IsControler(tp) then
e1:SetType(EFFECT_TYPE_SINGLE) local e1=Effect.CreateEffect(c)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetRange(LOCATION_MZONE) e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetCode(EFFECT_IMMUNE_EFFECT) e1:SetRange(LOCATION_MZONE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e1:SetCode(EFFECT_IMMUNE_EFFECT)
e1:SetValue(c40008688.efilter) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
e1:SetOwnerPlayer(tp) e1:SetValue(c40008688.efilter)
tc:RegisterEffect(e1) e1:SetOwnerPlayer(tp)
end tc:RegisterEffect(e1)
if tc:IsSetCard(0xf14) then end
if Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(40008688,3)) then if tc:IsSetCard(0xf14) then
Duel.ConfirmCards(1-tp,tc) if Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(40008688,3)) then
Duel.BreakEffect() Duel.ConfirmCards(1-tp,tc)
Duel.Draw(tp,1,REASON_EFFECT) Duel.BreakEffect()
end Duel.Draw(tp,1,REASON_EFFECT)
end end
end end
function c40008688.efilter(e,re) end
return e:GetOwnerPlayer()~=re:GetOwnerPlayer() function c40008688.efilter(e,re)
end return e:GetOwnerPlayer()~=re:GetOwnerPlayer()
end
--炼狱骑士团 巨剪龙 --炼狱骑士团 巨剪龙
function c40008694.initial_effect(c) function c40008694.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(40008694,0)) e1:SetDescription(aux.Stringid(40008694,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_EQUIP) e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_EQUIP)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,40008694) e1:SetCountLimit(1,40008694)
e1:SetCost(c40008694.cost1) e1:SetCost(c40008694.cost1)
e1:SetCondition(c40008694.spcon1) e1:SetCondition(c40008694.spcon1)
e1:SetTarget(c40008694.target) e1:SetTarget(c40008694.target)
e1:SetOperation(c40008694.activate) e1:SetOperation(c40008694.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--to hand --to hand
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(40008694,2)) e4:SetDescription(aux.Stringid(40008694,2))
e4:SetType(EFFECT_TYPE_IGNITION) e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetRange(LOCATION_GRAVE) e4:SetRange(LOCATION_GRAVE)
e4:SetProperty(EFFECT_FLAG_CARD_TARGET) e4:SetProperty(EFFECT_FLAG_CARD_TARGET)
e4:SetCost(c40008694.thcost) e4:SetCost(c40008694.thcost)
e4:SetCountLimit(1,40008695) e4:SetCountLimit(1,40008695)
e4:SetTarget(c40008694.thtg) e4:SetTarget(c40008694.thtg)
e4:SetOperation(c40008694.thop) e4:SetOperation(c40008694.thop)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c40008694.spcon1(e,tp,eg,ep,ev,re,r,rp) function c40008694.spcon1(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsPlayerAffectedByEffect(tp,40008677) return not Duel.IsPlayerAffectedByEffect(tp,40008677)
end end
function c40008694.spcon2(e,tp,eg,ep,ev,re,r,rp) function c40008694.spcon2(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()~=e:GetHandlerPlayer() return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()~=e:GetHandlerPlayer()
end end
function c40008694.spcon3(e,tp,eg,ep,ev,re,r,rp) function c40008694.spcon3(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()==e:GetHandlerPlayer() return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()==e:GetHandlerPlayer()
end end
function c40008694.cosfilter3(c) function c40008694.cosfilter3(c)
return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost() return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost()
end end
function c40008694.cost3(e,tp,eg,ep,ev,re,r,rp,chk) function c40008694.cost3(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c40008694.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c40008694.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c40008694.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c40008694.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil)
Duel.SendtoGrave(g,REASON_COST) Duel.SendtoGrave(g,REASON_COST)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008694.tgop) e2:SetOperation(c40008694.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008694.cost1(e,tp,eg,ep,ev,re,r,rp,chk) function c40008694.cost1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler()) end if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler()) end
Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD) Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008694.tgop) e2:SetOperation(c40008694.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008694.cosfilter1(c,tp) function c40008694.cosfilter1(c,tp)
if c:IsLocation(LOCATION_HAND) then return c:IsDiscardable() end if c:IsLocation(LOCATION_HAND) then return c:IsDiscardable() end
return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost() return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost()
end end
function c40008694.cosfilter2(c) function c40008694.cosfilter2(c)
return c:IsCode(40008694) and c:IsAbleToRemoveAsCost() return c:IsCode(40008694) and c:IsAbleToRemoveAsCost()
end end
function c40008694.cost2(e,tp,eg,ep,ev,re,r,rp,chk) function c40008694.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c40008694.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,1,nil,tp) and Duel.IsExistingMatchingCard(c40008694.cosfilter2,tp,LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c40008694.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,1,nil,tp) and Duel.IsExistingMatchingCard(c40008694.cosfilter2,tp,LOCATION_GRAVE,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c40008694.cosfilter2,tp,LOCATION_GRAVE,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c40008694.cosfilter2,tp,LOCATION_GRAVE,0,1,1,nil)
local g1=Duel.GetMatchingGroup(c40008694.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,nil,tp) local g1=Duel.GetMatchingGroup(c40008694.costfilter1,tp,LOCATION_HAND+LOCATION_DECK,0,nil,tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD)
local tc=g1:Select(tp,1,1,nil):GetFirst() local tc=g1:Select(tp,1,1,nil):GetFirst()
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
Duel.SendtoGrave(tc,REASON_COST) Duel.SendtoGrave(tc,REASON_COST)
else else
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
Duel.SendtoGrave(tc,REASON_COST+REASON_DISCARD) Duel.SendtoGrave(tc,REASON_COST+REASON_DISCARD)
end end
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008694.tgop) e2:SetOperation(c40008694.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
end end
function c40008694.tgop(e,tp,eg,ep,ev,re,r,rp) function c40008694.tgop(e,tp,eg,ep,ev,re,r,rp)
local cid=Duel.GetChainInfo(ev,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(ev,CHAININFO_CHAIN_ID)
if cid~=e:GetLabel() then return end if cid~=e:GetLabel() then return end
if e:GetOwner():IsRelateToChain(ev) then if e:GetOwner():IsRelateToChain(ev) then
e:GetOwner():CancelToGrave(false) e:GetOwner():CancelToGrave(false)
end end
end end
function c40008694.target(e,tp,eg,ep,ev,re,r,rp,chk) function c40008694.target(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.IsPlayerCanSpecialSummonMonster(tp,40008696,0,0x4011,1100,0,2,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) end and Duel.IsPlayerCanSpecialSummonMonster(tp,40008696,0,0x4011,1100,0,2,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) 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,1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
end end
function c40008694.activate(e,tp,eg,ep,ev,re,r,rp) function c40008694.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0
or not Duel.IsPlayerCanSpecialSummonMonster(tp,40008696,0,0x4011,1100,0,2,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) then return end or not Duel.IsPlayerCanSpecialSummonMonster(tp,40008696,0,0x4011,1100,0,2,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) then return end
local token=Duel.CreateToken(tp,40008696) local token=Duel.CreateToken(tp,40008696)
if Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP) if Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP)
then then
Duel.Equip(tp,c,token) Duel.Equip(tp,c,token)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_EQUIP_LIMIT) e1:SetCode(EFFECT_EQUIP_LIMIT)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(c40008694.eqlimit) e1:SetValue(c40008694.eqlimit)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(40008694,1)) e2:SetDescription(aux.Stringid(40008694,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON) e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O) e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN) e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0,TIMING_BATTLE_START+TIMING_BATTLE_END) e2:SetHintTiming(0,TIMING_BATTLE_START+TIMING_BATTLE_END)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1) e2:SetReset(RESET_EVENT+RESETS_STANDARD)
e2:SetCondition(c40008694.sccon) e2:SetCountLimit(1)
e2:SetTarget(c40008694.sctg) e2:SetCondition(c40008694.sccon)
e2:SetOperation(c40008694.scop) e2:SetTarget(c40008694.sctg)
c:RegisterEffect(e2) e2:SetOperation(c40008694.scop)
local e3=Effect.CreateEffect(c) c:RegisterEffect(e2)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT) local e3=Effect.CreateEffect(c)
e3:SetRange(LOCATION_SZONE) e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT)
e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e3:SetRange(LOCATION_SZONE)
e3:SetTarget(c40008694.eftg) e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e3:SetLabelObject(e2) e3:SetTarget(c40008694.eftg)
c:RegisterEffect(e3) e3:SetLabelObject(e2)
else c:RegisterEffect(e3)
c:CancelToGrave(false) else
Duel.SpecialSummonComplete() c:CancelToGrave(false)
end Duel.SpecialSummonComplete()
end end
function c40008694.eqlimit(e,c) end
return c:GetControler()==e:GetHandlerPlayer() or e:GetHandler():GetEquipTarget()==c function c40008694.eqlimit(e,c)
end return c:GetControler()==e:GetHandlerPlayer() or e:GetHandler():GetEquipTarget()==c
function c40008694.eftg(e,c) end
return e:GetHandler():GetEquipTarget()==c function c40008694.eftg(e,c)
end return e:GetHandler():GetEquipTarget()==c
function c40008694.sccon(e,tp,eg,ep,ev,re,r,rp) end
local ph=Duel.GetCurrentPhase() function c40008694.sccon(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetTurnPlayer()==tp then local ph=Duel.GetCurrentPhase()
return (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE) if Duel.GetTurnPlayer()==tp then
else return (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE)
return (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE) or ph==PHASE_MAIN1 or ph==PHASE_MAIN2 else
end return (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE) or ph==PHASE_MAIN1 or ph==PHASE_MAIN2
end end
function c40008694.sctg(e,tp,eg,ep,ev,re,r,rp,chk) end
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,1,nil,e:GetHandler()) end function c40008694.sctg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) if chk==0 then return Duel.IsExistingMatchingCard(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,1,nil,e:GetHandler()) end
end Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
function c40008694.scop(e,tp,eg,ep,ev,re,r,rp) end
local c=e:GetHandler() function c40008694.scop(e,tp,eg,ep,ev,re,r,rp)
if c:GetControler()~=tp or not c:IsRelateToEffect(e) then return end local c=e:GetHandler()
local g=Duel.GetMatchingGroup(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,nil,c) if c:GetControler()~=tp or not c:IsRelateToEffect(e) then return end
if g:GetCount()>0 then local g=Duel.GetMatchingGroup(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,nil,c)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) if g:GetCount()>0 then
local sg=g:Select(tp,1,1,nil) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
Duel.SynchroSummon(tp,sg:GetFirst(),c) local sg=g:Select(tp,1,1,nil)
end Duel.SynchroSummon(tp,sg:GetFirst(),c)
end end
function c40008694.cfilter(c,tp) end
return c:IsSetCard(0xf14) and c:IsAbleToRemoveAsCost() function c40008694.cfilter(c,tp)
end return c:IsSetCard(0xf14) and c:IsAbleToRemoveAsCost()
function c40008694.thcost(e,tp,eg,ep,ev,re,r,rp,chk) end
local c=e:GetHandler() function c40008694.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return c:IsAbleToRemoveAsCost() local c=e:GetHandler()
and Duel.IsExistingMatchingCard(c40008694.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end if chk==0 then return c:IsAbleToRemoveAsCost()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) and Duel.IsExistingMatchingCard(c40008694.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end
local g=Duel.SelectMatchingCard(tp,c40008694.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
g:AddCard(c) local g=Duel.SelectMatchingCard(tp,c40008694.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp)
Duel.Remove(g,POS_FACEUP,REASON_COST) g:AddCard(c)
end Duel.Remove(g,POS_FACEUP,REASON_COST)
function c40008694.thtg(e,tp,eg,ep,ev,re,r,rp,chk) end
if chkc then return chkc:IsLocation(LOCATION_MZONE) end function c40008694.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingTarget(nil,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end if chkc then return chkc:IsLocation(LOCATION_MZONE) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) if chk==0 then return Duel.IsExistingTarget(nil,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
Duel.SelectTarget(tp,nil,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
end Duel.SelectTarget(tp,nil,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
function c40008694.thop(e,tp,eg,ep,ev,re,r,rp) end
local c=e:GetHandler() function c40008694.thop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local c=e:GetHandler()
if tc:IsRelateToEffect(e) then local tc=Duel.GetFirstTarget()
local e1=Effect.CreateEffect(c) if tc:IsRelateToEffect(e) then
e1:SetType(EFFECT_TYPE_SINGLE) local e1=Effect.CreateEffect(c)
e1:SetCode(EFFECT_UNRELEASABLE_SUM) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetValue(1) e1:SetCode(EFFECT_UNRELEASABLE_SUM)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e1:SetValue(1)
tc:RegisterEffect(e1) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
local e2=e1:Clone() tc:RegisterEffect(e1)
e2:SetCode(EFFECT_UNRELEASABLE_NONSUM) local e2=e1:Clone()
tc:RegisterEffect(e2) e2:SetCode(EFFECT_UNRELEASABLE_NONSUM)
local e5=e1:Clone() tc:RegisterEffect(e2)
e5:SetCode(EFFECT_AVOID_BATTLE_DAMAGE) local e5=e1:Clone()
c:RegisterEffect(e5) e5:SetCode(EFFECT_AVOID_BATTLE_DAMAGE)
if tc:IsSetCard(0xf14) then c:RegisterEffect(e5)
if Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(40008694,3)) then if tc:IsSetCard(0xf14) then
Duel.ConfirmCards(1-tp,tc) if Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(40008694,3)) then
Duel.BreakEffect() Duel.ConfirmCards(1-tp,tc)
Duel.Draw(tp,1,REASON_EFFECT) Duel.BreakEffect()
end Duel.Draw(tp,1,REASON_EFFECT)
end end
end end
end end
end
--炼狱骑士团 刚链索命龙 --炼狱骑士团 刚链索命龙
function c40008697.initial_effect(c) function c40008697.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(40008697,0)) e1:SetDescription(aux.Stringid(40008697,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_EQUIP) e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_EQUIP)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,40008697) e1:SetCountLimit(1,40008697)
e1:SetCost(c40008697.cost1) e1:SetCost(c40008697.cost1)
e1:SetCondition(c40008697.spcon1) e1:SetCondition(c40008697.spcon1)
e1:SetTarget(c40008697.target) e1:SetTarget(c40008697.target)
e1:SetOperation(c40008697.activate) e1:SetOperation(c40008697.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--to hand --to hand
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(40008697,2)) e4:SetDescription(aux.Stringid(40008697,2))
e4:SetType(EFFECT_TYPE_IGNITION) e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetProperty(EFFECT_FLAG_CARD_TARGET) e4:SetProperty(EFFECT_FLAG_CARD_TARGET)
e4:SetRange(LOCATION_GRAVE) e4:SetRange(LOCATION_GRAVE)
e4:SetCost(c40008697.thcost) e4:SetCost(c40008697.thcost)
e4:SetCountLimit(1,40008698) e4:SetCountLimit(1,40008698)
e2:SetCondition(c40008697.dbcon) e2:SetCondition(c40008697.dbcon)
e4:SetTarget(c40008697.dbtg) e4:SetTarget(c40008697.dbtg)
e4:SetOperation(c40008697.dbop) e4:SetOperation(c40008697.dbop)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c40008697.spcon1(e,tp,eg,ep,ev,re,r,rp) function c40008697.spcon1(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsPlayerAffectedByEffect(tp,40008677) return not Duel.IsPlayerAffectedByEffect(tp,40008677)
end end
function c40008697.spcon2(e,tp,eg,ep,ev,re,r,rp) function c40008697.spcon2(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()~=tp return Duel.IsPlayerAffectedByEffect(tp,40008677) and Duel.GetTurnPlayer()~=tp
end end
function c40008697.spcon3(e,tp,eg,ep,ev,re,r,rp) function c40008697.spcon3(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,40008677) and not Duel.GetTurnPlayer()~=tp return Duel.IsPlayerAffectedByEffect(tp,40008677) and not Duel.GetTurnPlayer()~=tp
end end
function c40008697.cosfilter3(c) function c40008697.cosfilter3(c)
return c:IsSetCard(0xf14) and (c:IsAbleToGraveAsCost() or c:IsDiscardable()) return c:IsSetCard(0xf14) and (c:IsAbleToGraveAsCost() or c:IsDiscardable())
end end
function c40008697.cost3(e,tp,eg,ep,ev,re,r,rp,chk) function c40008697.cost3(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c40008697.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c40008697.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c40008697.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c40008697.cosfilter3,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil)
Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD) Duel.SendtoGrave(g,REASON_COST+REASON_DISCARD)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008697.tgop) e2:SetOperation(c40008697.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008697.cost1(e,tp,eg,ep,ev,re,r,rp,chk) function c40008697.cost1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler()) end if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,e:GetHandler()) end
Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD) Duel.DiscardHand(tp,Card.IsDiscardable,1,1,REASON_COST+REASON_DISCARD)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008697.tgop) e2:SetOperation(c40008697.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008697.cosfilter1(c) function c40008697.cosfilter1(c)
return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost() return c:IsSetCard(0xf14) and c:IsAbleToGraveAsCost()
end end
function c40008697.cosfilter2(c) function c40008697.cosfilter2(c)
return c:IsCode(40008697) and c:IsAbleToRemoveAsCost() return c:IsCode(40008697) and c:IsAbleToRemoveAsCost()
end end
function c40008697.cost2(e,tp,eg,ep,ev,re,r,rp,chk) function c40008697.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c40008697.cosfilter1,tp,LOCATION_DECK,0,1,nil) and Duel.IsExistingMatchingCard(c40008697.cosfilter2,tp,LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c40008697.cosfilter1,tp,LOCATION_DECK,0,1,nil) and Duel.IsExistingMatchingCard(c40008697.cosfilter2,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c40008697.cosfilter2,tp,LOCATION_GRAVE,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c40008697.cosfilter2,tp,LOCATION_GRAVE,0,1,1,nil)
local g1=Duel.SelectMatchingCard(tp,c40008697.cosfilter1,tp,LOCATION_DECK,0,1,1,nil) local g1=Duel.SelectMatchingCard(tp,c40008697.cosfilter1,tp,LOCATION_DECK,0,1,1,nil)
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
Duel.SendtoGrave(g1,REASON_COST) Duel.SendtoGrave(g1,REASON_COST)
local c=e:GetHandler() local c=e:GetHandler()
local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_REMAIN_FIELD) e1:SetCode(EFFECT_REMAIN_FIELD)
e1:SetProperty(EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_OATH)
e1:SetReset(RESET_CHAIN) e1:SetReset(RESET_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_DISABLED) e2:SetCode(EVENT_CHAIN_DISABLED)
e2:SetOperation(c40008697.tgop) e2:SetOperation(c40008697.tgop)
e2:SetLabel(cid) e2:SetLabel(cid)
e2:SetReset(RESET_CHAIN) e2:SetReset(RESET_CHAIN)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
function c40008697.tgop(e,tp,eg,ep,ev,re,r,rp) function c40008697.tgop(e,tp,eg,ep,ev,re,r,rp)
local cid=Duel.GetChainInfo(ev,CHAININFO_CHAIN_ID) local cid=Duel.GetChainInfo(ev,CHAININFO_CHAIN_ID)
if cid~=e:GetLabel() then return end if cid~=e:GetLabel() then return end
if e:GetOwner():IsRelateToChain(ev) then if e:GetOwner():IsRelateToChain(ev) then
e:GetOwner():CancelToGrave(false) e:GetOwner():CancelToGrave(false)
end end
end end
function c40008697.target(e,tp,eg,ep,ev,re,r,rp,chk) function c40008697.target(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.IsPlayerCanSpecialSummonMonster(tp,40008699,0,0x4011,1900,0,5,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) end and Duel.IsPlayerCanSpecialSummonMonster(tp,40008699,0,0x4011,1900,0,5,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) 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,1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
end end
function c40008697.activate(e,tp,eg,ep,ev,re,r,rp) function c40008697.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0
or not Duel.IsPlayerCanSpecialSummonMonster(tp,40008699,0,0x4011,1900,0,5,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) then return end or not Duel.IsPlayerCanSpecialSummonMonster(tp,40008699,0,0x4011,1900,0,5,RACE_DRAGON,ATTRIBUTE_FIRE,POS_FACEUP) then return end
local token=Duel.CreateToken(tp,40008699) local token=Duel.CreateToken(tp,40008699)
if Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP) if Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP)
then then
Duel.Equip(tp,c,token) Duel.Equip(tp,c,token)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_EQUIP_LIMIT) e1:SetCode(EFFECT_EQUIP_LIMIT)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(c40008697.eqlimit) e1:SetValue(c40008697.eqlimit)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(40008697,1)) e2:SetDescription(aux.Stringid(40008697,1))
e2:SetCategory(CATEGORY_TOGRAVE) e2:SetCategory(CATEGORY_TOGRAVE)
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1) e2:SetReset(RESET_EVENT+RESETS_STANDARD)
e2:SetTarget(c40008688.thtg) e2:SetCountLimit(1)
e2:SetOperation(c40008688.thop) e2:SetTarget(c40008688.thtg)
c:RegisterEffect(e2) e2:SetOperation(c40008688.thop)
local e3=Effect.CreateEffect(c) c:RegisterEffect(e2)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT) local e3=Effect.CreateEffect(c)
e3:SetRange(LOCATION_SZONE) e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT)
e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e3:SetRange(LOCATION_SZONE)
e3:SetTarget(c40008697.eftg) e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e3:SetLabelObject(e2) e3:SetTarget(c40008697.eftg)
c:RegisterEffect(e3) e3:SetLabelObject(e2)
else c:RegisterEffect(e3)
c:CancelToGrave(false) else
Duel.SpecialSummonComplete() c:CancelToGrave(false)
end Duel.SpecialSummonComplete()
end end
function c40008697.eqlimit(e,c) end
return c:GetControler()==e:GetHandlerPlayer() or e:GetHandler():GetEquipTarget()==c function c40008697.eqlimit(e,c)
end return c:GetControler()==e:GetHandlerPlayer() or e:GetHandler():GetEquipTarget()==c
function c40008697.eftg(e,c) end
return e:GetHandler():GetEquipTarget()==c function c40008697.eftg(e,c)
end return e:GetHandler():GetEquipTarget()==c
function c40008697.thfilter(c) end
return c:IsSetCard(0xf14) and not c:IsCode(40008697) and c:IsAbleToGrave() function c40008697.thfilter(c)
end return c:IsSetCard(0xf14) and not c:IsCode(40008697) and c:IsAbleToGrave()
function c40008697.thtg(e,tp,eg,ep,ev,re,r,rp,chk) end
if chk==0 then return Duel.IsExistingMatchingCard(c40008697.thfilter,tp,LOCATION_DECK,0,1,nil) end function c40008697.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK) if chk==0 then return Duel.IsExistingMatchingCard(c40008697.thfilter,tp,LOCATION_DECK,0,1,nil) end
end Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK)
function c40008697.thop(e,tp,eg,ep,ev,re,r,rp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) function c40008697.thop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.SelectMatchingCard(tp,c40008697.thfilter,tp,LOCATION_DECK,0,1,1,nil) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
if g:GetCount()>0 then local g=Duel.SelectMatchingCard(tp,c40008697.thfilter,tp,LOCATION_DECK,0,1,1,nil)
Duel.SendtoGrave(g,REASON_EFFECT) if g:GetCount()>0 then
end Duel.SendtoGrave(g,REASON_EFFECT)
end end
function c40008697.cfilter(c,tp) end
return c:IsSetCard(0xf14) and c:IsAbleToRemoveAsCost() function c40008697.cfilter(c,tp)
end return c:IsSetCard(0xf14) and c:IsAbleToRemoveAsCost()
function c40008697.thcost(e,tp,eg,ep,ev,re,r,rp,chk) end
local c=e:GetHandler() function c40008697.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return c:IsAbleToRemoveAsCost() local c=e:GetHandler()
and Duel.IsExistingMatchingCard(c40008697.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end if chk==0 then return c:IsAbleToRemoveAsCost()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) and Duel.IsExistingMatchingCard(c40008697.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end
local g=Duel.SelectMatchingCard(tp,c40008697.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
g:AddCard(c) local g=Duel.SelectMatchingCard(tp,c40008697.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp)
Duel.Remove(g,POS_FACEUP,REASON_COST) g:AddCard(c)
end Duel.Remove(g,POS_FACEUP,REASON_COST)
function c40008697.dbcon(e,tp,eg,ep,ev,re,r,rp) end
return Duel.IsAbleToEnterBP() function c40008697.dbcon(e,tp,eg,ep,ev,re,r,rp)
end return Duel.IsAbleToEnterBP()
function c40008697.dbfilter(c) end
return c:IsFaceup() and c:GetFlagEffect(40008697)==0 function c40008697.dbfilter(c)
end return c:IsFaceup() and c:GetFlagEffect(40008697)==0
function c40008697.dbtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) end
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c40008697.dbfilter(chkc) end function c40008697.dbtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingTarget(c40008697.dbfilter,tp,LOCATION_MZONE,0,1,nil) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c40008697.dbfilter(chkc) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) if chk==0 then return Duel.IsExistingTarget(c40008697.dbfilter,tp,LOCATION_MZONE,0,1,nil) end
Duel.SelectTarget(tp,c40008697.dbfilter,tp,LOCATION_MZONE,0,1,1,nil) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
end Duel.SelectTarget(tp,c40008697.dbfilter,tp,LOCATION_MZONE,0,1,1,nil)
function c40008697.dbop(e,tp,eg,ep,ev,re,r,rp) end
local c=e:GetHandler() function c40008697.dbop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local c=e:GetHandler()
local e1=Effect.CreateEffect(c) local tc=Duel.GetFirstTarget()
e1:SetType(EFFECT_TYPE_FIELD) local e1=Effect.CreateEffect(c)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_ACTIVATE) e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(0,1) e1:SetCode(EFFECT_CANNOT_ACTIVATE)
e1:SetValue(c40008697.aclimit) e1:SetTargetRange(0,1)
e1:SetReset(RESET_PHASE+PHASE_DAMAGE) e1:SetValue(c40008697.aclimit)
Duel.RegisterEffect(e1,tp) e1:SetReset(RESET_PHASE+PHASE_DAMAGE)
if tc:IsSetCard(0xf14) then Duel.RegisterEffect(e1,tp)
if Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(40008697,3)) then if tc:IsSetCard(0xf14) then
Duel.ConfirmCards(1-tp,tc) if Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(40008697,3)) then
Duel.BreakEffect() Duel.ConfirmCards(1-tp,tc)
Duel.Draw(tp,1,REASON_EFFECT) Duel.BreakEffect()
end Duel.Draw(tp,1,REASON_EFFECT)
end end
end end
function c40008697.aclimit(e,re,tp) end
return re:IsActiveType(TYPE_TRAP) and re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsActiveType(TYPE_MONSTER) and not re:GetHandler():IsImmuneToEffect(e) function c40008697.aclimit(e,re,tp)
end return re:IsActiveType(TYPE_TRAP) and re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsActiveType(TYPE_MONSTER) and not re:GetHandler():IsImmuneToEffect(e)
end
...@@ -8,6 +8,7 @@ function cm.initial_effect(c) ...@@ -8,6 +8,7 @@ function cm.initial_effect(c)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_IGNITION) e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCountLimit(1,m) e1:SetCountLimit(1,m)
e1:SetTarget(function(e,tp,eg,ep,ev,re,r,rp,chk) e1:SetTarget(function(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(1-tp,LOCATION_SZONE,tp)>0 and Duel.IsExistingMatchingCard(difficulty_filter,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end if chk==0 then return Duel.GetLocationCount(1-tp,LOCATION_SZONE,tp)>0 and Duel.IsExistingMatchingCard(difficulty_filter,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end
...@@ -35,6 +36,7 @@ function cm.initial_effect(c) ...@@ -35,6 +36,7 @@ function cm.initial_effect(c)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_IMMUNE_EFFECT) e2:SetCode(EFFECT_IMMUNE_EFFECT)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(LOCATION_ONFIELD,LOCATION_ONFIELD) e2:SetTargetRange(LOCATION_ONFIELD,LOCATION_ONFIELD)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetTarget(function(e,c) e2:SetTarget(function(e,c)
...@@ -48,13 +50,15 @@ function cm.initial_effect(c) ...@@ -48,13 +50,15 @@ function cm.initial_effect(c)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e1:SetRange(LOCATION_SZONE) e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(1,0) e1:SetTargetRange(1,0)
e1:SetTarget(function(e,c,tp,sumtp,sumpos,top,te) e1:SetTarget(function(e,c,tp,sumtp,sumpos,top,te)
--Debug.Message(aux.GetValueType(te))
if not te then return false end if not te then return false end
local tc=te:GetHandler() local tc=te:GetHandler()
return tc and Kaguya.IsDifficulty(tc) --Debug.Message(tc and tc:GetCode() or 0)
return not tc or not Kaguya.IsDifficulty(tc)
end) end)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
...@@ -14,18 +14,22 @@ function c77765002.initial_effect(c) ...@@ -14,18 +14,22 @@ function c77765002.initial_effect(c)
-- --
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_IGNITION) e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetCategory(CATEGORY_TOGRAVE)
e1:SetRange(LOCATION_FZONE) e1:SetRange(LOCATION_FZONE)
e1:SetCountLimit(1) e1:SetCountLimit(1)
e1:SetTarget(function(e,tp,eg,ep,ev,re,r,rp,chk) e1:SetTarget(function(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(1-tp,LOCATION_SZONE,tp)>0 and Duel.IsExistingMatchingCard(c77765002.filter1,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil) end if chk==0 then return Duel.GetLocationCount(1-tp,LOCATION_SZONE,tp)>0 and Duel.IsExistingMatchingCard(c77765002.filter1,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,tp) end
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,LOCATION_DECK+LOCATION_HAND,tp)
end) end)
e1:SetOperation(function(e,tp,eg,ep,ev,re,r,rp) e1:SetOperation(function(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(1-tp,LOCATION_SZONE,tp)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,c77765002.filter1,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c77765002.filter1,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil,tp)
if #g==0 then return end
Duel.SendtoGrave(g,REASON_EFFECT) Duel.SendtoGrave(g,REASON_EFFECT)
if Duel.GetLocationCount(1-tp,LOCATION_SZONE,tp)<=0 then return end local sc=g:GetFirst()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local sg=Duel.SelectMatchingCard(tp,c77765002.filter2,tp,LOCATION_DECK,1,1,g:GetFirst(),g:GetFirst()) local sg=Duel.SelectMatchingCard(tp,c77765002.filter2,tp,LOCATION_DECK,0,1,1,sc,sc)
if #sg>0 then if #sg>0 then
local tc=sg:GetFirst() local tc=sg:GetFirst()
local te=tc:GetActivateEffect() local te=tc:GetActivateEffect()
...@@ -47,42 +51,42 @@ function c77765002.initial_effect(c) ...@@ -47,42 +51,42 @@ function c77765002.initial_effect(c)
e2:SetLabelObject(g) e2:SetLabelObject(g)
e2:SetOperation(c77765002.checkop) e2:SetOperation(c77765002.checkop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local function KaguyaFilter(c,e,tp) local function KaguyaFilter(c,e,tp,cc)
local ec=e:GetHandler()
local tc=Senya.GetDFCBackSideCard(ec)
local p=c:GetControler() local p=c:GetControler()
return c:IsFaceup() and c:IsCode(77765001) and tc:CheckEquipTarget(c) and Duel.GetLocationCount(p,LOCATION_SZONE,p)>0 local tc=Senya.GetDFCBackSideCard(cc)
return c:IsFaceup() and c:IsCode(77765001) and Duel.GetLocationCount(p,LOCATION_SZONE,tp)>0 and tc:CheckEquipTarget(c)
end end
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_TRIGGER_F+EFFECT_TYPE_SINGLE) e3:SetType(EFFECT_TYPE_TRIGGER_F+EFFECT_TYPE_SINGLE)
e3:SetCode(EVENT_LEAVE_FIELD) e3:SetCode(EVENT_LEAVE_FIELD)
e3:SetProperty(0x14000+EFFECT_FLAG_IGNORE_IMMUNE)
e3:SetTarget(function(e,tp,eg,ep,ev,re,r,rp,chk) e3:SetTarget(function(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
local g=c:GetLabelObject():GetLabelObject() local g=e:GetLabelObject():GetLabelObject()
local tg=g:Filter(function(c) local tg=g:Filter(function(c)
return Senya.IsDFCTransformable(c) and Duel.IsExistingMatchingCard(KaguyaFilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil,e,tp) return Senya.IsDFCTransformable(c) and Duel.IsExistingMatchingCard(KaguyaFilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil,e,tp,c)
end,nil) end,nil)
if chk==0 then return #g>0 end if chk==0 then return #tg>0 end
Duel.SetOperationInfo(0,CATEGORY_EQUIP,tg,#tg,0,0) Duel.SetOperationInfo(0,CATEGORY_EQUIP,tg,#tg,0,0)
end) end)
e3:SetOperation(function (e,tp,eg,ep,ev,re,r,rp) e3:SetOperation(function (e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local g=c:GetLabelObject():GetLabelObject() local g=e:GetLabelObject():GetLabelObject()
local tg=g:Filter(function(c) local tg=g:Filter(function(c)
return Senya.IsDFCTransformable(c) and Duel.IsExistingMatchingCard(KaguyaFilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil,e,tp) return Senya.IsDFCTransformable(c) and Duel.IsExistingMatchingCard(KaguyaFilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil,e,tp,c)
end,nil) end,nil)
for cc in aux.Next(tg) do for cc in aux.Next(tg) do
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
local g=Duel.SelectMatchingCard(tp,KaguyaFilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,KaguyaFilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil,e,tp,cc)
local tc=g:GetFirst() local tc=g:GetFirst()
local p=tc:GetControler() local p=tc:GetControler()
if p~=tp then if p~=cc:GetControler() then
Duel.MoveToField(cc,p,p,LOCATION_SZONE,POS_FACEUP,true) Duel.MoveToField(cc,p,p,LOCATION_SZONE,POS_FACEUP,true)
end end
Senya.TransformDFCCard(cc) Senya.TransformDFCCard(cc)
Duel.Equip(p,cc,tc) Duel.Equip(p,cc,tc)
end end
Duel.RaiseEvent(tg,EVENT_CUSTOM+m,re,r,rp,ep,ev) Duel.RaiseEvent(tg,EVENT_CUSTOM+77765000,re,r,rp,ep,ev)
end) end)
e3:SetLabelObject(e2) e3:SetLabelObject(e2)
c:RegisterEffect(e3) c:RegisterEffect(e3)
...@@ -107,7 +111,7 @@ function c77765002.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -107,7 +111,7 @@ function c77765002.activate(e,tp,eg,ep,ev,re,r,rp)
end end
end end
end end
function c77765002.filter1(c) function c77765002.filter1(c,tp)
return c:IsAbleToGrave() and Kaguya.IsDifficulty(c) and Duel.IsExistingMatchingCard(c77765002.filter2,tp,LOCATION_DECK,0,1,c,c) return c:IsAbleToGrave() and Kaguya.IsDifficulty(c) and Duel.IsExistingMatchingCard(c77765002.filter2,tp,LOCATION_DECK,0,1,c,c)
end end
function c77765002.filter2(c,mc) function c77765002.filter2(c,mc)
......
...@@ -11,8 +11,8 @@ function c77765003.initial_effect(c) ...@@ -11,8 +11,8 @@ function c77765003.initial_effect(c)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_SZONE)
e1:SetCode(EFFECT_SELF_TOGRAVE) e1:SetCode(EFFECT_SELF_DESTROY)
e1:SetCondition(cm.con) e1:SetCondition(cm.con)
c:RegisterEffect(e1) c:RegisterEffect(e1)
...@@ -21,7 +21,7 @@ function c77765003.initial_effect(c) ...@@ -21,7 +21,7 @@ function c77765003.initial_effect(c)
e2:SetCategory(CATEGORY_TOGRAVE) e2:SetCategory(CATEGORY_TOGRAVE)
e2:SetType(EFFECT_TYPE_QUICK_O) e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN) e2:SetCode(EVENT_FREE_CHAIN)
e2:SetCountLimit(1) e2:SetCountLimit(1,m)
e2:SetRange(LOCATION_SZONE) e2:SetRange(LOCATION_SZONE)
e2:SetCost(cm.sgcost) e2:SetCost(cm.sgcost)
e2:SetTarget(cm.sgtg) e2:SetTarget(cm.sgtg)
...@@ -34,7 +34,7 @@ function c77765003.initial_effect(c) ...@@ -34,7 +34,7 @@ function c77765003.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_SZONE) e2:SetRange(LOCATION_SZONE)
e2:SetCountLimit(1) e2:SetCountLimit(1,m+100)
e2:SetCost(cm.cost) e2:SetCost(cm.cost)
e2:SetTarget(cm.target) e2:SetTarget(cm.target)
e2:SetOperation(cm.operation) e2:SetOperation(cm.operation)
...@@ -44,7 +44,7 @@ function cm.filter1(c) ...@@ -44,7 +44,7 @@ function cm.filter1(c)
return c:IsCode(77765001) return c:IsCode(77765001)
end end
function cm.con(e) function cm.con(e)
return not Duel.IsExistingMatchingCard(cm.filter1,e:GetHandlerPlayer(),LOCATION_GRAVE,0,1,nil) return not Duel.IsExistingMatchingCard(cm.filter1,e:GetHandlerPlayer(),LOCATION_MZONE,0,1,nil)
end end
function cm.costfilter(c) function cm.costfilter(c)
return Kaguya.IsDifficulty(c) and c:IsDiscardable() return Kaguya.IsDifficulty(c) and c:IsDiscardable()
......
...@@ -60,15 +60,15 @@ end ...@@ -60,15 +60,15 @@ end
function cm.condition2(e,tp,eg,ep,ev,re,r,rp) function cm.condition2(e,tp,eg,ep,ev,re,r,rp)
local a=Duel.GetAttacker() local a=Duel.GetAttacker()
local d=Duel.GetAttackTarget() local d=Duel.GetAttackTarget()
return d~=nil and d:IsFaceup() and ((a:GetControler()==tp and a:IsCode(77765001) and a:IsRelateToBattle()) return d~=nil and d:IsFaceup() and ((a:IsCode(77765001) and a:IsRelateToBattle())
or (d:GetControler()==tp and d:IsCode(77765001) and d:IsRelateToBattle())) or (d:IsCode(77765001) and d:IsRelateToBattle()))
end end
function cm.operation2(e,tp,eg,ep,ev,re,r,rp,chk) function cm.operation2(e,tp,eg,ep,ev,re,r,rp,chk)
local a=Duel.GetAttacker() local a=Duel.GetAttacker()
local d=Duel.GetAttackTarget() local d=Duel.GetAttackTarget()
if not a:IsRelateToBattle() or not d:IsRelateToBattle() then return end if not a:IsRelateToBattle() or not d:IsRelateToBattle() then return end
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetOwnerPlayer(tp) --e1:SetOwnerPlayer(tp)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
......
...@@ -8,9 +8,9 @@ function cm.initial_effect(c) ...@@ -8,9 +8,9 @@ function cm.initial_effect(c)
ex:SetProperty(0) ex:SetProperty(0)
ex:SetCost(function(e,tp,eg,ep,ev,re,r,rp,chk) ex:SetCost(function(e,tp,eg,ep,ev,re,r,rp,chk)
local ct=Duel.GetFieldGroupCount(tp,LOCATION_HAND,0)-Duel.GetFieldGroupCount(tp,0,LOCATION_HAND) local ct=Duel.GetFieldGroupCount(tp,LOCATION_HAND,0)-Duel.GetFieldGroupCount(tp,0,LOCATION_HAND)
if chk==0 then return ct>0 and Duel.IsExistingMatchingCard(Card.IsAbleToDeckAsCost,tp,LOCATION_HAND,0,1,nil) end if chk==0 then return ct>0 and Duel.IsExistingMatchingCard(Card.IsAbleToDeckAsCost,tp,LOCATION_HAND,0,ct,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,Card.IsAbleToDeckAsCost,tp,LOCATION_HAND,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,Card.IsAbleToDeckAsCost,tp,LOCATION_HAND,0,ct,ct,nil)
Duel.SendtoDeck(g,nil,2,REASON_COST) Duel.SendtoDeck(g,nil,2,REASON_COST)
end) end)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
...@@ -22,22 +22,26 @@ function cm.initial_effect(c) ...@@ -22,22 +22,26 @@ function cm.initial_effect(c)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD) e4:SetType(EFFECT_TYPE_FIELD)
e4:SetCode(EFFECT_SPSUMMON_COUNT_LIMIT) e4:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e4:SetRange(LOCATION_SZONE) e4:SetRange(LOCATION_SZONE)
e4:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e4:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e4:SetTargetRange(1,0) e4:SetTargetRange(1,0)
e4:SetValue(1) e4:SetTarget(function(e,c,tp)
--local tp=e:GetHandlerPlayer()
return Duel.GetActivityCount(tp,ACTIVITY_SPSUMMON)>=Duel.GetFieldGroupCount(tp,0,LOCATION_HAND)
end)
c:RegisterEffect(e4) c:RegisterEffect(e4)
local e1=Effect.CreateEffect(c) --[[local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_ADJUST) e1:SetCode(EVENT_ADJUST)
e1:SetLabelObject(e4) e1:SetLabelObject(e4)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetRange(LOCATION_SZONE)
e1:SetOperation(function(e,tp,eg,ep,ev,re,r,rp) e1:SetOperation(function(e,tp,eg,ep,ev,re,r,rp)
local te=e:GetLabelObject() local te=e:GetLabelObject()
te:SetValue(Duel.GetFieldGroupCount(tp,0,LOCATION_HAND)) te:SetValue(Duel.GetFieldGroupCount(tp,0,LOCATION_HAND))
end) end)
c:RegisterEffect(e1) c:RegisterEffect(e1)]]
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD) e4:SetType(EFFECT_TYPE_FIELD)
e4:SetCode(EFFECT_DIRECT_ATTACK) e4:SetCode(EFFECT_DIRECT_ATTACK)
......
...@@ -44,7 +44,7 @@ function cm.initial_effect(c) ...@@ -44,7 +44,7 @@ function cm.initial_effect(c)
local code=e:GetLabelObject():GetOriginalCode() local code=e:GetLabelObject():GetOriginalCode()
local c=e:GetHandler() local c=e:GetHandler()
if c:IsFaceup() and c:IsRelateToEffect(e) then if c:IsFaceup() and c:IsRelateToEffect(e) then
c:CopyEffect(code+1,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,1) c:CopyEffect(code+1,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,2)
end end
end) end)
c:RegisterEffect(e4) c:RegisterEffect(e4)
......
...@@ -55,7 +55,7 @@ function cm.initial_effect(c) ...@@ -55,7 +55,7 @@ function cm.initial_effect(c)
end) end)
c:RegisterEffect(e2) c:RegisterEffect(e2)
for _,code in ipairs({ for _,code in ipairs({
EFFECT_PUBLIC, --EFFECT_PUBLIC,
EFFECT_CANNOT_TRIGGER, EFFECT_CANNOT_TRIGGER,
EFFECT_CANNOT_SSET, EFFECT_CANNOT_SSET,
EFFECT_CANNOT_MSET EFFECT_CANNOT_MSET
...@@ -68,7 +68,7 @@ function cm.initial_effect(c) ...@@ -68,7 +68,7 @@ function cm.initial_effect(c)
ex:SetTargetRange(LOCATION_HAND,LOCATION_HAND) ex:SetTargetRange(LOCATION_HAND,LOCATION_HAND)
ex:SetProperty(EFFECT_FLAG_SET_AVAILABLE) ex:SetProperty(EFFECT_FLAG_SET_AVAILABLE)
ex:SetTarget(function(e,c) ex:SetTarget(function(e,c)
return c:IsPublic() return c:IsHasEffect(EFFECT_PUBLIC)
end) end)
c:RegisterEffect(ex) c:RegisterEffect(ex)
end end
...@@ -76,7 +76,7 @@ function cm.initial_effect(c) ...@@ -76,7 +76,7 @@ function cm.initial_effect(c)
e3:SetType(EFFECT_TYPE_SINGLE) e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_SSET_COST) e3:SetCode(EFFECT_SSET_COST)
e3:SetCost(function(e,c,tp) e3:SetCost(function(e,c,tp)
return Duel.IsExistingMatchingCard(Card.IsAbleToChangeControler,tp,LOCATION_HAND,0,1,c) return Duel.IsExistingMatchingCard(Card.IsAbleToChangeControler,tp,LOCATION_HAND,0,1,c) and tp==e:GetHandlerPlayer()
end) end)
e3:SetOperation(function(e,tp,eg,ep,ev,re,r,rp) e3:SetOperation(function(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,0,m) Duel.Hint(HINT_CARD,0,m)
...@@ -91,7 +91,8 @@ function cm.initial_effect(c) ...@@ -91,7 +91,8 @@ function cm.initial_effect(c)
local e3_=Effect.CreateEffect(c) local e3_=Effect.CreateEffect(c)
e3_:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT) e3_:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT)
e3_:SetRange(LOCATION_SZONE) e3_:SetRange(LOCATION_SZONE)
e3_:SetTargetRange(LOCATION_HAND,LOCATION_HAND) e3_:SetProperty(EFFECT_TYPE_IGNORE_RANGE)
e3_:SetTargetRange(0xff,0xff)
e3_:SetLabelObject(e3) e3_:SetLabelObject(e3)
c:RegisterEffect(e3_) c:RegisterEffect(e3_)
local e3__=e3_:Clone() local e3__=e3_:Clone()
......
...@@ -19,21 +19,21 @@ function cm.initial_effect(c) ...@@ -19,21 +19,21 @@ function cm.initial_effect(c)
e1:SetRange(LOCATION_SZONE) e1:SetRange(LOCATION_SZONE)
e1:SetCategory(CATEGORY_REMOVE) e1:SetCategory(CATEGORY_REMOVE)
e1:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) e1:SetCondition(function(e,tp,eg,ep,ev,re,r,rp)
return ep==tp and eg:IsExists(function(c) return eg:IsExists(function(c)
return not c:IsReason(REASON_DRAW) return not c:IsReason(REASON_DRAW) and c:GetReasonPlayer()==tp
end,1,nil) end,1,nil)
end) end)
e1:SetTarget(function(e,tp,eg,ep,ev,re,r,rp,chk) e1:SetTarget(function(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
local g=eg:Filter(function(c) local g=eg:Filter(function(c)
return c:IsAbleToRemove() and not c:IsReason(REASON_DRAW) return c:IsAbleToRemove() and not c:IsReason(REASON_DRAW) and c:GetReasonPlayer()==tp
end,nil) end,nil)
Duel.SetTargetCard(g) Duel.SetTargetCard(g)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,g,#g,0,0) Duel.SetOperationInfo(0,CATEGORY_REMOVE,g,#g,0,0)
end) end)
e1:SetOperation(function(e,tp,eg,ep,ev,re,r,rp) e1:SetOperation(function(e,tp,eg,ep,ev,re,r,rp)
local g=eg:Filter(function(c) local g=eg:Filter(function(c)
return c:IsAbleToRemove() and not c:IsReason(REASON_DRAW) and c:IsRelateToEffect(e) return c:IsAbleToRemove() and not c:IsReason(REASON_DRAW) and c:IsRelateToEffect(e) and c:GetReasonPlayer()==tp
end,nil) end,nil)
Duel.Remove(g,POS_FACEDOWN,REASON_EFFECT) Duel.Remove(g,POS_FACEDOWN,REASON_EFFECT)
end) end)
......
...@@ -32,6 +32,28 @@ function cm.initial_effect(c) ...@@ -32,6 +32,28 @@ function cm.initial_effect(c)
e2:SetRange(LOCATION_SZONE) e2:SetRange(LOCATION_SZONE)
e2:SetOperation(cm.counter) e2:SetOperation(cm.counter)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetRange(LOCATION_SZONE)
e2:SetTargetRange(LOCATION_MZONE,0)
e2:SetTarget(function(e,c)
return c:IsFaceup()
end)
e2:SetValue(function(e,c)
return e:GetHandler():GetCounter(0x1)*-300
end)
c:RegisterEffect(e2)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_SELF_DESTROY)
e2:SetRange(LOCATION_SZONE)
e2:SetTargetRange(LOCATION_MZONE,0)
e2:SetTarget(function(e,c)
return c:IsFaceup() and c:IsAttack(0) and c:GetBaseAttack()>0
end)
e2:SetValue(1)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetDescription(m*16) e3:SetDescription(m*16)
e3:SetCategory(CATEGORY_SPECIAL_SUMMON) e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
......
--故障诊断·池袋晶叶
function c81007028.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLevel,10),1,1)
c:EnableReviveLimit()
--cannot special summon
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(1,0)
e1:SetTarget(c81007028.splimit)
c:RegisterEffect(e1)
--destroy replace
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_DESTROY_REPLACE)
e2:SetRange(LOCATION_MZONE)
e2:SetTarget(c81007028.reptg)
e2:SetValue(c81007028.repval)
c:RegisterEffect(e2)
end
function c81007028.splimit(e,c)
return c:GetRace()~=RACE_MACHINE
end
function c81007028.repfilter(c,tp)
return c:IsFaceup() and c:IsControler(tp) and c:IsLocation(LOCATION_MZONE) and c:IsRace(RACE_MACHINE) and c:IsReason(REASON_BATTLE+REASON_EFFECT) and not c:IsReason(REASON_REPLACE)
end
function c81007028.rmfilter(c)
return c:IsLevel(10) and c:IsType(TYPE_MONSTER) and c:IsAbleToRemove()
end
function c81007028.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return eg:IsExists(c81007028.repfilter,1,nil,tp)
and Duel.IsExistingMatchingCard(c81007028.rmfilter,tp,LOCATION_GRAVE,0,1,nil) end
if Duel.SelectEffectYesNo(tp,e:GetHandler(),96) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c81007028.rmfilter,tp,LOCATION_GRAVE,0,1,1,nil)
Duel.Remove(g,POS_FACEUP,REASON_EFFECT+REASON_REPLACE)
return true
end
return false
end
function c81007028.repval(e,c)
return c81007028.repfilter(c,e:GetHandlerPlayer())
end
function c81008003.initial_effect(c)
c:SetUniqueOnField(1,0,81008003)
--fusion material
c:EnableReviveLimit()
aux.AddFusionProcFunRep(c,c81008003.ffilter,3,false)
--spsummon condition
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION)
e1:SetValue(aux.fuslimit)
c:RegisterEffect(e1)
--immune
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetCode(EFFECT_IMMUNE_EFFECT)
e2:SetRange(LOCATION_MZONE)
e2:SetValue(c81008003.efilter)
c:RegisterEffect(e2)
--damage after destruction
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_DAMAGE)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_LEAVE_FIELD)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY+EFFECT_FLAG_PLAYER_TARGET)
e3:SetCountLimit(1,81008003)
e3:SetCondition(c81008003.damcon2)
e3:SetTarget(c81008003.damtg2)
e3:SetOperation(c81008003.damop2)
c:RegisterEffect(e3)
--cannot material
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_SINGLE)
e5:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e5:SetCode(EFFECT_CANNOT_BE_FUSION_MATERIAL)
e5:SetValue(1)
c:RegisterEffect(e5)
local e6=e5:Clone()
e6:SetCode(EFFECT_CANNOT_BE_SYNCHRO_MATERIAL)
c:RegisterEffect(e6)
local e7=e5:Clone()
e7:SetCode(EFFECT_CANNOT_BE_XYZ_MATERIAL)
c:RegisterEffect(e7)
local e8=e5:Clone()
e8:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
c:RegisterEffect(e8)
end
function c81008003.ffilter(c)
return c:IsLocation(LOCATION_MZONE) and c:GetSequence()<5 and not c:IsType(TYPE_TOKEN)
end
function c81008003.efilter(e,te)
return te:IsActiveType(TYPE_SPELL+TYPE_TRAP)
end
function c81008003.damcon2(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return (c:IsReason(REASON_BATTLE) or (c:GetReasonPlayer()==1-tp and c:IsReason(REASON_EFFECT)))
and c:IsPreviousPosition(POS_FACEUP)
end
function c81008003.damtg2(e,tp,eg,ep,ev,re,r,rp,chk)
local gc=Duel.GetMatchingGroupCount(nil,tp,LOCATION_GRAVE,0,nil)
if chk==0 then return gc>0 end
Duel.SetTargetPlayer(1-tp)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,gc*200)
end
function c81008003.damop2(e,tp,eg,ep,ev,re,r,rp)
local gc=Duel.GetMatchingGroupCount(nil,tp,LOCATION_GRAVE,0,nil)
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
Duel.Damage(p,gc*200,REASON_EFFECT)
end
function c81008004.initial_effect(c)
c:SetUniqueOnField(1,0,81008004)
--fusion material
c:EnableReviveLimit()
aux.AddFusionProcFunRep(c,c81008004.ffilter,3,false)
--spsummon condition
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION)
e1:SetValue(aux.fuslimit)
c:RegisterEffect(e1)
--Special summon
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP)
e2:SetCode(EVENT_DESTROYED)
e2:SetCountLimit(1,81008004)
e2:SetTarget(c81008004.sptg)
e2:SetOperation(c81008004.spop)
c:RegisterEffect(e2)
--cannot be destroyed
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e3:SetRange(LOCATION_MZONE)
e3:SetValue(1)
c:RegisterEffect(e3)
--actlimit
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD)
e4:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e4:SetCode(EFFECT_CANNOT_ACTIVATE)
e4:SetRange(LOCATION_MZONE)
e4:SetTargetRange(0,1)
e4:SetValue(c81008004.aclimit)
e4:SetCondition(c81008004.actcon)
c:RegisterEffect(e4)
--cannot material
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_SINGLE)
e5:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e5:SetCode(EFFECT_CANNOT_BE_FUSION_MATERIAL)
e5:SetValue(1)
c:RegisterEffect(e5)
local e6=e5:Clone()
e6:SetCode(EFFECT_CANNOT_BE_SYNCHRO_MATERIAL)
c:RegisterEffect(e6)
local e7=e5:Clone()
e7:SetCode(EFFECT_CANNOT_BE_XYZ_MATERIAL)
c:RegisterEffect(e7)
local e8=e5:Clone()
e8:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
c:RegisterEffect(e8)
end
function c81008004.ffilter(c)
return c:IsSummonType(SUMMON_TYPE_SPECIAL) and not c:IsType(TYPE_TOKEN)
end
function c81008004.spfilter(c,e,tp)
return c:IsType(TYPE_FUSION) and c:IsType(TYPE_MONSTER) and c:IsLevelBelow(9) and c:IsCanBeSpecialSummoned(e,0,tp,true,false)
end
function c81008004.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c81008004.spfilter(chkc,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(c81008004.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c81008004.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function c81008004.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP)
end
end
function c81008004.aclimit(e,re,tp)
return (re:IsHasType(EFFECT_TYPE_ACTIVATE) or re:IsActiveType(TYPE_MONSTER)) and not re:GetHandler():IsImmuneToEffect(e)
end
function c81008004.actcon(e)
return Duel.GetAttacker()==e:GetHandler()
end
--Answer·原田美世
function c81008011.initial_effect(c)
c:EnableReviveLimit()
--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)
e1:SetValue(0)
c:RegisterEffect(e1)
--special summon
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_SPSUMMON_PROC)
e2:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e2:SetRange(LOCATION_HAND)
e2:SetCondition(c81008011.spcon)
e2:SetOperation(c81008011.spop)
c:RegisterEffect(e2)
--destroy
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_DESTROY+CATEGORY_POSITION)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN)
e3:SetRange(LOCATION_MZONE)
e3:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_MAIN_END)
e3:SetCountLimit(1,81008011)
e3:SetCondition(c81008011.descon)
e3:SetTarget(c81008011.destg)
e3:SetOperation(c81008011.desop)
c:RegisterEffect(e3)
--increase atk/def
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e4:SetCode(EFFECT_UPDATE_ATTACK)
e4:SetRange(LOCATION_MZONE)
e4:SetCondition(c81008011.condition)
e4:SetValue(1000)
c:RegisterEffect(e4)
local e5=e4:Clone()
e5:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e5)
--cannot attack
local e6=Effect.CreateEffect(c)
e6:SetType(EFFECT_TYPE_SINGLE)
e6:SetCode(EFFECT_CANNOT_ATTACK)
e6:SetCondition(c81008011.atcon)
c:RegisterEffect(e6)
--spsummon cost
local e7=Effect.CreateEffect(c)
e7:SetType(EFFECT_TYPE_SINGLE)
e7:SetCode(EFFECT_SPSUMMON_COST)
e7:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e7:SetCost(c81008011.ypcost)
e7:SetOperation(c81008011.ypcop)
c:RegisterEffect(e7)
end
function c81008011.rfilter(c)
return c:IsFaceup() and c:IsSummonType(SUMMON_TYPE_SPECIAL) and c:IsReleasable() and c:GetSummonLocation()==LOCATION_EXTRA
end
function c81008011.mzfilter(c)
return c:IsFaceup() and c:IsSummonType(SUMMON_TYPE_SPECIAL) and c:IsReleasable() and c:GetSummonLocation()==LOCATION_EXTRA and c:GetSequence()<5
end
function c81008011.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
local ct=-ft+1
if ct>2 then return false end
if ct>0 and not Duel.IsExistingMatchingCard(c81008011.mzfilter,tp,LOCATION_MZONE,0,ct,nil) then return false end
return Duel.IsExistingMatchingCard(c81008011.rfilter,tp,LOCATION_MZONE,LOCATION_MZONE,2,nil)
end
function c81008011.spop(e,tp,eg,ep,ev,re,r,rp,c)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
local ct=-ft+1
if ct<0 then ct=0 end
local g=Group.CreateGroup()
if ct>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local sg=Duel.SelectMatchingCard(tp,c81008011.mzfilter,tp,LOCATION_MZONE,0,ct,ct,nil)
g:Merge(sg)
end
if ct<2 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local sg=Duel.SelectMatchingCard(tp,c81008011.rfilter,tp,LOCATION_MZONE,LOCATION_MZONE,2-ct,2-ct,g:GetFirst())
g:Merge(sg)
end
Duel.Release(g,REASON_COST)
end
function c81008011.descon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2
end
function c81008011.posfilter(c)
return c:IsCanChangePosition()
end
function c81008011.otfilter(c)
return c:IsType(TYPE_MONSTER) and not c:IsCode(81008011)
end
function c81008011.destg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsType,tp,LOCATION_HAND,0,1,nil,TYPE_MONSTER)
and Duel.IsExistingMatchingCard(c81008011.posfilter,tp,0,LOCATION_MZONE,1,nil) end
local g=Duel.GetMatchingGroup(c81008011.posfilter,tp,0,LOCATION_MZONE,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,1,tp,LOCATION_HAND)
Duel.SetOperationInfo(0,CATEGORY_POSITION,g,g:GetCount(),0,0)
end
function c81008011.desop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g1=Duel.SelectMatchingCard(tp,c81008011.otfilter,tp,LOCATION_MZONE,0,1,1,nil,nil)
if g1:GetCount()>0 and Duel.Destroy(g1,REASON_EFFECT)~=0 then
local g2=Duel.GetMatchingGroup(c81008011.posfilter,tp,0,LOCATION_MZONE,nil)
if g2:GetCount()>0 then
Duel.ChangePosition(g2,POS_FACEUP_ATTACK)
end
end
end
function c81008011.condition(e)
local c=e:GetHandler()
local ph=Duel.GetCurrentPhase()
local bc=c:GetBattleTarget()
return (ph==PHASE_DAMAGE or ph==PHASE_DAMAGE_CAL)
and c:IsRelateToBattle() and bc and bc:IsSummonType(SUMMON_TYPE_SPECIAL)
end
function c81008011.atcon(e)
return Duel.GetFieldGroupCount(e:GetHandlerPlayer(),LOCATION_ONFIELD,0)>1 or Duel.GetFieldGroupCount(e:GetHandlerPlayer(),0,LOCATION_MZONE)==0
end
function c81008011.ypcost(e,c,tp)
return Duel.GetActivityCount(tp,ACTIVITY_NORMALSUMMON)==0
and Duel.GetActivityCount(tp,ACTIVITY_FLIPSUMMON)==0
and Duel.GetActivityCount(tp,ACTIVITY_SPSUMMON)==0
and Duel.GetActivityCount(tp,ACTIVITY_BATTLE_PHASE)==0
end
function c81008011.ypcop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTargetRange(1,0)
Duel.RegisterEffect(e1,tp)
local e2=e1:Clone()
e2:SetCode(EFFECT_CANNOT_MSET)
Duel.RegisterEffect(e2,tp)
local e3=e1:Clone()
e3:SetCode(EFFECT_CANNOT_FLIP_SUMMON)
Duel.RegisterEffect(e3,tp)
local e4=Effect.CreateEffect(e:GetHandler())
e4:SetType(EFFECT_TYPE_FIELD)
e4:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e4:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e4:SetTargetRange(1,0)
e4:SetTarget(c81008011.yplimit)
e4:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e4,tp)
local e5=Effect.CreateEffect(c)
e5:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e5:SetType(EFFECT_TYPE_FIELD)
e5:SetCode(EFFECT_CANNOT_BP)
e5:SetTargetRange(1,0)
e5:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e5,tp)
end
function c81008011.yplimit(e,c,tp,sumtp,sumpos)
return c~=e:GetHandler()
end
--九天玄女·藤原肇
function c81008012.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkRace,RACE_FAIRY),3)
c:EnableReviveLimit()
--cannot be destroyed
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE)
e1:SetValue(1)
c:RegisterEffect(e1)
--tohand
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_SOLVED)
e2:SetRange(LOCATION_MZONE)
e2:SetOperation(c81008012.drop)
c:RegisterEffect(e2)
--search
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_BATTLE_DAMAGE)
e3:SetCountLimit(1,81008012)
e3:SetCondition(c81008012.thcon)
e3:SetTarget(c81008012.thtg)
e3:SetOperation(c81008012.thop)
c:RegisterEffect(e3)
end
function c81008012.filter(c)
return c:IsFaceup() and c:IsRace(RACE_FAIRY) and c:IsAbleToHand()
end
function c81008012.drop(e,tp,eg,ep,ev,re,r,rp)
if not re:IsHasType(EFFECT_TYPE_ACTIVATE) or not re:IsActiveType(TYPE_COUNTER) then return end
Duel.BreakEffect()
local g=Duel.GetMatchingGroup(c81008012.filter,tp,LOCATION_GRAVE,0,nil)
if g:GetCount()<1 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local sg=g:Select(tp,1,1,nil)
Duel.SendtoHand(sg,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,sg)
end
function c81008012.thcon(e,tp,eg,ep,ev,re,r,rp)
return ep~=tp
end
function c81008012.thfilter(c)
return c:IsType(TYPE_COUNTER) and c:IsAbleToHand()
end
function c81008012.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c81008012.thfilter,tp,LOCATION_GRAVE,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_GRAVE)
end
function c81008012.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c81008012.thfilter,tp,LOCATION_GRAVE,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
--Answer·成宫由爱·S
function c81008015.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkType,TYPE_EFFECT),2)
c:EnableReviveLimit()
--atk
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE)
e1:SetValue(c81008015.atkval)
c:RegisterEffect(e1)
--to hand
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetCountLimit(1,81008015)
e2:SetRange(LOCATION_MZONE)
e2:SetCondition(c81008015.accon)
e2:SetTarget(c81008015.actg)
e2:SetOperation(c81008015.acop)
c:RegisterEffect(e2)
--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,81008915)
e3:SetCondition(aux.exccon)
e3:SetCost(aux.bfgcost)
e3:SetTarget(c81008015.thtg)
e3:SetOperation(c81008015.thop)
c:RegisterEffect(e3)
end
function c81008015.atkval(e,c)
return c:GetLinkedGroupCount()*500
end
function c81008015.cfilter(c,lg)
return c:IsType(TYPE_EFFECT) and lg:IsContains(c)
end
function c81008015.accon(e,tp,eg,ep,ev,re,r,rp)
local lg=e:GetHandler():GetLinkedGroup()
return eg:IsExists(c81008015.cfilter,1,nil,lg) and not Duel.IsExistingMatchingCard(aux.TRUE,tp,LOCATION_FZONE,0,1,nil)
end
function c81008015.acfilter(c,tp)
return c:IsType(TYPE_FIELD) and c:IsType(TYPE_SPELL) and c:GetActivateEffect() and c:GetActivateEffect():IsActivatable(tp,true,true)
end
function c81008015.actg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c81008015.acfilter,tp,LOCATION_GRAVE,0,1,nil,tp) end
end
function c81008015.acop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local tc=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c81008015.acfilter),tp,LOCATION_GRAVE,0,1,1,nil,tp):GetFirst()
if tc then
local fc=Duel.GetFieldCard(tp,LOCATION_SZONE,5)
if fc then
Duel.SendtoGrave(fc,REASON_RULE)
Duel.BreakEffect()
end
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
local te=tc:GetActivateEffect()
te:UseCountLimit(tp,1,true)
local tep=tc:GetControler()
local cost=te:GetCost()
if cost then cost(te,tep,eg,ep,ev,re,r,rp,1) end
Duel.RaiseEvent(tc,4179255,te,0,tp,tp,Duel.GetCurrentChain())
end
end
function c81008015.thfilter(c)
return c:IsType(TYPE_FIELD) and c:IsType(TYPE_SPELL) and c:IsAbleToHand()
end
function c81008015.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c81008015.thfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function c81008015.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c81008015.thfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
local tc=g:GetFirst()
if tc:IsLocation(LOCATION_HAND) then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_ACTIVATE)
e1:SetTargetRange(1,0)
e1:SetValue(c81008015.aclimit)
e1:SetLabelObject(tc)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
end
end
function c81008015.aclimit(e,re,tp)
local tc=e:GetLabelObject()
return re:GetHandler():IsCode(tc:GetCode()) and not re:GetHandler():IsImmuneToEffect(e)
end
function c81008016.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkType,TYPE_EFFECT),2)
c:EnableReviveLimit()
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e0:SetRange(LOCATION_MZONE)
e0:SetCode(EFFECT_IMMUNE_EFFECT)
e0:SetValue(c81008016.efilter)
c:RegisterEffect(e0)
--negate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DISABLE)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetRange(LOCATION_MZONE)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER)
e1:SetCountLimit(1,81008016)
e1:SetTarget(c81008016.negtg)
e1:SetOperation(c81008016.negop)
c:RegisterEffect(e1)
--destroy
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_DESTROYED)
e2:SetRange(LOCATION_GRAVE)
e2:SetCountLimit(1,81008916)
e2:SetCondition(c81008016.descon)
e2:SetCost(aux.bfgcost)
e2:SetTarget(c81008016.settg)
e2:SetOperation(c81008016.setop)
c:RegisterEffect(e2)
end
function c81008016.efilter(e,te)
return te:IsActiveType(TYPE_TRAP)
end
function c81008016.negfilter(c)
return c:IsFaceup() and c:GetSequence()<5
end
function c81008016.negtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() and c81008016.negfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c81008016.negfilter,tp,LOCATION_SZONE,LOCATION_SZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local g=Duel.SelectTarget(tp,c81008016.negfilter,tp,LOCATION_SZONE,LOCATION_SZONE,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_DISABLE,g,1,0,0)
end
function c81008016.negop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if ((tc:IsFaceup() and not tc:IsDisabled()) or tc:IsType(TYPE_TRAPMONSTER)) and tc:IsRelateToEffect(e) then
Duel.NegateRelatedChain(tc,RESET_TURN_SET)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EFFECT_DISABLE)
if Duel.GetCurrentPhase()==PHASE_STANDBY then
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_STANDBY,2)
else
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_STANDBY)
end
tc:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetValue(RESET_TURN_SET)
tc:RegisterEffect(e2)
end
end
function c81008016.cfilter(c,tp)
return c:IsPreviousLocation(LOCATION_ONFIELD) and c:GetPreviousControler()==tp and c:IsReason(REASON_EFFECT)
end
function c81008016.descon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c81008016.cfilter,1,nil,tp) and re and re:IsActiveType(TYPE_TRAP) and aux.exccon(e)
end
function c81008016.setfilter(c)
return c:IsType(TYPE_TRAP) and c:IsSSetable()
end
function c81008016.settg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c81008016.setfilter,tp,LOCATION_DECK,0,1,nil) end
end
function c81008016.setop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local g=Duel.SelectMatchingCard(tp,c81008016.setfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
local c=e:GetHandler()
local tc=g:GetFirst()
local fid=c:GetFieldID()
Duel.SSet(tp,tc)
Duel.ConfirmCards(1-tp,g)
end
end
--练习曲只有1首·三船美优
function c81008019.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(TIMING_ATTACK,0x11e0)
e1:SetCost(c81008019.cost)
e1:SetTarget(c81008019.target)
e1:SetOperation(c81008019.activate)
c:RegisterEffect(e1)
--spsummon
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_CHAINING)
e2:SetRange(LOCATION_GRAVE)
e2:SetCondition(c81008019.spcon)
e2:SetTarget(c81008019.sptg)
e2:SetOperation(c81008019.spop)
c:RegisterEffect(e2)
end
function c81008019.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckLPCost(tp,1000) end
Duel.PayLPCost(tp,1000)
end
function c81008019.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() and chkc~=e:GetHandler() end
if chk==0 then return Duel.IsExistingTarget(aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,e:GetHandler()) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(tp,aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
end
function c81008019.activate(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.Destroy(tc,REASON_EFFECT)
end
end
function c81008019.spcon(e,tp,eg,ep,ev,re,r,rp)
return re:IsActiveType(TYPE_MONSTER)
end
function c81008019.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:GetFlagEffect(81008019)==0 and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,81008019,0,0x11,0,2500,5,RACE_FAIRY,ATTRIBUTE_WATER) end
c:RegisterFlagEffect(81008019,RESET_CHAIN,0,1)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0)
end
function c81008019.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
local c=e:GetHandler()
if c:IsRelateToEffect(e) and Duel.IsPlayerCanSpecialSummonMonster(tp,81008019,0,0x11,0,2500,5,RACE_FAIRY,ATTRIBUTE_WATER) then
c:AddMonsterAttribute(TYPE_NORMAL)
Duel.SpecialSummonStep(c,0,tp,tp,true,false,POS_FACEUP)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_IMMUNE_EFFECT)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetRange(LOCATION_MZONE)
e2:SetValue(c81008019.efilter)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e2,true)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_LEAVE_FIELD_REDIRECT)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e3:SetReset(RESET_EVENT+RESETS_REDIRECT)
e3:SetValue(LOCATION_REMOVED)
c:RegisterEffect(e3,true)
Duel.SpecialSummonComplete()
end
end
function c81008019.efilter(e,re)
return re:IsActiveType(TYPE_SPELL+TYPE_TRAP)
end
--苍之夜·渋谷凛
function c81008021.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,c81008021.matfilter,3,3,c81008021.lcheck)
c:EnableReviveLimit()
--
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetValue(aux.linklimit)
c:RegisterEffect(e0)
--actlimit
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_ACTIVATE)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(0,1)
e1:SetValue(c81008021.aclimit)
e1:SetCondition(c81008021.actcon)
c:RegisterEffect(e1)
--special summon
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_LEAVE_FIELD)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e2:SetCountLimit(1,81008021+EFFECT_COUNT_CODE_DUEL)
e2:SetCondition(c81008021.spcon)
e2:SetTarget(c81008021.sptg)
e2:SetOperation(c81008021.spop)
c:RegisterEffect(e2)
--atk down
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_BATTLE_DESTROYED)
e3:SetProperty(EFFECT_FLAG_DELAY)
e3:SetCountLimit(1,81008921+EFFECT_COUNT_CODE_DUEL)
e3:SetOperation(c81008021.atkop)
c:RegisterEffect(e3)
--
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_SINGLE)
e5:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e5:SetCode(EFFECT_CANNOT_BE_FUSION_MATERIAL)
e5:SetValue(1)
c:RegisterEffect(e5)
local e6=e5:Clone()
e6:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
c:RegisterEffect(e6)
local e7=e5:Clone()
e7:SetCode(EFFECT_CANNOT_BE_XYZ_MATERIAL)
c:RegisterEffect(e7)
end
function c81008021.matfilter(c)
return c:IsLinkType(TYPE_FUSION) and c:IsLevelAbove(7)
end
function c81008021.lcheck(g,lc)
return g:GetClassCount(Card.GetOriginalCode)==g:GetCount()
end
function c81008021.aclimit(e,re,tp)
return not re:GetHandler():IsImmuneToEffect(e)
end
function c81008021.actcon(e)
return Duel.GetAttacker()==e:GetHandler() or Duel.GetAttackTarget()==e:GetHandler()
end
function c81008021.spcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:GetReasonPlayer()==1-tp
and c:IsReason(REASON_EFFECT) and c:IsPreviousPosition(POS_FACEUP)
end
function c81008021.filter0(c)
return c:IsFaceup() and c:IsCanBeFusionMaterial()
end
function c81008021.filter1(c,e)
return c:IsFaceup() and c:IsCanBeFusionMaterial() and not c:IsImmuneToEffect(e)
end
function c81008021.filter2(c,e,tp,m,f,chkf)
return c:IsType(TYPE_FUSION) and (not f or f(c))
and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_FUSION,tp,false,false) and c:CheckFusionMaterial(m,nil,chkf)
end
function c81008021.filter3(c,e)
return c:IsOnField() and not c:IsImmuneToEffect(e)
end
function c81008021.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then
local chkf=tp
local mg1=Duel.GetFusionMaterial(tp):Filter(Card.IsOnField,nil)
local mg2=Duel.GetMatchingGroup(c81008021.filter0,tp,0,LOCATION_MZONE,nil)
mg1:Merge(mg2)
local res=Duel.IsExistingMatchingCard(c81008021.filter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,mg1,nil,chkf)
if not res then
local ce=Duel.GetChainMaterial(tp)
if ce~=nil then
local fgroup=ce:GetTarget()
local mg3=fgroup(ce,e,tp)
local mf=ce:GetValue()
res=Duel.IsExistingMatchingCard(c81008021.filter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,mg3,mf,chkf)
end
end
return res
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function c81008021.spop(e,tp,eg,ep,ev,re,r,rp)
local chkf=tp
local mg1=Duel.GetFusionMaterial(tp):Filter(c81008021.filter3,nil,e)
local mg2=Duel.GetMatchingGroup(c81008021.filter1,tp,0,LOCATION_MZONE,nil,e)
mg1:Merge(mg2)
local sg1=Duel.GetMatchingGroup(c81008021.filter2,tp,LOCATION_EXTRA,0,nil,e,tp,mg1,nil,chkf)
local mg3=nil
local sg2=nil
local ce=Duel.GetChainMaterial(tp)
if ce~=nil then
local fgroup=ce:GetTarget()
mg3=fgroup(ce,e,tp)
local mf=ce:GetValue()
sg2=Duel.GetMatchingGroup(c81008021.filter2,tp,LOCATION_EXTRA,0,nil,e,tp,mg3,mf,chkf)
end
if sg1:GetCount()>0 or (sg2~=nil and sg2:GetCount()>0) then
local sg=sg1:Clone()
if sg2 then sg:Merge(sg2) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local tg=sg:Select(tp,1,1,nil)
local tc=tg:GetFirst()
if sg1:IsContains(tc) and (sg2==nil or not sg2:IsContains(tc) or not Duel.SelectYesNo(tp,ce:GetDescription())) then
local mat1=Duel.SelectFusionMaterial(tp,tc,mg1,nil,chkf)
tc:SetMaterial(mat1)
Duel.SendtoGrave(mat1,REASON_EFFECT+REASON_MATERIAL+REASON_FUSION)
Duel.BreakEffect()
Duel.SpecialSummon(tc,SUMMON_TYPE_FUSION,tp,tp,false,false,POS_FACEUP)
else
local mat2=Duel.SelectFusionMaterial(tp,tc,mg3,nil,chkf)
local fop=ce:GetOperation()
fop(ce,e,tp,tc,mat2)
end
tc:CompleteProcedure()
end
end
function c81008021.atkop(e,tp,eg,ep,ev,re,r,rp)
Duel.SetLP(1-tp,math.ceil(Duel.GetLP(1-tp)/2))
end
--战女神的先导·神崎兰子
function c81008027.initial_effect(c)
--link summon
c:EnableReviveLimit()
aux.AddLinkProcedure(c,nil,2,2)
--equip
local e1=Effect.CreateEffect(c)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCategory(CATEGORY_EQUIP)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetTarget(c81008027.eqtg)
e1:SetOperation(c81008027.eqop)
c:RegisterEffect(e1)
--unequip
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_SZONE)
e2:SetTarget(c81008027.sptg)
e2:SetOperation(c81008027.spop)
c:RegisterEffect(e2)
--destroy sub
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_EQUIP)
e3:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e3:SetCode(EFFECT_DESTROY_SUBSTITUTE)
e3:SetValue(c81008027.repval)
c:RegisterEffect(e3)
--untargetable
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_EQUIP)
e4:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET)
e4:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e4:SetValue(aux.tgoval)
c:RegisterEffect(e4)
--indes
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_EQUIP)
e5:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e5:SetValue(aux.indoval)
c:RegisterEffect(e5)
--eqlimit
local e6=Effect.CreateEffect(c)
e6:SetType(EFFECT_TYPE_SINGLE)
e6:SetCode(EFFECT_EQUIP_LIMIT)
e6:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e6:SetValue(1)
c:RegisterEffect(e6)
end
function c81008027.filter(c)
local ct1,ct2=c:GetUnionCount()
return c:IsFaceup() and ct2==0
end
function c81008027.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler()
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c81008027.filter(chkc) end
if chk==0 then return e:GetHandler():GetFlagEffect(81008027)==0 and Duel.GetLocationCount(tp,LOCATION_SZONE)>0
and Duel.IsExistingTarget(c81008027.filter,tp,LOCATION_MZONE,0,1,c) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
local g=Duel.SelectTarget(tp,c81008027.filter,tp,LOCATION_MZONE,0,1,1,c)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,g,1,0,0)
c:RegisterFlagEffect(81008027,RESET_EVENT+0x7e0000+RESET_PHASE+PHASE_END,0,1)
end
function c81008027.eqop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if not c:IsRelateToEffect(e) or c:IsFacedown() then return end
if not tc:IsRelateToEffect(e) or not c81008027.filter(tc) then
Duel.SendtoGrave(c,REASON_EFFECT)
return
end
if not Duel.Equip(tp,c,tc,false) then return end
aux.SetUnionState(c)
end
function c81008027.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:GetFlagEffect(81008027)==0 and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,true,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0)
c:RegisterFlagEffect(81008027,RESET_EVENT+0x7e0000+RESET_PHASE+PHASE_END,0,1)
end
function c81008027.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
if Duel.SpecialSummon(c,0,tp,tp,true,false,POS_FACEUP)==0 and Duel.GetLocationCount(tp,LOCATION_MZONE)<=0
and c:IsCanBeSpecialSummoned(e,0,tp,true,false) then
Duel.SendtoGrave(c,REASON_RULE)
end
end
function c81008027.repval(e,re,r,rp)
return bit.band(r,REASON_BATTLE+REASON_EFFECT)~=0
end
--摇曳花影·新田美波
function c81008029.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,nil,3,3,c81008029.lcheck)
c:EnableReviveLimit()
--atk
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetTarget(aux.TargetBoolFunction(Card.IsType,TYPE_LINK))
e1:SetValue(500)
c:RegisterEffect(e1)
--destroy
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_DESTROY)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1,81008029)
e2:SetCondition(c81008029.descon)
e2:SetTarget(c81008029.destg)
e2:SetOperation(c81008029.desop)
c:RegisterEffect(e2)
--todeck
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TOEXTRA)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetRange(LOCATION_GRAVE)
e3:SetCountLimit(1,81008929)
e3:SetCondition(aux.exccon)
e3:SetCost(aux.bfgcost)
e3:SetTarget(c81008029.tdtg)
e3:SetOperation(c81008029.tdop)
c:RegisterEffect(e3)
end
function c81008029.lcheck(g,lc)
return g:IsExists(Card.IsLinkType,1,nil,TYPE_LINK)
end
function c81008029.cfilter(c,lg)
return c:IsType(TYPE_LINK) and bit.band(c:GetSummonType(),SUMMON_TYPE_LINK)~=0 and lg:IsContains(c)
end
function c81008029.descon(e,tp,eg,ep,ev,re,r,rp)
local lg=e:GetHandler():GetLinkedGroup()
return eg:IsExists(c81008029.cfilter,1,nil,lg)
end
function c81008029.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() end
if chk==0 then return Duel.IsExistingTarget(aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(tp,aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,PLAYER_ALL,LOCATION_ONFIELD)
end
function c81008029.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.Destroy(tc,REASON_EFFECT)
end
end
function c81008029.tdfilter(c)
return c:IsType(TYPE_LINK) and c:IsAbleToExtra() and not c:IsCode(81008029)
end
function c81008029.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE+LOCATION_REMOVED) and c81008029.tdfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c81008029.tdfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectTarget(tp,c81008029.tdfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,g,1,0,0)
end
function c81008029.tdop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.SendtoDeck(tc,nil,2,REASON_EFFECT)
end
end
--镜花水月·小早川纱枝
function c81009009.initial_effect(c)
--synchro summon
aux.AddSynchroProcedure(c,nil,aux.NonTuner(nil),1)
c:EnableReviveLimit()
--add type
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCondition(c81009009.tncon)
e1:SetOperation(c81009009.tnop)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_MATERIAL_CHECK)
e2:SetValue(c81009009.valcheck)
e2:SetLabelObject(e1)
c:RegisterEffect(e2)
--spsummon
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(81009009,0))
e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_MZONE)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetCountLimit(1,81009009)
e3:SetCondition(c81009009.spcon)
e3:SetTarget(c81009009.sptg)
e3:SetOperation(c81009009.spop)
c:RegisterEffect(e3)
--spsummon
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(81009009,1))
e4:SetCategory(CATEGORY_SPECIAL_SUMMON)
e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetRange(LOCATION_MZONE)
e4:SetCountLimit(1,81009099)
e4:SetTarget(c81009009.dsptg)
e4:SetOperation(c81009009.dspop)
c:RegisterEffect(e4)
end
function c81009009.valcheck(e,c)
local g=c:GetMaterial()
if g:IsExists(Card.IsType,1,nil,TYPE_NORMAL) then
e:GetLabelObject():SetLabel(1)
else
e:GetLabelObject():SetLabel(0)
end
end
function c81009009.tncon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_SYNCHRO) and e:GetLabel()==1
end
function c81009009.tnop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EFFECT_ADD_TYPE)
e1:SetValue(TYPE_TUNER)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1)
end
function c81009009.cfilter(c)
return c:IsFaceup() and c:IsType(TYPE_NORMAL)
end
function c81009009.spcon(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(c81009009.cfilter,tp,LOCATION_MZONE,0,1,nil)
end
function c81009009.filter(c,e,tp)
return c:IsType(TYPE_NORMAL) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c81009009.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c81009009.filter(chkc,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(c81009009.filter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c81009009.filter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function c81009009.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end
end
function c81009009.dfilter(c,e,tp)
return c:IsLevelBelow(4) and c:IsType(TYPE_NORMAL) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c81009009.dsptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsLevelAbove(2) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c81009009.dfilter,tp,LOCATION_HAND,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND)
end
function c81009009.dspop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsFacedown() or not c:IsRelateToEffect(e) then return end
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_LEVEL)
e1:SetValue(-1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
c:RegisterEffect(e1)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c81009009.dfilter,tp,LOCATION_HAND,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
--一炎入魂·日野茜
function c81009019.initial_effect(c)
--xyz summon
c:EnableReviveLimit()
aux.AddXyzProcedureLevelFree(c,c81009019.mfilter,c81009019.xyzcheck,2,99)
--immune
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(c81009019.condition)
e1:SetCost(c81009019.cost)
e1:SetOperation(c81009019.operation)
c:RegisterEffect(e1)
--dice
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_TOSS_DICE_NEGATE)
e2:SetRange(LOCATION_MZONE)
e2:SetCondition(c81009019.dicecon)
e2:SetOperation(c81009019.diceop)
c:RegisterEffect(e2)
end
function c81009019.mfilter(c,xyzc)
return c:IsXyzType(TYPE_MONSTER) and not c:IsType(TYPE_TOKEN)
end
function c81009019.xyzcheck(g)
return g:GetClassCount(Card.GetLevel)==1
end
function c81009019.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFlagEffect(tp,81099919)==0
end
function c81009019.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end
e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST)
Duel.RegisterFlagEffect(tp,81099919,RESET_PHASE+PHASE_END,0,1)
end
function c81009019.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsFaceup() and c:IsRelateToEffect(e) then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_TOSS_DICE_NEGATE)
e1:SetCondition(c81009019.coincon)
e1:SetOperation(c81009019.coinop)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
end
function c81009019.coincon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFlagEffect(tp,81009919)==0
end
function c81009019.coinop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetFlagEffect(tp,81009919)~=0 then return end
if Duel.SelectYesNo(tp,aux.Stringid(81009019,0)) then
Duel.Hint(HINT_CARD,0,81009019)
Duel.RegisterFlagEffect(tp,81009919,RESET_PHASE+PHASE_END,0,1)
local ct1=bit.band(ev,0xff)
local ct2=bit.rshift(ev,16)
Duel.TossDice(ep,ct1,ct2)
end
end
function c81009019.dicecon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:GetFlagEffect(81009019)==0
end
function c81009019.diceop(e,tp,eg,ep,ev,re,r,rp)
local cc=Duel.GetCurrentChain()
local cid=Duel.GetChainInfo(cc,CHAININFO_CHAIN_ID)
if c81009019[0]~=cid and Duel.SelectYesNo(tp,aux.Stringid(81009019,1)) then
Duel.Hint(HINT_CARD,0,81009019)
e:GetHandler():RegisterFlagEffect(81009019,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,0,1)
local dc={Duel.GetDiceResult()}
local ac=1
local ct=bit.band(ev,0xff)+bit.rshift(ev,16)
if ct>1 then
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(81009019,2))
local val,idx=Duel.AnnounceNumber(tp,table.unpack(dc,1,ct))
ac=idx+1
end
dc[ac]=8
Duel.SetDiceResult(table.unpack(dc))
c81009019[0]=cid
end
end
--突击情人节·日野茜
function c81009020.initial_effect(c)
--level
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1)
e1:SetTarget(c81009020.lvtg)
e1:SetOperation(c81009020.lvop)
c:RegisterEffect(e1)
end
function c81009020.lvfilter(c)
return c:IsFaceup() and c:GetLevel()>0
end
function c81009020.lvtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c81009020.lvfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c81009020.lvfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
Duel.SelectTarget(tp,c81009020.lvfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
end
function c81009020.lvop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsFaceup() then
local dc=Duel.TossDice(tp,1)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CHANGE_LEVEL)
e1:SetValue(dc*2)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
end
end
--烦恼的年纪·矢口美羽
function c81009029.initial_effect(c)
--special summon rule
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetRange(LOCATION_HAND)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_SPSUM_PARAM)
e1:SetTargetRange(POS_FACEUP_ATTACK,1)
e1:SetCondition(c81009029.spcon)
e1:SetOperation(c81009029.spop)
c:RegisterEffect(e1)
--splimit
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetTargetRange(1,0)
e2:SetTarget(c81009029.splimit)
c:RegisterEffect(e2)
end
function c81009029.splimit(e,c,sump,sumtype,sumpos,targetp)
return bit.band(sumtype,SUMMON_TYPE_FUSION)==SUMMON_TYPE_FUSION
end
function c81009029.spfilter(c,tp)
return c:IsReleasable() and Duel.GetMZoneCount(1-tp,c,tp)>0
end
function c81009029.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
return Duel.IsExistingMatchingCard(c81009029.spfilter,tp,0,LOCATION_MZONE,1,nil,tp)
end
function c81009029.spop(e,tp,eg,ep,ev,re,r,rp,c)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local g=Duel.SelectMatchingCard(tp,c81009029.spfilter,tp,0,LOCATION_MZONE,1,1,nil,tp)
Duel.Release(g,REASON_COST)
end
--积木回忆·高森蓝子
function c81009030.initial_effect(c)
c:EnableReviveLimit()
--special summon
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(c81009030.spcon)
e1:SetOperation(c81009030.spop)
c:RegisterEffect(e1)
--splimit
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(1,0)
e2:SetTarget(c81009030.splimit)
c:RegisterEffect(e2)
--destroy
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TOEXTRA+CATEGORY_REMOVE)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,10678779)
e3:SetCost(c81009030.descost)
e3:SetTarget(c81009030.destg)
e3:SetOperation(c81009030.desop)
c:RegisterEffect(e3)
end
function c81009030.spcostfilter(c)
return c:IsAbleToRemoveAsCost() and (c:IsType(TYPE_LINK) or c:IsType(TYPE_FUSION))
end
function c81009030.spcost_selector(c,tp,g,sg,i)
sg:AddCard(c)
g:RemoveCard(c)
local flag=false
if i<2 then
flag=g:IsExists(c81009030.spcost_selector,1,nil,tp,g,sg,i+1)
else
flag=sg:FilterCount(Card.IsType,nil,TYPE_LINK)>0
and sg:FilterCount(Card.IsType,nil,TYPE_FUSION)>0
end
sg:RemoveCard(c)
g:AddCard(c)
return flag
end
function c81009030.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
if Duel.GetMZoneCount(tp)<=0 then return false end
local g=Duel.GetMatchingGroup(c81009030.spcostfilter,tp,LOCATION_EXTRA,0,nil)
local sg=Group.CreateGroup()
return g:IsExists(c81009030.spcost_selector,1,nil,tp,g,sg,1)
end
function c81009030.spop(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.GetMatchingGroup(c81009030.spcostfilter,tp,LOCATION_EXTRA,0,nil)
local sg=Group.CreateGroup()
for i=1,2 do
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g1=g:FilterSelect(tp,c81009030.spcost_selector,1,1,nil,tp,g,sg,i)
sg:Merge(g1)
g:Sub(g1)
end
Duel.Remove(sg,POS_FACEUP,REASON_COST)
end
function c81009030.splimit(e,c,sump,sumtype,sumpos,targetp)
return c:IsType(TYPE_SYNCHRO) or c:IsType(TYPE_XYZ)
end
function c81009030.descost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsReleasable() end
Duel.Release(e:GetHandler(),REASON_COST)
end
function c81009030.filter(c,tp)
local ctype=bit.band(c:GetType(),TYPE_FUSION+TYPE_LINK)
return c:IsFaceup() and ctype~=0 and c:IsAbleToExtra()
and Duel.IsExistingMatchingCard(c81009030.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil,ctype)
end
function c81009030.filter2(c,ctype)
return c:IsFaceup() and c:IsType(ctype) and c:IsAbleToRemove()
end
function c81009030.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_REMOVED) and chkc:IsControler(tp) and c81009030.filter(chkc,tp) end
if chk==0 then return Duel.IsExistingTarget(c81009030.filter,tp,LOCATION_REMOVED,0,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectTarget(tp,c81009030.filter,tp,LOCATION_REMOVED,0,1,1,nil,tp)
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,g,1,0,0)
local ctype=bit.band(g:GetFirst():GetType(),TYPE_FUSION+TYPE_LINK)
local dg=Duel.GetMatchingGroup(c81009030.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,nil,ctype)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,dg,1,0,0)
end
function c81009030.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,0,REASON_EFFECT)~=0 then
local ctype=bit.band(tc:GetType(),TYPE_FUSION+TYPE_LINK)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c81009030.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil,ctype)
Duel.Remove(g,POS_FACEUP,REASON_EFFECT)
end
end
--散步日和·高森蓝子
function c81009031.initial_effect(c)
c:EnableReviveLimit()
--special summon
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(c81009031.spcon)
e1:SetOperation(c81009031.spop)
c:RegisterEffect(e1)
--splimit
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(1,0)
e2:SetTarget(c81009031.splimit)
c:RegisterEffect(e2)
--destroy
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TOEXTRA+CATEGORY_REMOVE)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,10678779)
e3:SetCost(c81009031.descost)
e3:SetTarget(c81009031.destg)
e3:SetOperation(c81009031.desop)
c:RegisterEffect(e3)
end
function c81009031.spcostfilter(c)
return c:IsAbleToRemoveAsCost() and (c:IsType(TYPE_XYZ) or c:IsType(TYPE_FUSION))
end
function c81009031.spcost_selector(c,tp,g,sg,i)
sg:AddCard(c)
g:RemoveCard(c)
local flag=false
if i<2 then
flag=g:IsExists(c81009031.spcost_selector,1,nil,tp,g,sg,i+1)
else
flag=sg:FilterCount(Card.IsType,nil,TYPE_XYZ)>0
and sg:FilterCount(Card.IsType,nil,TYPE_FUSION)>0
end
sg:RemoveCard(c)
g:AddCard(c)
return flag
end
function c81009031.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
if Duel.GetMZoneCount(tp)<=0 then return false end
local g=Duel.GetMatchingGroup(c81009031.spcostfilter,tp,LOCATION_EXTRA,0,nil)
local sg=Group.CreateGroup()
return g:IsExists(c81009031.spcost_selector,1,nil,tp,g,sg,1)
end
function c81009031.spop(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.GetMatchingGroup(c81009031.spcostfilter,tp,LOCATION_EXTRA,0,nil)
local sg=Group.CreateGroup()
for i=1,2 do
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g1=g:FilterSelect(tp,c81009031.spcost_selector,1,1,nil,tp,g,sg,i)
sg:Merge(g1)
g:Sub(g1)
end
Duel.Remove(sg,POS_FACEUP,REASON_COST)
end
function c81009031.splimit(e,c,sump,sumtype,sumpos,targetp)
return c:IsType(TYPE_SYNCHRO) or c:IsType(TYPE_LINK)
end
function c81009031.descost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsReleasable() end
Duel.Release(e:GetHandler(),REASON_COST)
end
function c81009031.filter(c,tp)
local ctype=bit.band(c:GetType(),TYPE_FUSION+TYPE_XYZ)
return c:IsFaceup() and ctype~=0 and c:IsAbleToExtra()
and Duel.IsExistingMatchingCard(c81009031.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil,ctype)
end
function c81009031.filter2(c,ctype)
return c:IsFaceup() and c:IsType(ctype) and c:IsAbleToRemove()
end
function c81009031.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_REMOVED) and chkc:IsControler(tp) and c81009031.filter(chkc,tp) end
if chk==0 then return Duel.IsExistingTarget(c81009031.filter,tp,LOCATION_REMOVED,0,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectTarget(tp,c81009031.filter,tp,LOCATION_REMOVED,0,1,1,nil,tp)
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,g,1,0,0)
local ctype=bit.band(g:GetFirst():GetType(),TYPE_FUSION+TYPE_XYZ)
local dg=Duel.GetMatchingGroup(c81009031.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,nil,ctype)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,dg,1,0,0)
end
function c81009031.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,0,REASON_EFFECT)~=0 then
local ctype=bit.band(tc:GetType(),TYPE_FUSION+TYPE_XYZ)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c81009031.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil,ctype)
Duel.Remove(g,POS_FACEUP,REASON_EFFECT)
end
end
--芬芳花嫁·高森蓝子
function c81009032.initial_effect(c)
c:EnableReviveLimit()
--special summon
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(c81009032.spcon)
e1:SetOperation(c81009032.spop)
c:RegisterEffect(e1)
--splimit
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(1,0)
e2:SetTarget(c81009032.splimit)
c:RegisterEffect(e2)
--destroy
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TOEXTRA+CATEGORY_REMOVE)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,10678779)
e3:SetCost(c81009032.descost)
e3:SetTarget(c81009032.destg)
e3:SetOperation(c81009032.desop)
c:RegisterEffect(e3)
end
function c81009032.spcostfilter(c)
return c:IsAbleToRemoveAsCost() and (c:IsType(TYPE_SYNCHRO) or c:IsType(TYPE_FUSION))
end
function c81009032.spcost_selector(c,tp,g,sg,i)
sg:AddCard(c)
g:RemoveCard(c)
local flag=false
if i<2 then
flag=g:IsExists(c81009032.spcost_selector,1,nil,tp,g,sg,i+1)
else
flag=sg:FilterCount(Card.IsType,nil,TYPE_SYNCHRO)>0
and sg:FilterCount(Card.IsType,nil,TYPE_FUSION)>0
end
sg:RemoveCard(c)
g:AddCard(c)
return flag
end
function c81009032.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
if Duel.GetMZoneCount(tp)<=0 then return false end
local g=Duel.GetMatchingGroup(c81009032.spcostfilter,tp,LOCATION_EXTRA,0,nil)
local sg=Group.CreateGroup()
return g:IsExists(c81009032.spcost_selector,1,nil,tp,g,sg,1)
end
function c81009032.spop(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.GetMatchingGroup(c81009032.spcostfilter,tp,LOCATION_EXTRA,0,nil)
local sg=Group.CreateGroup()
for i=1,2 do
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g1=g:FilterSelect(tp,c81009032.spcost_selector,1,1,nil,tp,g,sg,i)
sg:Merge(g1)
g:Sub(g1)
end
Duel.Remove(sg,POS_FACEUP,REASON_COST)
end
function c81009032.splimit(e,c,sump,sumtype,sumpos,targetp)
return c:IsType(TYPE_LINK) or c:IsType(TYPE_XYZ)
end
function c81009032.descost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsReleasable() end
Duel.Release(e:GetHandler(),REASON_COST)
end
function c81009032.filter(c,tp)
local ctype=bit.band(c:GetType(),TYPE_FUSION+TYPE_SYNCHRO)
return c:IsFaceup() and ctype~=0 and c:IsAbleToExtra()
and Duel.IsExistingMatchingCard(c81009032.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil,ctype)
end
function c81009032.filter2(c,ctype)
return c:IsFaceup() and c:IsType(ctype) and c:IsAbleToRemove()
end
function c81009032.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_REMOVED) and chkc:IsControler(tp) and c81009032.filter(chkc,tp) end
if chk==0 then return Duel.IsExistingTarget(c81009032.filter,tp,LOCATION_REMOVED,0,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectTarget(tp,c81009032.filter,tp,LOCATION_REMOVED,0,1,1,nil,tp)
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,g,1,0,0)
local ctype=bit.band(g:GetFirst():GetType(),TYPE_FUSION+TYPE_SYNCHRO)
local dg=Duel.GetMatchingGroup(c81009032.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,nil,ctype)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,dg,1,0,0)
end
function c81009032.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,0,REASON_EFFECT)~=0 then
local ctype=bit.band(tc:GetType(),TYPE_FUSION+TYPE_SYNCHRO)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c81009032.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil,ctype)
Duel.Remove(g,POS_FACEUP,REASON_EFFECT)
end
end
--白银歌声·高森蓝子
function c81009033.initial_effect(c)
c:EnableReviveLimit()
--special summon
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(c81009033.spcon)
e1:SetOperation(c81009033.spop)
c:RegisterEffect(e1)
--splimit
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(1,0)
e2:SetTarget(c81009033.splimit)
c:RegisterEffect(e2)
--destroy
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TOEXTRA+CATEGORY_REMOVE)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,10678779)
e3:SetCost(c81009033.descost)
e3:SetTarget(c81009033.destg)
e3:SetOperation(c81009033.desop)
c:RegisterEffect(e3)
end
function c81009033.spcostfilter(c)
return c:IsAbleToRemoveAsCost() and (c:IsType(TYPE_SYNCHRO) or c:IsType(TYPE_XYZ))
end
function c81009033.spcost_selector(c,tp,g,sg,i)
sg:AddCard(c)
g:RemoveCard(c)
local flag=false
if i<2 then
flag=g:IsExists(c81009033.spcost_selector,1,nil,tp,g,sg,i+1)
else
flag=sg:FilterCount(Card.IsType,nil,TYPE_SYNCHRO)>0
and sg:FilterCount(Card.IsType,nil,TYPE_XYZ)>0
end
sg:RemoveCard(c)
g:AddCard(c)
return flag
end
function c81009033.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
if Duel.GetMZoneCount(tp)<=0 then return false end
local g=Duel.GetMatchingGroup(c81009033.spcostfilter,tp,LOCATION_EXTRA,0,nil)
local sg=Group.CreateGroup()
return g:IsExists(c81009033.spcost_selector,1,nil,tp,g,sg,1)
end
function c81009033.spop(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.GetMatchingGroup(c81009033.spcostfilter,tp,LOCATION_EXTRA,0,nil)
local sg=Group.CreateGroup()
for i=1,2 do
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g1=g:FilterSelect(tp,c81009033.spcost_selector,1,1,nil,tp,g,sg,i)
sg:Merge(g1)
g:Sub(g1)
end
Duel.Remove(sg,POS_FACEUP,REASON_COST)
end
function c81009033.splimit(e,c,sump,sumtype,sumpos,targetp)
return c:IsType(TYPE_FUSION) or c:IsType(TYPE_LINK)
end
function c81009033.descost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsReleasable() end
Duel.Release(e:GetHandler(),REASON_COST)
end
function c81009033.filter(c,tp)
local ctype=bit.band(c:GetType(),TYPE_SYNCHRO+TYPE_XYZ)
return c:IsFaceup() and ctype~=0 and c:IsAbleToExtra()
and Duel.IsExistingMatchingCard(c81009033.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil,ctype)
end
function c81009033.filter2(c,ctype)
return c:IsFaceup() and c:IsType(ctype) and c:IsAbleToRemove()
end
function c81009033.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_REMOVED) and chkc:IsControler(tp) and c81009033.filter(chkc,tp) end
if chk==0 then return Duel.IsExistingTarget(c81009033.filter,tp,LOCATION_REMOVED,0,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectTarget(tp,c81009033.filter,tp,LOCATION_REMOVED,0,1,1,nil,tp)
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,g,1,0,0)
local ctype=bit.band(g:GetFirst():GetType(),TYPE_SYNCHRO+TYPE_XYZ)
local dg=Duel.GetMatchingGroup(c81009033.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,nil,ctype)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,dg,1,0,0)
end
function c81009033.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,0,REASON_EFFECT)~=0 then
local ctype=bit.band(tc:GetType(),TYPE_SYNCHRO+TYPE_XYZ)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c81009033.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil,ctype)
Duel.Remove(g,POS_FACEUP,REASON_EFFECT)
end
end
--深绿魔女·高森蓝子
function c81009034.initial_effect(c)
c:EnableReviveLimit()
--special summon
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(c81009034.spcon)
e1:SetOperation(c81009034.spop)
c:RegisterEffect(e1)
--splimit
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(1,0)
e2:SetTarget(c81009034.splimit)
c:RegisterEffect(e2)
--destroy
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TOEXTRA+CATEGORY_REMOVE)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,10678779)
e3:SetCost(c81009034.descost)
e3:SetTarget(c81009034.destg)
e3:SetOperation(c81009034.desop)
c:RegisterEffect(e3)
end
function c81009034.spcostfilter(c)
return c:IsAbleToRemoveAsCost() and (c:IsType(TYPE_SYNCHRO) or c:IsType(TYPE_LINK))
end
function c81009034.spcost_selector(c,tp,g,sg,i)
sg:AddCard(c)
g:RemoveCard(c)
local flag=false
if i<2 then
flag=g:IsExists(c81009034.spcost_selector,1,nil,tp,g,sg,i+1)
else
flag=sg:FilterCount(Card.IsType,nil,TYPE_SYNCHRO)>0
and sg:FilterCount(Card.IsType,nil,TYPE_LINK)>0
end
sg:RemoveCard(c)
g:AddCard(c)
return flag
end
function c81009034.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
if Duel.GetMZoneCount(tp)<=0 then return false end
local g=Duel.GetMatchingGroup(c81009034.spcostfilter,tp,LOCATION_EXTRA,0,nil)
local sg=Group.CreateGroup()
return g:IsExists(c81009034.spcost_selector,1,nil,tp,g,sg,1)
end
function c81009034.spop(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.GetMatchingGroup(c81009034.spcostfilter,tp,LOCATION_EXTRA,0,nil)
local sg=Group.CreateGroup()
for i=1,2 do
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g1=g:FilterSelect(tp,c81009034.spcost_selector,1,1,nil,tp,g,sg,i)
sg:Merge(g1)
g:Sub(g1)
end
Duel.Remove(sg,POS_FACEUP,REASON_COST)
end
function c81009034.splimit(e,c,sump,sumtype,sumpos,targetp)
return c:IsType(TYPE_FUSION) or c:IsType(TYPE_XYZ)
end
function c81009034.descost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsReleasable() end
Duel.Release(e:GetHandler(),REASON_COST)
end
function c81009034.filter(c,tp)
local ctype=bit.band(c:GetType(),TYPE_SYNCHRO+TYPE_LINK)
return c:IsFaceup() and ctype~=0 and c:IsAbleToExtra()
and Duel.IsExistingMatchingCard(c81009034.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil,ctype)
end
function c81009034.filter2(c,ctype)
return c:IsFaceup() and c:IsType(ctype) and c:IsAbleToRemove()
end
function c81009034.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_REMOVED) and chkc:IsControler(tp) and c81009034.filter(chkc,tp) end
if chk==0 then return Duel.IsExistingTarget(c81009034.filter,tp,LOCATION_REMOVED,0,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectTarget(tp,c81009034.filter,tp,LOCATION_REMOVED,0,1,1,nil,tp)
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,g,1,0,0)
local ctype=bit.band(g:GetFirst():GetType(),TYPE_SYNCHRO+TYPE_LINK)
local dg=Duel.GetMatchingGroup(c81009034.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,nil,ctype)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,dg,1,0,0)
end
function c81009034.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,0,REASON_EFFECT)~=0 then
local ctype=bit.band(tc:GetType(),TYPE_SYNCHRO+TYPE_LINK)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c81009034.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil,ctype)
Duel.Remove(g,POS_FACEUP,REASON_EFFECT)
end
end
--炽热疾风·高森蓝子
function c81009035.initial_effect(c)
c:EnableReviveLimit()
--special summon
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND)
e1:SetCondition(c81009035.spcon)
e1:SetOperation(c81009035.spop)
c:RegisterEffect(e1)
--splimit
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(1,0)
e2:SetTarget(c81009035.splimit)
c:RegisterEffect(e2)
--destroy
local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TOEXTRA+CATEGORY_REMOVE)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,10678779)
e3:SetCost(c81009035.descost)
e3:SetTarget(c81009035.destg)
e3:SetOperation(c81009035.desop)
c:RegisterEffect(e3)
end
function c81009035.spcostfilter(c)
return c:IsAbleToRemoveAsCost() and (c:IsType(TYPE_LINK) or c:IsType(TYPE_XYZ))
end
function c81009035.spcost_selector(c,tp,g,sg,i)
sg:AddCard(c)
g:RemoveCard(c)
local flag=false
if i<2 then
flag=g:IsExists(c81009035.spcost_selector,1,nil,tp,g,sg,i+1)
else
flag=sg:FilterCount(Card.IsType,nil,TYPE_LINK)>0
and sg:FilterCount(Card.IsType,nil,TYPE_XYZ)>0
end
sg:RemoveCard(c)
g:AddCard(c)
return flag
end
function c81009035.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
if Duel.GetMZoneCount(tp)<=0 then return false end
local g=Duel.GetMatchingGroup(c81009035.spcostfilter,tp,LOCATION_EXTRA,0,nil)
local sg=Group.CreateGroup()
return g:IsExists(c81009035.spcost_selector,1,nil,tp,g,sg,1)
end
function c81009035.spop(e,tp,eg,ep,ev,re,r,rp,c)
local g=Duel.GetMatchingGroup(c81009035.spcostfilter,tp,LOCATION_EXTRA,0,nil)
local sg=Group.CreateGroup()
for i=1,2 do
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g1=g:FilterSelect(tp,c81009035.spcost_selector,1,1,nil,tp,g,sg,i)
sg:Merge(g1)
g:Sub(g1)
end
Duel.Remove(sg,POS_FACEUP,REASON_COST)
end
function c81009035.splimit(e,c,sump,sumtype,sumpos,targetp)
return c:IsType(TYPE_FUSION) or c:IsType(TYPE_SYNCHRO)
end
function c81009035.descost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsReleasable() end
Duel.Release(e:GetHandler(),REASON_COST)
end
function c81009035.filter(c,tp)
local ctype=bit.band(c:GetType(),TYPE_LINK+TYPE_XYZ)
return c:IsFaceup() and ctype~=0 and c:IsAbleToExtra()
and Duel.IsExistingMatchingCard(c81009035.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil,ctype)
end
function c81009035.filter2(c,ctype)
return c:IsFaceup() and c:IsType(ctype) and c:IsAbleToRemove()
end
function c81009035.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_REMOVED) and chkc:IsControler(tp) and c81009035.filter(chkc,tp) end
if chk==0 then return Duel.IsExistingTarget(c81009035.filter,tp,LOCATION_REMOVED,0,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectTarget(tp,c81009035.filter,tp,LOCATION_REMOVED,0,1,1,nil,tp)
Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,g,1,0,0)
local ctype=bit.band(g:GetFirst():GetType(),TYPE_LINK+TYPE_XYZ)
local dg=Duel.GetMatchingGroup(c81009035.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,nil,ctype)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,dg,1,0,0)
end
function c81009035.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,0,REASON_EFFECT)~=0 then
local ctype=bit.band(tc:GetType(),TYPE_LINK+TYPE_XYZ)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c81009035.filter2,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil,ctype)
Duel.Remove(g,POS_FACEUP,REASON_EFFECT)
end
end
--早餐的点心
function c81010013.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DRAW)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,81010013+EFFECT_COUNT_CODE_DUEL)
e1:SetCondition(c81010013.condition)
e1:SetCost(c81010013.cost)
e1:SetTarget(c81010013.target)
e1:SetOperation(c81010013.activate)
c:RegisterEffect(e1)
end
function c81010013.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetLP(tp)<=1000
end
function c81010013.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLP(tp)>100 end
local lp=Duel.GetLP(tp)
e:SetLabel(lp-100)
Duel.PayLPCost(tp,lp-100)
end
function c81010013.target(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 c81010013.activate(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)
if not e:IsHasType(EFFECT_TYPE_ACTIVATE) then return end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_DISCARD_HAND)
e1:SetTargetRange(1,0)
e1:SetValue(1)
Duel.RegisterEffect(e1,tp)
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_CANNOT_TO_GRAVE_AS_COST)
e2:SetTargetRange(LOCATION_HAND,0)
e2:SetValue(1)
Duel.RegisterEffect(e2,tp)
end
--照样被吓个半死
function c81010031.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,81010031)
e1:SetTarget(c81010031.target)
e1:SetOperation(c81010031.activate)
c:RegisterEffect(e1)
end
function c81010031.filter(c)
return c:IsFaceup() and c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsAbleToHand()
end
function c81010031.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c81010031.filter,tp,LOCATION_SZONE,0,1,e:GetHandler())
and Duel.IsExistingMatchingCard(nil,tp,LOCATION_MZONE,0,1,nil) end
local sg=Duel.GetMatchingGroup(nil,tp,LOCATION_MZONE,0,nil)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_SZONE)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,sg,sg:GetCount(),0,0)
end
function c81010031.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local g=Duel.SelectMatchingCard(tp,c81010031.filter,tp,LOCATION_SZONE,0,1,1,e:GetHandler())
local tc=g:GetFirst()
if tc and Duel.SendtoHand(tc,nil,REASON_EFFECT)~=0 and tc:IsLocation(LOCATION_HAND) then
local sg=Duel.GetMatchingGroup(nil,tp,LOCATION_MZONE,0,nil)
Duel.Destroy(sg,REASON_EFFECT)
end
end
--不自然的堕落
function c81010036.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMING_TOHAND+TIMINGS_CHECK_MONSTER)
e1:SetCountLimit(1,81010036+EFFECT_COUNT_CODE_DUEL+EFFECT_COUNT_CODE_OATH)
e1:SetCost(c81010036.cost)
e1:SetTarget(c81010036.target)
e1:SetOperation(c81010036.activate)
c:RegisterEffect(e1)
end
function c81010036.costfilter(c)
return c:IsAttackAbove(3000)
end
function c81010036.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckReleaseGroup(tp,c81010036.costfilter,1,nil) end
local g=Duel.SelectReleaseGroup(tp,c81010036.costfilter,1,1,nil)
Duel.Release(g,REASON_COST)
end
function c81010036.tgfilter(c)
return c:IsFaceup() and c:IsType(TYPE_RITUAL) and c:IsType(TYPE_MONSTER)
end
function c81010036.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
local g=Duel.GetMatchingGroup(c81010036.tgfilter,tp,0,LOCATION_MZONE,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
end
function c81010036.filter(c)
return c:IsType(TYPE_RITUAL) and c:IsType(TYPE_MONSTER)
end
function c81010036.activate(e,tp,eg,ep,ev,re,r,rp)
local conf=Duel.GetFieldGroup(tp,0,LOCATION_MZONE+LOCATION_HAND)
if conf:GetCount()>0 then
Duel.ConfirmCards(tp,conf)
local dg=conf:Filter(c81010036.filter,nil)
Duel.Destroy(dg,REASON_EFFECT)
Duel.ShuffleHand(1-tp)
end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_DRAW)
e1:SetOperation(c81010036.desop)
e1:SetReset(RESET_PHASE+PHASE_END+RESET_OPPO_TURN,3)
Duel.RegisterEffect(e1,tp)
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetCountLimit(1)
e2:SetCondition(c81010036.turncon)
e2:SetOperation(c81010036.turnop)
e2:SetReset(RESET_PHASE+PHASE_END+RESET_OPPO_TURN,3)
Duel.RegisterEffect(e2,tp)
e2:SetLabelObject(e1)
e:GetHandler():RegisterFlagEffect(1082946,RESET_PHASE+PHASE_END+RESET_OPPO_TURN,0,3)
c81010036[e:GetHandler()]=e2
end
function c81010036.desop(e,tp,eg,ep,ev,re,r,rp)
if ep==e:GetOwnerPlayer() then return end
local hg=eg:Filter(Card.IsLocation,nil,LOCATION_HAND)
if hg:GetCount()==0 then return end
Duel.ConfirmCards(1-ep,hg)
local dg=hg:Filter(c81010036.filter,nil)
Duel.Destroy(dg,REASON_EFFECT)
Duel.ShuffleHand(ep)
end
function c81010036.turncon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()~=tp
end
function c81010036.turnop(e,tp,eg,ep,ev,re,r,rp)
local ct=e:GetLabel()
ct=ct+1
e:SetLabel(ct)
e:GetHandler():SetTurnCounter(ct)
if ct==3 then
e:GetLabelObject():Reset()
e:GetOwner():ResetFlagEffect(1082946)
end
end
--终将分离
function c81011008.initial_effect(c)
--special summon
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_TO_GRAVE)
e1:SetCondition(c81011008.spcon)
e1:SetTarget(c81011008.sptg)
e1:SetOperation(c81011008.spop)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EVENT_REMOVE)
c:RegisterEffect(e2)
end
function c81011008.spcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsReason(REASON_EFFECT) and rp==1-tp and c:GetPreviousControler()==tp
and c:IsPreviousLocation(LOCATION_ONFIELD) and c:IsPreviousPosition(POS_FACEDOWN)
end
function c81011008.spfilter(c,e,tp)
return c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c81011008.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c81011008.spfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE)
end
function c81011008.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c81011008.spfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
--爽了鸽
function c81011012.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkType,TYPE_LINK),2)
c:EnableReviveLimit()
end
--绫濑亚梦·幼驯染 --绫濑亚梦·幼驯染
function c81011020.initial_effect(c) function c81011020.initial_effect(c)
--fusion material --fusion material
c:EnableReviveLimit() c:EnableReviveLimit()
aux.AddFusionProcFunRep(c,c81011023.ffilter,3,true) aux.AddFusionProcFunRep(c,c81011020.ffilter,3,true)
--name --name
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_IGNITION) e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET) e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCountLimit(1) e1:SetCountLimit(1)
e1:SetTarget(c81011020.nmtg) e1:SetTarget(c81011020.nmtg)
e1:SetOperation(c81011020.nmop) e1:SetOperation(c81011020.nmop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--token --token
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_REMOVE) e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN+CATEGORY_REMOVE)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY) e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_SPSUMMON_SUCCESS) e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCountLimit(1,81011020) e2:SetCountLimit(1,81011020)
e2:SetCondition(c81011020.tkcon) e2:SetCondition(c81011020.tkcon)
e2:SetTarget(c81011020.tktg) e2:SetTarget(c81011020.tktg)
e2:SetOperation(c81011020.tkop) e2:SetOperation(c81011020.tkop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--special summon --special summon
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY) e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_TO_GRAVE) e3:SetCode(EVENT_TO_GRAVE)
e3:SetCountLimit(1,81011920+EFFECT_COUNT_CODE_SINGLE) e3:SetCountLimit(1,81011920+EFFECT_COUNT_CODE_SINGLE)
e3:SetTarget(c81011020.sptg) e3:SetTarget(c81011020.sptg)
e3:SetOperation(c81011020.spop) e3:SetOperation(c81011020.spop)
c:RegisterEffect(e3) c:RegisterEffect(e3)
local e4=e3:Clone() local e4=e3:Clone()
e4:SetCode(EVENT_REMOVE) e4:SetCode(EVENT_REMOVE)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c81011020.ffilter(c,fc,sub,mg,sg) function c81011020.ffilter(c,fc,sub,mg,sg)
return (not c:IsType(TYPE_TOKEN)) and (not sg or sg:FilterCount(aux.TRUE,c)==0 or sg:IsExists(Card.IsFusionCode,1,c,c:GetFusionCode())) return (not c:IsType(TYPE_TOKEN)) and (not sg or sg:FilterCount(aux.TRUE,c)==0 or sg:IsExists(Card.IsFusionCode,1,c,c:GetFusionCode()))
end end
function c81011020.nmfilter(c,cd) function c81011020.nmfilter(c,cd)
return (c:IsFaceup() or c:IsLocation(LOCATION_GRAVE)) return (c:IsFaceup() or c:IsLocation(LOCATION_GRAVE))
and not c:IsCode(cd) and not c:IsCode(cd)
end end
function c81011020.nmtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c81011020.nmtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local cd=e:GetHandler():GetCode() local cd=e:GetHandler():GetCode()
if chkc then return chkc:IsLocation(LOCATION_MZONE+LOCATION_GRAVE) and c81011020.nmfilter(chkc,cd) end if chkc then return chkc:IsLocation(LOCATION_MZONE+LOCATION_GRAVE) and c81011020.nmfilter(chkc,cd) end
if chk==0 then return Duel.IsExistingTarget(c81011020.nmfilter,tp,LOCATION_MZONE+LOCATION_GRAVE,LOCATION_MZONE+LOCATION_GRAVE,1,nil,cd) end if chk==0 then return Duel.IsExistingTarget(c81011020.nmfilter,tp,LOCATION_MZONE+LOCATION_GRAVE,LOCATION_MZONE+LOCATION_GRAVE,1,nil,cd) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
Duel.SelectTarget(tp,c81011020.nmfilter,tp,LOCATION_MZONE+LOCATION_GRAVE,0,1,1,nil,cd) Duel.SelectTarget(tp,c81011020.nmfilter,tp,LOCATION_MZONE+LOCATION_GRAVE,0,1,1,nil,cd)
end end
function c81011020.nmop(e,tp,eg,ep,ev,re,r,rp) function c81011020.nmop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if c:IsRelateToEffect(e) and c:IsFaceup() and tc:IsRelateToEffect(e) and (tc:IsLocation(LOCATION_GRAVE) or tc:IsFaceup()) then if c:IsRelateToEffect(e) and c:IsFaceup() and tc:IsRelateToEffect(e) and (tc:IsLocation(LOCATION_GRAVE) or tc:IsFaceup()) then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CHANGE_CODE) e1:SetCode(EFFECT_CHANGE_CODE)
e1:SetValue(tc:GetOriginalCode()) e1:SetValue(tc:GetOriginalCode())
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
end end
function c81011020.tkcon(e,tp,eg,ep,ev,re,r,rp) function c81011020.tkcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(Card.IsSummonType,1,e:GetHandler(),SUMMON_TYPE_FUSION) return eg:IsExists(Card.IsSummonType,1,e:GetHandler(),SUMMON_TYPE_FUSION)
end end
function c81011020.tktg(e,tp,eg,ep,ev,re,r,rp,chk) function c81011020.tktg(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(Card.IsAbleToRemove,tp,LOCATION_MZONE,0,1,nil) and Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,LOCATION_MZONE,0,1,nil)
and Duel.IsPlayerCanSpecialSummonMonster(tp,81011019,0,0x4011,2800,2000,8,RACE_PLANT,ATTRIBUTE_EARTH) end and Duel.IsPlayerCanSpecialSummonMonster(tp,81011019,0,0x4011,2800,2000,8,RACE_PLANT,ATTRIBUTE_EARTH) 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,1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
end end
function c81011020.tkop(e,tp,eg,ep,ev,re,r,rp) function c81011020.tkop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
if Duel.IsPlayerCanSpecialSummonMonster(tp,81011019,0,0x4011,2800,2000,8,RACE_PLANT,ATTRIBUTE_EARTH) then if Duel.IsPlayerCanSpecialSummonMonster(tp,81011019,0,0x4011,2800,2000,8,RACE_PLANT,ATTRIBUTE_EARTH) then
local token=Duel.CreateToken(tp,81011019) local token=Duel.CreateToken(tp,81011019)
Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP)
end end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,Card.IsAbleToRemove,tp,LOCATION_MZONE,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,Card.IsAbleToRemove,tp,LOCATION_MZONE,0,1,1,nil)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.BreakEffect() Duel.BreakEffect()
Duel.Remove(g,POS_FACEUP,REASON_EFFECT) Duel.Remove(g,POS_FACEUP,REASON_EFFECT)
end end
end end
function c81011020.thfilter2(c) function c81011020.thfilter2(c)
return c:IsCode(81011021) and c:IsAbleToHand() return c:IsCode(81011021) and c:IsAbleToHand()
end end
function c81011020.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c81011020.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c81011020.thfilter2,tp,LOCATION_DECK,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c81011020.thfilter2,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end end
function c81011020.spop(e,tp,eg,ep,ev,re,r,rp) function c81011020.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c81011020.thfilter2,tp,LOCATION_DECK,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c81011020.thfilter2,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT) Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g) Duel.ConfirmCards(1-tp,g)
end end
end end
--小小的奖励·爱米莉 --小小的奖励·爱米莉
function c81012029.initial_effect(c) function c81012029.initial_effect(c)
--pendulum summon --pendulum summon
aux.EnablePendulumAttribute(c) aux.EnablePendulumAttribute(c)
c:EnableReviveLimit() c:EnableReviveLimit()
--draw --draw
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DRAW) e1:SetCategory(CATEGORY_DRAW)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_DESTROYED) e1:SetCode(EVENT_DESTROYED)
e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_DELAY)
e1:SetRange(LOCATION_PZONE) e1:SetRange(LOCATION_PZONE)
e1:SetCountLimit(1,81012029) e1:SetCountLimit(1,81012029)
e1:SetCondition(c81012029.drcon) e1:SetCondition(c81012029.drcon)
e1:SetTarget(c81012029.drtg) e1:SetTarget(c81012029.drtg)
e1:SetOperation(c81012029.drop) e1:SetOperation(c81012029.drop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--atkup --atkup
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)
e2:SetCode(EFFECT_UPDATE_ATTACK) e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetValue(c81012029.val) e2:SetValue(c81012029.val)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--negate --negate
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET) e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetType(EFFECT_TYPE_QUICK_O) e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_FREE_CHAIN) e3:SetCode(EVENT_FREE_CHAIN)
e3:SetRange(LOCATION_MZONE) e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,81012929) e3:SetCountLimit(1,81012929)
e3:SetTarget(c81012029.target) e3:SetTarget(c81012029.target)
e3:SetOperation(c81012029.operation) e3:SetOperation(c81012029.operation)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--tohand --tohand
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) e4:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e4:SetCode(EVENT_RELEASE) e4:SetCode(EVENT_RELEASE)
e4:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY) e4:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e4:SetCountLimit(1,81092929) e4:SetCountLimit(1,81092929)
e4:SetTarget(c81012029.thtg) e4:SetTarget(c81012029.thtg)
e4:SetOperation(c81012029.thop) e4:SetOperation(c81012029.thop)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c81012029.cfilter(c,tp) function c81012029.cfilter(c,tp)
return c:IsPreviousLocation(LOCATION_ONFIELD) and c:IsReason(REASON_EFFECT) return c:IsPreviousLocation(LOCATION_ONFIELD) and c:IsReason(REASON_EFFECT)
end end
function c81012029.drcon(e,tp,eg,ep,ev,re,r,rp) function c81012029.drcon(e,tp,eg,ep,ev,re,r,rp)
local des=eg:GetFirst() local des=eg:GetFirst()
if des:IsReason(REASON_BATTLE) then if des:IsReason(REASON_BATTLE) then
local rc=des:GetReasonCard() local rc=des:GetReasonCard()
return rc and rc:IsType(TYPE_RITUAL) and re:IsType(TYPE_PENDULUM) and rc:IsControler(tp) and rc:IsRelateToBattle() return rc and rc:IsType(TYPE_RITUAL) and rc:IsType(TYPE_PENDULUM) and rc:IsControler(tp) and rc:IsRelateToBattle()
elseif re then elseif re then
local rc=re:GetHandler() local rc=re:GetHandler()
return eg:IsExists(c81012029.cfilter,1,nil,tp) return eg:IsExists(c81012029.cfilter,1,nil,tp)
and rc and rc:IsType(TYPE_RITUAL) and re:IsType(TYPE_PENDULUM) and rc:IsControler(tp) and re:IsActiveType(TYPE_MONSTER) and rc and rc:IsType(TYPE_RITUAL) and rc:IsType(TYPE_PENDULUM) and rc:IsControler(tp) and re:IsActiveType(TYPE_MONSTER)
end end
return false return false
end end
function c81012029.drtg(e,tp,eg,ep,ev,re,r,rp,chk) function c81012029.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetTargetPlayer(tp) Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(1) Duel.SetTargetParam(1)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1) Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
end end
function c81012029.drop(e,tp,eg,ep,ev,re,r,rp) function c81012029.drop(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM) local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Draw(p,d,REASON_EFFECT) Duel.Draw(p,d,REASON_EFFECT)
end end
function c81012029.val(e,c) function c81012029.val(e,c)
return Duel.GetMatchingGroupCount(Card.IsFaceup,c:GetControler(),LOCATION_PZONE,LOCATION_PZONE,nil,nil)*500 return Duel.GetMatchingGroupCount(Card.IsFaceup,c:GetControler(),LOCATION_PZONE,LOCATION_PZONE,nil,nil)*500
end end
function c81012029.filter(c) function c81012029.filter(c)
return c:IsFaceup() and c:IsSummonType(SUMMON_TYPE_SPECIAL) return c:IsFaceup() and c:IsSummonType(SUMMON_TYPE_SPECIAL)
end end
function c81012029.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c81012029.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c81012029.filter(chkc) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and c81012029.filter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c81012029.filter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end if chk==0 then return Duel.IsExistingTarget(c81012029.filter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,c81012029.filter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) Duel.SelectTarget(tp,c81012029.filter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
end end
function c81012029.operation(e,tp,eg,ep,ev,re,r,rp) function c81012029.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsFaceup() and tc:IsRelateToEffect(e) then if tc:IsFaceup() and tc:IsRelateToEffect(e) then
Duel.NegateRelatedChain(tc,RESET_TURN_SET) Duel.NegateRelatedChain(tc,RESET_TURN_SET)
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:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCode(EFFECT_DISABLE) e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1) tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE) e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetCode(EFFECT_DISABLE_EFFECT) e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetValue(RESET_TURN_SET) e2:SetValue(RESET_TURN_SET)
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)
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE) e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_CANNOT_DISABLE) e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_CANNOT_DISABLE)
e3:SetRange(LOCATION_MZONE) e3:SetRange(LOCATION_MZONE)
e3:SetCode(EFFECT_IMMUNE_EFFECT) e3:SetCode(EFFECT_IMMUNE_EFFECT)
e3:SetValue(c81012029.efilter) e3:SetValue(c81012029.efilter)
e3:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e3:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e3) tc:RegisterEffect(e3)
end end
end end
function c81012029.efilter(e,te) function c81012029.efilter(e,te)
return te:GetOwner()~=e:GetOwner() return te:GetOwner()~=e:GetOwner()
end end
function c81012029.thfilter(c) function c81012029.thfilter(c)
return c:IsFaceup() and c:IsType(TYPE_RITUAL) and c:IsType(TYPE_PENDULUM) and c:IsAbleToHand() and not c:IsCode(81012029) return c:IsFaceup() and c:IsType(TYPE_RITUAL) and c:IsType(TYPE_PENDULUM) and c:IsAbleToHand() and not c:IsCode(81012029)
end end
function c81012029.thtg(e,tp,eg,ep,ev,re,r,rp,chk) function c81012029.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c81012029.thfilter,tp,LOCATION_EXTRA,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c81012029.thfilter,tp,LOCATION_EXTRA,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_EXTRA) Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_EXTRA)
end end
function c81012029.thop(e,tp,eg,ep,ev,re,r,rp) function c81012029.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c81012029.thfilter,tp,LOCATION_EXTRA,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c81012029.thfilter,tp,LOCATION_EXTRA,0,1,1,nil)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT) Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g) Duel.ConfirmCards(1-tp,g)
end end
end end
--混世魔王·萩原雪步
function c81013016.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,aux.NOT(aux.FilterBoolFunction(Card.IsLinkType,TYPE_TOKEN)),3,3)
c:EnableReviveLimit()
--atk gain
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetRange(LOCATION_MZONE)
e1:SetValue(c81013016.value)
c:RegisterEffect(e1)
--remove
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetProperty(EFFECT_FLAG_SET_AVAILABLE+EFFECT_FLAG_IGNORE_RANGE+EFFECT_FLAG_IGNORE_IMMUNE)
e2:SetRange(LOCATION_SZONE)
e2:SetCode(EFFECT_TO_GRAVE_REDIRECT)
e2:SetTargetRange(0xff,0xff)
e2:SetValue(LOCATION_REMOVED)
c:RegisterEffect(e2)
end
function c81013016.value(e,c)
return Duel.GetFieldGroupCount(c:GetControler(),LOCATION_REMOVED,LOCATION_REMOVED)*200
end
--新春之华·如月千早
function c81013021.initial_effect(c)
--link summon
aux.AddLinkProcedure(c,c81013021.mfilter,2,2)
c:EnableReviveLimit()
--search
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCountLimit(1,81013021)
e1:SetCondition(c81013021.thcon)
e1:SetTarget(c81013021.thtg)
e1:SetOperation(c81013021.thop)
c:RegisterEffect(e1)
--special summon
local e4=Effect.CreateEffect(c)
e4:SetCategory(CATEGORY_SPECIAL_SUMMON)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e4:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET)
e4:SetCode(EVENT_DESTROYED)
e4:SetCountLimit(1,81013921)
e4:SetCondition(c81013021.spcon)
e4:SetCost(c81013021.spcost)
e4:SetTarget(c81013021.sptg)
e4:SetOperation(c81013021.spop)
c:RegisterEffect(e4)
end
function c81013021.mfilter(c)
return c:IsLinkType(TYPE_MONSTER) and c:IsLinkType(TYPE_RITUAL)
end
function c81013021.thcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_LINK)
end
function c81013021.thfilter(c)
return c:IsType(TYPE_RITUAL) and c:IsAbleToHand()
end
function c81013021.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c81013021.thfilter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function c81013021.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c81013021.thfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
function c81013021.spcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:GetPreviousControler()==tp
and (c:IsReason(REASON_EFFECT) and rp==1-tp or c:IsReason(REASON_BATTLE) and Duel.GetAttacker():IsControler(1-tp))
end
function c81013021.spcfilter(c)
return c:IsAttribute(ATTRIBUTE_WATER) and c:IsAbleToGraveAsCost()
end
function c81013021.thcfilter(c)
return c:IsType(TYPE_RITUAL) and c:IsType(TYPE_SPELL) and c:IsDiscardable()
end
function c81013021.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c81013021.thcfilter,tp,LOCATION_HAND,0,1,nil) end
Duel.DiscardHand(tp,c81013021.thcfilter,1,1,REASON_COST+REASON_DISCARD)
end
function c81013021.spfilter(c,e,tp)
return c:IsType(TYPE_RITUAL) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE)
end
function c81013021.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c81013021.spfilter(chkc,e,tp) end
if chk==0 then return Duel.IsExistingTarget(c81013021.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c81013021.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function c81013021.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP_DEFENSE)
end
end
--中野一花
function c81014022.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
--atk up
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_ATKCHANGE)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_ATTACK_ANNOUNCE)
e1:SetRange(LOCATION_PZONE)
e1:SetCountLimit(1)
e1:SetCondition(c81014022.atkcon)
e1:SetTarget(c81014022.atktg)
e1:SetOperation(c81014022.atkop)
c:RegisterEffect(e1)
end
function c81014022.atkcon(e,tp,eg,ep,ev,re,r,rp)
local a=Duel.GetAttacker()
local d=Duel.GetAttackTarget()
if d and a:GetControler()~=d:GetControler() then
if a:IsControler(tp) and a:IsType(TYPE_NORMAL) then e:SetLabelObject(a)
elseif d:IsType(TYPE_NORMAL) then e:SetLabelObject(d)
else return false end
return true
else return false end
end
function c81014022.atktg(e,tp,eg,ep,ev,re,r,rp,chk)
local tc=e:GetLabelObject()
if chk==0 then return tc:IsOnField() end
Duel.SetTargetCard(tc)
end
function c81014022.atkop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsFaceup() and tc:IsControler(tp) then
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(1200)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_BATTLE)
tc:RegisterEffect(e1)
end
end
--1/5·中野二乃
function c81014023.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
--attack thrice
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetRange(LOCATION_PZONE)
e2:SetCountLimit(1)
e2:SetCondition(c81014023.atkcon)
e2:SetTarget(c81014023.atktg)
e2:SetOperation(c81014023.atkop)
c:RegisterEffect(e2)
end
function c81014023.atkcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsAbleToEnterBP()
end
function c81014023.atkfilter(c)
return c:IsFaceup() and c:IsType(TYPE_NORMAL)
end
function c81014023.atktg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c81014023.atkfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c81014023.atkfilter,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,c81014023.atkfilter,tp,LOCATION_MZONE,0,1,1,nil)
end
function c81014023.atkop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_EXTRA_ATTACK_MONSTER)
e1:SetValue(3)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
end
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_CANNOT_ATTACK)
e2:SetTargetRange(LOCATION_MZONE,0)
e2:SetTarget(c81014023.ftarget)
e2:SetLabel(tc:GetFieldID())
e2:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e2,tp)
end
function c81014023.ftarget(e,c)
return e:GetLabel()~=c:GetFieldID()
end
--1/5·中野三玖
function c81014024.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
--spsummon
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_DAMAGE)
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_PZONE)
e2:SetCountLimit(1,81014024)
e2:SetCondition(c81014024.spcon1)
e2:SetTarget(c81014024.sptg1)
e2:SetOperation(c81014024.spop1)
c:RegisterEffect(e2)
end
function c81014024.cfilter(c,tp)
return c:IsReason(REASON_BATTLE+REASON_EFFECT) and c:IsType(TYPE_NORMAL)
and c:IsType(TYPE_PENDULUM) and c:IsPreviousLocation(LOCATION_MZONE) and c:IsPreviousPosition(POS_FACEUP) and c:GetPreviousControler()==tp
end
function c81014024.spcon1(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c81014024.cfilter,1,nil,tp)
end
function c81014024.sptg1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,0,0,tp,1500)
end
function c81014024.spop1(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
if Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then
Duel.BreakEffect()
Duel.Damage(tp,1500,REASON_EFFECT)
end
end
--1/5·中野四叶
function c81014025.initial_effect(c)
aux.EnablePendulumAttribute(c)
--splimit
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetRange(LOCATION_PZONE)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE)
e1:SetTargetRange(1,0)
e1:SetTarget(c81014025.splimit)
c:RegisterEffect(e1)
--special summon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(81014025,0))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetRange(LOCATION_PZONE)
e2:SetCountLimit(1,81014025)
e2:SetTarget(c81014025.sptg)
e2:SetOperation(c81014025.spop)
c:RegisterEffect(e2)
end
function c81014025.splimit(e,c,tp,sumtp,sumpos)
return not c:IsType(TYPE_NORMAL) and bit.band(sumtp,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
function c81014025.spfilter(c,e,tp)
return c:IsType(TYPE_NORMAL) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c81014025.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and c81014025.spfilter(chkc,e,tp) end
if chk==0 then return Duel.IsExistingTarget(c81014025.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c81014025.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,e:GetHandler(),1,0,0)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end
function c81014025.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if c:IsRelateToEffect(e) and Duel.Destroy(c,REASON_EFFECT)~=0 and tc:IsRelateToEffect(e) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end
end
--1/5·中野五月
function c81014026.initial_effect(c)
--pendulum summon
aux.EnablePendulumAttribute(c)
--splimit
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE)
e2:SetRange(LOCATION_PZONE)
e2:SetTargetRange(1,0)
e2:SetTarget(c81014026.splimit)
c:RegisterEffect(e2)
--atk up
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetRange(LOCATION_PZONE)
e3:SetCode(EFFECT_UPDATE_ATTACK)
e3:SetTargetRange(LOCATION_MZONE,0)
e3:SetTarget(aux.TargetBoolFunction(Card.IsType,TYPE_NORMAL))
e3:SetValue(400)
c:RegisterEffect(e3)
end
function c81014026.splimit(e,c)
return c:IsType(TYPE_EFFECT)
end
--第三领域 --第三领域
function c9980197.initial_effect(c) function c9980197.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--special summon --special summon
local e5=Effect.CreateEffect(c) local e5=Effect.CreateEffect(c)
e5:SetDescription(aux.Stringid(9980197,0)) e5:SetDescription(aux.Stringid(9980197,0))
e5:SetCategory(CATEGORY_SPECIAL_SUMMON) e5:SetCategory(CATEGORY_SPECIAL_SUMMON)
e5:SetProperty(EFFECT_FLAG_CARD_TARGET) e5:SetProperty(EFFECT_FLAG_CARD_TARGET)
e5:SetType(EFFECT_TYPE_IGNITION) e5:SetType(EFFECT_TYPE_IGNITION)
e5:SetRange(LOCATION_SZONE) e5:SetRange(LOCATION_SZONE)
e5:SetCountLimit(1) e5:SetCountLimit(1)
e5:SetTarget(c9980197.sptg) e5:SetTarget(c9980197.sptg)
e5:SetOperation(c9980197.spop) e5:SetOperation(c9980197.spop)
c:RegisterEffect(e5) c:RegisterEffect(e5)
--spsummon --spsummon
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(9980197,1)) e2:SetDescription(aux.Stringid(9980197,1))
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_DESTROYED) e2:SetCode(EVENT_DESTROYED)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY) e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e2:SetRange(LOCATION_SZONE) e2:SetRange(LOCATION_SZONE)
e2:SetCountLimit(1) e2:SetCountLimit(1)
e2:SetCondition(c9980197.thcon) e2:SetCondition(c9980197.thcon)
e2:SetTarget(c9980197.thtg) e2:SetTarget(c9980197.thtg)
e2:SetOperation(c9980197.thop) e2:SetOperation(c9980197.thop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(9980197,2)) e1:SetDescription(aux.Stringid(9980197,2))
e1:SetCategory(CATEGORY_TOGRAVE+CATEGORY_SPECIAL_SUMMON) e1:SetCategory(CATEGORY_TOGRAVE+CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_QUICK_O) e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetRange(LOCATION_SZONE) e1:SetRange(LOCATION_SZONE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE) e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE)
e1:SetCost(c9980197.cost) e1:SetCost(c9980197.cost)
e1:SetTarget(c9980197.target) e1:SetTarget(c9980197.target)
e1:SetOperation(c9980197.activate) e1:SetOperation(c9980197.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function c9980197.cfilter2(c,tp) function c9980197.filter3(c,e,tp)
return c:IsSetCard(0x6bc8) and c:IsReason(REASON_BATTLE+REASON_EFFECT) return c:IsFaceup() and c:IsSetCard(0x6bc8) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
and c:IsPreviousPosition(POS_FACEUP) and c:IsPreviousLocation(LOCATION_MZONE) and c:GetPreviousControler()==tp end
end function c9980197.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
function c9980197.spcon(e,tp,eg,ep,ev,re,r,rp) if chkc then return chkc:IsLocation(LOCATION_SZONE) and chkc:IsControler(tp) and c9980197.filter3(chkc,e,tp) end
return eg:IsExists(c9980197.cfilter2,1,nil,tp) if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
end and Duel.IsExistingTarget(c9980197.filter3,tp,LOCATION_SZONE,0,1,nil,e,tp) end
function c9980197.filter3(c,e,tp) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
return c:IsFaceup() and c:IsSetCard(0x6bc8) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) local g=Duel.SelectTarget(tp,c9980197.filter3,tp,LOCATION_SZONE,0,1,1,nil,e,tp)
end Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
function c9980197.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) end
if chkc then return chkc:IsLocation(LOCATION_SZONE) and chkc:IsControler(tp) and c9980197.filter3(chkc,e,tp) end function c9980197.spop(e,tp,eg,ep,ev,re,r,rp)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if not Duel.IsExistingMatchingCard(c9980197.filter3,tp,LOCATION_SZONE,0,5,nil) then return end
and Duel.IsExistingTarget(c9980197.filter3,tp,LOCATION_SZONE,0,1,nil,e,tp) end local tc=Duel.GetFirstTarget()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) if tc:IsRelateToEffect(e) then
local g=Duel.SelectTarget(tp,c9980197.filter3,tp,LOCATION_SZONE,0,1,1,nil,e,tp) Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0) end
end Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980197,3))
function c9980197.spop(e,tp,eg,ep,ev,re,r,rp) end
if not Duel.IsExistingMatchingCard(c9980197.filter3,tp,LOCATION_SZONE,0,5,nil) then return end function c9980197.cfilter(c,tp)
local tc=Duel.GetFirstTarget() return c:IsReason(REASON_BATTLE+REASON_EFFECT)
if tc:IsRelateToEffect(e) then and c:IsPreviousLocation(LOCATION_MZONE) and c:GetPreviousControler()==tp
Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP) end
end function c9980197.thcon(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980197,3)) return eg:IsExists(c9980197.cfilter,1,nil,tp)
end end
function c9980197.cfilter(c,tp) function c9980197.thfilter(c)
return c:IsReason(REASON_BATTLE+REASON_EFFECT) return c:IsSetCard(0x6bc8) and c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsAbleToHand()
and c:IsPreviousLocation(LOCATION_MZONE) and c:GetPreviousControler()==tp end
end function c9980197.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
function c9980197.thcon(e,tp,eg,ep,ev,re,r,rp) if chk==0 then return Duel.IsExistingMatchingCard(c9980197.filter,tp,LOCATION_DECK,0,1,nil) end
return eg:IsExists(c9980197.cfilter,1,nil,tp) Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end end
function c9980197.thfilter(c) function c9980197.thop(e,tp,eg,ep,ev,re,r,rp)
return c:IsSetCard(0x6bc8) and c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsAbleToHand() Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
end local g=Duel.SelectMatchingCard(tp,c9980197.filter,tp,LOCATION_DECK,0,1,1,nil)
function c9980197.thtg(e,tp,eg,ep,ev,re,r,rp,chk) if g:GetCount()>0 then
if chk==0 then return Duel.IsExistingMatchingCard(c9980197.filter,tp,LOCATION_DECK,0,1,nil) end Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) Duel.ConfirmCards(1-tp,g)
end end
function c9980197.thop(e,tp,eg,ep,ev,re,r,rp) Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980197,3))
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) end
local g=Duel.SelectMatchingCard(tp,c9980197.filter,tp,LOCATION_DECK,0,1,1,nil) function c9980197.costfilter(c)
if g:GetCount()>0 then return c:IsFaceup() and c:IsSetCard(0x6bc8) and c:IsAbleToGraveAsCost()
Duel.SendtoHand(g,nil,REASON_EFFECT) end
Duel.ConfirmCards(1-tp,g) function c9980197.cost(e,tp,eg,ep,ev,re,r,rp,chk)
end e:SetLabel(1)
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980197,3)) if chk==0 then return Duel.IsExistingMatchingCard(c9980197.costfilter,tp,LOCATION_SZONE,0,4,nil) end
end Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
function c9980197.costfilter(c) local g=Duel.SelectMatchingCard(tp,c9980197.costfilter,tp,LOCATION_SZONE,0,4,4,nil)
return c:IsFaceup() and c:IsSetCard(0x6bc8) and c:IsAbleToGraveAsCost() Duel.SendtoGrave(g,REASON_COST)
end end
function c9980197.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c9980197.filter(c,e,tp)
e:SetLabel(1) return c:IsSetCard(0x6bc8) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
if chk==0 then return Duel.IsExistingMatchingCard(c9980197.costfilter,tp,LOCATION_SZONE,0,4,nil) end end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) function c9980197.target(e,tp,eg,ep,ev,re,r,rp,chk)
local g=Duel.SelectMatchingCard(tp,c9980197.costfilter,tp,LOCATION_SZONE,0,4,4,nil) if chk==0 then
Duel.SendtoGrave(g,REASON_COST) if e:GetLabel()~=1 then
end return Duel.IsExistingMatchingCard(c9980197.filter,tp,LOCATION_GRAVE,0,1,nil,e,tp)
function c9980197.filter(c,e,tp) else
return c:IsSetCard(0x6bc8) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) e:SetLabel(0)
end return Duel.IsExistingMatchingCard(c9980197.filter,tp,LOCATION_SZONE,0,1,nil,e,tp)
function c9980197.target(e,tp,eg,ep,ev,re,r,rp,chk) end
if chk==0 then end
if e:GetLabel()~=1 then e:SetLabel(0)
return Duel.IsExistingMatchingCard(c9980197.filter,tp,LOCATION_GRAVE,0,1,nil,e,tp) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE)
else end
e:SetLabel(0) function c9980197.ctfilter(c,tp)
return Duel.IsExistingMatchingCard(c9980197.filter,tp,LOCATION_SZONE,0,1,nil,e,tp) return c:GetPreviousControler()==tp and c:IsLocation(LOCATION_GRAVE)
end end
end function c9980197.activate(e,tp,eg,ep,ev,re,r,rp)
e:SetLabel(0) local g=Duel.GetFieldGroup(tp,0,LOCATION_ONFIELD)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) Duel.SendtoGrave(g,REASON_EFFECT)
end local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
function c9980197.ctfilter(c,tp) g=Duel.GetOperatedGroup()
return c:GetPreviousControler()==tp and c:IsLocation(LOCATION_GRAVE) local ct=g:FilterCount(c9980197.ctfilter,nil,1-tp)
end if ft>ct then ft=ct end
function c9980197.activate(e,tp,eg,ep,ev,re,r,rp) if Duel.IsPlayerAffectedByEffect(tp,59822133) then ft=1 end
local g=Duel.GetFieldGroup(tp,0,LOCATION_ONFIELD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
Duel.SendtoGrave(g,REASON_EFFECT) g=Duel.SelectMatchingCard(tp,c9980197.filter,tp,LOCATION_GRAVE,0,ft,ft,nil,e,tp)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE) if g:GetCount()>0 then
g=Duel.GetOperatedGroup() Duel.BreakEffect()
local ct=g:FilterCount(c9980197.ctfilter,nil,1-tp) Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
if ft>ct then ft=ct end end
if Duel.IsPlayerAffectedByEffect(tp,59822133) then ft=1 end Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980197,3))
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) end
g=Duel.SelectMatchingCard(tp,c9980197.filter,tp,LOCATION_GRAVE,0,ft,ft,nil,e,tp)
if g:GetCount()>0 then
Duel.BreakEffect()
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980197,3))
end
--物语纪录·北白蛇神社 --物语纪录·北白蛇神社
function c9980237.initial_effect(c) function c9980237.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--level --level
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_UPDATE_LEVEL) e2:SetCode(EFFECT_UPDATE_LEVEL)
e2:SetRange(LOCATION_FZONE) e2:SetRange(LOCATION_FZONE)
e2:SetTargetRange(LOCATION_HAND,LOCATION_HAND) e2:SetTargetRange(LOCATION_HAND,LOCATION_HAND)
e2:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0x5bc4)) e2:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0x5bc4))
e2:SetValue(-1) e2:SetValue(-1)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--atkup --atkup
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_UPDATE_ATTACK) e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetRange(LOCATION_FZONE) e2:SetRange(LOCATION_FZONE)
e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e2:SetTarget(aux.TargetBoolFunction(Card.IsRace,RACE_SPELLCASTER)) e2:SetTarget(aux.TargetBoolFunction(Card.IsRace,RACE_SPELLCASTER))
e2:SetValue(300) e2:SetValue(300)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND) e1:SetCategory(CATEGORY_TOHAND)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET) e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetType(EFFECT_TYPE_QUICK_O) e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetRange(LOCATION_FZONE) e1:SetRange(LOCATION_FZONE)
e1:SetCountLimit(1) e1:SetCountLimit(1)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE) e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE)
e1:SetCondition(c9980237.thcon) e1:SetCondition(c9980237.thcon)
e1:SetTarget(c9980237.thtg) e1:SetTarget(c9980237.thtg)
e1:SetOperation(c9980237.thop) e1:SetOperation(c9980237.thop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--special summon --special summon
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(9980237,0)) e4:SetDescription(aux.Stringid(9980237,0))
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e4:SetCode(EVENT_LEAVE_FIELD) e4:SetCode(EVENT_LEAVE_FIELD)
e4:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY) e4:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e4:SetRange(LOCATION_FZONE) e4:SetRange(LOCATION_FZONE)
e4:SetCountLimit(1) e4:SetCountLimit(1)
e4:SetCondition(c9980237.spcon) e4:SetCondition(c9980237.spcon)
e4:SetTarget(c9980237.sptg) e4:SetTarget(c9980237.sptg)
e4:SetOperation(c9980237.spop) e4:SetOperation(c9980237.spop)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c9980237.thcon(e,tp,eg,ep,ev,re,r,rp) function c9980237.thcon(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase() local ph=Duel.GetCurrentPhase()
return ph==PHASE_MAIN1 or (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE) or ph==PHASE_MAIN2 return ph==PHASE_MAIN1 or (ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE) or ph==PHASE_MAIN2
end end
function c9980237.thfilter(c) function c9980237.thfilter(c)
return c:IsFaceup() and c:IsSetCard(0x5bc4) and c:IsType(TYPE_PENDULUM) and c:IsAbleToHand() return c:IsFaceup() and c:IsSetCard(0x5bc4) and c:IsType(TYPE_PENDULUM) and c:IsAbleToHand()
end end
function c9980237.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c9980237.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE+LOCATION_EXTRA) and chkc:IsControler(tp) and c9980237.thfilter(chkc) end if chkc then return chkc:IsLocation(LOCATION_GRAVE+LOCATION_EXTRA) and chkc:IsControler(tp) and c9980237.thfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c9980237.thfilter,tp,LOCATION_GRAVE+LOCATION_EXTRA,0,1,nil) end if chk==0 then return Duel.IsExistingTarget(c9980237.thfilter,tp,LOCATION_GRAVE+LOCATION_EXTRA,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectTarget(tp,c9980237.thfilter,tp,LOCATION_GRAVE+LOCATION_EXTRA,0,1,1,nil) local g=Duel.SelectTarget(tp,c9980237.thfilter,tp,LOCATION_GRAVE+LOCATION_EXTRA,0,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end end
function c9980237.sumfilter(c) function c9980237.sumfilter(c)
return c:IsSetCard(0x5bc4) and c:IsType(TYPE_PENDULUM) and c:IsSummonable(true,nil,1) return c:IsSetCard(0x5bc4) and c:IsType(TYPE_PENDULUM) and c:IsSummonable(true,nil,1)
end end
function c9980237.thop(e,tp,eg,ep,ev,re,r,rp) function c9980237.thop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoHand(tc,nil,REASON_EFFECT)~=0 and tc:IsLocation(LOCATION_HAND) then if tc:IsRelateToEffect(e) and Duel.SendtoHand(tc,nil,REASON_EFFECT)~=0 and tc:IsLocation(LOCATION_HAND) then
local g=Duel.GetMatchingGroup(c9980237.sumfilter,tp,LOCATION_HAND,0,nil) local g=Duel.GetMatchingGroup(c9980237.sumfilter,tp,LOCATION_HAND,0,nil)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(9980237,0)) then if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(9980237,0)) then
Duel.BreakEffect() Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON)
local sc=g:Select(tp,1,1,nil):GetFirst() local sc=g:Select(tp,1,1,nil):GetFirst()
Duel.ShuffleHand(tp) Duel.ShuffleHand(tp)
Duel.Summon(tp,sc,true,nil,1) Duel.Summon(tp,sc,true,nil,1)
else else
Duel.ShuffleHand(tp) Duel.ShuffleHand(tp)
end end
end end
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980237,1)) Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980237,1))
end end
function c9980237.spcfilter(c,tp,rp) function c9980237.spcfilter(c,tp,rp)
return c:IsPreviousPosition(POS_FACEUP) and c:GetPreviousControler()==tp and c:IsPreviousSetCard(0x5bc4) return c:IsPreviousPosition(POS_FACEUP) and c:GetPreviousControler()==tp and c:IsPreviousSetCard(0x5bc4)
and (c:IsReason(REASON_BATTLE) or (rp==1-tp and c:IsReason(REASON_EFFECT))) and (c:IsReason(REASON_BATTLE) or (rp==1-tp and c:IsReason(REASON_EFFECT)))
end end
function c9980237.spcon(e,tp,eg,ep,ev,re,r,rp) function c9980237.spcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c9980237.spcfilter,1,nil,tp,rp) return eg:IsExists(c9980237.spcfilter,1,nil,tp,rp)
end end
function c9980237.filter(c,e,tp) function c9980237.filter(c,e,tp)
return c:IsFaceup() and c:IsSetCard(0x5bc4) and c:IsType(TYPE_MONSTER) and (c:IsLocation(LOCATION_GRAVE) or (c:IsLocation(LOCATION_EXTRA)and Duel.GetLocationCountFromEx(tp,tp,c)>0)) return c:IsFaceup() and c:IsSetCard(0x5bc4) and c:IsType(TYPE_MONSTER) and (c:IsLocation(LOCATION_GRAVE) or (c:IsLocation(LOCATION_EXTRA)and Duel.GetLocationCountFromEx(tp,tp,c)>0))
and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function c9980237.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c9980237.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE+LOCATION_EXTRA) and chkc:IsControler(tp) and c9980237.filter(chkc,e,tp) end if chkc then return chkc:IsLocation(LOCATION_GRAVE+LOCATION_EXTRA) and chkc:IsControler(tp) and c9980237.filter(chkc,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingTarget(c9980237.filter,tp,LOCATION_GRAVE+LOCATION_EXTRA,0,1,nil,e,tp) end and Duel.IsExistingTarget(c9980237.filter,tp,LOCATION_GRAVE+LOCATION_EXTRA,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c9980237.filter,tp,LOCATION_GRAVE+LOCATION_EXTRA,0,1,1,nil,e,tp) local g=Duel.SelectTarget(tp,c9980237.filter,tp,LOCATION_GRAVE+LOCATION_EXTRA,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
end end
function c9980237.spop(e,tp,eg,ep,ev,re,r,rp) function c9980237.spop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end if not e:GetHandler():IsRelateToEffect(e) then return end
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP_ATTACK) Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP_ATTACK)
end end
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980237,1)) Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980237,1))
end end
--外传纪录·愤怒之梅丽莎 --外传纪录·愤怒之梅丽莎
function c9980287.initial_effect(c) function c9980287.initial_effect(c)
c:EnableCounterPermit(0x1) c:EnableCounterPermit(0x1)
--link summon --link summon
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkRace,RACE_SPELLCASTER),2,2,c9980287.lcheck) aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkRace,RACE_SPELLCASTER),2,2,c9980287.lcheck)
c:EnableReviveLimit() c:EnableReviveLimit()
--counter --counter
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_SUMMON_SUCCESS) e2:SetCode(EVENT_SUMMON_SUCCESS)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCondition(c9980287.ctcon) e2:SetCondition(c9980287.ctcon)
e2:SetOperation(c9980287.ctop) e2:SetOperation(c9980287.ctop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local e3=e2:Clone() local e3=e2:Clone()
e3:SetCode(EVENT_SPSUMMON_SUCCESS) e3:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--atkup --atkup
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE) e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetProperty(EFFECT_FLAG_SINGLE_RANGE) e4:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e4:SetCode(EFFECT_UPDATE_ATTACK) e4:SetCode(EFFECT_UPDATE_ATTACK)
e4:SetRange(LOCATION_MZONE) e4:SetRange(LOCATION_MZONE)
e4:SetValue(c9980287.atkval) e4:SetValue(c9980287.atkval)
c:RegisterEffect(e4) c:RegisterEffect(e4)
--cannot target --cannot target
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)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET) e2:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET)
e2:SetValue(aux.tgoval) e2:SetValue(aux.tgoval)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--indes --indes
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE) e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) e3:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE) e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e3:SetRange(LOCATION_MZONE) e3:SetRange(LOCATION_MZONE)
e3:SetValue(aux.indoval) e3:SetValue(aux.indoval)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--to hand --to hand
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(9980287,0)) e1:SetDescription(aux.Stringid(9980287,0))
e1:SetCategory(CATEGORY_TOHAND) e1:SetCategory(CATEGORY_TOHAND)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET) e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetType(EFFECT_TYPE_QUICK_O) e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,9980287) e1:SetCountLimit(1,9980287)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE) e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE)
e1:SetTarget(c9980287.thtg) e1:SetTarget(c9980287.thtg)
e1:SetOperation(c9980287.thop) e1:SetOperation(c9980287.thop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--spsummon bgm --spsummon bgm
local e8=Effect.CreateEffect(c) local e8=Effect.CreateEffect(c)
e8:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e8:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e8:SetCode(EVENT_SPSUMMON_SUCCESS) e8:SetCode(EVENT_SPSUMMON_SUCCESS)
e8:SetOperation(c9980287.sumsuc) e8:SetOperation(c9980287.sumsuc)
c:RegisterEffect(e8) c:RegisterEffect(e8)
local e9=e8:Clone() local e9=e8:Clone()
e9:SetCode(EVENT_SUMMON_SUCCESS) e9:SetCode(EVENT_SUMMON_SUCCESS)
c:RegisterEffect(e9) c:RegisterEffect(e9)
end end
function c9980287.sumsuc(e,tp,eg,ep,ev,re,r,rp) function c9980287.sumsuc(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980287,1)) Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980287,1))
end end
function c9980287.lcheck(g,lc) function c9980287.lcheck(g,lc)
return g:IsExists(Card.IsLinkSetCard,1,nil,0xbc4) return g:IsExists(Card.IsLinkSetCard,1,nil,0xbc4)
end end
function c9980287.cfilter(c,ec) function c9980287.cfilter(c,ec)
if c:IsLocation(LOCATION_MZONE) then if c:IsLocation(LOCATION_MZONE) then
return c:IsSetCard(0xbc4) and c:IsFaceup() and ec:GetLinkedGroup():IsContains(c) return c:IsSetCard(0xbc4) and c:IsFaceup() and ec:GetLinkedGroup():IsContains(c)
else else
return c:IsPreviousSetCard(0xbc4) and c:IsPreviousPosition(POS_FACEUP) return c:IsPreviousSetCard(0xbc4) and c:IsPreviousPosition(POS_FACEUP)
and bit.extract(ec:GetLinkedZone(c:GetPreviousControler()),c:GetPreviousSequence())~=0 and bit.extract(ec:GetLinkedZone(c:GetPreviousControler()),c:GetPreviousSequence())~=0
end end
end end
function c9980287.ctcon(e,tp,eg,ep,ev,re,r,rp) function c9980287.ctcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c9980287.cfilter,1,nil,e:GetHandler()) return eg:IsExists(c9980287.cfilter,1,nil,e:GetHandler())
end end
function c9980287.ctop(e,tp,eg,ep,ev,re,r,rp) function c9980287.ctop(e,tp,eg,ep,ev,re,r,rp)
e:GetHandler():AddCounter(0x1,1) e:GetHandler():AddCounter(0x1,1)
end end
function c9980287.atkval(e,c) function c9980287.atkval(e,c)
return Duel.GetCounter(c:GetControler(),1,0,0x1)*100 return Duel.GetCounter(c:GetControler(),1,0,0x1)*100
end end
function c9980287.filter(c) function c9980287.filter(c)
return c:IsFaceup() and c:IsAbleToHand() return c:IsFaceup() and c:IsAbleToHand()
end end
function c9980287.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c9980287.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() and c9980287.filter(chkc) end if chkc then return chkc:IsOnField() and c9980287.filter(chkc) end
if chk==0 then return Duel.IsCanRemoveCounter(tp,1,1,0x1,1,REASON_EFFECT) if chk==0 then return Duel.IsCanRemoveCounter(tp,1,1,0x1,1,REASON_EFFECT)
and Duel.IsExistingTarget(c9980287.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end and Duel.IsExistingTarget(c9980287.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local g=Duel.SelectTarget(tp,c9980287.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil) local g=Duel.SelectTarget(tp,c9980287.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end end
function c9980287.thop(e,tp,eg,ep,ev,re,r,rp) function c9980287.thop(e,tp,eg,ep,ev,re,r,rp)
if Duel.IsCanRemoveCounter(tp,1,1,0x1,1,REASON_EFFECT) then if Duel.IsCanRemoveCounter(tp,1,1,0x1,1,REASON_EFFECT) then
Duel.RemoveCounter(tp,1,1,0x1,1,REASON_EFFECT) Duel.RemoveCounter(tp,1,1,0x1,1,REASON_EFFECT)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) then
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980287,1)) Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980287,1))
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
end end
end end
end end
--光之流法—辉彩华刃 --光之流法—辉彩华刃
function c9980512.initial_effect(c) function c9980512.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_ATKCHANGE+CATEGORY_DEFCHANGE) e1:SetCategory(CATEGORY_ATKCHANGE+CATEGORY_DEFCHANGE)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP) e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(TIMING_DAMAGE_STEP) e1:SetHintTiming(TIMING_DAMAGE_STEP)
e1:SetCondition(c9980512.condition) e1:SetCondition(c9980512.condition)
e1:SetTarget(c9980512.target) e1:SetTarget(c9980512.target)
e1:SetOperation(c9980512.activate) e1:SetOperation(c9980512.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function c9980513.cfilter(c) function c9980513.cfilter(c)
return c:IsFaceup() and c:IsSetCard(0xcbcc) return c:IsFaceup() and c:IsSetCard(0xcbcc)
end end
function c9980512.condition(e,tp,eg,ep,ev,re,r,rp) function c9980512.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetCurrentPhase()~=PHASE_DAMAGE or not Duel.IsDamageCalculated() andDuel.IsExistingMatchingCard(c9980513.cfilter,tp,LOCATION_PZONE+LOCATION_MZONE,0,1,nil) return Duel.GetCurrentPhase()~=PHASE_DAMAGE or not Duel.IsDamageCalculated() and Duel.IsExistingMatchingCard(c9980513.cfilter,tp,LOCATION_PZONE+LOCATION_MZONE,0,1,nil)
end end
function c9980512.filter(c) function c9980512.filter(c)
return c:IsFaceup() and c:IsSetCard(0x5bcc) return c:IsFaceup() and c:IsSetCard(0x5bcc)
end end
function c9980512.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c9980512.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c9980512.filter(chkc) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c9980512.filter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c9980512.filter,tp,LOCATION_MZONE,0,1,nil) end if chk==0 then return Duel.IsExistingTarget(c9980512.filter,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,c9980512.filter,tp,LOCATION_MZONE,0,1,1,nil) Duel.SelectTarget(tp,c9980512.filter,tp,LOCATION_MZONE,0,1,1,nil)
Duel.SetChainLimit(c9980512.chainlm) Duel.SetChainLimit(c9980512.chainlm)
end end
function c9980512.activate(e,tp,eg,ep,ev,re,r,rp) function c9980512.activate(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsFaceup() then if tc:IsRelateToEffect(e) and tc:IsFaceup() then
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_ATTACK_FINAL) e1:SetCode(EFFECT_SET_ATTACK_FINAL)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
e1:SetValue(tc:GetAttack()*2) e1:SetValue(tc:GetAttack()*2)
tc:RegisterEffect(e1) tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(e:GetHandler()) local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_SINGLE) e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_SET_DEFENSE_FINAL) e2:SetCode(EFFECT_SET_DEFENSE_FINAL)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
e2:SetValue(tc:GetDefense()*2) e2:SetValue(tc:GetDefense()*2)
tc:RegisterEffect(e2) tc:RegisterEffect(e2)
local e3=Effect.CreateEffect(e:GetHandler()) local e3=Effect.CreateEffect(e:GetHandler())
e3:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_SINGLE) e3:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_SINGLE)
e3:SetCode(EVENT_PRE_BATTLE_DAMAGE) e3:SetCode(EVENT_PRE_BATTLE_DAMAGE)
e3:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) e3:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
e3:SetCondition(c9980512.rdcon) e3:SetCondition(c9980512.rdcon)
e3:SetOperation(c9980512.rdop) e3:SetOperation(c9980512.rdop)
tc:RegisterEffect(e3) tc:RegisterEffect(e3)
end end
end end
function c9980512.chainlm(e,rp,tp) function c9980512.chainlm(e,rp,tp)
return tp==rp return tp==rp
end end
function c9980512.rdcon(e,tp,eg,ep,ev,re,r,rp) function c9980512.rdcon(e,tp,eg,ep,ev,re,r,rp)
return ep~=tp return ep~=tp
end end
function c9980512.rdop(e,tp,eg,ep,ev,re,r,rp) function c9980512.rdop(e,tp,eg,ep,ev,re,r,rp)
Duel.ChangeBattleDamage(ep,ev/2) Duel.ChangeBattleDamage(ep,ev/2)
end end
--MRS拟态甲斗-骑士形态 --MRS拟态甲斗-骑士形态
function c9980573.initial_effect(c) function c9980573.initial_effect(c)
--special summon --special summon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC) e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND) e1:SetRange(LOCATION_HAND)
e1:SetCountLimit(1,9980573) e1:SetCountLimit(1,9980573)
e1:SetCondition(c9980573.spcon) e1:SetCondition(c9980573.spcon)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--damage --damage
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DAMAGE) e1:SetCategory(CATEGORY_DAMAGE)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCountLimit(1,9980573) e1:SetCountLimit(1,99805731)
e1:SetTarget(c9980573.target) e1:SetTarget(c9980573.target)
e1:SetOperation(c9980573.operation) e1:SetOperation(c9980573.operation)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(9980573,1)) e1:SetDescription(aux.Stringid(9980573,1))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION) e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_GRAVE) e1:SetRange(LOCATION_GRAVE)
e1:SetCost(aux.bfgcost) e1:SetCost(aux.bfgcost)
e1:SetCountLimit(1,99805730) e1:SetCountLimit(1,99805730)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET) e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetTarget(c9980573.sptg) e1:SetTarget(c9980573.sptg)
e1:SetOperation(c9980573.spop) e1:SetOperation(c9980573.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--summon success --summon success
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e4:SetCode(EVENT_SUMMON_SUCCESS) e4:SetCode(EVENT_SUMMON_SUCCESS)
e4:SetOperation(c9980573.sumsuc) e4:SetOperation(c9980573.sumsuc)
c:RegisterEffect(e4) c:RegisterEffect(e4)
local e5=e4:Clone() local e5=e4:Clone()
e5:SetCode(EVENT_SPSUMMON_SUCCESS) e5:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e5) c:RegisterEffect(e5)
end end
function c9980573.sumsuc(e,tp,eg,ep,ev,re,r,rp) function c9980573.sumsuc(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980573,2)) Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980573,2))
end end
function c9980573.filter(c) function c9980573.filter(c)
return c:IsFaceup() and c:IsSetCard(0xcbca) and not c:IsCode(9980573) return c:IsFaceup() and c:IsSetCard(0xcbca) and not c:IsCode(9980573)
end end
function c9980573.spcon(e,c) function c9980573.spcon(e,c)
if c==nil then return true end if c==nil then return true end
return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0 return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c9980573.filter,c:GetControler(),LOCATION_MZONE,0,1,nil) and Duel.IsExistingMatchingCard(c9980573.filter,c:GetControler(),LOCATION_MZONE,0,1,nil)
end end
function c9980573.target(e,tp,eg,ep,ev,re,r,rp,chk) function c9980573.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
Duel.SetTargetPlayer(1-tp) Duel.SetTargetPlayer(1-tp)
Duel.SetTargetParam(1000) Duel.SetTargetParam(1000)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,1000) Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,1000)
end end
function c9980573.operation(e,tp,eg,ep,ev,re,r,rp) function c9980573.operation(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM) local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
if Duel.Damage(p,d,REASON_EFFECT)>0 then if Duel.Damage(p,d,REASON_EFFECT)>0 then
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980573,3)) Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980573,3))
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local g=Duel.SelectMatchingCard(tp,Card.IsFaceup,tp,0,LOCATION_MZONE,1,1,nil) local g=Duel.SelectMatchingCard(tp,Card.IsFaceup,tp,0,LOCATION_MZONE,1,1,nil)
local tc=g:GetFirst() local tc=g:GetFirst()
if tc then if tc then
Duel.BreakEffect() Duel.BreakEffect()
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(-1000) e1:SetValue(-1000)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1) tc:RegisterEffect(e1)
local e2=e1:Clone() local e2=e1:Clone()
e2:SetCode(EFFECT_UPDATE_DEFENSE) e2:SetCode(EFFECT_UPDATE_DEFENSE)
tc:RegisterEffect(e2) tc:RegisterEffect(e2)
end end
end end
if Duel.GetFlagEffect(tp,9980573)~=0 then return end if Duel.GetFlagEffect(tp,9980573)~=0 then return end
--extra summon --extra summon
local e2=Effect.CreateEffect(e:GetHandler()) local e2=Effect.CreateEffect(e:GetHandler())
e2:SetDescription(aux.Stringid(9980573,0)) e2:SetDescription(aux.Stringid(9980573,0))
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_EXTRA_SUMMON_COUNT) e2:SetCode(EFFECT_EXTRA_SUMMON_COUNT)
e2:SetTargetRange(LOCATION_HAND+LOCATION_MZONE,0) e2:SetTargetRange(LOCATION_HAND+LOCATION_MZONE,0)
e2:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0xcbca)) e2:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0xcbca))
e2:SetReset(RESET_PHASE+PHASE_END) e2:SetReset(RESET_PHASE+PHASE_END)
c:RegisterEffect(e2,tp) c:RegisterEffect(e2,tp)
Duel.RegisterFlagEffect(tp,9980573,RESET_PHASE+PHASE_END,0,1) Duel.RegisterFlagEffect(tp,9980573,RESET_PHASE+PHASE_END,0,1)
end end
function c9980573.filter1(c,e,tp) function c9980573.filter1(c,e,tp)
local rk=c:GetRank() local rk=c:GetRank()
return c:IsFaceup() and c:IsType(TYPE_XYZ) and c:IsSetCard(0xcbca) return c:IsFaceup() and c:IsType(TYPE_XYZ) and c:IsSetCard(0xcbca)
and Duel.IsExistingMatchingCard(c9980573.filter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,c,rk+1) and Duel.IsExistingMatchingCard(c9980573.filter2,tp,LOCATION_EXTRA,0,1,nil,e,tp,c,rk+1)
and Duel.GetLocationCountFromEx(tp,tp,c)>0 and Duel.GetLocationCountFromEx(tp,tp,c)>0
and aux.MustMaterialCheck(c,tp,EFFECT_MUST_BE_XMATERIAL) and aux.MustMaterialCheck(c,tp,EFFECT_MUST_BE_XMATERIAL)
end end
function c9980573.filter2(c,e,tp,mc,rk) function c9980573.filter2(c,e,tp,mc,rk)
return c:IsRank(rk) and c:IsType(TYPE_XYZ) and c:IsAttribute(ATTRIBUTE_WIND) and mc:IsCanBeXyzMaterial(c) return c:IsRank(rk) and c:IsType(TYPE_XYZ) and c:IsAttribute(ATTRIBUTE_WIND) and mc:IsCanBeXyzMaterial(c)
and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_XYZ,tp,false,false) and c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_XYZ,tp,false,false)
end end
function c9980573.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c9980573.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c9980573.filter1(chkc,e,tp) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c9980573.filter1(chkc,e,tp) end
if chk==0 then return Duel.IsExistingTarget(c9980573.filter1,tp,LOCATION_MZONE,0,1,nil,e,tp) end if chk==0 then return Duel.IsExistingTarget(c9980573.filter1,tp,LOCATION_MZONE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
Duel.SelectTarget(tp,c9980573.filter1,tp,LOCATION_MZONE,0,1,1,nil,e,tp) Duel.SelectTarget(tp,c9980573.filter1,tp,LOCATION_MZONE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end end
function c9980573.spop(e,tp,eg,ep,ev,re,r,rp) function c9980573.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if Duel.GetLocationCountFromEx(tp,tp,tc)<=0 or not aux.MustMaterialCheck(tc,tp,EFFECT_MUST_BE_XMATERIAL) then return end if Duel.GetLocationCountFromEx(tp,tp,tc)<=0 or not aux.MustMaterialCheck(tc,tp,EFFECT_MUST_BE_XMATERIAL) then return end
if tc:IsFacedown() or not tc:IsRelateToEffect(e) or tc:IsControler(1-tp) or tc:IsImmuneToEffect(e) then return end if tc:IsFacedown() or not tc:IsRelateToEffect(e) or tc:IsControler(1-tp) or tc:IsImmuneToEffect(e) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c9980573.filter2,tp,LOCATION_EXTRA,0,1,1,nil,e,tp,tc,tc:GetRank()+1) local g=Duel.SelectMatchingCard(tp,c9980573.filter2,tp,LOCATION_EXTRA,0,1,1,nil,e,tp,tc,tc:GetRank()+1)
local sc=g:GetFirst() local sc=g:GetFirst()
if sc then if sc then
local mg=tc:GetOverlayGroup() local mg=tc:GetOverlayGroup()
if mg:GetCount()~=0 then if mg:GetCount()~=0 then
Duel.Overlay(sc,mg) Duel.Overlay(sc,mg)
end end
sc:SetMaterial(Group.FromCards(tc)) sc:SetMaterial(Group.FromCards(tc))
Duel.Overlay(sc,Group.FromCards(tc)) Duel.Overlay(sc,Group.FromCards(tc))
Duel.SpecialSummon(sc,SUMMON_TYPE_XYZ,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(sc,SUMMON_TYPE_XYZ,tp,tp,false,false,POS_FACEUP)
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980573,3)) Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980573,3))
sc:CompleteProcedure() sc:CompleteProcedure()
end end
end end
\ No newline at end of file
--Hyper Rider Kick --Hyper Rider Kick
function c9980577.initial_effect(c) function c9980577.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DESTROY) e1:SetCategory(CATEGORY_DESTROY)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET) e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMING_END_PHASE) e1:SetHintTiming(0,TIMING_END_PHASE)
e1:SetCountLimit(1,9980577+EFFECT_COUNT_CODE_OATH) e1:SetCountLimit(1,9980577+EFFECT_COUNT_CODE_OATH)
e1:SetCost(c9980577.cost) e1:SetCost(c9980577.cost)
e1:SetTarget(c9980577.target) e1:SetTarget(c9980577.target)
e1:SetOperation(c9980577.activate) e1:SetOperation(c9980577.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function c9980577.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c9980577.cost(e,tp,eg,ep,ev,re,r,rp,chk)
e:SetLabel(1) e:SetLabel(1)
return true return true
end end
function c9980577.costfilter(c) function c9980577.costfilter(c)
return c:IsSetCard(0xcbca) and c:IsAbleToRemoveAsCost() return c:IsSetCard(0xcbca) and c:IsAbleToRemoveAsCost()
end end
function c9980577.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c9980577.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() end if chkc then return chkc:IsOnField() end
if chk==0 then if chk==0 then
if e:GetLabel()==1 then if e:GetLabel()==1 then
e:SetLabel(0) e:SetLabel(0)
return Duel.IsExistingMatchingCard(c9980577.costfilter,tp,LOCATION_GRAVE,0,1,nil) return Duel.IsExistingMatchingCard(c9980577.costfilter,tp,LOCATION_GRAVE,0,1,nil)
and Duel.IsExistingTarget(aux.TRUE,tp,0,LOCATION_ONFIELD,1,e:GetHandler()) and Duel.IsExistingTarget(aux.TRUE,tp,0,LOCATION_ONFIELD,1,e:GetHandler())
else return false end else return false end
end end
e:SetLabel(0) e:SetLabel(0)
local rt=Duel.GetTargetCount(aux.TRUE,tp,0,LOCATION_ONFIELD,e:GetHandler()) local rt=Duel.GetTargetCount(aux.TRUE,tp,0,LOCATION_ONFIELD,e:GetHandler())
if rt>2 then rt=2 end if rt>2 then rt=2 end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local cg=Duel.SelectMatchingCard(tp,c9980577.costfilter,tp,LOCATION_GRAVE,0,1,rt,nil) local cg=Duel.SelectMatchingCard(tp,c9980577.costfilter,tp,LOCATION_GRAVE,0,1,rt,nil)
local ct=cg:GetCount() local ct=cg:GetCount()
Duel.Remove(cg,POS_FACEUP,REASON_COST) Duel.Remove(cg,POS_FACEUP,REASON_COST)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(tp,aux.TRUE,tp,0,LOCATION_ONFIELD,ct,ct,e:GetHandler()) local g=Duel.SelectTarget(tp,aux.TRUE,tp,0,LOCATION_ONFIELD,ct,ct,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1) Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
end end
function c9980577.activate(e,tp,eg,ep,ev,re,r,rp) function c9980577.activate(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS)
if tc and tc:IsRelateToEffect(e) and Duel.Destroy(tc,REASON_EFFECT)>0 then local sg=g:Filter(Card.IsRelateToEffect,nil,e)
Duel.Draw(tp,1,REASON_EFFECT) Duel.Destroy(sg,REASON_EFFECT)
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980577,0)) Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980577,0))
end end
end
--古朗基·14号 --古朗基·14号
function c9980580.initial_effect(c) function c9980580.initial_effect(c)
--cannot special summon --cannot special summon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_SINGLE_RANGE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_SINGLE_RANGE)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetRange(LOCATION_DECK) e1:SetRange(LOCATION_DECK)
e1:SetCode(EFFECT_SPSUMMON_CONDITION) e1:SetCode(EFFECT_SPSUMMON_CONDITION)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--special summon --special summon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC) e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND) e1:SetRange(LOCATION_HAND)
e1:SetCondition(c9980580.spcon) e1:SetCondition(c9980580.spcon)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--destroy --destroy
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(9980580,1)) e2:SetDescription(aux.Stringid(9980580,1))
e2:SetCategory(CATEGORY_DESTROY) e2:SetCategory(CATEGORY_DESTROY)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCode(EVENT_SUMMON_SUCCESS) e2:SetCode(EVENT_SUMMON_SUCCESS)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY) e2:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e2:SetCountLimit(1,9980580) e2:SetCountLimit(1,9980580)
e2:SetTarget(c9980580.destg) e2:SetTarget(c9980580.destg)
e2:SetOperation(c9980580.desop) e2:SetOperation(c9980580.desop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local e3=e2:Clone() local e3=e2:Clone()
e3:SetCode(EVENT_SPSUMMON_SUCCESS) e3:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--tohand --tohand
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(9980580,0)) e2:SetDescription(aux.Stringid(9980580,0))
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY) e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_TO_GRAVE) e2:SetCode(EVENT_TO_GRAVE)
e2:SetCountLimit(1,99805800) e2:SetCountLimit(1,99805800)
e2:SetCondition(c9980580.thcon) e2:SetCondition(c9980580.thcon)
e2:SetCost(c9980580.cost) e2:SetTarget(c9980580.thtg)
e2:SetTarget(c9980580.thtg) e2:SetOperation(c9980580.thop)
e2:SetOperation(c9980580.thop) c:RegisterEffect(e2)
c:RegisterEffect(e2) end
end function c9980580.spcon(e,c)
function c9980580.spcon(e,c) if c==nil then return true end
if c==nil then return true end return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0
return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0 and Duel.GetFieldGroupCount(c:GetControler(),LOCATION_MZONE,0,nil)<Duel.GetFieldGroupCount(c:GetControler(),0,LOCATION_MZONE,nil)
and Duel.GetFieldGroupCount(c:GetControler(),LOCATION_MZONE,0,nil)<Duel.GetFieldGroupCount(c:GetControler(),0,LOCATION_MZONE,nil) end
end function c9980580.desfilter(c)
function c9980580.desfilter(c) return c:GetSequence()<5
return c:GetSequence()<5 end
end function c9980580.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
function c9980580.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) if chkc then return chkc:IsLocation(LOCATION_SZONE) and chkc:IsControler(tp) and c9980580.desfilter(chkc) end
if chkc then return chkc:IsLocation(LOCATION_SZONE) and chkc:IsControler(tp) and c9980580.desfilter(chkc) end if chk==0 then return Duel.IsExistingTarget(c9980580.desfilter,tp,0,LOCATION_SZONE,1,nil) end
if chk==0 then return Duel.IsExistingTarget(c9980580.desfilter,tp,0,LOCATION_SZONE,1,nil) end Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) local g=Duel.SelectTarget(tp,c9980580.desfilter,tp,0,LOCATION_SZONE,1,1,nil)
local g=Duel.SelectTarget(tp,c9980580.desfilter,tp,0,LOCATION_SZONE,1,1,nil) Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0) end
end function c9980580.desop(e,tp,eg,ep,ev,re,r,rp)
function c9980580.desop(e,tp,eg,ep,ev,re,r,rp) local tc=Duel.GetFirstTarget()
local tc=Duel.GetFirstTarget() if tc:IsRelateToEffect(e) then
if tc:IsRelateToEffect(e) then Duel.Destroy(tc,REASON_EFFECT)
Duel.Destroy(tc,REASON_EFFECT) Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980580,2))
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980580,2)) end
end end
end function c9980580.thcon(e,tp,eg,ep,ev,re,r,rp)
function c9980580.thcon(e,tp,eg,ep,ev,re,r,rp) return e:GetHandler():IsReason(REASON_EFFECT)
return e:GetHandler():IsReason(REASON_EFFECT) end
end function c9980580.thfilter(c)
function c9980580.thfilter(c) return c:IsRace(RACE_WARRIOR) and c:IsAttribute(ATTRIBUTE_DARK) and not c:IsCode(9980580) and c:IsAbleToHand()
return c:IsRace(RACE_WARRIOR) and c:IsAttribute(ATTRIBUTE_DARK) and not c:IsCode(9980580) and c:IsAbleToHand() end
end function c9980580.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
function c9980580.thtg(e,tp,eg,ep,ev,re,r,rp,chk) if chk==0 then return Duel.IsExistingMatchingCard(c9980580.thfilter,tp,LOCATION_DECK,0,1,nil) end
if chk==0 then return Duel.IsExistingMatchingCard(c9980580.thfilter,tp,LOCATION_DECK,0,1,nil) end Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) end
end function c9980580.thop(e,tp,eg,ep,ev,re,r,rp)
function c9980580.thop(e,tp,eg,ep,ev,re,r,rp) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) local g=Duel.SelectMatchingCard(tp,c9980580.thfilter,tp,LOCATION_DECK,0,1,1,nil)
local g=Duel.SelectMatchingCard(tp,c9980580.thfilter,tp,LOCATION_DECK,0,1,1,nil) if g:GetCount()>0 then
if g:GetCount()>0 then Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.SendtoHand(g,nil,REASON_EFFECT) Duel.ConfirmCards(1-tp,g)
Duel.ConfirmCards(1-tp,g) Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980580,3))
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980580,3)) end
end end
end
--古朗基·3号 --古朗基·3号
function c9980581.initial_effect(c) function c9980581.initial_effect(c)
--cannot special summon --cannot special summon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_SINGLE_RANGE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_SINGLE_RANGE)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetRange(LOCATION_DECK) e1:SetRange(LOCATION_DECK)
e1:SetCode(EFFECT_SPSUMMON_CONDITION) e1:SetCode(EFFECT_SPSUMMON_CONDITION)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--special summon --special summon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SPSUMMON_PROC) e1:SetCode(EFFECT_SPSUMMON_PROC)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) e1:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e1:SetRange(LOCATION_HAND) e1:SetRange(LOCATION_HAND)
e1:SetCondition(c9980581.spcon) e1:SetCondition(c9980581.spcon)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--atkup --atkup
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(9980581,0)) e1:SetDescription(aux.Stringid(9980581,0))
e1:SetCategory(CATEGORY_ATKCHANGE) e1:SetCategory(CATEGORY_ATKCHANGE)
e1:SetType(EFFECT_TYPE_QUICK_O) e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP) e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(TIMING_DAMAGE_STEP) e1:SetHintTiming(TIMING_DAMAGE_STEP)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,9980581) e1:SetCountLimit(1,9980581)
e1:SetCondition(c9980581.condition) e1:SetCondition(c9980581.condition)
e1:SetCost(c9980581.cost) e1:SetCost(c9980581.cost)
e1:SetOperation(c9980581.operation) e1:SetOperation(c9980581.operation)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--add to hand --add to hand
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(9980581,1)) e2:SetDescription(aux.Stringid(9980581,1))
e2:SetCategory(CATEGORY_TOHAND) e2:SetCategory(CATEGORY_TOHAND)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP) e2:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP)
e2:SetCode(EVENT_TO_GRAVE) e2:SetCode(EVENT_TO_GRAVE)
e2:SetCondition(c9980581.thcon) e2:SetCondition(c9980581.thcon)
e2:SetTarget(c9980581.thtg) e2:SetTarget(c9980581.thtg)
e2:SetOperation(c9980581.thop) e2:SetOperation(c9980581.thop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c9980581.spcon(e,c) function c9980581.spcon(e,c)
if c==nil then return true end if c==nil then return true end
return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0 return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0
and Duel.GetFieldGroupCount(c:GetControler(),LOCATION_MZONE,0,nil)<Duel.GetFieldGroupCount(c:GetControler(),0,LOCATION_MZONE,nil) and Duel.GetFieldGroupCount(c:GetControler(),LOCATION_MZONE,0,nil)<Duel.GetFieldGroupCount(c:GetControler(),0,LOCATION_MZONE,nil)
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9980581,2)) end
end function c9980581.condition(e,tp,eg,ep,ev,re,r,rp)
function c9980581.condition(e,tp,eg,ep,ev,re,r,rp) return Duel.GetCurrentPhase()~=PHASE_DAMAGE or not Duel.IsDamageCalculated()
return Duel.GetCurrentPhase()~=PHASE_DAMAGE or not Duel.IsDamageCalculated() end
end function c9980581.cfilter(c)
function c9980581.cfilter(c) return c:IsRace(RACE_WARRIOR) and c:IsAbleToRemoveAsCost()
return c:IsRace(RACE_WARRIOR) and c:IsAbleToRemoveAsCost() end
end function c9980581.cost(e,tp,eg,ep,ev,re,r,rp,chk)
function c9980581.cost(e,tp,eg,ep,ev,re,r,rp,chk) if chk==0 then return Duel.IsExistingMatchingCard(c9980581.cfilter,tp,LOCATION_GRAVE,0,1,nil) end
if chk==0 then return Duel.IsExistingMatchingCard(c9980581.cfilter,tp,LOCATION_GRAVE,0,1,nil) end Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) local g=Duel.SelectMatchingCard(tp,c9980581.cfilter,tp,LOCATION_GRAVE,0,1,1,nil)
local g=Duel.SelectMatchingCard(tp,c9980581.cfilter,tp,LOCATION_GRAVE,0,1,1,nil) Duel.Remove(g,POS_FACEUP,REASON_COST)
Duel.Remove(g,POS_FACEUP,REASON_COST) end
end function c9980581.operation(e,tp,eg,ep,ev,re,r,rp)
function c9980581.operation(e,tp,eg,ep,ev,re,r,rp) local c=e:GetHandler()
local c=e:GetHandler() if c:IsFaceup() and c:IsRelateToEffect(e) then
if c:IsFaceup() and c:IsRelateToEffect(e) then local e1=Effect.CreateEffect(c)
local e1=Effect.CreateEffect(c) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetValue(1000)
e1:SetValue(1000) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END) c:RegisterEffect(e1)
c:RegisterEffect(e1) local e2=Effect.CreateEffect(c)
local e2=Effect.CreateEffect(c) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e2:SetCode(EVENT_BATTLED)
e2:SetCode(EVENT_BATTLED) e2:SetOperation(c9980581.rmop)
e2:SetOperation(c9980581.rmop) e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END) c:RegisterEffect(e2)
c:RegisterEffect(e2) end
end end
end function c9980581.rmop(e,tp,eg,ep,ev,re,r,rp)
function c9980581.rmop(e,tp,eg,ep,ev,re,r,rp) local tc=e:GetHandler():GetBattleTarget()
local tc=e:GetHandler():GetBattleTarget() if tc then
if tc then Duel.Remove(tc,POS_FACEUP,REASON_EFFECT)
Duel.Remove(tc,POS_FACEUP,REASON_EFFECT) end
end end
end function c9980581.thcon(e,tp,eg,ep,ev,re,r,rp)
function c9980581.thcon(e,tp,eg,ep,ev,re,r,rp) return bit.band(r,REASON_DESTROY)>0
return bit.band(r,REASON_DESTROY)>0 and e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD)
and e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD) and e:GetHandler():GetPreviousControler()==tp
and e:GetHandler():GetPreviousControler()==tp end
end function c9980581.filter(c)
function c9980581.filter(c) return c:IsFaceup() and c:IsType(TYPE_MONSTER) and c:IsAbleToHand()
return c:IsFaceup() and c:IsType(TYPE_MONSTER) and c:IsAbleToHand() end
end function c9980581.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
function c9980581.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_REMOVED) and c9980581.filter(chkc) end
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_REMOVED) and c9980581.filter(chkc) end if chk==0 then return Duel.IsExistingTarget(c9980581.filter,tp,LOCATION_REMOVED,0,1,nil) end
if chk==0 then return Duel.IsExistingTarget(c9980581.filter,tp,LOCATION_REMOVED,0,1,nil) end Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) local g=Duel.SelectTarget(tp,c9980581.filter,tp,LOCATION_REMOVED,0,1,1,nil)
local g=Duel.SelectTarget(tp,c9980581.filter,tp,LOCATION_REMOVED,0,1,1,nil) Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,g:GetCount(),0,0)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,g:GetCount(),0,0) end
end function c9980581.thop(e,tp,eg,ep,ev,re,r,rp)
function c9980581.thop(e,tp,eg,ep,ev,re,r,rp) local tc=Duel.GetFirstTarget()
local tc=Duel.GetFirstTarget() if tc and tc:IsRelateToEffect(e) then
if tc and tc:IsRelateToEffect(e) then Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.ConfirmCards(1-tp,tc)
Duel.ConfirmCards(1-tp,tc) end
end end
end
--降临卡片·奇妙降临 --降临卡片·奇妙降临
function c9980590.initial_effect(c) function c9980590.initial_effect(c)
--activate --activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_REMOVE) 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:SetProperty(EFFECT_FLAG_CARD_TARGET) e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE) e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE)
e1:SetCountLimit(1.9980590) e1:SetCountLimit(1.9980590)
e1:SetCondition(c9980590.con1) e1:SetCondition(c9980590.con1)
e1:SetTarget(c9980590.tg) e1:SetTarget(c9980590.tg)
e1:SetOperation(c9980590.op) e1:SetOperation(c9980590.op)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--remove --remove
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(9980590,1)) e3:SetDescription(aux.Stringid(9980590,1))
e3:SetCategory(CATEGORY_REMOVE) e3:SetCategory(CATEGORY_REMOVE)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_DELAY) e3:SetProperty(EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_TO_GRAVE) e3:SetCode(EVENT_TO_GRAVE)
e3:SetCountLimit(1.99805900) e3:SetCountLimit(1.99805900)
e3:SetCondition(c9980590.con2) e3:SetCondition(c9980590.con2)
e3:SetTarget(c9980590.tg) e3:SetTarget(c9980590.tg)
e3:SetOperation(c9980590.op) e3:SetOperation(c9980590.op)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--to hand --to hand
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(9980590,0)) e2:SetDescription(aux.Stringid(9980590,0))
e2:SetCategory(CATEGORY_TODECK) e2:SetCategory(CATEGORY_TODECK)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetCode(EVENT_PHASE+PHASE_END) e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetRange(LOCATION_GRAVE) e2:SetRange(LOCATION_GRAVE)
e2:SetCondition(c9980590.tdcon) e2:SetCondition(c9980590.tdcon)
e2:SetTarget(c9980590.tdtg) e2:SetTarget(c9980590.tdtg)
e2:SetOperation(c9980590.tdop) e2:SetOperation(c9980590.tdop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c9980590.con1(e,tp,eg,ep,ev,re,r,rp) function c9980590.con1(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c9980590.confilter,tp,LOCATION_MZONE,0,1,nil) return Duel.IsExistingMatchingCard(c9980590.confilter,tp,LOCATION_MZONE,0,1,nil)
end end
function c9980590.con2(e,tp,eg,ep,ev,re,r,rp) function c9980590.con2(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL) and Duel.IsExistingMatchingCard(c9980590.confilter,tp,LOCATION_MZONE,0,1,nil) return c:IsPreviousLocation(LOCATION_DECK) and c:IsReason(REASON_REVEAL) and Duel.IsExistingMatchingCard(c9980590.confilter,tp,LOCATION_MZONE,0,1,nil)
end end
function c9980590.confilter(c) function c9980590.confilter(c)
return c:IsFaceup() and c:IsSetCard(0x6bca) return c:IsFaceup() and c:IsSetCard(0x6bca)
end end
function c9980590.setfilter(c,tp) function c9980590.setfilter(c,tp)
return c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsSSetable(true) and (c:IsType(TYPE_FIELD) or Duel.GetLocationCount(tp,LOCATION_SZONE)>0) return c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsSSetable(true) and (c:IsType(TYPE_FIELD) or Duel.GetLocationCount(tp,LOCATION_SZONE)>0)
end end
function c9980590.tg(e,tp,eg,ep,ev,re,r,rp,chk) function c9980590.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_GRAVE) and c9980590.setfilter(chkc,tp) end if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_GRAVE) and c9980590.setfilter(chkc,tp) end
if chk==0 then return Duel.IsExistingTarget(c9980590.setfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,e:GetHandler(),tp) end if chk==0 then return Duel.IsExistingTarget(c9980590.setfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,e:GetHandler(),tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local g=Duel.SelectTarget(tp,c9980590.setfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,e:GetHandler(),tp) local g=Duel.SelectTarget(tp,c9980590.setfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,e:GetHandler(),tp)
Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,g,1,0,0)
end end
function c9980590.op(e,tp,eg,ep,ev,re,r,rp) function c9980590.op(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and (tc:IsType(TYPE_FIELD) or Duel.GetLocationCount(tp,LOCATION_SZONE)>0) then if tc:IsRelateToEffect(e) and (tc:IsType(TYPE_FIELD) or Duel.GetLocationCount(tp,LOCATION_SZONE)>0) then
Duel.SSet(tp,tc) Duel.SSet(tp,tc)
Duel.ConfirmCards(1-tp,tc) Duel.ConfirmCards(1-tp,tc)
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_LEAVE_FIELD_REDIRECT) e1:SetCode(EFFECT_LEAVE_FIELD_REDIRECT)
e1:SetReset(RESET_EVENT+RESETS_REDIRECT) e1:SetReset(RESET_EVENT+RESETS_REDIRECT)
e1:SetValue(LOCATION_REMOVED) e1:SetValue(LOCATION_REMOVED)
tc:RegisterEffect(e1,true) tc:RegisterEffect(e1,true)
end end
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetTargetRange(LOCATION_MZONE,0) e1:SetTargetRange(LOCATION_MZONE,0)
e1:SetValue(200) e1:SetValue(200)
e1:SetTarget(c9980590.filter1) e1:SetTarget(c9980590.filter1)
e1:SetReset(RESET_PHASE+PHASE_END) e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
local e2=e1:Clone() local e2=e1:Clone()
e2:SetCode(EFFECT_UPDATE_DEFENSE) e2:SetCode(EFFECT_UPDATE_DEFENSE)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
Duel.Remove(sg,POS_FACEUP,REASON_EFFECT) Duel.Remove(tc,POS_FACEUP,REASON_EFFECT)
end end
function c9980590.filter1(e,c) function c9980590.filter1(e,c)
return c:IsSetCard(0x6bca) return c:IsSetCard(0x6bca)
end end
function c9980590.rccfilter(c) function c9980590.rccfilter(c)
return c:IsFaceup() and c:IsSetCard(0x6bca) return c:IsFaceup() and c:IsSetCard(0x6bca)
end end
function c9980590.tdcon(e,tp,eg,ep,ev,re,r,rp) function c9980590.tdcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp return Duel.GetTurnPlayer()==tp
and Duel.IsExistingMatchingCard(c9980590.rccfilter,tp,LOCATION_MZONE+LOCATION_GRAVE,0,1,nil) and Duel.IsExistingMatchingCard(c9980590.rccfilter,tp,LOCATION_MZONE+LOCATION_GRAVE,0,1,nil)
end end
function c9980590.tdtg(e,tp,eg,ep,ev,re,r,rp,chk) function c9980590.tdtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToDeck() end if chk==0 then return e:GetHandler():IsAbleToDeck() end
Duel.SetOperationInfo(0,CATEGORY_TODECK,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_TODECK,e:GetHandler(),1,0,0)
end end
function c9980590.tdop(e,tp,eg,ep,ev,re,r,rp) function c9980590.tdop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) or e:GetHandler():IsFacedown() then return end if not e:GetHandler():IsRelateToEffect(e) or e:GetHandler():IsFacedown() then return end
Duel.SendtoDeck(e:GetHandler(),nil,2,REASON_EFFECT) Duel.SendtoDeck(e:GetHandler(),nil,2,REASON_EFFECT)
end end
\ No newline at end of file
--他者封印·鲜血神殿 --他者封印·鲜血神殿
function c9980705.initial_effect(c) function c9980705.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--defup --defup
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_UPDATE_DEFENSE) e2:SetCode(EFFECT_UPDATE_DEFENSE)
e2:SetRange(LOCATION_FZONE) e2:SetRange(LOCATION_FZONE)
e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e2:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0x3bc1)) e2:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0x3bc1))
e2:SetValue(300) e2:SetValue(300)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--atk/def --atk/def
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_UPDATE_ATTACK) e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetRange(LOCATION_FZONE) e2:SetRange(LOCATION_FZONE)
e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e2:SetTarget(c9980705.atktg) e2:SetTarget(c9980705.atktg)
e2:SetValue(-500) e2:SetValue(-500)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local e3=e2:Clone() local e3=e2:Clone()
e3:SetCode(EFFECT_UPDATE_DEFENSE) e3:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--disable --disable
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_SOLVING) e2:SetCode(EVENT_CHAIN_SOLVING)
e2:SetRange(LOCATION_FZONE) e2:SetRange(LOCATION_FZONE)
e2:SetCondition(c9980705.discon) e2:SetCondition(c9980705.discon)
e2:SetOperation(c9980705.disop) e2:SetOperation(c9980705.disop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--spsummon --spsummon
local e6=Effect.CreateEffect(c) local e6=Effect.CreateEffect(c)
e6:SetDescription(aux.Stringid(9980705,1)) e6:SetDescription(aux.Stringid(9980705,1))
e6:SetCategory(CATEGORY_SPECIAL_SUMMON) e6:SetCategory(CATEGORY_SPECIAL_SUMMON)
e6:SetType(EFFECT_TYPE_IGNITION) e6:SetType(EFFECT_TYPE_IGNITION)
e6:SetRange(LOCATION_FZONE) e6:SetRange(LOCATION_FZONE)
e6:SetCountLimit(1) e6:SetCountLimit(1)
e6:SetTarget(c9980705.sptg) e6:SetTarget(c9980705.sptg)
e6:SetOperation(c9980705.spop) e6:SetOperation(c9980705.spop)
c:RegisterEffect(e6) c:RegisterEffect(e6)
end end
c9980705.card_code_list={9980706} c9980705.card_code_list={9980706}
function c9980705.atktg(e,c) function c9980705.atktg(e,c)
return not c:IsSetCard(0x3bc1) return not c:IsSetCard(0x3bc1)
end end
function c9980705.discon(e,tp,eg,ep,ev,re,r,rp) function c9980705.discon(e,tp,eg,ep,ev,re,r,rp)
if e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) then return false end if e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) then return false end
local atk=Duel.GetChainInfo(ev,CHAININFO_TRIGGERING_ATTACK) local atk=Duel.GetChainInfo(ev,CHAININFO_TRIGGERING_ATTACK)
local def=Duel.GetChainInfo(ev,CHAININFO_TRIGGERING_DEFENSE) local def=Duel.GetChainInfo(ev,CHAININFO_TRIGGERING_DEFENSE)
return re:IsActiveType(TYPE_MONSTER) and (atk==0 or def==0) and not c:IsRace(RACE_REPTILE) return re:IsActiveType(TYPE_MONSTER) and (atk==0 or def==0) and not re:IsSetCard(0x3bc1)
end end
function c9980705.disop(e,tp,eg,ep,ev,re,r,rp) function c9980705.disop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateEffect(ev) Duel.NegateEffect(ev)
end end
function c9980705.spfilter(c,e,tp) function c9980705.spfilter(c,e,tp)
return c:IsSetCard(0x3bc1) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsSetCard(0x3bc1) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function c9980705.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c9980705.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(c9980705.spfilter,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_REMOVED,0,1,nil,e,tp) end and Duel.IsExistingMatchingCard(c9980705.spfilter,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_REMOVED,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_REMOVED) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_REMOVED)
end end
function c9980705.spop(e,tp,eg,ep,ev,re,r,rp) function c9980705.spop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end if not e:GetHandler():IsRelateToEffect(e) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c9980705.spfilter,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,c9980705.spfilter,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil,e,tp)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end end
end end
\ No newline at end of file
--克律萨俄耳 --克律萨俄耳
function c9980712.initial_effect(c) function c9980712.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_EQUIP) e1:SetCategory(CATEGORY_EQUIP)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET) e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetTarget(c9980712.eqtg) e1:SetTarget(c9980712.eqtg)
e1:SetOperation(c9980712.eqop) e1:SetOperation(c9980712.eqop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--Equip limit --Equip limit
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE) e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_EQUIP_LIMIT) e2:SetCode(EFFECT_EQUIP_LIMIT)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetValue(c9980712.effcon) e2:SetValue(c9980712.effcon)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--atk & def --atk & def
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_UPDATE_ATTACK) e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetRange(LOCATION_SZONE) e2:SetRange(LOCATION_SZONE)
e2:SetTargetRange(LOCATION_MZONE,0) e2:SetTargetRange(LOCATION_MZONE,0)
e2:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0x3bc1)) e2:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,0x3bc1))
e2:SetValue(300) e2:SetValue(300)
c:RegisterEffect(e2) c:RegisterEffect(e2)
local e3=e2:Clone() local e3=e2:Clone()
e3:SetCode(EFFECT_UPDATE_DEFENSE) e3:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_POSITION) e1:SetCategory(CATEGORY_POSITION)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET) e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetType(EFFECT_TYPE_IGNITION) e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_SZONE) e1:SetRange(LOCATION_SZONE)
e1:SetCountLimit(1) e1:SetCountLimit(1)
e1:SetTarget(c9980712.pstg) e1:SetTarget(c9980712.pstg)
e1:SetOperation(c9980712.psop) e1:SetOperation(c9980712.psop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--to hand --to hand
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(9980712,2)) e4:SetDescription(aux.Stringid(9980712,2))
e4:SetCategory(CATEGORY_TOHAND) e4:SetCategory(CATEGORY_TOHAND)
e4:SetType(EFFECT_TYPE_IGNITION) e4:SetType(EFFECT_TYPE_IGNITION)
e4:SetProperty(EFFECT_FLAG_CARD_TARGET) e4:SetProperty(EFFECT_FLAG_CARD_TARGET)
e4:SetRange(LOCATION_GRAVE) e4:SetRange(LOCATION_GRAVE)
e4:SetCountLimit(1,9980712) e4:SetCountLimit(1,9980712)
e4:SetCost(c9980712.thcost) e4:SetCost(c9980712.thcost)
e4:SetTarget(c9980712.thtg) e4:SetTarget(c9980712.thtg)
e4:SetOperation(c9980712.thop) e4:SetOperation(c9980712.thop)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
c9980712.card_code_list={9980706} c9980712.card_code_list={9980706}
function c9980712.effcon(e,c) function c9980712.effcon(e,c)
return c:IsSetCard(0x3bc1) return c:IsSetCard(0x3bc1)
end end
function c9980712.eqfilter(c) function c9980712.eqfilter(c)
return c:IsFaceup() and c:IsSetCard(0x3bc1) return c:IsFaceup() and c:IsSetCard(0x3bc1)
end end
function c9980712.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c9980712.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c9980712.eqfilter(chkc) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and c9980712.eqfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c9980712.eqfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end if chk==0 then return Duel.IsExistingTarget(c9980712.eqfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
Duel.SelectTarget(tp,c9980712.eqfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) Duel.SelectTarget(tp,c9980712.eqfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
end end
function c9980712.eqop(e,tp,eg,ep,ev,re,r,rp) function c9980712.eqop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and tc:IsFaceup() then if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and tc:IsFaceup() then
Duel.Equip(tp,c,tc) Duel.Equip(tp,c,tc)
end end
end end
function c9980712.psfilter(c) function c9980712.psfilter(c)
return c:IsFaceup() and c:IsCanTurnSet() return c:IsFaceup() and c:IsCanTurnSet()
end end
function c9980712.pstg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c9980712.pstg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c9980712.psfilter(chkc) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and c9980712.psfilter(chkc) end
if chk==0 then return Duel.IsExistingTarget(c9980712.psfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end if chk==0 then return Duel.IsExistingTarget(c9980712.psfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local g=Duel.SelectTarget(tp,c9980712.spfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) local g=Duel.SelectTarget(tp,c9980712.spfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_POSITION,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_POSITION,g,1,0,0)
end end
function c9980712.psop(e,tp,eg,ep,ev,re,r,rp) function c9980712.psop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsLocation(LOCATION_MZONE) and tc:IsFaceup() then if tc:IsRelateToEffect(e) and tc:IsLocation(LOCATION_MZONE) and tc:IsFaceup() then
Duel.ChangePosition(tc,POS_FACEDOWN_DEFENSE) Duel.ChangePosition(tc,POS_FACEDOWN_DEFENSE)
end end
end end
function c9980712.cfilter(c,tp) function c9980712.cfilter(c,tp)
return (aux.IsCodeListed(c,9980706) or c:IsSetCard(0x3bc1)) and c:IsAbleToRemoveAsCost() return (aux.IsCodeListed(c,9980706) or c:IsSetCard(0x3bc1)) and c:IsAbleToRemoveAsCost()
and Duel.IsExistingTarget(c9980712.thfilter,tp,LOCATION_GRAVE,0,1,c) and Duel.IsExistingTarget(c9980712.thfilter,tp,LOCATION_GRAVE,0,1,c)
end end
function c9980712.thfilter(c) function c9980712.thfilter(c)
return aux.IsCodeListed(c,9980706) and c:IsAbleToHand() return aux.IsCodeListed(c,9980706) and c:IsAbleToHand()
end end
function c9980712.thcost(e,tp,eg,ep,ev,re,r,rp,chk) function c9980712.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return c:IsAbleToRemoveAsCost() if chk==0 then return c:IsAbleToRemoveAsCost()
and Duel.IsExistingMatchingCard(c9980712.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end and Duel.IsExistingMatchingCard(c9980712.cfilter,tp,LOCATION_GRAVE,0,1,c,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c9980712.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp) local g=Duel.SelectMatchingCard(tp,c9980712.cfilter,tp,LOCATION_GRAVE,0,1,1,c,tp)
g:AddCard(c) g:AddCard(c)
Duel.Remove(g,POS_FACEUP,REASON_COST) Duel.Remove(g,POS_FACEUP,REASON_COST)
end end
function c9980712.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c9980712.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c9980712.thfilter(chkc) end if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c9980712.thfilter(chkc) end
if chk==0 then return true end if chk==0 then return true end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectTarget(tp,c9980712.thfilter,tp,LOCATION_GRAVE,0,1,1,nil) local g=Duel.SelectTarget(tp,c9980712.thfilter,tp,LOCATION_GRAVE,0,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
end end
function c9980712.thop(e,tp,eg,ep,ev,re,r,rp) function c9980712.thop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local c=e:GetHandler()
if tc:IsRelateToEffect(e) then local tc=Duel.GetFirstTarget()
Duel.SendtoHand(tc,nil,REASON_EFFECT) if tc:IsRelateToEffect(e) then
end Duel.SendtoHand(tc,nil,REASON_EFFECT)
end end
end
...@@ -284,7 +284,7 @@ ...@@ -284,7 +284,7 @@
!setname 0x6700 魔法之派 !setname 0x6700 魔法之派
!setname 0x7700 技巧之场 !setname 0x7700 技巧之场
!setname 0x1701 格莱亚斯 !setname 0x1701 格莱亚斯
!setname 0x2701 维翁 !setname 0x2701 维翁
#cm.is_named_with_Gran 古兰 #cm.is_named_with_Gran 古兰
#cm.is_named_with_Opear_type 歌剧型 #cm.is_named_with_Opear_type 歌剧型
#cm.is_named_with_Ma_Elf 妖精 #cm.is_named_with_Ma_Elf 妖精
...@@ -598,17 +598,18 @@ named_with_Zero 泽洛 ...@@ -598,17 +598,18 @@ named_with_Zero 泽洛
#彩神 ?????????? 766 0x760-0x76f #彩神 ?????????? 766 0x760-0x76f
#论外
!setname 0x766 死神 !setname 0x766 死神
#雪花 598403759 777 0x9c0-0x9cf #雪花 598403759 777 0x9c0-0x9cf
!setcounter 0x9c0 露西菲尼亚指示物 !setcounter 0x9c0 露西菲尼亚指示物
!setname 0xa9c0 大罪之器 !setname 0xa9c0 大罪之器
!setname 0xb9c0 Evillious !setname 0xb9c0 Evillious
#set_without_id 辉夜 #Senya_name_with_difficulty 难题
#Sekka_name_with_lap LapisLazuli #Sekka_name_with_lap LapisLazuli
#
#
#Ranger 892777862 791 0x790-0x79f #Ranger 892777862 791 0x790-0x79f
#千神奈奈子 1836885841 800 #千神奈奈子 1836885841 800
......
...@@ -12,9 +12,9 @@ deck/6.23_new_card6.ydk dc1e6d892518c0f048b6925cacc77ab3 ...@@ -12,9 +12,9 @@ deck/6.23_new_card6.ydk dc1e6d892518c0f048b6925cacc77ab3
deck/6.23_new_card7.ydk 406f9353356ff039da1da5170ba69863 deck/6.23_new_card7.ydk 406f9353356ff039da1da5170ba69863
deck/6.23_new_card8.ydk df5adeca06d7a083196b6870fc556f52 deck/6.23_new_card8.ydk df5adeca06d7a083196b6870fc556f52
deck/6.23_new_card9.ydk 48228013ac8eb02d028c92f97253efe5 deck/6.23_new_card9.ydk 48228013ac8eb02d028c92f97253efe5
expansions/222DIY.cdb 2158a0543a44e7178d920180fa9bdecd expansions/222DIY.cdb ea63bc8be62eb34e31c29ab9be895c34
expansions/lflist.conf 45fddb76b828955b8d2d4d81263ad5d6 expansions/lflist.conf 1cf3f4b2ce9583d054a06835ebdc8632
expansions/strings.conf 389c8b47eac8f813859758c1ec200c32 expansions/strings.conf a1769336a95187ecb07e7398d11028d7
expansions/pics/08209710.jpg ed0e60085631bfa641ffeebd6abbd910 expansions/pics/08209710.jpg ed0e60085631bfa641ffeebd6abbd910
expansions/pics/1000360.jpg d1aa6f44fcd413402141a6bf4b886c2a expansions/pics/1000360.jpg d1aa6f44fcd413402141a6bf4b886c2a
expansions/pics/1000361.jpg f957894610a5c40637825c4cb1c136d2 expansions/pics/1000361.jpg f957894610a5c40637825c4cb1c136d2
......
2019/6/24 14:38:11 2019/6/24 19:56:01
\ No newline at end of file \ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment