--Miku local ref=_G['c'..28916164] local id=28916164 function ref.initial_effect(c) --Burn local e1=Effect.CreateEffect(c) e1:SetDescription(aux.Stringid(id,0)) e1:SetCategory(CATEGORY_POSITION+CATEGORY_DAMAGE) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP) e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCountLimit(1,id) e1:SetCondition(ref.damcon) e1:SetTarget(ref.damtg) e1:SetOperation(ref.damop) c:RegisterEffect(e1) --Position local e2=Effect.CreateEffect(c) e2:SetCategory(CATEGORY_POSITION) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e2:SetCode(EVENT_SUMMON_SUCCESS) e2:SetProperty(EFFECT_FLAG_CARD_TARGET) e2:SetRange(LOCATION_MZONE) e2:SetCountLimit(1,EFFECT_COUNT_CODE_SINGLE) e2:SetCondition(ref.poscon) e2:SetTarget(ref.postg) e2:SetOperation(ref.posop) c:RegisterEffect(e2) local e3=e2:Clone() e3:SetCode(EVENT_SPSUMMON_SUCCESS) c:RegisterEffect(e3) local e4=e2:Clone() e4:SetCode(EVENT_FLIP_SUMMON_SUCCESS) c:RegisterEffect(e4) end --Burn function ref.damcon(e,tp,eg,ep,ev,re,r,rp) return re and re:GetHandler():IsSetCard(0x740) end function ref.damtg(e,tp,eg,ep,ev,re,r,rp,chk) local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,0,LOCATION_MZONE,nil) if chk==0 then return g:GetCount()>0 end local dam=g:GetCount()*500 Duel.SetTargetPlayer(1-tp) Duel.SetTargetParam(dam) Duel.SetOperationInfo(0,CATEGORY_POSITION,g,g:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,dam) end function ref.damop(e,tp,eg,ep,ev,re,r,rp) local g=Duel.GetMatchingGroup(aux.AND(Card.IsFaceup,Card.IsCanTurnSet),tp,0,LOCATION_MZONE,nil) if g:GetCount()>0 and Duel.ChangePosition(g,POS_FACEDOWN_DEFENSE)~=0 then local ct=Duel.GetOperatedGroup():FilterCount(Card.IsPosition,nil,POS_FACEDOWN_DEFENSE) if ct<=0 then return end Duel.Damage(1-tp,ct*500,REASON_EFFECT) end end --Position function ref.poscon(e,tp,eg,ep,ev,re,r,rp) return not eg:IsContains(e:GetHandler()) end function ref.posfilter(c,e) return c:IsFaceup() and c:IsCanBeEffectTarget(e) and c:IsCanTurnSet() end function ref.posfilter2(c,e) return c:IsFaceup() and c:IsSetCard(1856) and c:IsCanBeEffectTarget(e) and c:IsCanTurnSet() end function ref.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) if chkc then return false end if chk==0 then return Duel.IsExistingTarget(ref.posfilter,tp,0,LOCATION_ONFIELD,1,nil,e) and Duel.IsExistingTarget(ref.posfilter2,tp,LOCATION_ONFIELD,0,1,nil,e) end Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) local g1=Duel.SelectMatchingCard(tp,ref.posfilter,tp,0,LOCATION_ONFIELD,1,1,nil,e) if #g1<=0 then return end Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) local g2=Duel.SelectMatchingCard(tp,ref.posfilter2,tp,LOCATION_ONFIELD,0,1,1,g1,e) if #g2<=0 then return end g1:Merge(g2) Duel.SetTargetCard(g1) Duel.SetOperationInfo(0,CATEGORY_POSITION,g1,#g1,0,0) end function ref.posop(e,tp,eg,ep,ev,re,r,rp) local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS):Filter(Card.IsRelateToEffect,nil,e) if #g>0 and Duel.ChangePosition(g,POS_FACEDOWN_DEFENSE)~=0 then local og=Duel.GetOperatedGroup() local tc=og:GetFirst() while tc do if tc:IsFacedown() then if tc:IsType(TYPE_MONSTER) then local e1=Effect.CreateEffect(e:GetHandler()) e1:SetType(EFFECT_TYPE_SINGLE) e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE) e1:SetCode(EFFECT_CANNOT_CHANGE_POSITION) e1:SetReset(RESET_EVENT+RESETS_STANDARD) tc:RegisterEffect(e1) end if tc:IsType(TYPE_SPELL+TYPE_TRAP) then local e1=Effect.CreateEffect(e:GetHandler()) e1:SetType(EFFECT_TYPE_SINGLE) e1:SetCode(EFFECT_CANNOT_TRIGGER) e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE) e1:SetReset(RESET_EVENT+RESETS_STANDARD) tc:RegisterEffect(e1) end end tc=og:GetNext() end end end