Commit ec252a6c authored by mercury233's avatar mercury233 Committed by GitHub

fix HSR/CWライダー

parent c157c12a
...@@ -79,15 +79,23 @@ function c86154370.sptg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -79,15 +79,23 @@ function c86154370.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c86154370.spfilter,tp,LOCATION_EXTRA,0,1,nil,e,tp,e:GetHandler()) end if chk==0 then return Duel.IsExistingMatchingCard(c86154370.spfilter,tp,LOCATION_EXTRA,0,1,nil,e,tp,e:GetHandler()) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end end
function c86154370.exfilter(c)
return c:IsFaceup() and c:IsType(TYPE_PENDULUM)
end
function c86154370.gcheck(g,ft1,ft2)
return aux.dncheck(g) and #g<=ft1
and g:FilterCount(c86154370.exfilter,nil)<=ft2
end
function c86154370.spop(e,tp,eg,ep,ev,re,r,rp) function c86154370.spop(e,tp,eg,ep,ev,re,r,rp)
local ft=Duel.GetLocationCountFromEx(tp,tp,nil,TYPE_SYNCHRO) local ft=Duel.GetLocationCountFromEx(tp,tp,nil,TYPE_SYNCHRO)
local ect=(c29724053 and Duel.IsPlayerAffectedByEffect(tp,29724053) and c29724053[tp]) or ft local ect=(c29724053 and Duel.IsPlayerAffectedByEffect(tp,29724053) and c29724053[tp]) or ft
local ct=math.min(ft,ect,2) local ct=math.min(ft,ect,2)
if ct<=0 then return end if ct<=0 then return end
if Duel.IsPlayerAffectedByEffect(tp,59822133) then ct=1 end if Duel.IsPlayerAffectedByEffect(tp,59822133) then ct=1 end
local ft2=Duel.GetLocationCountFromEx(tp,tp,nil,TYPE_PENDULUM)
local g=Duel.GetMatchingGroup(c86154370.spfilter,tp,LOCATION_EXTRA,0,nil,e,tp,nil) local g=Duel.GetMatchingGroup(c86154370.spfilter,tp,LOCATION_EXTRA,0,nil,e,tp,nil)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=g:SelectSubGroup(tp,aux.dncheck,false,1,ct) local sg=g:SelectSubGroup(tp,c86154370.gcheck,false,1,2,ct,ft2)
if sg then if sg then
Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP)
end 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