--Invocyte Warrior local m=888120 local cm=_G["c"..m] function cm.initial_effect(c) --spsummon local e1=Effect.CreateEffect(c) e1:SetDescription(aux.Stringid(m,0)) e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) e1:SetType(EFFECT_TYPE_TRIGGER_O+EFFECT_TYPE_SINGLE) e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetTarget(cm.tg) e1:SetCountLimit(1,880120) e1:SetOperation(cm.op) c:RegisterEffect(e1) local e2=e1:Clone() e2:SetCode(EVENT_SPSUMMON_SUCCESS) c:RegisterEffect(e2) local e3=aux.AddRitualProcEqual2(c,cm.Ritfilter,nil,nil,cm.mfilter) e3:SetDescription(aux.Stringid(m,1)) e3:SetType(EFFECT_TYPE_QUICK_O) e3:SetCode(EVENT_FREE_CHAIN) e3:SetCountLimit(1,881120) e3:SetRange(LOCATION_MZONE+LOCATION_HAND) --e3:SetCost(cm.cost) c:RegisterEffect(e3) end function cm.Ritfilter(c) return c:IsSetCard(0xff8) end function cm.mfilter(c,e,tp) return c:IsType(TYPE_MONSTER) end function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk) if chk==0 then return e:GetHandler():IsReleasable() end Duel.Release(e:GetHandler(),REASON_COST) end function cm.filter(c) return c:IsType(TYPE_RITUAL) and c:IsAbleToHand() and c:IsSetCard(0xff8) end function cm.tg(e,tp,eg,ep,ev,re,r,rp,chk) if chk==0 then return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_DECK,0,1,nil) end Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) end function cm.op(e,tp,eg,ep,ev,re,r,rp) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) local g=Duel.SelectMatchingCard(tp,cm.filter,tp,LOCATION_DECK,0,1,1,nil) if g:GetCount()>0 then Duel.SendtoHand(g,nil,REASON_EFFECT) Duel.ConfirmCards(1-tp,g) end end