Commit 6a9da8e8 authored by Chen Bill's avatar Chen Bill

fix 魂喰いオヴィラプター

parent b59675d8
...@@ -47,19 +47,19 @@ function c44335251.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -47,19 +47,19 @@ function c44335251.operation(e,tp,eg,ep,ev,re,r,rp)
end end
end end
end end
function c44335251.desfilter(c) function c44335251.desfilter(c,tp)
return c:IsFaceup() and c:IsLevelBelow(4) and c:IsRace(RACE_DINOSAUR) return c:IsFaceup() and c:IsLevelBelow(4) and c:IsRace(RACE_DINOSAUR) and Duel.GetMZoneCount(tp,c,tp)>0
end end
function c44335251.spfilter(c,e,tp) function c44335251.spfilter(c,e,tp)
return c:IsRace(RACE_DINOSAUR) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE) return c:IsRace(RACE_DINOSAUR) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE)
end end
function c44335251.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c44335251.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler() local c=e:GetHandler()
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c44335251.desfilter(chkc) and chkc~=c end if chkc then return chkc:IsLocation(LOCATION_MZONE) and c44335251.desfilter(chkc,tp) and chkc~=c end
if chk==0 then return Duel.IsExistingTarget(c44335251.desfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,c) if chk==0 then return Duel.IsExistingTarget(c44335251.desfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,c,tp)
and Duel.IsExistingMatchingCard(c44335251.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end and Duel.IsExistingMatchingCard(c44335251.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(tp,c44335251.desfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,c) local g=Duel.SelectTarget(tp,c44335251.desfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,c,tp)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE)
end 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