Commit 6412b134 authored by Chrono-Genex's avatar Chrono-Genex Committed by GitHub

fix for Blue-Eyes Spirit Dragon (#1753)

parent fb4df35e
...@@ -24,6 +24,7 @@ end ...@@ -24,6 +24,7 @@ end
function c3493978.operation(e,tp,eg,ep,ev,re,r,rp) function c3493978.operation(e,tp,eg,ep,ev,re,r,rp)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE) local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
if ft<=0 then return end if ft<=0 then return end
if Duel.IsPlayerAffectedByEffect(tp,59822133) then ft=1 end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c3493978.filter,tp,LOCATION_HAND,0,1,ft,nil,e,tp) local g=Duel.SelectMatchingCard(tp,c3493978.filter,tp,LOCATION_HAND,0,1,ft,nil,e,tp)
if g:GetCount()>0 then if g:GetCount()>0 then
......
...@@ -74,9 +74,9 @@ function c41141943.sptg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -74,9 +74,9 @@ function c41141943.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function c41141943.spop(e,tp,eg,ep,ev,re,r,rp) function c41141943.spop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c41141943.spfilter,tp,LOCATION_HAND,0,nil,e,tp) local g=Duel.GetMatchingGroup(c41141943.spfilter,tp,LOCATION_HAND,0,nil,e,tp)
if g:GetCount()==0 then return end local ft=math.min((Duel.GetLocationCount(tp,LOCATION_MZONE)),2)
local ft=Duel.GetLocationCount(1-tp,LOCATION_MZONE) if g:GetCount()==0 or ft<=0 then return end
if ft>2 then ft=2 end if Duel.IsPlayerAffectedByEffect(tp,59822133) then ft=1 end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=g:Select(tp,1,ft,nil) local sg=g:Select(tp,1,ft,nil)
local ct=Duel.SpecialSummon(sg,0,tp,1-tp,false,false,POS_FACEUP_DEFENSE) local ct=Duel.SpecialSummon(sg,0,tp,1-tp,false,false,POS_FACEUP_DEFENSE)
......
...@@ -16,6 +16,7 @@ end ...@@ -16,6 +16,7 @@ end
function c47658964.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c47658964.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c47658964.cfilter,tp,LOCATION_GRAVE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c47658964.cfilter,tp,LOCATION_GRAVE,0,1,nil) end
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE) local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
if Duel.IsPlayerAffectedByEffect(tp,59822133) then ft=1 end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c47658964.cfilter,tp,LOCATION_GRAVE,0,1,ft,nil) local g=Duel.SelectMatchingCard(tp,c47658964.cfilter,tp,LOCATION_GRAVE,0,1,ft,nil)
e:SetLabel(g:GetCount()) e:SetLabel(g:GetCount())
...@@ -29,7 +30,8 @@ function c47658964.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -29,7 +30,8 @@ function c47658964.target(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function c47658964.activate(e,tp,eg,ep,ev,re,r,rp) function c47658964.activate(e,tp,eg,ep,ev,re,r,rp)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE) local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
if ft<e:GetLabel() or not Duel.IsPlayerCanSpecialSummonMonster(tp,47658965,0x39,TYPES_TOKEN_MONSTER,0,0,1,RACE_PYRO,ATTRIBUTE_FIRE) then return end if ft<e:GetLabel() or not Duel.IsPlayerCanSpecialSummonMonster(tp,47658965,0x39,TYPES_TOKEN_MONSTER,0,0,1,RACE_PYRO,ATTRIBUTE_FIRE)
or (e:GetLabel()>1 and Duel.IsPlayerAffectedByEffect(tp,59822133)) then return end
for i=1,e:GetLabel() do for i=1,e:GetLabel() do
local token=Duel.CreateToken(tp,47658965) local token=Duel.CreateToken(tp,47658965)
Duel.SpecialSummonStep(token,0,tp,tp,false,false,POS_FACEUP_DEFENSE) Duel.SpecialSummonStep(token,0,tp,tp,false,false,POS_FACEUP_DEFENSE)
......
...@@ -18,10 +18,10 @@ function c55416843.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -18,10 +18,10 @@ function c55416843.target(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_GRAVE) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_GRAVE)
end end
function c55416843.operation(e,tp,eg,ep,ev,re,r,rp) function c55416843.operation(e,tp,eg,ep,ev,re,r,rp)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE) local ft=math.min((Duel.GetLocationCount(tp,LOCATION_MZONE)),2)
if ft<=0 then return end if ft<=0 then return end
local c=e:GetHandler() local c=e:GetHandler()
if ft>2 then ft=2 end if Duel.IsPlayerAffectedByEffect(tp,59822133) then ft=1 end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c55416843.filter),tp,LOCATION_HAND+LOCATION_GRAVE,0,1,ft,nil,e,tp) local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c55416843.filter),tp,LOCATION_HAND+LOCATION_GRAVE,0,1,ft,nil,e,tp)
if g:GetCount()>0 then if g:GetCount()>0 then
......
...@@ -37,6 +37,7 @@ function c64283880.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -37,6 +37,7 @@ function c64283880.spop(e,tp,eg,ep,ev,re,r,rp)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(64283880,0)) then if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(64283880,0)) then
Duel.BreakEffect() Duel.BreakEffect()
if ct>2 then ct=2 end if ct>2 then ct=2 end
if Duel.IsPlayerAffectedByEffect(tp,59822133) then ct=1 end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=g:Select(tp,1,ct,nil) local sg=g:Select(tp,1,ct,nil)
Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP_DEFENSE) Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP_DEFENSE)
......
...@@ -39,9 +39,9 @@ function c92609670.sptg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -39,9 +39,9 @@ function c92609670.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_GRAVE) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_GRAVE)
end end
function c92609670.spop(e,tp,eg,ep,ev,re,r,rp) function c92609670.spop(e,tp,eg,ep,ev,re,r,rp)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE) local ft=math.min((Duel.GetLocationCount(tp,LOCATION_MZONE)),2)
if ft<1 then return end if ft<=0 then return end
if ft>2 then ft=2 end if Duel.IsPlayerAffectedByEffect(tp,59822133) then ft=1 end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c92609670.filter),tp,LOCATION_HAND+LOCATION_GRAVE,0,1,ft,nil,e,tp) local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(c92609670.filter),tp,LOCATION_HAND+LOCATION_GRAVE,0,1,ft,nil,e,tp)
if g:GetCount()>0 then if g:GetCount()>0 then
......
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