Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --Dragon Piper
- --COPYRIGHT by YAMI AN
- function c999999995.initial_effect(c)
- --Activate
- local e1=Effect.CreateEffect(c)
- e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
- e1:SetType(EFFECT_TYPE_IGNITION)
- e1:SetRange(LOCATION_MZONE)
- e1:SetCountLimit(1)
- e1:SetCondition(c999999995.condition)
- e1:SetTarget(c999999995.target)
- e1:SetOperation(c999999995.activate)
- c:RegisterEffect(e1)
- end
- function c999999995.cfilter(c)
- return c:IsFaceup() and c:IsCode(50045299)
- end
- function c999999995.spfilter(c,e,tp)
- return c:IsRace(RACE_DRAGON) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
- end
- function c999999995.condition(e,tp,eg,ep,ev,re,r,rp)
- return Duel.IsExistingMatchingCard(c999999995.cfilter,tp,LOCATION_SZONE,0,1,nil)
- end
- function c999999995.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
- if chk==0 then
- return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingTarget(c999999995.spfilter,tp,0,LOCATION_REMOVED,1,nil,e,tp)
- end
- Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
- local g=Duel.SelectTarget(tp,c999999995.spfilter,tp,0,LOCATION_REMOVED,1,1,nil,e,tp)
- Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
- end
- function c999999995.activate(e,tp,eg,ep,ev,re,r,rp)
- local tc=Duel.GetFirstTarget()
- if tc:IsRelateToEffect(e) then
- Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement