--Skeleton Soldier local s,id=GetID() function s.initial_effect(c) --If NS/SS, banish and mill local e1=Effect.CreateEffect(c) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetProperty(EFFECT_FLAG_DELAY) e1:HOPT() e1:SetCost(s.bmcost) e1:SetTarget(s.bmtg) e1:SetOperation(s.bmop) c:RegisterEffect(e1) local e2=e1:Clone() e2:SetCode(EVENT_SPSUMMON_SUCCESS) c:RegisterEffect(e2) --If in your GY while you have Zombie Boss, banish and add local e3=Effect.CreateEffect(c) e3:SetType(EFFECT_TYPE_IGNITION) e3:SetRange(LOCATION_GRAVE) e3:SetProperty(EFFECT_FLAG_CARD_TARGET) e3:HOPT() e3:SetCost(s.stcost) e3:SetTarget(s.sttg) e3:SetOperation(s.stop) c:RegisterEffect(e3) end --e1/e2 group function s.costfilter(c) return c:IsRace(RACE_ZOMBIE) and c:IsAbleToRemoveAsCost() and not c:IsCode(id) end function s.bmcost(e,tp,eg,ep,ev,re,r,rp,chk) if chk==0 then return Duel.IsExistingMatchingCard(s.costfilter,tp,LOCATION_GRAVE,0,1,nil) end Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) local g=Duel.SelectMatchingCard(tp,s.costfilter,tp,LOCATION_GRAVE,0,1,1,nil) Duel.Remove(g,POS_FACEUP,REASON_COST) end function s.bmtg(e,tp,eg,ep,ev,re,r,rp,chk) if chk==0 then return Duel.IsPlayerCanDiscardDeck(tp,3) end Duel.SetOperationInfo(0,CATEGORY_DECKDES,nil,0,tp,3) end function s.bmop(e,tp,eg,ep,ev,re,r,rp) Duel.DiscardDeck(tp,3,REASON_EFFECT) end --e3 group function s.bossfilter(c) return c:IsFaceup() and c:IsRace(RACE_ZOMBIE) and c:IsType(TYPE_RITUAL) or (c:IsFaceup() and c:IsRace(RACE_ZOMBIE) and c:IsPreviousLocation(LOCATION_EXTRA)) end function s.targetfilter(c) return c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsAbleToHand() end function s.stcost(e,tp,eg,ep,ev,re,r,rp,chk) if chk==0 then return e:GetHandler():IsAbleToRemoveAsCost() and Duel.IsExistingMatchingCard(s.costfilter,tp,LOCATION_GRAVE,0,1,e:GetHandler()) end Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) local rg=Duel.SelectMatchingCard(tp,s.costfilter,tp,LOCATION_GRAVE,0,1,1,e:GetHandler()) rg:AddCard(e:GetHandler()) Duel.Remove(rg,POS_FACEUP,REASON_COST) end function s.sttg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.targetfilter(chkc) end if chk==0 then return Duel.IsExistingTarget(s.targetfilter,tp,LOCATION_GRAVE,0,1,nil) end Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) local g=Duel.SelectTarget(tp,s.targetfilter,tp,LOCATION_GRAVE,0,1,1,nil) Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0) end function s.stop(e,tp,eg,ep,ev,re,r,rp) local tc=Duel.GetFirstTarget() if tc:IsRelateToEffect(e) then Duel.SendtoHand(tc,nil,REASON_EFFECT) end end