--Aurora Pendulum-Angel function c249000379.initial_effect(c) --pendulum summon aux.EnablePendulumAttribute(c) --indes local e2=Effect.CreateEffect(c) e2:SetType(EFFECT_TYPE_FIELD) e2:SetCode(EFFECT_INDESTRUCTABLE_COUNT) e2:SetRange(LOCATION_PZONE) e2:SetTargetRange(LOCATION_PZONE,0) e2:SetCountLimit(1) e2:SetTarget(aux.TRUE) e2:SetValue(c249000379.indval) c:RegisterEffect(e2) --inactivatable --draw local e3=Effect.CreateEffect(c) e3:SetDescription(aux.Stringid(24943456,0)) e3:SetCategory(CATEGORY_DRAW) e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F) e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e3:SetCode(EVENT_LEAVE_FIELD) e3:SetCondition(c249000379.drcon) e3:SetTarget(c249000379.drtg) e3:SetOperation(c249000379.drop) c:RegisterEffect(e3) --special summon local e4=Effect.CreateEffect(c) e4:SetType(EFFECT_TYPE_FIELD) e4:SetCode(EFFECT_SPSUMMON_PROC) e4:SetProperty(EFFECT_FLAG_UNCOPYABLE) e4:SetRange(LOCATION_HAND) e4:SetCondition(c249000379.spcon) c:RegisterEffect(e4) end function c249000379.indval(e,re,r,rp) return bit.band(r,REASON_EFFECT)~=0 and rp==1-e:GetHandlerPlayer() end function c249000379.drcon(e,tp,eg,ep,ev,re,r,rp) return e:GetHandler():IsPreviousLocation(LOCATION_MZONE) and e:GetHandler():IsReason(REASON_DESTROY) end function c249000379.drtg(e,tp,eg,ep,ev,re,r,rp,chk) if chk==0 then return true end Duel.SetTargetPlayer(tp) Duel.SetTargetParam(1) Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1) end function c249000379.drop(e,tp,eg,ep,ev,re,r,rp) local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM) Duel.Draw(p,d,REASON_EFFECT) end function c249000379.filter(c) return c:IsFaceup() and c:IsSetCard(0x1B7) and c:GetCode()~=249000379 end function c249000379.spcon(e,c) if c==nil then return true end return Duel.GetLocationCount(c:GetControler(),LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(c249000379.filter,c:GetControler(),LOCATION_ONFIELD,0,1,nil) end