Commit d9b8c8db authored by POLYMER's avatar POLYMER

fix

parent 885eca2f
No preview for this file type
--「02退出了观战」
if not pcall(function() require("expansions/script/c10199990") end) then require("script/c10199990") end
local m=65010007
local cm=_G["c"..m]
cm.card_code_list={65010001}
function cm.initial_effect(c)
local e1=rsef.ACT(c,nil,nil,{1,m,1})
local e2=rsef.QO(c,nil,nil,1,"eq",{"tg",EFFECT_FLAG_NO_TURN_RESET },LOCATION_SZONE,nil,nil,rstg.target(rscf.FilterFaceUp(Card.IsCode,65010001),"eq",LOCATION_MZONE),cm.op)
end
function cm.op(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsLocation(LOCATION_SZONE) then return end
if not c:IsRelateToEffect(e) or c:IsStatus(STATUS_LEAVE_CONFIRMED) then return end
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsFaceup() then
Duel.Equip(tp,c,tc)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_EQUIP_LIMIT)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(cm.eqlimit)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetRange(LOCATION_SZONE)
e2:SetCode(EFFECT_CANNOT_ACTIVATE)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetReset(RESET_EVENT+RESETS_STANDARD)
e2:SetTargetRange(1,1)
e2:SetValue(cm.aclimit)
c:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetCode(EFFECT_INDESTRUCTABLE_COUNT)
e3:SetRange(LOCATION_SZONE)
e3:SetTargetRange(LOCATION_ONFIELD,0)
e3:SetReset(RESET_EVENT+RESETS_STANDARD)
e3:SetTarget(cm.indtg)
e3:SetCountLimit(1)
e3:SetValue(cm.valcon)
c:RegisterEffect(e3)
else
c:CancelToGrave(false)
end
end
function cm.valcon(e,re,r,rp)
return r&REASON_EFFECT ~=0
end
function cm.indtg(e,c)
return c:IsFaceup() and c:IsType(TYPE_SPELL+TYPE_TRAP)
end
function cm.aclimit(e,re,tp)
local c=e:GetHandler()
local rc=re:GetHandler()
local ec=c:GetEquipTarget()
if not ec then return false end
local atk=ec:GetAttack()
return re:IsActiveType(TYPE_MONSTER) and not rc:IsImmuneToEffect(e) and rc:IsLocation(LOCATION_GRAVE+LOCATION_MZONE) and rc:IsAttackBelow(atk)
end
function cm.eqlimit(e,c)
return c:GetControler()==e:GetHandlerPlayer() and c:IsCode(65010001)
end
\ No newline at end of file
--窥屏02
if not pcall(function() require("expansions/script/c10199990") end) then require("script/c10199990") end
local m=65010013
local cm=_G["c"..m]
cm.card_code_list={65010001}
function cm.initial_effect(c)
local e1=rsef.QO(c,EVENT_CHAINING,{m,0},{1,m},"neg","dsp,dcal",LOCATION_HAND,rscon.negcon(cm.filterfun,true),rscost.cost(Card.IsDiscardable,"dish"),cm.tg,cm.op)
--special summon
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetDescription(aux.Stringid(m,0))
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_GRAVE+LOCATION_MZONE)
e2:SetCountLimit(1,m+100)
e2:SetCost(aux.bfgcost)
e2:SetTarget(cm.sptg)
e2:SetOperation(cm.spop)
c:RegisterEffect(e2)
end
function cm.filterfun(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(rscf.FilterFaceUp(Card.IsCode,65010001),tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsChainNegatable(ev)
end
function cm.spfilter(c,e,tp)
return c:IsCode(65010001) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function cm.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_HAND+LOCATION_DECK,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_DECK)
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.spfilter),tp,LOCATION_HAND+LOCATION_DECK,0,1,1,nil,e,tp)
if #g>0 and Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)~=0 then
local e1=rsef.SV_LIMIT({e:GetHandler(),g:GetFirst()},"atk",nil,nil,rsreset.est_pend)
end
end
function cm.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,0,0)
end
function cm.op(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateActivation(ev)
end
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment