--.LiveVTuber Nekonoki Mochi function c33701107.initial_effect(c) --xyz summon aux.AddXyzProcedure(c,nil,8,3) c:EnableReviveLimit() --extra material local e2=Effect.CreateEffect(c) e2:SetDescription(aux.Stringid(33701107,0)) e2:SetType(EFFECT_TYPE_FIELD) e2:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_IGNORE_IMMUNE) e2:SetCode(EFFECT_SPSUMMON_PROC) e2:SetRange(LOCATION_EXTRA) e2:SetLabelObject(c) e2:SetCondition(c33701107.xyzcon) e2:SetOperation(c33701107.xyzop) e2:SetValue(SUMMON_TYPE_XYZ) local e3=Effect.CreateEffect(c) e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_GRANT) e3:SetRange(LOCATION_MZONE) e3:SetTargetRange(LOCATION_EXTRA,0) e3:SetTarget(c33701107.mattg) e3:SetLabelObject(e2) c:RegisterEffect(e3) --effect gian local e5=Effect.CreateEffect(c) e5:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e5:SetCode(EVENT_ADJUST) e5:SetRange(LOCATION_MZONE) e5:SetOperation(c33701107.efop) c:RegisterEffect(e5) -- local e3=Effect.CreateEffect(c) e3:SetType(EFFECT_TYPE_IGNITION) e3:SetRange(LOCATION_MZONE) e3:SetCode(EVENT_FREE_CHAIN) e3:SetCost(c33701107.ovcost) e3:SetTarget(c33701107.ovtg) e3:SetOperation(c33701107.ovop) c:RegisterEffect(e3) end function c33701107.mattg(e,c) return c:IsSetCard(0x1445) and c:IsType(TYPE_XYZ) and c:IsRank(9,7) end function c33701107.xyzcon(e,c,og,lmat,min,max) if c==nil then return true end local tp=c:GetControler() local xc=e:GetLabelObject() return Duel.GetLocationCountFromEx(tp,tp,xc,e:GetHandler())>0 and xc:IsCanBeXyzMaterial(nil) end function c33701107.xyzop(e,tp,eg,ep,ev,re,r,rp,c,og,lmat,min,max) local xc=e:GetLabelObject() local mg=xc:GetOverlayGroup() if mg:GetCount()~=0 then Duel.Overlay(e:GetHandler(),mg) end e:GetHandler():SetMaterial(Group.FromCards(xc)) Duel.Overlay(e:GetHandler(),Group.FromCards(xc)) -- local e3=Effect.CreateEffect(c) e3:SetType(EFFECT_TYPE_FIELD) e3:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e3:SetReset(RESET_PHASE+PHASE_END) e3:SetTargetRange(1,0) e3:SetTarget(c33701107.splimit) Duel.RegisterEffect(e3,tp) end function c33701107.splimit(e,c,tp,sumtp,sumpos) return bit.band(sumtp,SUMMON_TYPE_XYZ)==SUMMON_TYPE_XYZ end function c33701107.effilter(c) return c:IsSetCard(0x44f) end function c33701107.efop(e,tp,eg,ep,ev,re,r,rp) local c=e:GetHandler() local ct=c:GetOverlayGroup(tp,1,0) local wg=ct:Filter(c33701107.effilter,nil,tp) local wbc=wg:GetFirst() while wbc do local code=wbc:GetOriginalCode() if c:IsFaceup() and c:GetFlagEffect(code)==0 then c:CopyEffect(code,RESET_EVENT+0x1fe0000+EVENT_CHAINING,1) c:RegisterFlagEffect(code,RESET_EVENT+0x1fe0000+EVENT_CHAINING,0,1) end wbc=wg:GetNext() end end function c33701107.ovcost(e,tp,eg,ep,ev,re,r,rp,chk,chkc) if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST) end function c33701107.ovfil(c) return c:IsCanOverlay() and c:IsSetCard(0x44f) end function c33701107.ovtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) if chk==0 then return Duel.IsExistingMatchingCard(c33701107.ovfil,tp,LOCATION_DECK,0,1,nil) and not e:GetHandler():GetOverlayGroup():IsExists(Card.IsSetCard,1,nil,0x44f) end local g=Duel.SelectMatchingCard(tp,c33701107.ovfil,tp,LOCATION_DECK,0,1,1,nil) Duel.SetTargetCard(g) end function c33701107.ovop(e,tp,eg,ep,ev,re,r,rp) local tc=Duel.GetFirstTarget() Duel.Overlay(e:GetHandler(),tc) end