Commit 5b7d0e55 authored by wind2009's avatar wind2009

Fix 血樹竜姫ドラセレア

parent f418f525
Pipeline #42135 passed with stages
in 1 minute and 41 seconds
No preview for this file type
......@@ -11,6 +11,7 @@
101304016
101304022
101304023
101304027
101304030
101304031
101304033
......
......@@ -26,7 +26,7 @@ function s.initial_effect(c)
Duel.AddCustomActivityCounter(id,ACTIVITY_SPSUMMON,s.counterfilter)
end
function s.counterfilter(c)
return c:IsRace(RACE_DRAGON+RACE_PLANT)
return c:IsRace(RACE_DRAGON+RACE_PLANT) and c:IsFaceup()
end
function s.thfilter(c)
return not c:IsCode(id) and c:IsRace(RACE_PLANT) and c:IsLevelBelow(4) and c:IsAbleToGraveAsCost()
......@@ -66,15 +66,18 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
c:RegisterEffect(e1)
end
end
function s.cfilter(c,e,tp)
function s.cfilter(c,e,tp,ec)
return c:IsRace(RACE_PLANT) and c:IsAbleToRemoveAsCost()
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND+LOCATION_GRAVE,0,1,c,e,tp)
and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND+LOCATION_GRAVE,0,1,Group.FromCards(c,ec),e,tp)
end
function s.spcost2(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return Duel.GetCustomActivityCount(id,tp,ACTIVITY_SPSUMMON)==0
and Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
and c:IsAbleToRemoveAsCost()
and Duel.IsExistingMatchingCard(s.cfilter,tp,LOCATION_GRAVE,0,1,c,e,tp,c) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,s.cfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
local g=Duel.SelectMatchingCard(tp,s.cfilter,tp,LOCATION_GRAVE,0,1,1,c,e,tp,c)
g:AddCard(c)
Duel.Remove(g,POS_FACEUP,REASON_COST)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
......@@ -100,4 +103,4 @@ function s.spop2(e,tp,eg,ep,ev,re,r,rp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
\ No newline at end of file
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