Commit 7f406f12 authored by POLYMER's avatar POLYMER

fix

parent 7aec3078
No preview for this file type
...@@ -38,10 +38,10 @@ function cm.initial_effect(c) ...@@ -38,10 +38,10 @@ function cm.initial_effect(c)
local _GetType=Effect.GetType local _GetType=Effect.GetType
local _IsHasType=Effect.IsHasType local _IsHasType=Effect.IsHasType
function Effect.GetType(e) function Effect.GetType(e)
if e:GetDescription()==aux.Stringid(m,0) then return EFFECT_TYPE_ACTIVATE else return _GetType(e) end if e:GetDescription()==aux.Stringid(m,0) then return 26 else return _GetType(e) end
end end
function Effect.IsHasType(e,typ) function Effect.IsHasType(e,typ)
if e:GetDescription()==aux.Stringid(m,0) then return EFFECT_TYPE_ACTIVATE&typ>0 else return _IsHasType(e,typ) end if e:GetDescription()==aux.Stringid(m,0) then return 26&typ>0 else return _IsHasType(e,typ) end
end end
function Effect.GetActiveType(e) function Effect.GetActiveType(e)
if e:GetDescription()==aux.Stringid(m,0) then if e:GetDescription()==aux.Stringid(m,0) then
......
...@@ -158,14 +158,15 @@ function cm.reop(e,tp,eg,ep,ev,re,r,rp) ...@@ -158,14 +158,15 @@ function cm.reop(e,tp,eg,ep,ev,re,r,rp)
end end
function cm.efilter(e,te) function cm.efilter(e,te)
if e:GetHandler():GetFlagEffect(m+0xffffff)>0 and te and te:GetHandler() and not te:IsHasProperty(EFFECT_FLAG_UNCOPYABLE) and te:IsHasType(EFFECT_TYPE_ACTIONS) then if e:GetHandler():GetFlagEffect(m+0xffffff)>0 and te and te:GetHandler() and not te:IsHasProperty(EFFECT_FLAG_UNCOPYABLE) and te:IsHasType(EFFECT_TYPE_ACTIONS) then
if 0==1 then if KOISHI_CHECK then
Duel.DisableActionCheck(true) Duel.DisableActionCheck(true)
pcall(Duel.HintSelection,Group.FromCards(e:GetHandler())) pcall(Duel.HintSelection,Group.FromCards(e:GetHandler()))
local tc=te:GetHandler() local tc=te:GetHandler()
local e1=Effect.CreateEffect(tc) local e1=Effect.CreateEffect(tc)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(m) e1:SetCode(m)
e1:SetOperation(function() pcall(Duel.Draw,te:GetHandlerPlayer(),1,REASON_EFFECT) e1:Reset() end) e1:SetLabel(te:GetOwnerPlayer())
e1:SetOperation(function(e) pcall(Duel.Draw,e:GetLabel(),1,REASON_EFFECT) e:Reset() end)
Duel.RegisterEffect(e1,0) Duel.RegisterEffect(e1,0)
pcall(Duel.RaiseEvent,tc,m,e,0,0,0,0) pcall(Duel.RaiseEvent,tc,m,e,0,0,0,0)
e1:Reset() e1:Reset()
...@@ -175,7 +176,7 @@ function cm.efilter(e,te) ...@@ -175,7 +176,7 @@ function cm.efilter(e,te)
e5:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e5:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e5:SetCode(EVENT_ADJUST) e5:SetCode(EVENT_ADJUST)
e5:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE) e5:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE)
e5:SetLabel(te:GetHandlerPlayer()) e5:SetLabel(te:GetOwnerPlayer())
e5:SetCondition(function() return not pnfl_adjusting end) e5:SetCondition(function() return not pnfl_adjusting end)
e5:SetOperation(cm.acop) e5:SetOperation(cm.acop)
Duel.RegisterEffect(e5,tp) Duel.RegisterEffect(e5,tp)
......
...@@ -74,12 +74,12 @@ function cm.chcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -74,12 +74,12 @@ function cm.chcon(e,tp,eg,ep,ev,re,r,rp)
return rc:IsSetCard(0x836) return rc:IsSetCard(0x836)
end end
function cm.thfilter(c) function cm.thfilter(c)
return c:IsSetCard(0x836) and c:IsType(TYPE_QUICKPLAY) and c:IsSSetable() return c:IsSetCard(0x836) and c:IsType(TYPE_SPELL) and c:IsSSetable()
end end
function cm.chtg(e,tp,eg,ep,ev,re,r,rp,chk) function cm.chtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then if chk==0 then
if rp==tp then return Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_DECK,0,1,nil) if rp==tp then return Duel.IsExistingMatchingCard(cm.thfilter,tp,LOCATION_DECK,0,1,nil)
else return Duel.IsExistingMatchingCard(nil,tp,0,LOCATION_DECK,1,nil) end else return Duel.IsExistingMatchingCard(nil,tp,0,LOCATION_DECK,1,nil) and Duel.IsPlayerCanSSet(1-tp) end
end end
end end
function cm.chop(e,tp,eg,ep,ev,re,r,rp) function cm.chop(e,tp,eg,ep,ev,re,r,rp)
......
--七仟陌
function c71000100.initial_effect(c)
c:EnableReviveLimit()
-- spsummon condition
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetValue(c71000100.splimit)
c:RegisterEffect(e1)
-- cannot releaase
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetRange(LOCATION_MZONE)
e2:SetCode(EFFECT_UNRELEASABLE_SUM)
e2:SetValue(1)
c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetCode(EFFECT_UNRELEASABLE_NONSUM)
c:RegisterEffect(e3)
local e4=e2:Clone()
e4:SetCode(EFFECT_UNRELEASABLE_EFFECT)
c:RegisterEffect(e4)
local e5=e2:Clone()
e5:SetCode(EFFECT_CANNOT_BE_FUSION_MATERIAL)
c:RegisterEffect(e5)
local e6=e2:Clone()
e6:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
c:RegisterEffect(e6)
local e7=e2:Clone()
e7:SetCode(EFFECT_CANNOT_BE_SYNCHRO_MATERIAL)
c:RegisterEffect(e7)
local e8=e2:Clone()
e8:SetCode(EFFECT_CANNOT_BE_XYZ_MATERIAL)
c:RegisterEffect(e8)
--atk,def
local e9=Effect.CreateEffect(c)
e9:SetType(EFFECT_TYPE_SINGLE)
e9:SetCode(EFFECT_UPDATE_ATTACK)
e9:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e9:SetRange(LOCATION_MZONE)
e9:SetValue(c71000100.val)
c:RegisterEffect(e9)
local e10=e9:Clone()
e10:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e10)
--
local e22=Effect.CreateEffect(c)
e22:SetCategory(CATEGORY_TODECK)
e22:SetType(EFFECT_TYPE_QUICK_O)
e22:SetRange(LOCATION_MZONE)
e22:SetCode(EVENT_FREE_CHAIN)
e22:SetHintTiming(0,TIMING_END_PHASE)
e22:SetCountLimit(1)
e22:SetCost(c71000100.cost)
e22:SetTarget(c71000100.tg)
e22:SetOperation(c71000100.op)
c:RegisterEffect(e22)
--
--local e21=Effect.CreateEffect(c)
--e21:SetType(EFFECT_TYPE_SINGLE)
--e21:SetCode(EFFECT_IMMUNE_EFFECT)
--e21:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
--e21:SetRange(LOCATION_MZONE)
--e21:SetCondition(c71000100.econ)
--e21:SetValue(c71000100.efilter)
--c:RegisterEffect(e21)
end
function c71000100.splimit(e,se,sp,st)
return se:GetHandler():IsCode(71000101,71000102)
end
function c71000100.val(e,c)
return c:GetOverlayCount()*300
end
function c71000100.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:CheckRemoveOverlayCard(tp,1,REASON_COST) end
local rt=Duel.GetFieldGroupCount(tp,LOCATION_GRAVE+LOCATION_ONFIELD+LOCATION_REMOVED,0)
local ct=c:RemoveOverlayCard(tp,1,rt,REASON_COST)
e:SetLabel(ct)
end
function c71000100.tg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingMatchingCard(aux.TRUE,tp,LOCATION_GRAVE+LOCATION_ONFIELD+LOCATION_REMOVED,0,1,nil) end
local g=Duel.GetMatchingGroup(aux.TRUE,tp,LOCATION_GRAVE+LOCATION_ONFIELD+LOCATION_REMOVED,0,1,nil)
Duel.SetOperationInfo(0,CATEGORY_TODECK,g,e:GetLabel(),0,0)
end
function c71000100.stfilter(c)
return c:IsSetCard(0xe73) and c:IsSSetable()
end
function c71000100.op(e,tp,eg,ep,ev,re,r,rp)
local ct=e:GetLabel()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,aux.TRUE,tp,LOCATION_GRAVE+LOCATION_ONFIELD+LOCATION_REMOVED,0,1,ct,nil)
if g:GetCount()>0 then
Duel.HintSelection(g)
Duel.SendtoDeck(g,nil,CATEGORY_TODECK,REASON_EFFECT)
local st=Duel.GetMatchingGroup(c71000100.stfilter,tp,LOCATION_DECK,0,nil)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(71000100,0)) then
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local sg=st:Select(tp,1,1,nil)
Duel.SSet(tp,sg)
end
end
end
--function c71000100.econ(e)
--return e:GetHandler():GetOverlayGroup():IsExists(Card.IsCode,1,nil,71000117)
--end
--function c71000100.efilter(e,te)
--return te:IsActiveType(TYPE_MONSTER) and te:GetOwnerPlayer()~=e:GetHandlerPlayer()
--end
\ No newline at end of file
--不知从何时开始
local s,id=GetID()
function s.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetCondition(s.condition)
e1:SetTarget(s.tg)
e1:SetOperation(s.op)
c:RegisterEffect(e1)
end
function s.cfilter(c)
return c:IsSummonType(SUMMON_TYPE_SPECIAL)
end
function s.condition(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_MZONE,0,1,nil)
end
function s.spfilter(c,e,tp)
return c:IsSetCard(0xe73) and c:IsCanBeSpecialSummoned(e,0,tp,true,false) and Duel.GetLocationCountFromEx(tp,tp,nil,c,0x60)>0 and c:IsType(TYPE_XYZ)
end
function s.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_EXTRA,0,1,nil,e,tp) end
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function s.op(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_EXTRA,0,1,1,nil,e,tp)
local sc=g:GetFirst()
if g:GetCount()>0 and c:IsRelateToEffect(e) and c:IsCanOverlay() and sc then
Duel.SpecialSummon(g,0,tp,tp,true,false,POS_FACEUP,0x60)
c:CancelToGrave()
Duel.Overlay(sc,Group.FromCards(c))
end
aux.LabrynthDestroyOp(e,tp,res)
if e:IsHasType(EFFECT_TYPE_ACTIVATE) then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SUMMON)
e1:SetTargetRange(1,0)
e1:SetTarget(s.aclimit)
Duel.RegisterEffect(e1,tp)
local e2=e1:Clone()
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
Duel.RegisterEffect(e2,tp)
end
end
function s.aclimit(e,c)
return not c:IsSetCard(0xe73)
end
--and c:IsLocation(LOCATION_DECK+LOCATION_HAND+LOCATION_REMOVED+LOCATION_GRAVE+LOCATION_EXTRA)
--不知该何时结束
local s,id=GetID()
function s.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetCondition(s.condition)
e1:SetTarget(s.tg)
e1:SetOperation(s.op)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_TRAP_ACT_IN_HAND)
e2:SetCondition(s.c)
c:RegisterEffect(e2)
end
function s.cfilter(c)
return c:IsSummonType(SUMMON_TYPE_SPECIAL)
end
function s.condition(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_MZONE,0,1,nil)
end
function s.f(c,e,tp)
return c:IsSetCard(0xe73) and c:IsCanBeSpecialSummoned(e,0,tp,true,false) and Duel.GetLocationCountFromEx(tp,tp,nil,c,0x60)>0 and c:IsType(TYPE_XYZ)
end
function s.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.f,tp,LOCATION_EXTRA,0,1,nil,e,tp) end
Duel.Hint(HINT_OPSELECTED,1-tp,e:GetDescription())
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
function s.op(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,s.f,tp,LOCATION_EXTRA,0,1,1,nil,e,tp)
local sc=g:GetFirst()
if g:GetCount()>0 and c:IsRelateToEffect(e) and c:IsCanOverlay() and sc then
Duel.SpecialSummon(g,0,tp,tp,true,false,POS_FACEUP,0x60)
c:CancelToGrave()
Duel.Overlay(sc,Group.FromCards(c))
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetTargetRange(1,0)
e1:SetTarget(s.a)
Duel.RegisterEffect(e1,tp)
local e2=e1:Clone()
e2:SetCode(EFFECT_CANNOT_SUMMON)
Duel.RegisterEffect(e2,tp)
end
end
function s.a(e,c)
return not c:IsSetCard(0xe73)
end
function s.c(e)
local tp=e:GetHandlerPlayer()
return Duel.GetFieldGroupCount(tp,LOCATION_ONFIELD,0)==0
end
\ No newline at end of file
--许下永恒的誓言
function c71000103.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetOperation(c71000103.op)
c:RegisterEffect(e1)
--
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_ONFIELD+LOCATION_GRAVE+LOCATION_REMOVED)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCountLimit(2,71000103)
e2:SetTarget(c71000103.xtg)
e2:SetOperation(c71000103.xop)
c:RegisterEffect(e2)
--
end
function c71000103.f(c)
return c:IsCode(71000101,71000102) and c:IsAbleToHand()
end
function c71000103.op(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c71000103.f,tp,LOCATION_DECK,0,nil)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(71000103,0)) then
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
end
function c71000103.xf(c)
return c:IsFaceup() and c:IsType(TYPE_XYZ) and c:IsCode(71000100)
end
function c71000103.xtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler()
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c71000103.xf(chkc) and chkc:IsControler(tp) and chkc~=c end
if chk==0 then return Duel.IsExistingTarget(c71000103.xf,tp,LOCATION_MZONE,0,1,c) and c:IsCanOverlay() end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,c71000103.xf,tp,LOCATION_MZONE,0,1,1,c)
end
function c71000103.xop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and not tc:IsImmuneToEffect(e) and c:IsCanOverlay() then
local mg=c:GetOverlayGroup()
if mg:GetCount()>0 then Duel.Overlay(tc,mg,false) end
Duel.Overlay(tc,Group.FromCards(c))
end
end
--初见之地
function c71000104.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetOperation(c71000104.op)
c:RegisterEffect(e1)
--
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e2:SetRange(LOCATION_FZONE)
e2:SetCondition(c71000104.con)
e2:SetValue(aux.indoval)
c:RegisterEffect(e2)
--
--local e4=Effect.CreateEffect(c)
--e4:SetCode(EVENT_TO_DECK)
--e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
--e4:SetRange(LOCATION_FZONE)
--e4:SetCondition(c71000104.damcon)
--e4:SetOperation(c71000104.damop)
--c:RegisterEffect(e4)
--
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_PIERCE)
e3:SetRange(LOCATION_SZONE)
e3:SetTargetRange(LOCATION_MZONE,0)
e3:SetTarget(aux.TargetBoolFunction(Card.IsCode,71000100))
c:RegisterEffect(e3)
end
function c71000104.filter(c)
return c:IsCode(71000101,71000102) and c:IsAbleToHand()
end
function c71000104.ab(e,c)
return c:IsCode(71000100)
end
function c71000104.op(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c71000104.filter,tp,LOCATION_DECK,0,nil)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(71000104,0)) then
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
end
--function c71000104.xf(c,tp)
--return c:GetOwner()
--end
--function c71000104.operation(e,tp,eg,ep,ev,re,r,rp)
--local d1=eg:FilterCount(c71000104.xf,nil,tp)*300
--Duel.Damage(1-tp,d1,REASON_EFFECT,true)
--Duel.Recover(tp,d1,REASON_EFFECT,true)
--Duel.RDComplete()
--end
--function c71000104.damcon(e,tp,eg,ep,ev,re,r,rp)
--return eg:IsExists(Card.IsPreviousLocation,1,nil,LOCATION_ONFIELD+LOCATION_GRAVE+LOCATION_REMOVED)
--end
--function c71000104.damop(e,tp,eg,ep,ev,re,r,rp)
--local ct=eg:FilterCount(Card.IsPreviousLocation,nil,LOCATION_ONFIELD+LOCATION_GRAVE+LOCATION_REMOVED)
--if ct>0 then
--Duel.Damage(1-tp,ct*300,REASON_EFFECT)
--Duel.Recover(tp,ct*300,REASON_EFFECT)
--end
--end
function c71000104.confilter(c)
return c:IsFaceup() and c:IsSetCard(0xe73) and c:GetOriginalType()&TYPE_MONSTER~=0
end
function c71000104.con(e)
local tp=e:GetHandlerPlayer()
return Duel.IsExistingMatchingCard(c71000104.confilter,tp,LOCATION_ONFIELD,0,1,nil)
end
\ No newline at end of file
-- 七仟陌支援
-- 卡片ID:
local s,id=GetID()
function s.initial_effect(c)
-- 发动条件检查
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetTarget(s.target)
e1:SetCondition(s.condition)
e1:SetOperation(s.activate)
e1:SetCountLimit(1,71000106)
c:RegisterEffect(e1)
end
-- 发动条件:存在「七仟陌」
function s.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(s.xyzfilter,tp,LOCATION_MZONE,0,1,nil)
end
-- 超量怪兽过滤器
function s.xyzfilter(c)
return c:IsFaceup() and c:IsCode(71000100) and c:IsType(TYPE_XYZ)
end
function s.tgfilter(c)
return (c:IsLocation(LOCATION_GRAVE) or c:IsLocation(LOCATION_REMOVED))
and not c:IsType(TYPE_TOKEN)
end
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.tgfilter,tp,LOCATION_GRAVE+LOCATION_REMOVED,LOCATION_GRAVE+LOCATION_REMOVED,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,nil,1,tp,LOCATION_GRAVE+LOCATION_REMOVED)
end
-- 效果处理(操作阶段选择)
function s.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
-- 选择超量怪兽
local xyzg=Duel.GetMatchingGroup(s.xyzfilter,tp,LOCATION_MZONE,0,nil)
if #xyzg==0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local xyzc=xyzg:Select(tp,1,1,nil):GetFirst()
if not xyzc then return end
-- 选择场上的卡
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
local g=Duel.SelectMatchingCard(tp,Card.IsCanBeOverlay,tp,LOCATION_GRAVE+LOCATION_REMOVED,LOCATION_GRAVE+LOCATION_REMOVED,1,1,nil)
local tc=g:GetFirst()
if tc and xyzc:IsType(TYPE_XYZ) then
-- 作为超量素材附加
Duel.Overlay(xyzc,Group.FromCards(tc))
-- 获取原始代码
local code=tc:GetOriginalCodeRule()
-- 效果无效化处理
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_DISABLE)
e1:SetTargetRange(LOCATION_ONFIELD,LOCATION_ONFIELD)
e1:SetTarget(s.distg)
e1:SetLabel(code)
e1:SetReset(RESET_PHASE+PHASE_END,1)
Duel.RegisterEffect(e1,tp)
-- 连锁无效处理
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_CHAIN_SOLVING)
e2:SetCondition(s.discon)
e2:SetOperation(s.disop)
e2:SetLabel(code)
e2:SetReset(RESET_PHASE+PHASE_END,1)
Duel.RegisterEffect(e2,tp)
end
end
-- 无效化过滤器
function s.distg(e,c)
return c:IsOriginalCodeRule(e:GetLabel())
end
-- 连锁无效条件
function s.discon(e,tp,eg,ep,ev,re,r,rp)
return re:GetHandler():IsOriginalCodeRule(e:GetLabel())
end
-- 连锁无效操作
function s.disop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateEffect(ev)
end
-- 七仟陌支援
-- 卡片ID:
local s,id=GetID()
function s.initial_effect(c)
-- 发动条件检查
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,id)
e1:SetCondition(s.condition)
e1:SetOperation(s.activate)
c:RegisterEffect(e1)
end
-- 发动条件:存在「七仟陌」
function s.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(s.xyzfilter,tp,LOCATION_MZONE,0,1,nil)
end
-- 超量怪兽过滤器
function s.xyzfilter(c)
return c:IsFaceup() and c:IsCode(71000100) and c:IsType(TYPE_XYZ)
end
-- 效果处理(操作阶段选择)
function s.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
-- 选择超量怪兽
local xyzg=Duel.GetMatchingGroup(s.xyzfilter,tp,LOCATION_MZONE,0,nil)
if #xyzg==0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local xyzc=xyzg:Select(tp,1,1,nil):GetFirst()
if not xyzc then return end
-- 选择场上的卡
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
local g=Duel.SelectMatchingCard(tp,Card.IsCanBeOverlay,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,xyzc)
local tc=g:GetFirst()
if tc and xyzc:IsType(TYPE_XYZ) then
-- 作为超量素材附加
tc:CancelToGrave()
local og=tc:GetOverlayGroup()
if og:GetCount()>0 then
Duel.SendtoGrave(og,REASON_RULE)
end
Duel.Overlay(xyzc,Group.FromCards(tc))
-- 获取原始代码
--local code=tc:GetOriginalCodeRule()
-- 效果无效化处理
--local e1=Effect.CreateEffect(c)
--e1:SetType(EFFECT_TYPE_FIELD)
--e1:SetCode(EFFECT_DISABLE)
--e1:SetTargetRange(LOCATION_ONFIELD,LOCATION_ONFIELD)
--e1:SetTarget(s.distg)
--e1:SetLabel(code)
--e1:SetReset(RESET_PHASE+PHASE_END,1)
--Duel.RegisterEffect(e1,tp)
-- 连锁无效处理
--local e2=Effect.CreateEffect(c)
--e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
--e2:SetCode(EVENT_CHAIN_SOLVING)
--e2:SetCondition(s.discon)
--e2:SetOperation(s.disop)
--e2:SetLabel(code)
--e2:SetReset(RESET_PHASE+PHASE_END,1)
--Duel.RegisterEffect(e2,tp)
end
end
-- 无效化过滤器
function s.distg(e,c)
return c:IsOriginalCodeRule(e:GetLabel())
end
-- 连锁无效条件
function s.discon(e,tp,eg,ep,ev,re,r,rp)
return re:GetHandler():IsOriginalCodeRule(e:GetLabel())
end
-- 连锁无效操作
function s.disop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateEffect(ev)
end
\ No newline at end of file
--一曲镇魂
function c71000108.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_CHAINING)
e1:SetCategory(CATEGORY_NEGATE)
e1:SetCountLimit(1,71000108)
e1:SetCondition(c71000108.con)
e1:SetTarget(c71000108.tg)
e1:SetOperation(c71000108.op)
c:RegisterEffect(e1)
end
function c71000108.f(c)
return c:IsFaceup() and c:IsCode(71000100) and c:IsType(TYPE_XYZ)
end
function c71000108.f2(c)
return c:IsFaceup() and c:IsCode(71000100) and c:IsType(TYPE_XYZ) and not c:IsStatus(STATUS_BATTLE_DESTROYED)
end
function c71000108.con(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c71000108.f,tp,LOCATION_MZONE,0,1,nil)
and re:IsActiveType(TYPE_MONSTER)
and Duel.IsChainNegatable(ev)
end
function c71000108.tg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
end
function c71000108.op(e,tp,eg,ep,ev,re,r,rp)
local rc=re:GetHandler()
if Duel.NegateActivation(ev) and rc:IsRelateToEffect(re) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local g=Duel.SelectMatchingCard(tp,c71000108.f2,tp,LOCATION_MZONE,0,1,1,nil)
if g:GetCount()>0 and not g:GetFirst():IsImmuneToEffect(e) and rc:IsCanOverlay() then
rc:CancelToGrave()
Duel.Overlay(g:GetFirst(),Group.FromCards(rc))
end
end
end
\ No newline at end of file
--尽在掌握
function c71000109.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_CHAINING)
e1:SetCategory(CATEGORY_NEGATE)
e1:SetCountLimit(1,71000109)
e1:SetCondition(c71000109.con)
e1:SetTarget(c71000109.tg)
e1:SetOperation(c71000109.op)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_TRAP_ACT_IN_HAND)
c:RegisterEffect(e2)
end
function c71000109.f(c)
return c:IsFaceup() and c:IsCode(71000100) and c:IsType(TYPE_XYZ)
end
function c71000109.f2(c)
return c:IsFaceup() and c:IsCode(71000100) and c:IsType(TYPE_XYZ) and not c:IsStatus(STATUS_BATTLE_DESTROYED)
end
function c71000109.con(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c71000109.f,tp,LOCATION_MZONE,0,1,nil)
and re:IsActiveType(TYPE_TRAP)
and Duel.IsChainNegatable(ev)
end
function c71000109.tg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
end
function c71000109.op(e,tp,eg,ep,ev,re,r,rp)
local rc=re:GetHandler()
if Duel.NegateActivation(ev) and rc:IsRelateToEffect(re) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local g=Duel.SelectMatchingCard(tp,c71000109.f2,tp,LOCATION_MZONE,0,1,1,nil)
if g:GetCount()>0 and not g:GetFirst():IsImmuneToEffect(e) and rc:IsCanOverlay() then
rc:CancelToGrave()
Duel.Overlay(g:GetFirst(),Group.FromCards(rc))
end
end
end
--魔归于无
function c71000110.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_CHAINING)
e1:SetCategory(CATEGORY_NEGATE)
e1:SetCountLimit(1,71000110)
e1:SetCondition(c71000110.con)
e1:SetTarget(c71000110.tg)
e1:SetOperation(c71000110.op)
c:RegisterEffect(e1)
end
function c71000110.f(c)
return c:IsFaceup() and c:IsCode(71000100) and c:IsType(TYPE_XYZ)
end
function c71000110.f2(c)
return c:IsFaceup() and c:IsCode(71000100) and c:IsType(TYPE_XYZ) and not c:IsStatus(STATUS_BATTLE_DESTROYED)
end
function c71000110.con(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c71000110.f,tp,LOCATION_MZONE,0,1,nil)
and re:IsActiveType(TYPE_SPELL)
and Duel.IsChainNegatable(ev)
end
function c71000110.tg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
end
function c71000110.op(e,tp,eg,ep,ev,re,r,rp)
local rc=re:GetHandler()
if Duel.NegateActivation(ev) and rc:IsRelateToEffect(re) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local g=Duel.SelectMatchingCard(tp,c71000110.f2,tp,LOCATION_MZONE,0,1,1,nil)
if g:GetCount()>0 and not g:GetFirst():IsImmuneToEffect(e) and rc:IsCanOverlay() then
rc:CancelToGrave()
Duel.Overlay(g:GetFirst(),Group.FromCards(rc))
end
end
end
\ No newline at end of file
--最后的伙伴
function c71000111.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetCountLimit(2,71000111)
e1:SetTarget(c71000111.tg)
e1:SetOperation(c71000111.op)
c:RegisterEffect(e1)
--
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_GRAVE+LOCATION_REMOVED)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCountLimit(2,71000111)
e2:SetTarget(c71000111.xtg)
e2:SetOperation(c71000111.xop)
c:RegisterEffect(e2)
end
function c71000111.f(c)
return c:IsType(TYPE_MONSTER) and c:IsAbleToHand() and c:IsSetCard(0xe73)
end
function c71000111.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c71000111.f,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function c71000111.op(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c71000111.f,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 c71000111.xf(c)
return c:IsFaceup() and c:IsType(TYPE_XYZ) and c:IsCode(71000100)
end
function c71000111.xtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler()
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c71000111.xf(chkc) and chkc:IsControler(tp) and chkc~=c end
if chk==0 then return Duel.IsExistingTarget(c71000111.xf,tp,LOCATION_MZONE,0,1,c) and c:IsCanOverlay() end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SetOperationInfo(tp,c71000111.xf,tp,LOCATION_MZONE,0,1,1,c)
end
function c71000111.xop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
-- local tc=Duel.GetFirstTarget()
local g=Duel.SelectMatchingCard(tp,c71000111.xf,tp,LOCATION_ONFIELD,0,1,1,nil)
local tc=g:GetFirst()
if c:IsRelateToEffect(e) then --and not tc:IsImmuneToEffect(e) and tc:IsCanOverlay()
local mg=c:GetOverlayGroup()
if mg:GetCount()>0 then Duel.Overlay(tc,mg,false) end
Duel.Overlay(tc,Group.FromCards(c))
end
end
\ No newline at end of file
--默然然
function c71000112.initial_effect(c)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(71000112,0))
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SUMMON_SUCCESS)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e1:SetCountLimit(3,71000112)
e1:SetTarget(c71000112.tg)
e1:SetOperation(c71000112.op)
c:RegisterEffect(e1)
--
local e2=Effect.CreateEffect(c)
e2:SetCode(EVENT_REMOVE)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetCategory(CATEGORY_TOHAND)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCountLimit(3,71000112)
e2:SetTarget(c71000112.xtg)
e2:SetOperation(c71000112.xop)
c:RegisterEffect(e2)
end
function c71000112.f(c)
return c:IsAbleToHand() and c:IsSetCard(0xe73)
end
function c71000112.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c71000112.f,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
end
function c71000112.op(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c71000112.f,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 c71000112.xtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToHand() end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,e:GetHandler(),1,0,0)
end
function c71000112.xop(e,tp,eg,ep,ev,re,r,rp)
if e:GetHandler():IsRelateToEffect(e) then
Duel.SendtoHand(e:GetHandler(),nil,REASON_EFFECT)
Duel.Recover(tp,700,REASON_EFFECT)
Duel.Damage(1-tp,300,REASON_EFFECT)
end
end
\ No newline at end of file
local s, id = GetID()
function s.initial_effect(c)
-- 效果①:除外盖卡
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,0))
e1:SetCategory(CATEGORY_REMOVE)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMING_DRAW_PHASE+TIMING_END_PHASE)
e1:SetRange(LOCATION_HAND+LOCATION_MZONE)
e1:SetCountLimit(2,id)
e1:SetCost(s.excost1)
e1:SetTarget(s.extg)
e1:SetOperation(s.exop)
c:RegisterEffect(e1)
--效果②:回收与LP操作
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(id,1))
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_RECOVER)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0)
e2:SetRange(LOCATION_GRAVE+LOCATION_REMOVED)
e2:SetCountLimit(2,id)
e2:SetCost(s.excost2)
e2:SetTarget(s.rectg)
e2:SetOperation(s.recop)
c:RegisterEffect(e2)
end
--===== 效果①处理 =====--
function s.excost1_filter(c)
return c:IsAbleToRemove() and (c:IsLocation(LOCATION_HAND) or c:IsLocation(LOCATION_ONFIELD)) and c:IsSetCard(0xe73)
end
function s.excost1(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then
return Duel.IsExistingMatchingCard(s.excost1_filter,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,c)
and c:IsAbleToRemove()
end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,s.excost1_filter,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,1,c)
g:AddCard(c)
Duel.Remove(g,POS_FACEUP,REASON_COST)
e:SetLabel(g:FilterCount(Card.IsSetCard,nil,0xe73))
end
function s.filter(c)
return c:IsSetCard(0xe73) and c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsSSetable()
end
function s.extg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.filter,tp,LOCATION_DECK,0,1,nil) end
end
function s.exop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local g=Duel.SelectMatchingCard(tp,s.filter,tp,LOCATION_DECK,0,1,1,nil)
local c=e:GetHandler()
if #g>0 then
local tc=Duel.SSet(tp,g:GetFirst())
Duel.Recover(tp,700,REASON_EFFECT)
Duel.Damage(1-tp,300,REASON_EFFECT)
-- 如果除外了七仟陌卡则允许当回合发动
if e:GetLabel()>0 then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_QP_ACT_IN_SET_TURN)
e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EFFECT_TRAP_ACT_IN_SET_TURN)
c:RegisterEffect(e2)
end
end
end
--===== 效果②处理 =====--
function s.excost2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,e:GetHandler()) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,Card.IsAbleToRemove,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,1,e:GetHandler())
Duel.Remove(g,POS_FACEUP,REASON_COST)
e:SetLabel(g:GetFirst():IsSetCard(0xe73) and 1 or 0)
end
function s.rectg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToHand() end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,e:GetHandler(),1,0,0)
-- Duel.SetPossibleOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,700)
end
function s.recop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsRelateToEffect(e) and Duel.SendtoHand(c,nil,REASON_EFFECT)>0 then
if e:GetLabel()>0 then
Duel.Recover(tp,700,REASON_EFFECT)
Duel.Damage(1-tp,300,REASON_EFFECT)
end
end
end
\ No newline at end of file
local s, id = GetID()
function s.initial_effect(c)
-- 效果①
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,0))
e1:SetCategory(CATEGORY_REMOVE)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMING_DRAW_PHASE+TIMING_END_PHASE)
e1:SetRange(LOCATION_HAND+LOCATION_GRAVE)
e1:SetCountLimit(2,id)
e1:SetCost(s.excost1)
e1:SetOperation(s.exop)
c:RegisterEffect(e1)
--效果②
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetRange(LOCATION_REMOVED)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetCountLimit(2,71000114)
e2:SetTarget(c71000114.xtg)
e2:SetOperation(c71000114.xop)
c:RegisterEffect(e2)
--get effect
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(id,1))
e3:SetType(EFFECT_TYPE_XMATERIAL)
e3:SetCode(EFFECT_UPDATE_ATTACK)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e3:SetRange(LOCATION_MZONE)
e3:SetCondition(s.xcon)
e3:SetValue(s.xval)
c:RegisterEffect(e3)
local e4=e3:Clone()
e4:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e4)
--local e5=e3:Clone()
--e5:SetCode(EFFECT_INDESTRUCTABLE_BATTLE)
--c:RegisterEffect(e5)
--local e6=e3:Clone()
--e6:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
--c:RegisterEffect(e6)
end
--===== 效果①处理 =====--
function s.excost1_filter(c)
return c:IsAbleToRemove() and (c:IsLocation(LOCATION_HAND) or c:IsLocation(LOCATION_EXTRA)) and c:IsSetCard(0xe73)
end
function s.excost1(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then
return Duel.IsExistingMatchingCard(s.excost1_filter,tp,LOCATION_HAND+LOCATION_EXTRA+LOCATION_GRAVE,0,1,c)
and c:IsAbleToRemove()
end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,s.excost1_filter,tp,LOCATION_HAND+LOCATION_EXTRA+LOCATION_GRAVE,0,1,1,c)
g:AddCard(c)
Duel.Remove(g,POS_FACEUP,REASON_COST)
end
function s.filter(c)
return c:IsSetCard(0xe73) and c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsSSetable()
end
function s.exop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetDescription(aux.Stringid(71000114,2))
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_TRAP_ACT_IN_SET_TURN)
e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE)
e1:SetTargetRange(LOCATION_SZONE,0)
e1:SetCountLimit(1)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
local e3=e1:Clone()
e3:SetCode(EFFECT_QP_ACT_IN_SET_TURN)
Duel.RegisterEffect(e3,tp)
end
--===== 效果②处理 =====--
function c71000114.xf(c)
return c:IsFaceup() and c:IsType(TYPE_XYZ) and c:IsCode(71000100)
end
function c71000114.xtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler()
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c71000114.xf(chkc) and chkc:IsControler(tp) and chkc~=c end
if chk==0 then return Duel.IsExistingTarget(c71000114.xf,tp,LOCATION_MZONE,0,1,c) and c:IsCanOverlay() end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,c71000114.xf,tp,LOCATION_MZONE,0,1,1,c)
end
function c71000114.xop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and not tc:IsImmuneToEffect(e) and c:IsCanOverlay() then
local mg=c:GetOverlayGroup()
if mg:GetCount()>0 then Duel.Overlay(tc,mg,false) end
Duel.Overlay(tc,Group.FromCards(c))
end
end
--
function s.xcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsSetCard(0xe73)
end
function s.xval(e,c)
return e:GetHandler():GetOverlayCount()*300
end
local s, id = GetID()
function s.initial_effect(c)
c:EnableReviveLimit()
aux.AddLinkProcedure(c,c71000117.mfilter,1,1)
--效果②
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetRange(LOCATION_REMOVED+LOCATION_GRAVE)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetCountLimit(2,71000117)
e2:SetTarget(c71000117.xtg)
e2:SetOperation(c71000117.xop)
c:RegisterEffect(e2)
--get effect
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(id,1))
e3:SetType(EFFECT_TYPE_XMATERIAL)
e3:SetCode(EFFECT_UPDATE_ATTACK)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e3:SetRange(LOCATION_MZONE)
e3:SetCondition(s.xcon)
e3:SetValue(s.xval)
c:RegisterEffect(e3)
local e4=e3:Clone()
e4:SetCode(EFFECT_UPDATE_DEFENSE)
c:RegisterEffect(e4)
local e6=e3:Clone()
e6:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
c:RegisterEffect(e6)
local e5=e3:Clone()
e5:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET)
e5:SetValue(aux.tgoval)
c:RegisterEffect(e5)
end
--===== 效果①处理 =====--
function c71000117.mfilter(c)
return c:IsLinkSetCard(0xe73)
end
--===== 效果②处理 =====--
function c71000117.xf(c)
return c:IsFaceup() and c:IsType(TYPE_XYZ) and c:IsCode(71000100)
end
function c71000117.xtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler()
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c71000117.xf(chkc) and chkc:IsControler(tp) and chkc~=c end
if chk==0 then return Duel.IsExistingTarget(c71000117.xf,tp,LOCATION_MZONE,0,1,c) and c:IsCanOverlay() end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,c71000117.xf,tp,LOCATION_MZONE,0,1,1,c)
end
function c71000117.xop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and not tc:IsImmuneToEffect(e) and c:IsCanOverlay() then
local mg=c:GetOverlayGroup()
if mg:GetCount()>0 then Duel.Overlay(tc,mg,false) end
Duel.Overlay(tc,Group.FromCards(c))
end
end
--
function s.xcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsSetCard(0xe73)
end
function s.xval(e,c)
return e:GetHandler():GetOverlayCount()*100
end
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