Commit 5473afba authored by mercury233's avatar mercury233 Committed by GitHub

fix Release Restraint Wave (#854)

parent b40b922e
...@@ -25,10 +25,13 @@ function c34022290.spcon(e,c) ...@@ -25,10 +25,13 @@ function c34022290.spcon(e,c)
return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0 return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0
and not Duel.IsExistingMatchingCard(Card.IsType,c:GetControler(),LOCATION_GRAVE,0,1,nil,TYPE_MONSTER) and not Duel.IsExistingMatchingCard(Card.IsType,c:GetControler(),LOCATION_GRAVE,0,1,nil,TYPE_MONSTER)
end end
function c34022290.cfilter(c)
return c:IsType(TYPE_SPELL) and c:IsAbleToGraveAsCost()
end
function c34022290.rmcost(e,tp,eg,ep,ev,re,r,rp,chk) function c34022290.rmcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():GetEquipGroup():IsExists(Card.IsAbleToGraveAsCost,1,nil) end if chk==0 then return e:GetHandler():GetEquipGroup():IsExists(c34022290.cfilter,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=e:GetHandler():GetEquipGroup():FilterSelect(tp,Card.IsAbleToGraveAsCost,1,1,nil) local g=e:GetHandler():GetEquipGroup():FilterSelect(tp,c34022290.cfilter,1,1,nil)
Duel.SendtoGrave(g,REASON_COST) Duel.SendtoGrave(g,REASON_COST)
end end
function c34022290.rmfilter(c) function c34022290.rmfilter(c)
......
...@@ -12,6 +12,7 @@ function c98847704.initial_effect(c) ...@@ -12,6 +12,7 @@ function c98847704.initial_effect(c)
end end
function c98847704.filter1(c) function c98847704.filter1(c)
return c:IsFaceup() and c:IsType(TYPE_EQUIP) return c:IsFaceup() and c:IsType(TYPE_EQUIP)
and (not c:IsType(TYPE_TRAP) or c:IsPreviousLocation(LOCATION_MZONE))
end end
function c98847704.filter2(c) function c98847704.filter2(c)
return c:IsFacedown() return c:IsFacedown()
......
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