--Bigbang Moon Dragon local s,id=GetID() function s.initial_effect(c) local e0=aux.AddThisCardInGraveAlreadyCheck(c) --If this card is Normal or Special Summoned: You can destroy 1 Bigbang Monster from your Extra Deck, --also you cannot Special Summon monsters from the Extra Deck for the rest of this turn, except Bigbang Monsters, --then you can make this card gain 500 ATK or DEF (your choice) until the end of this turn. local e1=Effect.CreateEffect(c) e1:SetCategory(CATEGORY_DESTROY+CATEGORY_ATKCHANGE+CATEGORY_DEFCHANGE) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetCountLimit(1,{id,0}) e1:SetTarget(s.destg) e1:SetOperation(s.desop) c:RegisterEffect(e1) local e2=e1:Clone() e2:SetCode(EVENT_SPSUMMON_SUCCESS) c:RegisterEffect(e2) --If 2 or more monsters with different Vibes are destroyed at the same time while this card is in your GY: You can target 1 Bigbang Monster in your GY; shuffle both this card and that card into the Deck, then draw 1 card. local e3=Effect.CreateEffect(c) e3:SetCategory(CATEGORY_TODECK+CATEGORY_DRAW) e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e3:SetRange(LOCATION_GRAVE) e3:SetCountLimit(1,{id,1}) e3:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) e3:SetCode(EVENT_DESTROYED) e3:SetLabelObject(e0) e3:SetCondition(s.drawcon) e3:SetTarget(s.drawtg) e3:SetOperation(s.drawop) c:RegisterEffect(e3) end function s.desfilter(c) return c:IsType(TYPE_BIGBANG) end function s.destg(e,tp,eg,ep,ev,re,r,rp,chk) if chk==0 then return Duel.IsExistingMatchingCard(s.desfilter,tp,LOCATION_EXTRA,0,1,nil) end Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,1,tp,LOCATION_EXTRA) end function s.desop(e,tp,eg,ep,ev,re,r,rp) local c=e:GetHandler() Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) local g=Duel.SelectMatchingCard(tp,s.desfilter,tp,LOCATION_EXTRA,0,1,1,nil) if g:GetCount()>0 then Duel.HintSelection(g) if Duel.Destroy(g,REASON_EFFECT)>0 then if c:IsFaceup() and c:IsRelateToEffect(e) and Duel.SelectYesNo(tp,aux.Stringid(id,1)) then Duel.BreakEffect() if Duel.SelectOption(tp,1371,1372)==1 then local e1=Effect.CreateEffect(c) e1:SetType(EFFECT_TYPE_SINGLE) e1:SetCode(EFFECT_UPDATE_DEFENSE) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END) e1:SetValue(500) c:RegisterEffect(e1) else local e1=Effect.CreateEffect(c) e1:SetType(EFFECT_TYPE_SINGLE) e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END) e1:SetValue(500) c:RegisterEffect(e1) end end end end local e2=Effect.CreateEffect(c) e2:SetType(EFFECT_TYPE_FIELD) e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) e2:SetDescription(aux.Stringid(id,0)) e2:SetTargetRange(1,0) e2:SetReset(RESET_PHASE+PHASE_END) e2:SetTarget(s.splimit) Duel.RegisterEffect(e2,tp) end function s.splimit(e,c) return not c:IsType(TYPE_BIGBANG) and c:IsLocation(LOCATION_EXTRA) end function s.drawfilter(c) return c:IsType(TYPE_BIGBANG) and c:IsAbleToExtra() and c:IsLocation(LOCATION_GRAVE) end function s.filter(c,se) return c:HasVibe() and (se==nil or c:GetReasonEffect()~=se) end function s.drawcon(e,tp,eg,ep,ev,re,r,rp) local se=e:GetLabelObject():GetLabelObject() return eg:IsExists(s.filter,2,nil,se) and eg:GetClassCount(Card.GetVibe)>=2 end function s.drawtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) if chkc then return s.drawfilter(chkc) end if chk==0 then return e:GetHandler():IsAbleToDeck() and Duel.IsPlayerCanDraw(tp,1) and Duel.IsExistingTarget(s.drawfilter,tp,LOCATION_GRAVE,0,1,e:GetHandler()) end Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) local g=Duel.SelectTarget(tp,s.drawfilter,tp,LOCATION_GRAVE,0,1,1,e:GetHandler()) g:AddCard(e:GetHandler()) Duel.SetOperationInfo(0,CATEGORY_TODECK,g,2,0,0) Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1) end function s.drawop(e,tp,eg,ep,ev,re,r,rp) local c=e:GetHandler() local tc=Duel.GetFirstTarget() if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) then local g=Group.FromCards(c,tc) Duel.SendtoDeck(g,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) if g:IsExists(Card.IsLocation,1,nil,LOCATION_DECK) then Duel.ShuffleDeck(tp) end local ct=g:FilterCount(Card.IsLocation,nil,LOCATION_DECK+LOCATION_EXTRA) if ct==2 then Duel.BreakEffect() Duel.Draw(tp,1,REASON_EFFECT) end end end