Commit 9dff4ac4 authored by Nemo Ma's avatar Nemo Ma

upd wild 0518

parent f3246b9f
......@@ -70,6 +70,57 @@
9990228 0
9990233 0
10080420 0
10100000 0
10106001 0
10106002 0
10106003 0
10106004 0
10106005 0
10106006 0
10106007 0
10106008 0
10106009 0
10106010 0
10106011 0
10106012 0
10106013 0
10106014 0
10122001 0
10122002 0
10122003 0
10122004 0
10122005 0
10122006 0
10122007 0
10122008 0
10122009 0
10122010 0
10122011 0
10122012 0
10122013 0
10122014 0
10122015 0
10122016 0
10122017 0
10122018 0
10122019 0
10122020 0
10130001 0
10130002 0
10130003 0
10130004 0
10130005 0
10130006 0
10130007 0
10130008 0
10130009 0
10130010 0
10130011 0
10130012 0
10130013 0
10130014 0
10171001 0
10199990 0
10736541 0
11163044 0
11450000 0
......@@ -225,6 +276,8 @@
31400002 0
31400003 0
31400004 0
31400005 0
31400006 0
31400032 0
31400033 0
31400034 0
......@@ -489,6 +542,13 @@
67200710 0
67200800 0
67200801 0
67200810 0
67200812 0
67200814 0
67200816 0
67200818 0
67200819 0
67200820 0
70052400 0
70052402 0
70052404 0
......@@ -599,6 +659,7 @@
79783881 0
80002333 0
80250315 0
82209077 0
82549999 0
82550000 0
82550001 0
......@@ -1052,6 +1113,7 @@
98731001 0
98920032 0
98920042 0
98920055 0
98920114 0
98920183 0
98920188 0
......@@ -1060,6 +1122,7 @@
98920203 0
98920245 0
98920289 0
98920305 0
98920313 0
98920339 0
98920377 0
......@@ -1079,7 +1142,9 @@
98940012 0
98940013 0
98940014 0
98940018 0
98940019 0
98940020 0
98940039 0
98941044 0
98941045 0
......
No preview for this file type
expansions/pics/10106001.jpg

13.9 KB | W: | H:

expansions/pics/10106001.jpg

246 KB | W: | H:

expansions/pics/10106001.jpg
expansions/pics/10106001.jpg
expansions/pics/10106001.jpg
expansions/pics/10106001.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10106002.jpg

13.4 KB | W: | H:

expansions/pics/10106002.jpg

241 KB | W: | H:

expansions/pics/10106002.jpg
expansions/pics/10106002.jpg
expansions/pics/10106002.jpg
expansions/pics/10106002.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10106003.jpg

13.8 KB | W: | H:

expansions/pics/10106003.jpg

246 KB | W: | H:

expansions/pics/10106003.jpg
expansions/pics/10106003.jpg
expansions/pics/10106003.jpg
expansions/pics/10106003.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10106004.jpg

13.6 KB | W: | H:

expansions/pics/10106004.jpg

247 KB | W: | H:

expansions/pics/10106004.jpg
expansions/pics/10106004.jpg
expansions/pics/10106004.jpg
expansions/pics/10106004.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10106005.jpg

12.8 KB | W: | H:

expansions/pics/10106005.jpg

240 KB | W: | H:

expansions/pics/10106005.jpg
expansions/pics/10106005.jpg
expansions/pics/10106005.jpg
expansions/pics/10106005.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10106006.jpg

14 KB | W: | H:

expansions/pics/10106006.jpg

245 KB | W: | H:

expansions/pics/10106006.jpg
expansions/pics/10106006.jpg
expansions/pics/10106006.jpg
expansions/pics/10106006.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10106007.jpg

13.7 KB | W: | H:

expansions/pics/10106007.jpg

247 KB | W: | H:

expansions/pics/10106007.jpg
expansions/pics/10106007.jpg
expansions/pics/10106007.jpg
expansions/pics/10106007.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10106008.jpg

14.2 KB | W: | H:

expansions/pics/10106008.jpg

250 KB | W: | H:

expansions/pics/10106008.jpg
expansions/pics/10106008.jpg
expansions/pics/10106008.jpg
expansions/pics/10106008.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10106009.jpg

13.7 KB | W: | H:

expansions/pics/10106009.jpg

252 KB | W: | H:

expansions/pics/10106009.jpg
expansions/pics/10106009.jpg
expansions/pics/10106009.jpg
expansions/pics/10106009.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10106010.jpg

14.1 KB | W: | H:

expansions/pics/10106010.jpg

252 KB | W: | H:

expansions/pics/10106010.jpg
expansions/pics/10106010.jpg
expansions/pics/10106010.jpg
expansions/pics/10106010.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10106011.jpg

14.1 KB | W: | H:

expansions/pics/10106011.jpg

233 KB | W: | H:

expansions/pics/10106011.jpg
expansions/pics/10106011.jpg
expansions/pics/10106011.jpg
expansions/pics/10106011.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10106012.jpg

12.1 KB | W: | H:

expansions/pics/10106012.jpg

226 KB | W: | H:

expansions/pics/10106012.jpg
expansions/pics/10106012.jpg
expansions/pics/10106012.jpg
expansions/pics/10106012.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10106013.jpg

13.7 KB | W: | H:

expansions/pics/10106013.jpg

368 KB | W: | H:

expansions/pics/10106013.jpg
expansions/pics/10106013.jpg
expansions/pics/10106013.jpg
expansions/pics/10106013.jpg
  • 2-up
  • Swipe
  • Onion skin
expansions/pics/10171001.jpg

80.1 KB | W: | H:

expansions/pics/10171001.jpg

280 KB | W: | H:

expansions/pics/10171001.jpg
expansions/pics/10171001.jpg
expansions/pics/10171001.jpg
expansions/pics/10171001.jpg
  • 2-up
  • Swipe
  • Onion skin
This diff is collapsed.
--梦魇魔 使魔
function c10106001.initial_effect(c)
--cannot special summon
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--Summon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10106001,0))
e1:SetCategory(CATEGORY_SUMMON)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetRange(LOCATION_HAND)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCondition(c10106001.sumcon)
e1:SetCost(c10106001.sumcost)
e1:SetTarget(c10106001.sumtg)
e1:SetOperation(c10106001.sumop)
c:RegisterEffect(e1)
--tohand
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10106001,1))
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_REMOVE)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_SUMMON_SUCCESS)
e2:SetTarget(c10106001.thtg)
e2:SetOperation(c10106001.thop)
c:RegisterEffect(e2)
end
function c10106001.thfilter(c)
return c:IsAbleToHand() and c:IsSummonType(SUMMON_TYPE_NORMAL) and not c:IsCode(10106001)
end
function c10106001.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c10106001.thfilter,tp,LOCATION_MZONE,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_ONFIELD)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,0,PLAYER_ALL,0xc)
end
function c10106001.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local g=Duel.SelectMatchingCard(tp,c10106001.thfilter,tp,LOCATION_MZONE,0,1,99,nil)
if g:GetCount()>0 then
Duel.HintSelection(g)
if Duel.SendtoHand(g,nil,REASON_EFFECT)~=0 and Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(10106001,2)) then
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local tg=Duel.SelectMatchingCard(tp,Card.IsAbleToRemove,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
Duel.HintSelection(tg)
Duel.Remove(tg,POS_FACEUP,REASON_EFFECT)
end
end
end
function c10106001.sumcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(aux.FilterEqualFunction(Card.GetSummonPlayer,1-tp),1,nil)
end
function c10106001.sumcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return not e:GetHandler():IsPublic() end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_PUBLIC)
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END)
e:GetHandler():RegisterEffect(e1)
end
function c10106001.sumfilter(c)
return c:IsSetCard(0x3338) and c:IsSummonable(true,nil)
end
function c10106001.sumtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c10106001.sumfilter,tp,LOCATION_HAND,0,1,e:GetHandler()) end
Duel.SetOperationInfo(0,CATEGORY_SUMMON,nil,1,tp,LOCATION_HAND)
end
function c10106001.sumop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON)
local g=Duel.SelectMatchingCard(tp,c10106001.sumfilter,tp,LOCATION_HAND,0,1,1,e:GetHandler())
if g:GetCount()>0 then
Duel.Summon(tp,g:GetFirst(),true,nil)
--恶念体制造兵器
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
local e1 = Scl.CreateSingleTriggerOptionalEffect(c, "BeNormalSummoned",
"Search", nil, "Search,Add2Hand", "Delay", nil, nil,
{ "~Target", "Add2Hand", s.thfilter, "Deck" }, s.thop)
local e2 = Scl.CreateQuickOptionalEffect(c, nil, "ChangeControl", 1,
"ChangeControl", "Target", "MonsterZone", nil, nil, {
{ "Target", "ChangeControl", s.ctfilter, 0, "MonsterZone"}, { "~Target", "Return2Hand", s.rtfilter, "OnField", 0, 1, 1, c }} , s.ctop)
end
function s.thfilter(c)
return c:IsSetCard(0x3338) and c:IsType(TYPE_MONSTER) and c:IsAbleToHand() and not c:IsCode(id)
end
function s.thop(e,tp)
Scl.SelectAndOperateCards("Add2Hand",tp,s.thfilter,tp,"Deck",0,1,1,nil)()
end
function s.ctfilter(c)
return c:IsControlerCanBeChanged() and c:IsSummonType(SUMMON_TYPE_SPECIAL)
end
function s.rtfilter(c)
return c:IsAbleToHand() and c:IsFaceup() and c:IsSetCard(0x3338)
end
function s.ctop(e,tp)
if Scl.SelectAndOperateCards("Return2Hand",tp,s.rtfilter,tp,"OnField",0,1,1,aux.ExceptThisCard(e))() > 0 and Scl.IsCorrectlyOperated("Hand") then
local _, tc = Scl.GetTargetsReleate2Chain()
if not tc then return end
Duel.GetControl(tc,tp,PHASE_END,1)
end
end
\ No newline at end of file
--梦魇魔的仆从
function c10106002.initial_effect(c)
--cannot special summon
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--Summon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10106002,0))
e1:SetCategory(CATEGORY_SUMMON)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetRange(LOCATION_HAND)
e1:SetCode(EVENT_CHAINING)
e1:SetCondition(c10106002.sumcon)
e1:SetCost(c10106002.sumcost)
e1:SetTarget(c10106002.sumtg)
e1:SetOperation(c10106002.sumop)
c:RegisterEffect(e1)
--tograve
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10106002,1))
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_DRAW)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_SUMMON_SUCCESS)
e2:SetTarget(c10106002.thtg)
e2:SetOperation(c10106002.thop)
c:RegisterEffect(e2)
end
function c10106002.thfilter(c)
return c:IsSummonType(SUMMON_TYPE_NORMAL) and c:IsAbleToHand() and not c:IsCode(10106002)
end
function c10106002.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c10106002.thfilter,tp,LOCATION_MZONE,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_ONFIELD)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,0)
end
function c10106002.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local g=Duel.SelectMatchingCard(tp,c10106002.thfilter,tp,LOCATION_MZONE,0,1,99,nil)
if g:GetCount()>0 then
Duel.HintSelection(g)
if Duel.SendtoHand(g,nil,REASON_EFFECT)~=0 and Duel.IsPlayerCanDraw(tp,1) and Duel.SelectYesNo(tp,aux.Stringid(10106002,2)) then
Duel.BreakEffect()
Duel.Draw(tp,1,REASON_EFFECT)
end
end
end
function c10106002.sumcon(e,tp,eg,ep,ev,re,r,rp)
local loc=Duel.GetChainInfo(ev,CHAININFO_TRIGGERING_LOCATION)
return loc==LOCATION_MZONE and re:IsActiveType(TYPE_MONSTER) and re:GetHandler():IsSummonType(SUMMON_TYPE_SPECIAL) and rp~=tp
end
function c10106002.sumcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return not e:GetHandler():IsPublic() end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_PUBLIC)
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END)
e:GetHandler():RegisterEffect(e1)
end
function c10106002.sumfilter(c)
return c:IsSetCard(0x3338) and c:IsSummonable(true,nil)
end
function c10106002.sumtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c10106002.sumfilter,tp,LOCATION_HAND,0,1,e:GetHandler()) end
Duel.SetOperationInfo(0,CATEGORY_SUMMON,nil,1,tp,LOCATION_HAND)
end
function c10106002.sumop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON)
local g=Duel.SelectMatchingCard(tp,c10106002.sumfilter,tp,LOCATION_HAND,0,1,1,e:GetHandler())
if g:GetCount()>0 then
Duel.Summon(tp,g:GetFirst(),true,nil)
--恶念体复制兵器
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
local e1 = Scl.CreateSingleTriggerOptionalEffect(c, "BeNormalSummoned",
"AddFromDeck/GY2Hand", nil, "AddFromDeck/GY2Hand", "Delay",
nil, nil, {
{ "~Target", "Look", s.codefilter, "Hand,OnField" },
{ "~Target", "Add2Hand", aux.TRUE, "Deck,GY"} }, s.thop)
local e2 = Scl.CreateQuickOptionalEffect(c, nil, "Destroy", 1,
"Destroy", "Target", "MonsterZone", nil, nil, {
{ "Target", "Destroy", aux.TRUE, 0, "OnField"}, { "~Target", "Return2Hand", s.rtfilter, "OnField", 0, 1, 1, c }} , s.desop)
end
function s.thfilter(c,code)
return c:IsCode(code) and c:IsAbleToHand()
end
function s.codefilter(c,e,tp)
return c:IsSetCard(0x3338) and Scl.IsOriginalType(c, 0, TYPE_MONSTER) and Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil,c:GetCode()) and not c:IsCode(id)
end
function s.thop(e,tp)
local _,_,tc = Scl.SelectAndOperateCards("Look",tp,s.codefilter,tp,"Hand,OnField",0,1,1,nil,e,tp)()
if not tc then return end
Scl.SelectAndOperateCards("Add2Hand",tp,aux.NecroValleyFilter(s.thfilter),tp,"Deck,GY",0,1,2,nil,tc:GetCode())()
end
function s.rtfilter(c)
return c:IsAbleToHand() and c:IsFaceup() and c:IsSetCard(0x3338)
end
function s.desop(e,tp)
if Scl.SelectAndOperateCards("Return2Hand",tp,s.rtfilter,tp,"OnField",0,1,1,aux.ExceptThisCard(e))() > 0 and Scl.IsCorrectlyOperated("Hand") then
local _, tc = Scl.GetTargetsReleate2Chain()
if not tc then return end
Duel.Destroy(tc,REASON_EFFECT)
end
end
\ No newline at end of file
--梦魇魔的斥侯
function c10106003.initial_effect(c)
--cannot special summon
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--Summon
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10106003,0))
e1:SetCategory(CATEGORY_SUMMON)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetRange(LOCATION_HAND)
e1:SetCode(EVENT_ATTACK_ANNOUNCE)
e1:SetCondition(c10106003.sumcon)
e1:SetCost(c10106003.sumcost)
e1:SetTarget(c10106003.sumtg)
e1:SetOperation(c10106003.sumop)
c:RegisterEffect(e1)
--tohand
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10106003,1))
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_REMOVE)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_SUMMON_SUCCESS)
e2:SetTarget(c10106003.thtg)
e2:SetOperation(c10106003.thop)
c:RegisterEffect(e2)
end
function c10106003.thfilter(c)
return c:IsAbleToHand() and c:IsSummonType(SUMMON_TYPE_NORMAL) and not c:IsCode(10106003)
end
function c10106003.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c10106003.thfilter,tp,LOCATION_MZONE,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_ONFIELD)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,0,PLAYER_ALL,LOCATION_GRAVE)
end
function c10106003.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local g=Duel.SelectMatchingCard(tp,c10106003.thfilter,tp,LOCATION_MZONE,0,1,99,nil)
if g:GetCount()>0 then
Duel.HintSelection(g)
if Duel.SendtoHand(g,nil,REASON_EFFECT)~=0 and Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(10106003,2)) then
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local tg=Duel.SelectMatchingCard(tp,Card.IsAbleToRemove,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,nil)
Duel.HintSelection(tg)
Duel.Remove(tg,POS_FACEUP,REASON_EFFECT)
end
end
end
function c10106003.sumcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetAttacker():IsSummonType(SUMMON_TYPE_SPECIAL) and Duel.GetAttacker():IsControler(1-tp)
end
function c10106003.sumcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return not e:GetHandler():IsPublic() end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_PUBLIC)
e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END)
e:GetHandler():RegisterEffect(e1)
end
function c10106003.sumfilter(c)
return c:IsSetCard(0x3338) and c:IsSummonable(true,nil)
end
function c10106003.sumtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c10106003.sumfilter,tp,LOCATION_HAND,0,1,e:GetHandler()) end
Duel.SetOperationInfo(0,CATEGORY_SUMMON,nil,1,tp,LOCATION_HAND)
end
function c10106003.sumop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON)
local g=Duel.SelectMatchingCard(tp,c10106003.sumfilter,tp,LOCATION_HAND,0,1,1,e:GetHandler())
if g:GetCount()>0 then
Duel.Summon(tp,g:GetFirst(),true,nil)
--恶念体增幅兵器
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
local e1 = Scl.CreateSingleTriggerOptionalEffect(c, "BeNormalSummoned",
"PlaceInSpell&TrapZone", nil, nil, "Delay", nil, nil,
{ "~Target", "PlaceInSpell&TrapZone", s.pfilter, "Deck,GY" }, s.tfop)
local e2 = Scl.CreateQuickOptionalEffect(c, nil, "BanishFacedown", 1,
"BanishFacedown", "Target", "MonsterZone", nil, nil, {
{ "Target", "BanishFacedown", s.bfilter, 0, "GY"}, { "~Target", "Return2Hand", s.rtfilter, "OnField", 0, 1, 1, c }} , s.bop)
end
function s.pfilter(c,e,tp)
return aux.IsCodeListed(c, 10106003) and Scl.IsType(c,TYPE_CONTINUOUS,TYPE_TRAP,TYPE_SPELL) and not c:IsForbidden() and Duel.GetLocationCount(tp,LOCATION_SZONE) > 0
end
function s.tfop(e,tp)
Scl.SelectAndOperateCards("PlaceInSpell&TrapZone",tp,aux.NecroValleyFilter(s.pfilter),tp,"Deck,GY",0,1,1,nil,e,tp)()
end
function s.bfilter(c,e,tp)
return c:IsAbleToRemove(tp,POS_FACEDOWN)
end
function s.rtfilter(c)
return c:IsAbleToHand() and c:IsFaceup() and c:IsSetCard(0x3338)
end
function s.bop(e,tp)
if Scl.SelectAndOperateCards("Return2Hand",tp,s.rtfilter,tp,"OnField",0,1,1,aux.ExceptThisCard(e))() > 0 and Scl.IsCorrectlyOperated("Hand") then
local _, tc = Scl.GetTargetsReleate2Chain()
if not tc then return end
Duel.Remove(tc,POS_FACEDOWN,REASON_EFFECT)
end
end
\ No newline at end of file
--梦魇魔的门番
function c10106004.initial_effect(c)
--cannot special summon
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--draw
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10106004,1))
e1:SetCategory(CATEGORY_DRAW+CATEGORY_TODECK)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_TO_HAND)
e1:SetCondition(c10106004.drcon)
e1:SetTarget(c10106004.drtg)
e1:SetOperation(c10106004.drop)
c:RegisterEffect(e1)
--atk
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10106004,0))
e2:SetCategory(CATEGORY_ATKCHANGE+CATEGORY_DEFCHANGE+CATEGORY_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetRange(LOCATION_HAND)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0,0x1c0+TIMING_MAIN_END)
e2:SetCost(c10106004.acost)
e2:SetTarget(c10106004.atg)
e2:SetOperation(c10106004.aop)
c:RegisterEffect(e2)
--自负之恶念体
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
local e1 = Scl.CreateQuickOptionalEffect(c, "ActivateEffect", "Equip", nil,
"Equip", "Target", "Hand,MonsterZone", s.eqcon, nil,
s.eqtg, s.eqop)
local e2 = Scl.CreateFieldTriggerContinousEffect(c, "BeforeEffectResolving", nil, nil, nil, "Spell&TrapZone", s.cecon, s.ceop)
--[[local e1 = Scl.CreateQ(c, "BeSpecialSummoned",
"Equip", nil, "Equip",
"Delay", "Hand,MonsterZone", s.eqcon, nil,
{ "~Target", "Equip", s.eqfilter, true }, s.eqop)
local e2 = Scl.CreateEquipBuffEffect(c, "+ATK", 800)
local e3,e4 = Scl.CreateEquipBuffEffect(c,
"NegateEffect,NegateActivatedEffect", 1)
--]]
local e5,e6 = Scl.CreateSingleTriggerOptionalEffect(c, "BeNormalSummoned,BeAdded2Hand",
"Draw", nil, "Draw,ShuffleIn2Deck", "Delay", nil,
nil, { "PlayerTarget", "Draw", 1 }, s.drop)
end
function c10106004.drcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_ONFIELD) and c:IsPreviousPosition(POS_FACEUP)
function s.cfilter(c)
return c:IsFaceup() and c:IsSetCard(0x3338)
end
function c10106004.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToDeck,tp,LOCATION_HAND,0,1,nil) and Duel.IsPlayerCanDraw(tp,1) end
Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,1,tp,LOCATION_HAND)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
function s.eqcon(e,tp)
return Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_ONFIELD,0,1,e:GetHandler())
end
function c10106004.drop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,Card.IsAbleToDeck,tp,0x2,0,1,1,nil)
if g:GetCount()>0 and Duel.SendtoDeck(g,nil,1,REASON_EFFECT)~=0 and g:GetFirst():IsLocation(LOCATION_DECK) then
Duel.Draw(tp,1,REASON_EFFECT)
function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk)
local rc = re:GetHandler()
if chk == 0 then
return rc:IsFaceup() and rc:IsCanBeEffectTarget(e) and rc:IsSummonType(SUMMON_TYPE_SPECIAL) and re:IsActiveType(TYPE_MONSTER) and rc:IsLocation(LOCATION_MZONE) and rp ~= tp and rc:IsRelateToChain(ev) and Duel.GetLocationCount(tp,LOCATION_SZONE) > 0
end
Duel.SetTargetCard(rc)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
end
function c10106004.acost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:GetFlagEffect(10106004)==0 end
c:RegisterFlagEffect(10106004,RESET_CHAIN,0,1)
function s.eqfilter(c,e,tp)
return c:IsFaceup() and c:IsSummonType(SUMMON_TYPE_SPECIAL) and c:IsSummonPlayer(1-tp) and Duel.GetLocationCount(tp,LOCATION_SZONE) > 0
end
function c10106004.afilter(c)
return c:IsSummonType(SUMMON_TYPE_SPECIAL) and c:IsFaceup()
function s.egfilter(c)
return c:IsRelateToChain() and c:IsFaceup()
end
function c10106004.atg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsSummonable(true,nil)
and Duel.IsExistingMatchingCard(c10106004.afilter,tp,0,LOCATION_MZONE,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_SUMMON,e:GetHandler(),1,tp,LOCATION_HAND)
function s.eqop(e,tp,eg,ep,ev,re,r,rp)
local _, rc = Scl.GetTargetsReleate2Chain(Card.IsFaceup)
local _,c = Scl.GetActivateCard()
if rc and c then
Scl.Equip(c, rc)
end
end
function s.cecon(e,tp,eg,ep,ev,re,r,rp)
local c = e:GetHandler()
return re:GetHandler():GetEquipGroup():IsContains(c)
end
function s.ceop(e,tp,eg,ep,ev,re,r,rp)
Scl.HintCard(id)
local g=Group.CreateGroup()
Duel.ChangeTargetCard(ev,g)
Duel.ChangeChainOperation(ev,s.rep_op)
end
function s.rep_op(e,tp)
local c = e:GetHandler()
if c:IsFaceup() and c:IsRelateToEffect(e) then
Scl.AddSingleBuff2Self(c, "+ATK", 800, "Reset", RESETS_SCL)
end
end
function s.rvfilter(c)
return not c:IsPublic()
end
function c10106004.aop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local g=Duel.SelectMatchingCard(tp,c10106004.afilter,tp,0,LOCATION_MZONE,1,1,nil)
if g:GetCount()<=0 then return end
Duel.HintSelection(g)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(-800)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
g:GetFirst():RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_UPDATE_DEFENSE)
g:GetFirst():RegisterEffect(e2)
if not g:GetFirst():IsImmuneToEffect(e) and c:IsRelateToEffect(e) and c:IsSummonable(true,nil) then
Duel.BreakEffect()
Duel.Summon(tp,c,true,nil)
function s.drop(e,tp)
if Duel.Draw(tp,1,REASON_EFFECT) > 0 then
Scl.SetExtraSelectAndOperateParama(nil,true)
Scl.SelectAndOperateCards("ShuffleIn2Deck",tp,Card.IsAbleToDeck,tp,"Hand,OnField",0,1,1,nil)()
end
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(1,0)
e1:SetReset(RESET_PHASE+PHASE_END,2)
Duel.RegisterEffect(e1,tp)
end
\ No newline at end of file
--梦魇魔的前卫
function c10106005.initial_effect(c)
--cannot special summon
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--draw
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10106005,1))
e1:SetCategory(CATEGORY_RECOVER)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EVENT_TO_HAND)
e1:SetCondition(c10106005.reccon)
e1:SetTarget(c10106005.rectg)
e1:SetOperation(c10106005.recop)
c:RegisterEffect(e1)
--dis
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10106005,0))
e2:SetCategory(CATEGORY_DISABLE+CATEGORY_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetRange(LOCATION_HAND)
e2:SetCode(EVENT_CHAINING)
e2:SetCondition(c10106005.discon)
e2:SetTarget(c10106005.distg)
e2:SetOperation(c10106005.disop)
c:RegisterEffect(e2)
--自卑之恶念体
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
local e1 = Scl.CreateFieldTriggerOptionalEffect(c, "DeclareAttack",
"Equip", nil, "Equip",
"Target", "Hand,MonsterZone", s.eqcon, nil, s.eqtg, s.eqop)
local e2 = Scl.CreateEquipBuffEffect(c, "!Attack", 1)
local e3,e4 = Scl.CreateEquipBuffEffect(c,
"=ATK,=DEF", 0)
local e5,e6 = Scl.CreateSingleTriggerOptionalEffect(c, "BeNormalSummoned,BeAdded2Hand",
{id, 0}, nil, nil, "Delay", nil, nil, nil, s.drop)
end
function c10106005.reccon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_ONFIELD) and c:IsPreviousPosition(POS_FACEUP)
function s.cfilter(c)
return c:IsFaceup() and c:IsSetCard(0x3338)
end
function c10106005.rectg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(800)
Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,800)
function s.eqcon(e,tp)
return Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_ONFIELD,0,1,e:GetHandler())
end
function c10106005.recop(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Recover(p,d,REASON_EFFECT)
function s.eqfilter(c,e,tp)
return c:IsControler(1-tp) and c:IsFaceup() and c:IsSummonType(SUMMON_TYPE_SPECIAL) and c:IsCanBeEffectTarget(e)
end
function c10106005.distg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsSummonable(true,nil) end
Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_SUMMON,e:GetHandler(),1,0,0)
end
function c10106005.disop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if Duel.NegateEffect(ev) and c:IsRelateToEffect(e) and c:IsSummonable(true,nil) then
Duel.BreakEffect()
Duel.Summon(tp,c,true,nil)
function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk)
local bc1,bc2 = Duel.GetBattleMonster(tp)
local g = Scl.Mix2Group(bc1,bc2)
local sg = g:Filter(s.eqfilter,nil,e,tp)
if chk == 0 then return #sg > 0 and Duel.GetLocationCount(tp,LOCATION_SZONE) > 0 end
local tc = sg:GetFirst()
if #sg > 1 then
Scl.HintSelect(tp, "Opponent")
tc = sg:Select(tp,1,1,nil):GetFirst()
end
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(1,0)
e1:SetReset(RESET_PHASE+PHASE_END,2)
Duel.RegisterEffect(e1,tp)
Duel.SetTargetCard(tc)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
end
function s.eqop(e,tp,eg)
local _, tc = Scl.GetTargetsReleate2Chain(Card.IsFaceup)
local _, c = Scl.GetActivateCard()
if not tc or not c then return end
Scl.Equip(c, tc)
end
function s.drop(e,tp)
Duel.RegisterFlagEffect(tp,id,RESET_EP_SCL,0,1)
if s.buff then return end
s.buff = true
local c = e:GetHandler()
Scl.CreateFieldBuffEffect({c,tp},"+ATK,+DEF",s.val1,s.limtg,{0, "MonsterZone"},nil, nil, RESET_EP_SCL)
Scl.CreateFieldBuffEffect({c,tp},"+Level",s.val2,s.limtg,{0, "MonsterZone"},nil, nil, RESET_EP_SCL)
end
function s.val1(e,c)
local ct = Duel.GetFlagEffect(tp, id)
return ct * -800
end
function s.val2(e,c)
local ct = Duel.GetFlagEffect(tp, id)
return ct * -1
end
function c10106005.discon(e,tp,eg,ep,ev,re,r,rp)
return re:IsHasCategory(CATEGORY_SPECIAL_SUMMON) and Duel.IsChainDisablable(ev) and not Duel.IsExistingMatchingCard(Card.IsSummonType,tp,LOCATION_MZONE,0,1,nil,SUMMON_TYPE_SPECIAL)
function s.limtg(e,c)
return c:IsSummonType(SUMMON_TYPE_SPECIAL)
end
--梦魇魔·恐魔
function c10106006.initial_effect(c)
--cannot special summon
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--summon cost
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SUMMON_COST)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCost(c10106006.scost)
e1:SetOperation(c10106006.scop)
c:RegisterEffect(e1)
--search
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(10106006,0))
e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_SUMMON_SUCCESS)
e3:SetTarget(c10106006.thtg)
e3:SetOperation(c10106006.thop)
c:RegisterEffect(e3)
--extra summon
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e4:SetCode(EVENT_SUMMON_SUCCESS)
e4:SetOperation(c10106006.sumop)
c:RegisterEffect(e4)
--焦躁之恶念体
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
local e1 = Scl.CreateFieldTriggerOptionalEffect(c, "BeSpecialSummoned",
"Equip", nil, "Equip,NormalSummon",
"Target", "Hand,MonsterZone", s.eqcon, nil,
{ "Target", "Equip", s.eqfilter, 0, "MonsterZone" }, s.eqop)
local e2 = Scl.CreateFieldTriggerContinousEffect(c, "BeforeEffectResolving",
nil, nil, nil, "Spell&TrapZone", s.drcon, s.drop)
local e3 = Scl.CreateFieldTriggerContinousEffect(c, "NegateActivatedEffect",
nil, nil, nil, "Spell&TrapZone", s.drcon, s.drop)
end
function c10106006.scost(e,c,tp)
return Duel.GetActivityCount(tp,ACTIVITY_SPSUMMON)==0
function s.cfilter(c,tp)
return (c:IsSummonLocation(LOCATION_EXTRA) or c:IsSummonLocation(LOCATION_DECK) ) and c:IsSummonPlayer(1-tp) and c:IsType(TYPE_EFFECT)
end
function c10106006.scop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTargetRange(1,0)
Duel.RegisterEffect(e1,tp)
function s.eqcon(e,tp,eg)
return eg:IsExists(s.cfilter,1,nil,tp)
end
function c10106006.sumop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_DISABLE)
e1:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTarget(aux.TargetBoolFunction(Card.IsSummonType,SUMMON_TYPE_SPECIAL))
Duel.RegisterEffect(e1,tp)
function s.eqfilter(c,e,tp)
return c:IsSummonType(SUMMON_TYPE_SPECIAL) and c:IsFaceup() and Duel.GetLocationCount(tp,LOCATION_SZONE) > 0
end
function c10106006.thfilter(c)
return c:IsSetCard(0x3338) and c:IsAbleToHand() and (c:IsFaceup() or c:IsLocation(LOCATION_DECK))
function s.sumfilter(c)
return c:IsSetCard(0x3338) and c:IsSummonable(true, nil)
end
function c10106006.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c10106006.thfilter,tp,0x11,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,0x11)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,0,tp,LOCATION_MZONE)
end
function c10106006.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c10106006.thfilter),tp,0x11,0,1,1,nil)
if g:GetCount()>0 and Duel.SendtoHand(g,nil,REASON_EFFECT)~=0 then
Duel.ConfirmCards(1-tp,g)
local rg=Duel.GetMatchingGroup(c10106006.thfilter,tp,LOCATION_MZONE,0,e:GetHandler())
if rg:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(10106006,1)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local rg2=rg:Select(tp,1,1,nil)
Duel.HintSelection(rg2)
Duel.SendtoHand(rg2,nil,REASON_EFFECT)
function s.eqop(e,tp,eg)
local _, c = Scl.GetActivateCard()
local _, tc = Scl.GetTargetsReleate2Chain(Card.IsFaceup)
if not c or not tc then return end
if Scl.Equip(c, tc) > 0 then
Scl.SetExtraSelectAndOperateParama("NormalSummon", true)
local _,c = Scl.SelectCards("NormalSummon",tp,s.sumfilter,tp,"Hand,MonsterZone",0,1,1,nil)
if c then
Duel.Summon(tp,c,true,nil)
end
end
end
function s.drcon(e,tp,eg,ep,ev,re,r,rp)
local tc = e:GetHandler():GetEquipTarget()
local re2=Duel.GetChainInfo(ev, CHAININFO_TRIGGERING_EFFECT)
return tc and re2:GetHandler() == tc
end
function s.drop(e,tp)
Scl.HintCard(id)
Duel.Draw(tp,1,REASON_EFFECT)
--Duel.Draw(1-tp,1,REASON_EFFECT)
--local c = e:GetHandler()
--local e1,e2 = Scl.CreatePlayerBuffEffect({c,tp}, "!Normal&SpecialSummon",1,aux.TargetBoolFunction(Card.IsSetCard,0x3338),nil,nil,{RESET_EP_SCL,2})
end
\ No newline at end of file
--梦魇魔·惧魔
function c10106007.initial_effect(c)
--cannot special summon
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--summon cost
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SUMMON_COST)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCost(c10106007.scost)
e1:SetOperation(c10106007.scop)
c:RegisterEffect(e1)
--search
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(10106007,0))
e3:SetCategory(CATEGORY_TOHAND)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_SUMMON_SUCCESS)
e3:SetTarget(c10106007.thtg)
e3:SetOperation(c10106007.thop)
c:RegisterEffect(e3)
--extra summon
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e4:SetCode(EVENT_SUMMON_SUCCESS)
e4:SetOperation(c10106007.sumop)
c:RegisterEffect(e4)
--惶恐之恶念体
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
local e1 = Scl.CreateFieldTriggerOptionalEffect(c, "BeSpecialSummoned",
"Equip", nil, "Equip,NormalSummon",
"Target", "Hand,MonsterZone", s.eqcon, nil,
{ "Target", "Equip", s.eqfilter, 0, "MonsterZone" }, s.eqop)
--local e2 = Scl.CreateFieldTriggerContinousEffect(c, "Adjust", nil, nil, nil, "Spell&TrapZone", nil, s.bnop)
local e3 = Scl.CreateFieldTriggerContinousEffect(c, "BeEffectTarget", nil, nil, nil, "Spell&TrapZone", s.bncon2, s.bnop2)
local e4 = Scl.CreateFieldTriggerContinousEffect(c, "BeAttackTarget", nil, nil, nil, "Spell&TrapZone", s.bncon3, s.bnop2)
local e5 = Scl.CreateFieldTriggerContinousEffect(c, "BeforeEffectResolving", nil, nil, nil, "Spell&TrapZone", s.bncon4, s.bnop2)
end
function c10106007.scost(e,c,tp)
return Duel.GetActivityCount(tp,ACTIVITY_SPSUMMON)==0
function s.cfilter(c,tp)
return (c:IsSummonLocation(LOCATION_HAND) or c:IsSummonLocation(LOCATION_GRAVE) ) and c:IsSummonPlayer(1-tp)
end
function c10106007.scop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTargetRange(1,0)
Duel.RegisterEffect(e1,tp)
function s.eqcon(e,tp,eg)
return eg:IsExists(s.cfilter,1,nil,tp)
end
function c10106007.sumop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_SET_ATTACK_FINAL)
e1:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTarget(c10106007.atktg)
e1:SetValue(c10106007.atkval)
Duel.RegisterEffect(e1,tp)
local e2=e1:Clone()
e2:SetCode(EFFECT_SET_DEFENSE_FINAL)
e2:SetValue(c10106007.defval)
Duel.RegisterEffect(e2,tp)
function s.eqfilter(c,e,tp)
return c:IsSummonType(SUMMON_TYPE_SPECIAL) and c:IsFaceup() and Duel.GetLocationCount(tp,LOCATION_SZONE) > 0
end
function c10106007.atktg(e,c)
return bit.band(c:GetSummonType(),SUMMON_TYPE_SPECIAL)==SUMMON_TYPE_SPECIAL
function s.sumfilter(c)
return c:IsSetCard(0x3338) and c:IsSummonable(true, nil)
end
function c10106007.atkval(e,c)
return c:GetAttack()/2
function s.eqop(e,tp,eg)
local _, c = Scl.GetActivateCard()
local _, tc = Scl.GetTargetsReleate2Chain(Card.IsFaceup)
if not c or not tc then return end
if Scl.Equip(c, tc) > 0 then
Scl.SetExtraSelectAndOperateParama("NormalSummon", true)
local _,c = Scl.SelectCards("NormalSummon",tp,s.sumfilter,tp,"Hand,MonsterZone",0,1,1,nil)
if c then
Duel.Summon(tp,c,true,nil)
end
end
end
function c10106007.defval(e,c)
return c:GetDefense()/2
function s.bnop(e,tp)
local c = e:GetHandler()
local ec = c:GetEquipTarget()
if not ec then return end
if ec:GetOwnerTargetCount()>0 then
Scl.HintCard(id)
Scl.AddSingleBuff({c,ec},"NegateEffect",1,"NegateActivatedEffect",1)
end
end
function c10106007.thfilter(c)
return c:IsSetCard(0x3338) and c:IsAbleToHand() and c:IsFaceup()
function s.bncon2(e,tp,eg)
local c = e:GetHandler()
local ec = c:GetEquipTarget()
return ec and eg:IsContains(ec)
end
function c10106007.acfilter(c,tp)
return c:IsSetCard(0x3338) and c:IsType(TYPE_TRAP) and c:IsType(TYPE_CONTINUOUS) and c:GetActivateEffect():IsActivatable(tp,true)
function s.bnop2(e,tp,eg)
local c = e:GetHandler()
local ec = c:GetEquipTarget()
if not ec then return end
if not ec:IsDisabled() then
Scl.HintCard(id)
end
Scl.AddSingleBuff({c,ec},"NegateEffect",1,"NegateActivatedEffect",1)
end
function c10106007.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c10106007.acfilter,tp,0x11,0,1,nil,tp) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,0,tp,LOCATION_MZONE)
function s.bncon3(e,tp,eg)
local c = e:GetHandler()
local ec = c:GetEquipTarget()
local bc = Duel.GetAttackTarget()
return ec and bc and ec == bc
end
function c10106007.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local tc=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c10106007.acfilter),tp,0x11,0,1,1,nil,tp):GetFirst()
if tc then
if not Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) then return end
local te=tc:GetActivateEffect()
local tep=tc:GetControler()
local cost=te:GetCost()
if cost then cost(te,tep,eg,ep,ev,re,r,rp,1) end
local rg=Duel.GetMatchingGroup(c10106007.thfilter,tp,LOCATION_MZONE,0,e:GetHandler())
if rg:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(10106007,1)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local rg2=rg:Select(tp,1,1,nil)
Duel.HintSelection(rg2)
Duel.SendtoHand(rg2,nil,REASON_EFFECT)
end
end
function s.bncon4(e,tp,eg,ep,ev,re,r,rp)
local c = e:GetHandler()
local ec = c:GetEquipTarget()
local tg = Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS)
return re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) and tg and tg:IsContains(ec)
end
\ No newline at end of file
--梦魇魔·悲怆魔
function c10106008.initial_effect(c)
--cannot special summon
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--summon cost
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SUMMON_COST)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetCost(c10106008.scost)
e1:SetOperation(c10106008.scop)
c:RegisterEffect(e1)
--summon
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(10106008,0))
e3:SetCategory(CATEGORY_SUMMON+CATEGORY_TOHAND)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_SUMMON_SUCCESS)
e3:SetTarget(c10106008.sumtg)
e3:SetOperation(c10106008.sumop)
c:RegisterEffect(e3)
--Remove
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e4:SetCode(EVENT_SUMMON_SUCCESS)
e4:SetOperation(c10106008.sumop2)
c:RegisterEffect(e4)
--惊惧之恶念体
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
local e1 = Scl.CreateFieldTriggerOptionalEffect(c, "BeSpecialSummoned",
"Equip", nil, "Equip,NormalSummon",
"Target", "Hand,MonsterZone", s.eqcon, nil,
{ "Target", "Equip", s.eqfilter, 0, "MonsterZone" }, s.eqop)
local e2 = Scl.CreateFieldTriggerContinousEffect(c, "BeforeLeavingField",nil,nil,nil,"Spell&TrapZone",s.lfcon,s.lfop)
end
function s.cfilter(c,tp)
return c:IsSummonPlayer(1-tp) and not c:GetReasonEffect():IsHasProperty(EFFECT_FLAG_UNCOPYABLE)
end
function s.eqcon(e,tp,eg)
return eg:IsExists(s.cfilter,1,nil,tp)
end
function s.eqfilter(c,e,tp)
return c:IsSummonType(SUMMON_TYPE_SPECIAL) and c:IsFaceup() and Duel.GetLocationCount(tp,LOCATION_SZONE) > 0
end
function s.sumfilter(c)
return c:IsSetCard(0x3338) and c:IsSummonable(true, nil)
end
function s.eqop(e,tp,eg)
local _, c = Scl.GetActivateCard()
local _, tc = Scl.GetTargetsReleate2Chain(Card.IsFaceup)
if not c or not tc then return end
if Scl.Equip(c, tc) > 0 then
Scl.SetExtraSelectAndOperateParama("NormalSummon", true)
local _,c = Scl.SelectCards("NormalSummon",tp,s.sumfilter,tp,"Hand,MonsterZone",0,1,1,nil)
if c then
Duel.Summon(tp,c,true,nil)
end
end
end
function c10106008.scost(e,c,tp)
return Duel.GetActivityCount(tp,ACTIVITY_SPSUMMON)==0
function s.lfcon(e,tp,eg)
local c = e:GetHandler()
local ec = c:GetEquipTarget()
return ec and eg:IsContains(ec)
end
function c10106008.scop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
function s.lfop(e,tp)
local c = e:GetHandler()
local ec = c:GetEquipTarget()
local eg = ec:GetEquipGroup()
for tc in aux.Next(eg) do
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTargetRange(1,0)
Duel.RegisterEffect(e1,tp)
end
function c10106008.sumop2(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE+EFFECT_FLAG_IGNORE_RANGE+EFFECT_FLAG_IGNORE_IMMUNE)
e1:SetCode(EFFECT_TO_GRAVE_REDIRECT)
e1:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e1:SetValue(LOCATION_REMOVED)
e1:SetTarget(aux.TargetBoolFunction(Card.IsSummonType,SUMMON_TYPE_SPECIAL))
Duel.RegisterEffect(e1,tp)
end
function c10106008.sumfilter(c,code)
return c:IsSetCard(0x3338) and not c:IsCode(code) and c:IsSummonable(true,nil)
end
function c10106008.thfilter(c)
return c:IsSetCard(0x3338) and c:IsAbleToHand()
end
function c10106008.sumtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c10106008.thfilter,tp,LOCATION_MZONE,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_SUMMON,nil,0,tp,0x2)
end
function c10106008.sumop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local g=Duel.SelectMatchingCard(tp,c10106008.thfilter,tp,LOCATION_MZONE,0,1,1,nil)
if g:GetCount()>0 then
Duel.HintSelection(g)
if Duel.SendtoHand(g,nil,REASON_EFFECT)~=0 and g:GetFirst():IsLocation(LOCATION_HAND) and Duel.IsExistingMatchingCard(c10106008.sumfilter,tp,LOCATION_HAND,0,1,nil,g:GetFirst():GetCode()) and Duel.SelectYesNo(tp,aux.Stringid(10106008,1)) then
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON)
local sg=Duel.SelectMatchingCard(tp,c10106008.sumfilter,tp,LOCATION_HAND,0,1,1,nil,g:GetFirst():GetCode())
Duel.Summon(tp,sg:GetFirst(),true,nil)
end
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_LEAVE_FIELD_REDIRECT)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_REDIRECT)
e1:SetValue(LOCATION_HAND)
tc:RegisterEffect(e1,true)
end
end
\ No newline at end of file
--梦魇魔·摧毁者
function c10106009.initial_effect(c)
--cannot special summon
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--disable spsummon
--恶念体 神智摧毁者
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
Scl.SetSummonCondition(c, false, aux.FALSE)
local e0 = Scl.AddNormalSummonProcedure(c, false, s.sumcon, nil,
s.sumop, nil, nil, "TributeSummon")
--[[local e1 = Scl.CreateFieldBuffEffect(c, "NegateEffect", 1,
aux.TargetBoolFunction(s.cfilter),
{"MonsterZone","MonsterZone"}, "MonsterZone", s.con)--]]
local e1 = Scl.CreateFieldBuffEffect(c, "UnaffectedByOpponentsCardEffects",
s.val, nil,
{"OnField",0}, "MonsterZone", s.con, nil, nil, nil, "SetAvailable,IgnoreUnaffected")
local e2 = Scl.CreateSingleBuffEffect(c, "+ATK", s.val, "MonsterZone", s.con)
end
function s.ecfilter(c)
return c:IsFaceup() and c:IsSetCard(0x3338)
end
function s.otfilter(c,tp)
return c:GetEquipGroup():IsExists(s.ecfilter,1,nil)
end
function s.sumcon(e,c,tp,minc)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetRange(LOCATION_MZONE)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(1,0)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_ADD_EXTRA_TRIBUTE)
e1:SetTargetRange(0,LOCATION_MZONE)
e1:SetTarget(aux.TargetBoolFunction(s.otfilter))
e1:SetValue(POS_FACEUP_ATTACK)
c:RegisterEffect(e1)
--cannot target
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET)
e2:SetValue(1)
c:RegisterEffect(e2)
--immune
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_IMMUNE_EFFECT)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e3:SetRange(LOCATION_MZONE)
e3:SetValue(c10106009.efilter)
c:RegisterEffect(e3)
--remove
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(10106009,0))
e4:SetCategory(CATEGORY_REMOVE)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e4:SetCode(EVENT_BATTLE_START)
e4:SetCondition(c10106009.rmcon)
e4:SetTarget(c10106009.rmtg)
e4:SetOperation(c10106009.rmop)
c:RegisterEffect(e4)
end
function c10106009.efilter(e,te)
return te:GetHandler():IsSummonType(SUMMON_TYPE_SPECIAL)
end
function c10106009.rmcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local bc=c:GetBattleTarget()
return bc and bc:IsSummonType(SUMMON_TYPE_SPECIAL) and bc:IsAbleToRemove()
end
function c10106009.rmtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_REMOVE,e:GetHandler():GetBattleTarget(),1,0,0)
end
function c10106009.rmop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local bc=c:GetBattleTarget()
if bc:IsRelateToBattle() and Duel.Remove(bc,POS_FACEUP,REASON_EFFECT)~=0 and bc:IsLocation(LOCATION_REMOVED) and Duel.GetAttacker()==c and c:IsRelateToBattle() and c:IsChainAttackable() and Duel.SelectYesNo(tp,aux.Stringid(10106009,1)) then
Duel.BreakEffect()
Duel.ChainAttack()
end
local mg=Duel.GetMatchingGroup(s.otfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil,tp)
local res = c:IsLevelAbove(7) and minc<=1 and Duel.CheckTribute(c,1,1,mg)
e1:Reset()
return res
end
function s.sumop(e,tp,eg,ep,ev,re,r,rp,c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_ADD_EXTRA_TRIBUTE)
e1:SetTargetRange(0,LOCATION_MZONE)
e1:SetTarget(aux.TargetBoolFunction(s.otfilter))
e1:SetValue(POS_FACEUP_ATTACK)
c:RegisterEffect(e1)
local mg=Duel.GetMatchingGroup(s.otfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil,tp)
local sg=Duel.SelectTribute(tp,c,1,1,mg)
e1:Reset()
c:SetMaterial(sg)
Duel.Release(sg,REASON_SUMMON+REASON_MATERIAL)
end
function s.con(e)
return e:GetHandler():IsSummonType(SUMMON_TYPE_ADVANCE)
end
function s.cfilter(c)
return c:IsSummonType(SUMMON_TYPE_SPECIAL)
end
function s.val(e,c)
return Duel.GetMatchingGroupCount(s.cfilter, e:GetHandlerPlayer(), 0, LOCATION_MZONE, nil) * 800
end
\ No newline at end of file
--梦魇魔·洗脑魔
function c10106010.initial_effect(c)
--cannot special summon
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--disable spsummon
--恶念体 大脑掌控者
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
Scl.SetSummonCondition(c, false, aux.FALSE)
local e0 = Scl.AddNormalSummonProcedure(c, false, s.sumcon, nil,
s.sumop, nil, nil, "TributeSummon")
local e1 = Scl.CreateFieldTriggerContinousEffect(c, "BeSpecialSummoned", nil,
nil, nil, "MonsterZone", s.damcon, s.damop)
local e2 = Scl.CreateFieldTriggerContinousEffect(c, "ActivateEffect", nil,
nil, nil, "MonsterZone", s.glpcon, s.glpop)
end
function s.ecfilter(c)
return c:IsFaceup() and c:IsSetCard(0x3338)
end
function s.otfilter(c,tp)
return c:GetEquipGroup():IsExists(s.ecfilter,1,nil)
end
function s.sumcon(e,c,tp,minc)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_ADD_EXTRA_TRIBUTE)
e1:SetTargetRange(0,LOCATION_MZONE)
e1:SetTarget(aux.TargetBoolFunction(s.otfilter))
e1:SetValue(POS_FACEUP_ATTACK)
c:RegisterEffect(e1)
local mg=Duel.GetMatchingGroup(s.otfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil,tp)
local res = c:IsLevelAbove(7) and minc<=1 and Duel.CheckTribute(c,1,1,mg)
e1:Reset()
return res
end
function s.sumop(e,tp,eg,ep,ev,re,r,rp,c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetRange(LOCATION_MZONE)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(1,0)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_ADD_EXTRA_TRIBUTE)
e1:SetTargetRange(0,LOCATION_MZONE)
e1:SetTarget(aux.TargetBoolFunction(s.otfilter))
e1:SetValue(POS_FACEUP_ATTACK)
c:RegisterEffect(e1)
--Atk
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_UPDATE_ATTACK)
e2:SetRange(LOCATION_MZONE)
e2:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
e2:SetTarget(aux.TargetBoolFunction(Card.IsSummonType,SUMMON_TYPE_NORMAL))
e2:SetValue(300)
c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e3)
local e4=e2:Clone()
e4:SetCode(EFFECT_UPDATE_ATTACK)
e4:SetTarget(aux.TargetBoolFunction(Card.IsSummonType,SUMMON_TYPE_SPECIAL))
e4:SetValue(-300)
c:RegisterEffect(e4)
local e5=e4:Clone()
e5:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e5)
--damage
local e6=Effect.CreateEffect(c)
e6:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e6:SetCode(EVENT_SPSUMMON_SUCCESS)
e6:SetProperty(EFFECT_FLAG_DELAY)
e6:SetRange(LOCATION_MZONE)
e6:SetCondition(c10106010.damcon)
e6:SetOperation(c10106010.damop)
c:RegisterEffect(e6)
--activate cost
local e7=Effect.CreateEffect(c)
e7:SetType(EFFECT_TYPE_FIELD)
e7:SetCode(EFFECT_ACTIVATE_COST)
e7:SetRange(LOCATION_MZONE)
e7:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e7:SetTargetRange(0,1)
e7:SetTarget(c10106010.sumtg)
e7:SetCost(c10106010.costchk)
e7:SetOperation(c10106010.costop)
c:RegisterEffect(e7)
--accumulate
local e8=Effect.CreateEffect(c)
e8:SetType(EFFECT_TYPE_FIELD)
e8:SetCode(0x10000000+10106010)
e8:SetRange(LOCATION_MZONE)
e8:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e8:SetTargetRange(0,1)
c:RegisterEffect(e8)
local mg=Duel.GetMatchingGroup(s.otfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil,tp)
local sg=Duel.SelectTribute(tp,c,1,1,mg)
e1:Reset()
c:SetMaterial(sg)
Duel.Release(sg,REASON_SUMMON+REASON_MATERIAL)
end
function c10106010.sumtg(e,te)
return te:GetActivateLocation()==LOCATION_MZONE and te:GetHandler():IsSummonType(SUMMON_TYPE_SPECIAL)
function s.con(e)
return e:GetHandler():IsSummonType(SUMMON_TYPE_ADVANCE)
end
function c10106010.costchk(e,te_or_c,tp)
local ct=Duel.GetFlagEffect(tp,10106010)
return Duel.CheckLPCost(tp,ct*800)
function s.damcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(Card.IsSummonPlayer, 1, nil, 1 - tp) and s.con(e)
end
function c10106010.costop(e,tp,eg,ep,ev,re,r,rp)
Duel.PayLPCost(tp,800)
function s.damop(e,tp,eg,ep,ev,re,r,rp)
Scl.HintCard(id)
local ct = eg:FilterCount(Card.IsSummonPlayer, nil, 1 - tp)
Duel.Damage(1 - tp, ct * 800, REASON_EFFECT, true)
Duel.Recover(tp, ct * 1000, REASON_EFFECT, true)
Duel.RDComplete()
end
function c10106010.damcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(aux.FilterEqualFunction(Card.GetSummonPlayer,1-tp),1,nil)
function s.glpcon(e,tp,eg,ep,ev,re,r,rp)
local loc = Duel.GetChainInfo(ev, CHAININFO_TRIGGERING_LOCATION)
return rp ~= tp and re:GetHandler():IsSummonType(SUMMON_TYPE_SPECIAL) and s.con(e) and loc & LOCATION_MZONE ~= 0
end
function c10106010.damop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_CARD,0,10106010)
local ct=eg:FilterCount(aux.FilterEqualFunction(Card.GetSummonPlayer,1-tp),nil)
Duel.Damage(1-tp,ct*800,REASON_EFFECT)
function s.glpop(e,tp)
Scl.HintCard(id)
Duel.Damage(1 - tp, 800, REASON_EFFECT, true)
Duel.Recover(tp, 1000, REASON_EFFECT, true)
Duel.RDComplete()
end
\ No newline at end of file
--梦魇魔的兵卒
function c10106011.initial_effect(c)
--cannot special summon
local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_SPSUMMON_CONDITION)
e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
c:RegisterEffect(e0)
--draw
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(10106011,1))
e1:SetCategory(CATEGORY_DAMAGE)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EVENT_TO_HAND)
e1:SetCondition(c10106011.damcon)
e1:SetTarget(c10106011.damtg)
e1:SetOperation(c10106011.damop)
c:RegisterEffect(e1)
--remove
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10106011,0))
e2:SetCategory(CATEGORY_REMOVE+CATEGORY_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetRange(LOCATION_HAND)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_MAIN_END)
e2:SetCost(c10106011.rmcost)
e2:SetCondition(c10106011.rmcon)
e2:SetTarget(c10106011.rmtg)
e2:SetOperation(c10106011.rmop)
c:RegisterEffect(e2)
end
function c10106011.damcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_ONFIELD) and c:IsPreviousPosition(POS_FACEUP)
end
function c10106011.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetTargetPlayer(1-tp)
Duel.SetTargetParam(800)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,800)
end
function c10106011.damop(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Damage(p,d,REASON_EFFECT)
end
function c10106011.rmcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:GetFlagEffect(10106004)==0 end
c:RegisterFlagEffect(10106004,RESET_CHAIN,0,1)
end
function c10106011.rmcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(Card.IsSummonType,tp,0,LOCATION_MZONE,1,nil,SUMMON_TYPE_SPECIAL) and not Duel.IsExistingMatchingCard(Card.IsSummonType,tp,LOCATION_MZONE,0,1,nil,SUMMON_TYPE_SPECIAL)
end
function c10106011.rmtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,0,LOCATION_EXTRA,1,nil) and e:GetHandler():IsSummonable(true,nil) end
Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,1-tp,LOCATION_EXTRA)
Duel.SetOperationInfo(0,CATEGORY_SUMMON,e:GetHandler(),1,0,0)
end
function c10106011.rmop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local g=Duel.GetMatchingGroup(Card.IsAbleToRemove,tp,0,LOCATION_EXTRA,nil)
if g:GetCount()==0 then return end
local rg=g:RandomSelect(tp,1)
if Duel.Remove(rg,POS_FACEDOWN,REASON_EFFECT)~=0 and c:IsSummonable(true,nil) then
Duel.BreakEffect()
Duel.Summon(tp,c,true,nil)
end
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(1,0)
e1:SetReset(RESET_PHASE+PHASE_END,2)
Duel.RegisterEffect(e1,tp)
--自私之恶念体
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
local e1 = Scl.CreateFieldTriggerOptionalEffect(c, "BeSpecialSummoned",
"Equip", nil, "Equip",
"Target", "Hand,MonsterZone", s.eqcon, nil,
{ "Target", "Equip", s.eqfilter, true }, s.eqop)
local e2 = Scl.CreateEquipBuffEffect(c,
"!BeUsedAsMaterial4SpecialSummon", 1)
local e3 = Scl.CreateFieldBuffEffect(c, "!BeTributed", 1,
s.tg, {0, 1}, "Spell&TrapZone")
local e4,e5 = Scl.CreateSingleTriggerOptionalEffect(c, "BeNormalSummoned,BeAdded2Hand",
"AddFromDeck2Hand", nil, "AddFromDeck2Hand", "Delay", nil,
nil, s.thtg, s.thop)
end
function s.cfilter(c)
return c:IsFaceup() and c:IsSetCard(0x3338)
end
function s.eqcon(e,tp)
return Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_ONFIELD,0,1,e:GetHandler())
end
function s.eqfilter(c,e,tp)
return c:IsFaceup() and c:IsSummonType(SUMMON_TYPE_SPECIAL) and c:IsSummonPlayer(1-tp) and Duel.GetLocationCount(tp,LOCATION_SZONE) > 0
end
function s.egfilter(c)
return c:IsRelateToChain() and c:IsFaceup()
end
function s.eqop(e,tp,eg)
local _, tc = Scl.GetTargetsReleate2Chain(Card.IsFaceup)
local _, c = Scl.GetActivateCard()
if not tc or not c then return end
Scl.Equip(c, tc)
end
function s.tg(e,c)
local ec = e:GetHandler():GetEquipTarget()
return ec and ec == c
end
function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
local g = Duel.GetDecktopGroup(1-tp,1)
if chk == 0 then return #g > 0 and g:GetFirst():IsAbleToHand(tp) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,#g,0,0)
end
function s.thop(e,tp)
local c = e:GetHandler()
local g = Duel.GetDecktopGroup(1-tp,1)
if #g == 0 then return end
local tc = g:GetFirst()
if Duel.SendtoHand(g,tp,REASON_EFFECT) <= 0 or not tc:IsLocation(LOCATION_HAND) then return end
Scl.AddSingleBuff({c,tc},"Reveal",1)
Scl.CreateFieldTriggerContinousEffect_PhaseOpearte({c,tp},tc,"BanishFacedown",nil, nil, PHASE_END)
end
\ No newline at end of file
--异位魔的威压
function c10106012.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,0x1e0)
c:RegisterEffect(e1)
--SpecialSummon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10106012,0))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0,0x1e0)
e2:SetRange(LOCATION_SZONE)
e2:SetCountLimit(1,10106012)
e2:SetTarget(c10106012.sptg)
e2:SetOperation(c10106012.spop)
c:RegisterEffect(e2)
--tohand
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(10106012,1))
e3:SetCategory(CATEGORY_TOHAND)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_TO_HAND)
e3:SetRange(LOCATION_SZONE)
e3:SetCountLimit(1)
e3:SetCondition(c10106012.thcon)
e3:SetTarget(c10106012.thtg)
e3:SetOperation(c10106012.thop)
c:RegisterEffect(e3)
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
aux.AddCodeList(c,10106003)
local e1 = Scl.CreateActivateEffect(c)
local e2 = Scl.CreateQuickOptionalEffect(c, nil, "Look", 1,
"SpecialSummonFromHand/GY", nil, "Spell&TrapZone", nil, nil,
{ "~Target", "Dummy", aux.TRUE, 0, "Hand,GY" }, s.spop)
local e3 = Scl.CreateFieldTriggerOptionalEffect(c, "BeAdded2Hand",
"Add2Hand", 1, "Search,Add2Hand" , "Delay", "Spell&TrapZone",
nil, nil, s.thtg, s.thop)
end
function c10106012.thcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c10106012.cfilter,1,nil,tp)
function s.spfilter(c,e,tp)
return c:IsCanBeSpecialSummoned(e,0,1-tp,false,false,POS_FACEUP,1-tp) and Duel.GetLocationCount(1-tp,LOCATION_MZONE ) > 0
end
function c10106012.cfilter(c,tp)
return c:IsPreviousPosition(POS_FACEUP) and c:IsPreviousLocation(LOCATION_MZONE) and c:IsControler(tp)
end
function c10106012.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToHand,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,PLAYER_ALL,LOCATION_ONFIELD)
end
function c10106012.thop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local g=Duel.SelectMatchingCard(tp,Card.IsAbleToHand,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
if g:GetCount()>0 then
Duel.HintSelection(g)
Duel.SendtoHand(g,nil,REASON_EFFECT)
function s.spop(e,tp)
local g = Duel.GetFieldGroup(tp,0,LOCATION_HAND+LOCATION_GRAVE)
if #g == 0 then return end
Duel.ConfirmCards(tp, g)
if g:IsExists(s.spfilter,1,nil,e,tp) and Scl.SelectYesNo(tp, "SpecialSummon") then
local sg = g:FilterSelect(tp, s.spfilter, 1, 1, nil, e, tp)
Scl.HintSelection(sg)
Scl.AddSingleBuff(nil, "NegateEffect,NegateActivatedEffect", 1)
Scl.SpecialSummon(sg,0,1-tp,1-tp,false,false,POS_FACEUP)
end
end
function c10106012.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return (Duel.GetFieldGroupCount(tp,0,LOCATION_HAND)>0 or Duel.IsExistingMatchingCard(Card.IsCanBeSpecialSummoned,1-tp,0x10,0,1,nil,e,0,1-tp,false,false,POS_FACEUP,1-tp)) and Duel.GetLocationCount(1-tp,LOCATION_MZONE)>0 end
--has bug in ocgcore (find in 2018.7.12)
--Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,1-tp,LOCATION_GRAVE+LOCATION_HAND)
function s.pfilter(c,tp)
return not c:IsPublic() and c:IsControler(tp) and c:IsSetCard(0x3338) and c:IsPreviousSetCard(0x3338) and c:IsType(TYPE_MONSTER) and Scl.IsOriginalType(c, 0, "Monster") and (not c:IsReason(REASON_DRAW) or not c:IsReason(REASON_RULE)) and Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil,c:GetCode())
end
function c10106012.spop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) or Duel.GetLocationCount(1-tp,LOCATION_MZONE)<=0 then return end
local g=Duel.GetMatchingGroup(Card.IsCanBeSpecialSummoned,1-tp,0x12,0,nil,e,0,1-tp,false,false,POS_FACEUP,1-tp)
if g:GetCount()>0 then
Duel.Hint(HINT_SELECTMSG,1-tp,HINTMSG_SPSUMMON)
local sg=g:Select(1-tp,1,1,nil)
Duel.HintSelection(sg)
Duel.SpecialSummon(sg,0,1-tp,1-tp,false,false,POS_FACEUP)
function s.thfilter(c,code)
return c:IsCode(0x3338) and c:IsType(TYPE_MONSTER) and c:IsAbleToHand() and not c:IsCode(code)
end
function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk == 0 then
return e:IsCostChecked() and eg:IsExists(s.pfilter,1,nil,tp)
end
local ct,og,tc = Scl.SelectAndOperateCardsFromGroup("Reveal",eg,tp,s.pfilter,1,1,nil,tp)()
Duel.SetTargetCard(tc)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE)
end
function s.thop(e,tp)
local tc = Duel.GetFirstTarget()
Scl.SelectAndOperateCards("Add2Hand",tp,aux.NecroValleyFilter(s.thfilter),tp,"Deck,GY",0,1,1,nil,tc:GetCode())()
end
\ No newline at end of file
--异位魔的威信
function c10106013.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0x1e0)
c:RegisterEffect(e1)
--tohand
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(10106013,0))
e2:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND)
e2:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_FIELD)
e2:SetRange(LOCATION_SZONE)
e2:SetCode(EVENT_SUMMON_SUCCESS)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCountLimit(1,10106013)
e2:SetTarget(c10106013.thtg)
e2:SetOperation(c10106013.thop)
c:RegisterEffect(e2)
--tohand
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(10106013,1))
e3:SetCategory(CATEGORY_SUMMON)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_TO_HAND)
e3:SetRange(LOCATION_SZONE)
e3:SetCountLimit(1)
e3:SetCondition(c10106013.sumcon)
e3:SetTarget(c10106013.sumtg)
e3:SetOperation(c10106013.sumop)
c:RegisterEffect(e3)
end
function c10106013.sumcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c10106013.cfilter2,1,nil,tp)
end
function c10106013.cfilter2(c,tp)
return c:IsPreviousPosition(POS_FACEUP) and c:IsPreviousLocation(LOCATION_MZONE) and c:IsControler(tp)
end
function c10106013.sumtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c10106013.sumfilter,tp,LOCATION_HAND,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_SUMMON,nil,1,tp,LOCATION_HAND)
end
function c10106013.sumfilter(c)
return c:IsSetCard(0x3338) and c:IsSummonable(true,nil)
end
function c10106013.sumop(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON)
local tc=Duel.SelectMatchingCard(tp,c10106013.sumfilter,tp,LOCATION_HAND,0,1,1,nil):GetFirst()
if tc then
Duel.Summon(tp,tc,true,nil)
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
aux.AddCodeList(c,10106003)
local e1 = Scl.CreateActivateEffect(c)
local e2 = Scl.CreateQuickOptionalEffect(c, nil, "Look", 1,
"SpecialSummonFromDeck/Extra", nil, "Spell&TrapZone", nil, nil,
{ "~Target", "Dummy", aux.TRUE, 0, "Deck,Extra" }, s.spop)
local e2 = Scl.CreateQuickOptionalEffect(c, nil, "Equip", 1,
"Equip", "Target", "Spell&TrapZone", nil, nil, {
{ "Target", "Dummy", Card.IsFaceup, "MonsterZone", "MonsterZone" },
{ "~Target", "Equip", s.eqfilter, "Hand,Deck,GY" } }, s.eqop)
end
function s.spfilter(c,e,tp)
return c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP,1-tp) and Duel.GetLocationCount( 1- tp,LOCATION_MZONE ) > 0
end
function s.spop(e,tp)
local g = Duel.GetFieldGroup(tp,0,LOCATION_DECK+LOCATION_EXTRA)
if #g == 0 then return end
Duel.ConfirmCards(tp, g)
if g:IsExists(s.spfilter,1,nil,e,tp) and Scl.SelectYesNo(tp, "SpecialSummon") then
local sg = g:FilterSelect(tp, s.spfilter, 1, 1, nil, e, tp)
Scl.HintSelection(sg)
Scl.AddSingleBuff(nil, "NegateEffect,NegateActivatedEffect", 1)
Scl.SpecialSummon(sg,0,1-tp,1-tp,false,false,POS_FACEUP)
end
end
function c10106013.cfilter(c)
return c:IsSetCard(0x3338) and c:IsType(TYPE_MONSTER) and not c:IsPublic()
function s.eqfilter(c,e,tp)
return (c:GetOriginalLevel() == 1 or c:GetOriginalLevel() == 4) and c:IsSetCard(0x3338) and Scl.GetSZoneCount(tp) > 0 and not c:IsForbidden()
end
function c10106013.thfilter(c,ec)
return c:IsAbleToHand() and c:IsLevel(ec:GetLevel()) and not c:IsCode(ec:GetCode()) and c:IsSetCard(0x3338)
end
function c10106013.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
local ec=eg:GetFirst()
return eg:GetCount()==1 and ec:IsControler(tp) and ec:IsFaceup() and ec:IsSetCard(0x3338) and Duel.IsExistingMatchingCard(c10106013.thfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil,ec)
end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE)
end
function c10106013.thop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c10106013.thfilter),tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil,eg:GetFirst())
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
function s.eqop(e,tp)
local _,tc = Scl.GetTargetsReleate2Chain(Card.IsFaceup)
if not tc then return end
Scl.SelectAndOperateCards("Equip",tp,aux.NecroValleyFilter(s.eqfilter),tp,"Hand,Deck,GY",0,1,1,nil,e,tp)(tc)
end
\ No newline at end of file
--恶念聚集
if not pcall(function() require("expansions/script/c10100000") end) then require("script/c10100000") end
local s,id = GetID()
function s.initial_effect(c)
aux.AddCodeList(c,10106003)
local e1 = Scl.CreateActivateEffect(c)
local e2 = Scl.CreateIgnitionEffect(c, "Search", 1,
"AddFromDeck2Hand,NormalSummon", "Target",
"Spell&TrapZone", nil,
{ "PlayerCost", "Discard", 1},
{{ "Target", "Dummy", s.cfilter, "OnField" },
{ "~Target", "Add2Hand", Card.IsAbleToHand, "Deck,GY" }}, s.thop)
local e3 = Scl.CreateFieldTriggerContinousEffect(c, "ActivateEffect",
nil, nil, nil, "Spell&TrapZone", nil, s.lcop)
end
function s.cfilter(c,e,tp)
return Scl.IsOriginalType(c,0,TYPE_MONSTER) and c:IsSetCard(0x3338) and c:IsFaceup() and Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil,c:GetOriginalLevel())
end
function s.thfilter(c,lv)
return c:IsAbleToHand() and c:IsSetCard(0x3338) and c:IsType(TYPE_MONSTER) and c:GetOriginalLevel() ~= lv
end
function s.thop(e,tp)
local _,tc = Scl.GetTargetsReleate2Chain(Card.IsFaceup)
if not tc then return end
if Scl.SelectAndOperateCards("Add2Hand",tp,aux.NecroValleyFilter(s.thfilter),tp,"Deck,GY",0,1,1,nil,tc:GetOriginalLevel())() > 0 and Scl.IsCorrectlyOperated("Hand") then
Scl.SetExtraSelectAndOperateParama("NormalSummon", true)
Scl.SelectAndOperateCards("NormalSummon",tp,s.sumfilter,tp,"Hand,MonsterZone",0,1,1,nil)()
end
end
function s.sumfilter(c)
return c:IsSetCard(0x3338) and c:IsSummonable(true,nil)
end
function s.lcop(e,tp,eg,ep,ev,re,r,rp)
if re:GetHandler():IsSetCard(0x3338) and ep==tp then
Duel.SetChainLimit(s.chainlm)
end
end
function s.chainlm(e,rp,tp)
return tp==rp
end
\ No newline at end of file
This diff is collapsed.
--乌托兰秘境 平和海滩
local s,id = GetID()
if not pcall(function() require("expansions/script/c10122001") end) then require("script/c10122001") end
function s.initial_effect(c)
Scl_Utoland.FieldEffects(c, id, nil, nil, 1, 1, s.exop)
end
function s.exop(e,tp)
local e1 = Scl.CreatePlayerBuffEffect({e:GetHandler(),tp},"!SpecialSummon", 1, s.tg, {1,0}, nil, nil, RESETS_EP_SCL)
end
function s.tg(e,c)
return not c:IsSetCard(0xc333)
end
\ No newline at end of file
--乌托兰秘境 星辉原野
local s,id = GetID()
if not pcall(function() require("expansions/script/c10122001") end) then require("script/c10122001") end
function s.initial_effect(c)
Scl_Utoland.FieldEffects(c, id, { "PlayerCost", "Discard", 1 }, nil, 1, 2)
end
\ No newline at end of file
--空想星界 星辉沼地
local s,id = GetID()
if not pcall(function() require("expansions/script/c10122001") end) then require("script/c10122001") end
function s.initial_effect(c)
Scl_Utoland.FieldEffects(c, id, nil, s.tg, 1, 2)
end
function s.cfilter(c,tp)
return Scl_Utoland.SpecialSummonTokenAble(tp, c, 1, 2)
end
function s.tg(e,tp,eg,ep,ev,re,r,rp,chk)
local rg = Scl_Utoland.GetTributeGroup(tp)
if chk==0 then
if e:IsCostChecked() then
return rg:IsExists(s.cfilter,1,nil,tp)
else
local res = Scl_Utoland.SpecialSummonTokenAble(tp, nil, 1, 2)
return res
end
end
if e:IsCostChecked() then
Scl.SelectAndOperateCardsFromGroup("Tribute",rg,tp,aux.TRUE,1,1,nil)(REASON_COST)
end
Duel.SetOperationInfo(0,CATEGORY_TOKEN,nil,2,0,0)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,2,0,0)
end
--梦吟
local s,id = GetID()
if not pcall(function() require("expansions/script/c10122001") end) then require("script/c10122001") end
function s.initial_effect(c)
Scl.AddTokenList(c, 10122011)
local e1 = Scl.CreateActivateEffect(c, "FreeChain", "SpecialSummonToken", { 1, id }, "SpecialSummonToken", nil, nil, nil, Scl_Utoland.Token_Target(1, 1, nil, true), s.act)
local e2 = Scl.CreateFieldTriggerOptionalEffect(c, "BePlacedOnField", "Return2Hand", {1, id + 100}, "Return2Hand", "Delay", "GY", s.thcon, nil, { "~Target", "Return2Hand", Card.IsAbleToHand }, s.thop)
end
function s.act(e,tp)
local maxct = Duel.GetFieldCard(tp,LOCATION_SZONE,5) and 2 or 1
Scl_Utoland.SpecialSummonToken(e:GetHandler(), tp, 1, maxct)
end
function s.thcon(e,tp,eg)
return eg:IsExists(s.thcfilter,1,nil,tp)
end
function s.thcfilter(c,tp)
return c:IsControler(tp) and c:IsFaceup() and c:IsCode(10122011)
end
function s.thop(e,tp)
local _, c = Scl.GetActivateCard()
if c then
Scl.Send2Hand(c, nil, REASON_EFFECT, true)
end
end
\ No newline at end of file
--梦坠
local s,id = GetID()
if not pcall(function() require("expansions/script/c10122001") end) then require("script/c10122001") end
function s.initial_effect(c)
local e1 = Scl.CreateActivateEffect(c, "FreeChain", "Destroy", {1, id}, "Destroy", "Target", nil, nil, { "Target", "Destroy", {aux.TRUE, s.gcheck}, "OnField", "OnField", 1, 3 }, s.act)
local e2 = Scl.CreateFieldTriggerOptionalEffect(c, "BePlacedOnField", "Return2Hand", {1, id + 100}, "Return2Hand", "Delay", "GY", s.thcon, nil, { "~Target", "Return2Hand", Card.IsAbleToHand }, s.thop)
end
function s.cfilter(c,tp)
return c:IsFaceup() and Scl.IsOriginalType(c,0,TYPE_MONSTER) and c:IsSetCard(0xc333)
end
function s.gcheck(g,e,tp)
return g:IsExists(s.cfilter,1,nil,tp)
end
function s.act(e,tp)
local g= Scl.GetTargetsReleate2Chain()
if #g>0 then
Duel.Destroy(g,REASON_EFFECT)
end
end
function s.thcon(e,tp,eg)
return eg:IsExists(s.thcfilter,1,nil,tp)
end
function s.thcfilter(c,tp)
return c:IsControler(tp) and c:IsFaceup() and c:IsCode(10122011)
end
function s.thop(e,tp)
local _, c = Scl.GetActivateCard()
if c then
Scl.Send2Hand(c, nil, REASON_EFFECT, true)
end
end
\ No newline at end of file
--来自乌托兰秘境的守护者
local s,id = GetID()
if not pcall(function() require("expansions/script/c10122001") end) then require("script/c10122001") end
function s.initial_effect(c)
Scl_Utoland.Link(c)
local e1 = Scl_Utoland.Unaffected(c)
--local e2 = Scl.CreateFieldBuffEffect(c, "!BeBattleTarget", 1, s.tg, {"MonsterZone", 0}, "MonsterZone", Scl_Utoland.TokenCondition)
local e2 = Scl.CreateFieldBuffEffect(c, "!BeDestroyedByBattle", 1, s.tg, {"MonsterZone", 0}, "MonsterZone", Scl_Utoland.TokenCondition)
local e3 = Scl.CreatePlayerBuffEffect(c, "GainLPInsteadOfTakingDamage", s.val, nil, {1, 0}, "MonsterZone", Scl_Utoland.TokenCondition)
local e4 = Scl.CreateEffectBuffEffect(c, "!NegateActivation", s.efilter, "MonsterZone", Scl_Utoland.TokenCondition)
local e5 = Scl.CreateEffectBuffEffect(c, "!NegateActivatedEffect", s.efilter, "MonsterZone", Scl_Utoland.TokenCondition)
end
function s.tg(e,c)
return c:IsFaceup() and c:IsSetCard(0xc333)
end
function s.efilter(e,ct)
local p=e:GetHandler():GetControler()
local te,tp=Duel.GetChainInfo(ct,CHAININFO_TRIGGERING_EFFECT,CHAININFO_TRIGGERING_PLAYER)
return p==tp and te:GetHandler():IsSetCard(0xc333)
end
function s.val(e,re,r,rp,rc)
if r & REASON_BATTLE ==0 then
return false
end
local tp=e:GetHandlerPlayer()
local bc=rc:GetBattleTarget()
return bc and bc:IsSetCard(0xc333) and bc:IsControler(tp)
end
--乌托兰最深层-迷失域之主
local s,id = GetID()
if not pcall(function() require("expansions/script/c10122001") end) then require("script/c10122001") end
function s.initial_effect(c)
Scl_Utoland.Link(c)
local e1 = Scl_Utoland.Unaffected(c)
local e2 = Scl.CreateQuickOptionalEffect_NegateActivation(c, "Banish", 1, "MonsterZone", { "All", 1 }, { "Cost", "Tribute", s.tfilter, "OnField" })
end
function s.tfilter(c)
return c:IsSetCard(0xc333) and Scl.IsOriginalType(c,0,TYPE_MONSTER)
end
\ No newline at end of file
--如梦
local s,id = GetID()
if not pcall(function() require("expansions/script/c10122001") end) then require("script/c10122001") end
function s.initial_effect(c)
local e1 = Scl.CreateActivateEffect(c, "FreeChain", "ActivateSpell", nil, "ActivateSpell", nil, nil, nil, { "~Target", "ActivateSpell", s.afilter, "Hand,Deck,GY" }, s.act)
end
function s.afilter(c,e,tp)
return c:IsSetCard(0xc333) and Scl.IsType(c,0,TYPE_SPELL+TYPE_FIELD) and c:GetActivateEffect():IsActivatable(tp,true)
end
function s.act(e,tp)
Scl.SelectAndOperateCards("ActivateSpell",tp,aux.NecroValleyFilter(s.afilter),tp,"Hand,Deck,GY",0,1,1,nil,e,tp)()
end
\ No newline at end of file
--初醒
local s,id = GetID()
if not pcall(function() require("expansions/script/c10122001") end) then require("script/c10122001") end
function s.initial_effect(c)
local e1 = Scl.CreateActivateEffect(c,"FreeChain","Destroy",nil,"Destroy,Draw,BanishFacedown", nil, nil, nil, { { "~Target", "Destroy", s.dfilter, "OnField",0, true, true, c }, { "PlayerTarget", "Draw", scl.black_hole_count } }, s.act)
end
function s.act(e,tp)
local g = Duel.GetMatchingGroup(s.dfilter,tp,LOCATION_ONFIELD,0,aux.ExceptThisCard(e))
if #g == 0 then return end
local ct = Duel.Destroy(g,REASON_EFFECT)
if ct == 0 then return end
local rg = Duel.GetMatchingGroup(Card.IsAbleToRemove,tp,0,LOCATION_ONFIELD+LOCATION_GRAVE,nil,tp,POS_FACEDOWN)
if Duel.Draw(tp,ct,REASON_EFFECT) > 0 and ct >= 8 and #rg > 0 and Scl.SelectYesNo(tp, "BanishFacedown") then
Duel.BreakEffect()
Duel.Remove(rg,POS_FACEDOWN,REASON_EFFECT)
end
end
\ No newline at end of file
--侵入乌托兰梦境的梦魇魔
local s,id = GetID()
if not pcall(function() require("expansions/script/c10122001") end) then require("script/c10122001") end
function s.initial_effect(c)
Scl_Utoland.Link(c)
local e1 = Scl.CreatePlayerBuffEffect(c, id, 1, nil, { 1, 0 }, "MonsterZone")
end
\ No newline at end of file
--乌托兰深层 灼炎地狱
local s,id = GetID()
if not pcall(function() require("expansions/script/c10122001") end) then require("script/c10122001") end
function s.initial_effect(c)
Scl_Utoland.DeepFieldEffects(c, id, "BeNormal/SpecialSummoned", s.con)
end
function s.cfilter(c,tp)
return c:GetSummonPlayer()~=tp
end
function s.con(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(s.cfilter,1,nil,tp)
end
--乌托兰深层 迷失雨林
local s,id = GetID()
if not pcall(function() require("expansions/script/c10122001") end) then require("script/c10122001") end
function s.initial_effect(c)
Scl_Utoland.DeepFieldEffects(c, id, "BeAdded2Hand", s.con)
end
function s.cfilter(c,tp)
return c:IsControler(1-tp)
end
function s.con(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(s.cfilter,1,nil,tp) and Duel.GetCurrentPhase() ~= PHASE_DRAW
end
--乌托兰深层 死域之海
local s,id = GetID()
if not pcall(function() require("expansions/script/c10122001") end) then require("script/c10122001") end
function s.initial_effect(c)
Scl_Utoland.DeepFieldEffects(c, id, "DeclareAttack", s.con, 1, 2)
end
function s.con(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetAttacker():IsControler(1-tp)
end
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment