Commit 2f943b70 authored by mercury233's avatar mercury233

fix Fabled monsters

parent 391ef4f8
......@@ -23,7 +23,7 @@ function c24040093.cost(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SendtoGrave(e:GetHandler(),REASON_COST)
end
function c24040093.filter(c)
return c:IsSetCard(0x35) and c:GetCode()~=24040093 and c:IsAbleToHand()
return c:IsSetCard(0x35) and c:IsType(TYPE_MONSTER) and c:GetCode()~=24040093 and c:IsAbleToHand()
end
function c24040093.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c24040093.filter,tp,LOCATION_DECK,0,1,nil) end
......
......@@ -14,7 +14,7 @@ function c26704411.initial_effect(c)
c:RegisterEffect(e1)
end
function c26704411.costfilter(c)
return c:IsSetCard(0x35) and c:IsDiscardable()
return c:IsSetCard(0x35) and c:IsType(TYPE_MONSTER) and c:IsDiscardable()
end
function c26704411.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c26704411.costfilter,tp,LOCATION_HAND,0,1,nil) end
......
......@@ -10,15 +10,18 @@ function c29905795.initial_effect(c)
e1:SetOperation(c29905795.op)
c:RegisterEffect(e1)
end
function c29905795.filter(c)
return c:IsSetCard(0x35) and c:IsType(TYPE_MONSTER)
end
function c29905795.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(Card.IsSetCard,tp,LOCATION_HAND,0,1,e:GetHandler(),0x35)
and Duel.IsExistingMatchingCard(c29905795.filter,tp,LOCATION_HAND,0,1,e:GetHandler())
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false)
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end
function c29905795.op(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(Card.IsSetCard,tp,LOCATION_HAND,0,nil,0x35)
local g=Duel.GetMatchingGroup(c29905795.filter,tp,LOCATION_HAND,0,nil)
if g:GetCount()==0 then return end
if g:GetCount()==1 then
Duel.SendtoGrave(g,REASON_EFFECT+REASON_DISCARD)
......
......@@ -17,7 +17,7 @@ function c46833854.con(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFieldGroupCount(tp,0,LOCATION_HAND)-Duel.GetFieldGroupCount(tp,LOCATION_HAND,0)>=2
end
function c46833854.cfilter(c)
return c:IsSetCard(0x35) and not c:IsPublic()
return c:IsSetCard(0x35) and c:IsType(TYPE_MONSTER) and not c:IsPublic()
end
function c46833854.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsReleasable()
......
......@@ -20,15 +20,18 @@ function c55277252.initial_effect(c)
e2:SetOperation(c55277252.op2)
c:RegisterEffect(e2)
end
function c55277252.filter(c)
return c:IsSetCard(0x35) and c:IsType(TYPE_MONSTER)
end
function c55277252.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(Card.IsSetCard,tp,LOCATION_HAND,0,1,e:GetHandler(),0x35)
and Duel.IsExistingMatchingCard(c55277252.filter,tp,LOCATION_HAND,0,1,e:GetHandler())
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false)
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end
function c55277252.op(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(Card.IsSetCard,tp,LOCATION_HAND,0,nil,0x35)
local g=Duel.GetMatchingGroup(c55277252.filter,tp,LOCATION_HAND,0,nil)
if g:GetCount()==0 then return end
if g:GetCount()==1 then
Duel.SendtoGrave(g,REASON_EFFECT+REASON_DISCARD)
......
......@@ -10,7 +10,7 @@ function c94845226.initial_effect(c)
c:RegisterEffect(e1)
end
function c94845226.cfilter(c)
return c:IsSetCard(0x35) and c:IsDiscardable()
return c:IsSetCard(0x35) and c:IsType(TYPE_MONSTER) and c:IsDiscardable()
end
function c94845226.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c94845226.cfilter,tp,LOCATION_HAND,0,1,nil) end
......
......@@ -12,7 +12,7 @@ function c97439806.initial_effect(c)
c:RegisterEffect(e1)
end
function c97439806.costfilter(c)
return c:IsSetCard(0x35) and c:GetCode()~=97439806 and c:IsDiscardable()
return c:IsSetCard(0x35) and c:IsType(TYPE_MONSTER) and c:GetCode()~=97439806 and c:IsDiscardable()
end
function c97439806.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c97439806.costfilter,tp,LOCATION_HAND,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