Commit 9dcbc4a3 authored by nanahira's avatar nanahira

missings

parent e42e2871
...@@ -2601,3 +2601,31 @@ function cm.GetPZoneCount(tp,g) ...@@ -2601,3 +2601,31 @@ function cm.GetPZoneCount(tp,g)
end end
return res return res
end end
function cm.HelltakerFilter(c)
return c:GetBaseAttack()==1700 and c:GetBaseDefense()==1400 and c:IsRace(RACE_FIEND) and c:IsType(TYPE_MONSTER)
end
function cm.HelltakerCommonEffect(c)
local e4=Effect.CreateEffect(c)
e4:SetDescription(aux.Stringid(35952884,1))
e4:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_SINGLE)
e4:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e4:SetCategory(CATEGORY_SPECIAL_SUMMON)
e4:SetCode(EVENT_LEAVE_FIELD)
e4:SetCondition(function(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD)
end)
e4:SetTarget(function(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,LOCATION_DECK,0,1,nil,tp,POS_FACEDOWN) end
Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_DECK)
end)
e4:SetOperation(function(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,Card.IsAbleToRemove,tp,LOCATION_DECK,0,1,1,nil,tp,POS_FACEDOWN)
local tc=g:GetFirst()
if tc then
Duel.Remove(tc,POS_FACEDOWN,REASON_EFFECT)
end
end)
c:RegisterEffect(e4)
return e4
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