Commit 75cb4af5 authored by mercury233's avatar mercury233 Committed by DailyShana

fix Shooting Star Dragon (#677)

parent 65a3f296
...@@ -52,16 +52,27 @@ function c24696097.mtcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -52,16 +52,27 @@ function c24696097.mtcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsAbleToEnterBP() and Duel.GetFieldGroupCount(tp,LOCATION_DECK,0)>=5 return Duel.IsAbleToEnterBP() and Duel.GetFieldGroupCount(tp,LOCATION_DECK,0)>=5
end end
function c24696097.mtop(e,tp,eg,ep,ev,re,r,rp) function c24696097.mtop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
Duel.ConfirmDecktop(tp,5) Duel.ConfirmDecktop(tp,5)
local g=Duel.GetDecktopGroup(tp,5) local g=Duel.GetDecktopGroup(tp,5)
local ct=g:FilterCount(Card.IsType,nil,TYPE_TUNER) local ct=g:FilterCount(Card.IsType,nil,TYPE_TUNER)
Duel.ShuffleDeck(tp) Duel.ShuffleDeck(tp)
local e1=Effect.CreateEffect(e:GetHandler()) if ct>1 then
e1:SetType(EFFECT_TYPE_SINGLE) local e1=Effect.CreateEffect(c)
e1:SetCode(EFFECT_EXTRA_ATTACK) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetReset(RESET_EVENT+0x1ff0000+RESET_PHASE+PHASE_END) e1:SetCode(EFFECT_EXTRA_ATTACK)
e1:SetValue(ct-1) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e:GetHandler():RegisterEffect(e1) e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END)
e1:SetValue(ct-1)
c:RegisterEffect(e1)
elseif ct==0 then
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_CANNOT_ATTACK)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END)
c:RegisterEffect(e2)
end
end end
function c24696097.discon(e,tp,eg,ep,ev,re,r,rp) function c24696097.discon(e,tp,eg,ep,ev,re,r,rp)
if e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) or not Duel.IsChainNegatable(ev) then return false end if e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) or not Duel.IsChainNegatable(ev) then return false end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment