Commit 4f8eeb89 authored by 2924713558's avatar 2924713558 Committed by GitHub

Update c1197119.lua

parent 3f20313e
......@@ -15,6 +15,7 @@ function c1197119.initial_effect(c)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,m)
e1:SetCost(cm.cost1)
e1:SetTarget(cm.tg1)
e1:SetOperation(cm.op1)
c:RegisterEffect(e1)
......@@ -27,7 +28,6 @@ function c1197119.initial_effect(c)
e2:SetCode(EVENT_TO_HAND)
e2:SetCountLimit(1,m+100)
e2:SetCondition(cm.con2)
e2:SetCost(cm.cost2)
e2:SetTarget(cm.tg2)
e2:SetOperation(cm.op2)
c:RegisterEffect(e2)
......@@ -43,6 +43,17 @@ function c1197119.initial_effect(c)
]]--
end
--
function cm.cfilter1(c)
return c:IsAbleToRemoveAsCost() and c:IsRace(RACE_SEASERPENT)
end
function cm.cost1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cfilter1,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local sg=Duel.SelectMatchingCard(tp,cm.cfilter1,tp,LOCATION_GRAVE,0,1,1,nil)
if sg:GetCount()<1 then return end
Duel.Remove(sg,POS_FACEUP,REASON_COST)
end
--
function cm.tfilter1(c)
return c:IsLinkSummonable(nil) and c:IsSetCard(0xe10)
end
......@@ -62,17 +73,6 @@ function cm.con2(e,tp,eg,ep,ev,re,r,rp)
return not e:GetHandler():IsReason(REASON_DRAW)
end
--
function cm.cfilter2(c)
return c:IsAbleToRemoveAsCost() and c:IsRace(RACE_SEASERPENT)
end
function cm.cost2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.cfilter2,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local sg=Duel.SelectMatchingCard(tp,cm.cfilter2,tp,LOCATION_GRAVE,0,1,1,nil)
if sg:GetCount()<1 then return end
Duel.Remove(sg,POS_FACEUP,REASON_COST)
end
--
function cm.tg2(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
......
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