Commit 48ac7eb7 authored by wind2009's avatar wind2009

Fix K9-66b号 ランタン

parent 605b361c
No preview for this file type
...@@ -10,16 +10,16 @@ function s.initial_effect(c) ...@@ -10,16 +10,16 @@ function s.initial_effect(c)
e1:SetCondition(s.ntcon) e1:SetCondition(s.ntcon)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--spsummon --spsummon
local e1=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,1)) e2:SetDescription(aux.Stringid(id,1))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_IGNITION)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET) e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetRange(LOCATION_HAND) e2:SetRange(LOCATION_HAND)
e1:SetCountLimit(1,id) e2:SetCountLimit(1,id)
e1:SetTarget(s.sptg) e2:SetTarget(s.sptg)
e1:SetOperation(s.spop) e2:SetOperation(s.spop)
c:RegisterEffect(e1) c:RegisterEffect(e2)
--tohand --tohand
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(id,2)) e3:SetDescription(aux.Stringid(id,2))
...@@ -37,7 +37,7 @@ function s.ntcon(e,c,minc) ...@@ -37,7 +37,7 @@ function s.ntcon(e,c,minc)
and Duel.IsExistingMatchingCard(aux.TRUE,c:GetControler(),0,LOCATION_HAND,2,nil) and Duel.IsExistingMatchingCard(aux.TRUE,c:GetControler(),0,LOCATION_HAND,2,nil)
end end
function s.spfilter(c,e,tp) function s.spfilter(c,e,tp)
return c:IsSetCard(0x2cb) and c:IsLevel(5) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsSetCard(0x2cb) and c:IsLevel(5) and not c:IsRace(RACE_PYRO) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler() local c=e:GetHandler()
...@@ -54,28 +54,29 @@ end ...@@ -54,28 +54,29 @@ end
function s.spop(e,tp,eg,ep,ev,re,r,rp) function s.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and tc:IsCanBeSpecialSummoned(e,0,tp,false,false) if c:IsRelateToChain() and tc:IsRelateToChain() and aux.NecroValleyFilter()(tc)
and not Duel.IsPlayerAffectedByEffect(tp,s) and Duel.GetLocationCount(tp,LOCATION_MZONE)>1 then and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and tc:IsCanBeSpecialSummoned(e,0,tp,false,false)
and not Duel.IsPlayerAffectedByEffect(tp,59822133) and Duel.GetLocationCount(tp,LOCATION_MZONE)>1 then
local g=Group.FromCards(c,tc) local g=Group.FromCards(c,tc)
if Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)~=0 then if Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)~=0 then
for tc in aux.Next(g) do for sc in aux.Next(g) do
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CANNOT_BE_XYZ_MATERIAL) e1:SetCode(EFFECT_CANNOT_BE_XYZ_MATERIAL)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetValue(s.xyzlimit) e1:SetValue(s.xyzlimit)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1,true) sc:RegisterEffect(e1,true)
sc:RegisterFlagEffect(id,RESET_EVENT+RESETS_STANDARD,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(id,3))
end end
end end
end end
end end
function s.xyzlimit(e,c) function s.xyzlimit(e,c)
if not c then return false end return c and c:IsAttribute(ATTRIBUTE_LIGHT)
return c:IsAttribute(ATTRIBUTE_LIGHT)
end end
function s.thfilter(c) function s.thfilter(c)
return c:IsSetCard(0x2cb) and c:IsType(TYPE_SPELL+TYPE_TRAP) and not c:IsRace(RACE_AQUA) and c:IsAbleToHand() return c:IsSetCard(0x2cb) and c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsAbleToHand()
end end
function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) 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