Commit 4153d40b authored by mercury233's avatar mercury233 Committed by GitHub

update some SelectYesNo to use SelectOption (#1083)

the str of 8165596,23927567,24140059 is changed
parent bd8c9faf
...@@ -46,7 +46,7 @@ function c1322368.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -46,7 +46,7 @@ function c1322368.spop(e,tp,eg,ep,ev,re,r,rp)
local sc=sg:GetFirst() local sc=sg:GetFirst()
if sc then if sc then
if zone~=0 and sc:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP,tp,zone) if zone~=0 and sc:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP,tp,zone)
and (not sc:IsAbleToHand() or Duel.SelectYesNo(tp,aux.Stringid(1322368,1))) then and (not sc:IsAbleToHand() or Duel.SelectOption(tp,1190,1152)==1) then
Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP,zone) Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP,zone)
else else
Duel.SendtoHand(sc,nil,REASON_EFFECT) Duel.SendtoHand(sc,nil,REASON_EFFECT)
......
...@@ -40,7 +40,7 @@ function c14733538.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -40,7 +40,7 @@ function c14733538.activate(e,tp,eg,ep,ev,re,r,rp)
local cg=sg1:Select(1-tp,1,1,nil) local cg=sg1:Select(1-tp,1,1,nil)
local tc=cg:GetFirst() local tc=cg:GetFirst()
Duel.Hint(HINT_CARD,0,tc:GetCode()) Duel.Hint(HINT_CARD,0,tc:GetCode())
if b1 and (not b2 or not tc:IsCanBeSpecialSummoned(e,0,tp,false,false) or Duel.SelectYesNo(tp,aux.Stringid(14733538,0))) then if b1 and (not b2 or not tc:IsCanBeSpecialSummoned(e,0,tp,false,false) or Duel.SelectOption(tp,1160,1152)==0) then
Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true)
else else
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
......
...@@ -26,7 +26,7 @@ function c20065322.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -26,7 +26,7 @@ function c20065322.activate(e,tp,eg,ep,ev,re,r,rp)
local th=g:GetFirst():IsAbleToHand() local th=g:GetFirst():IsAbleToHand()
local sp=ft>0 and g:GetFirst():IsCanBeSpecialSummoned(e,0,tp,false,false) local sp=ft>0 and g:GetFirst():IsCanBeSpecialSummoned(e,0,tp,false,false)
local op=0 local op=0
if th and sp then op=Duel.SelectOption(tp,aux.Stringid(20065322,0),aux.Stringid(20065322,1)) if th and sp then op=Duel.SelectOption(tp,1190,1152)
elseif th then op=0 elseif th then op=0
else op=1 end else op=1 end
if op==0 then if op==0 then
......
...@@ -40,7 +40,7 @@ function c22499034.thop(e,tp,eg,ep,ev,re,r,rp) ...@@ -40,7 +40,7 @@ function c22499034.thop(e,tp,eg,ep,ev,re,r,rp)
if tc then if tc then
local b1=tc:IsAbleToHand() local b1=tc:IsAbleToHand()
local b2=tc:GetActivateEffect():IsActivatable(tp) local b2=tc:GetActivateEffect():IsActivatable(tp)
if b1 and (not b2 or Duel.SelectYesNo(tp,aux.Stringid(22499034,2))) then if b1 and (not b2 or Duel.SelectOption(tp,1190,1150)==0) then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc) Duel.ConfirmCards(1-tp,tc)
else else
......
...@@ -12,7 +12,7 @@ function c23927567.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -12,7 +12,7 @@ function c23927567.operation(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.SelectMatchingCard(tp,Card.IsType,tp,LOCATION_DECK,0,1,1,nil,TYPE_FIELD) local g=Duel.SelectMatchingCard(tp,Card.IsType,tp,LOCATION_DECK,0,1,1,nil,TYPE_FIELD)
local tc=g:GetFirst() local tc=g:GetFirst()
if tc then if tc then
if Duel.IsEnvironment(47355498) and tc:IsAbleToHand() and Duel.SelectYesNo(tp,aux.Stringid(23927567,0)) then if Duel.IsEnvironment(47355498) and tc:IsAbleToHand() and Duel.SelectOption(tp,1190,aux.Stringid(23927567,0))==0 then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc) Duel.ConfirmCards(1-tp,tc)
else else
......
...@@ -12,7 +12,7 @@ function c24140059.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -12,7 +12,7 @@ function c24140059.operation(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.SelectMatchingCard(tp,Card.IsType,tp,LOCATION_DECK,0,1,1,nil,TYPE_TRAP) local g=Duel.SelectMatchingCard(tp,Card.IsType,tp,LOCATION_DECK,0,1,1,nil,TYPE_TRAP)
local tc=g:GetFirst() local tc=g:GetFirst()
if tc then if tc then
if Duel.IsEnvironment(47355498) and tc:IsAbleToHand() and Duel.SelectYesNo(tp,aux.Stringid(24140059,0)) then if Duel.IsEnvironment(47355498) and tc:IsAbleToHand() and Duel.SelectOption(tp,1190,aux.Stringid(24140059,0))==0 then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc) Duel.ConfirmCards(1-tp,tc)
else else
......
...@@ -51,7 +51,7 @@ function c28201945.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -51,7 +51,7 @@ function c28201945.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=g:GetFirst() local tc=g:GetFirst()
if tc then if tc then
if ft>0 and tc:IsCanBeSpecialSummoned(e,0,tp,false,false) if ft>0 and tc:IsCanBeSpecialSummoned(e,0,tp,false,false)
and (not tc:IsAbleToHand() or Duel.SelectYesNo(tp,aux.Stringid(28201945,1))) then and (not tc:IsAbleToHand() or Duel.SelectOption(tp,1190,1152)==1) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
else else
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
......
...@@ -38,9 +38,9 @@ function c39913299.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -38,9 +38,9 @@ function c39913299.operation(e,tp,eg,ep,ev,re,r,rp)
local b1=sc:IsAbleToHand() local b1=sc:IsAbleToHand()
local b2=sc:IsCanBeSpecialSummoned(e,0,tp,false,false) local b2=sc:IsCanBeSpecialSummoned(e,0,tp,false,false)
local op=0 local op=0
if b1 and b2 then op=Duel.SelectOption(tp,aux.Stringid(39913299,2),aux.Stringid(39913299,3)) if b1 and b2 then op=Duel.SelectOption(tp,1190,1152)
elseif b1 then op=Duel.SelectOption(tp,aux.Stringid(39913299,2)) elseif b1 then op=0
else op=Duel.SelectOption(tp,aux.Stringid(39913299,3))+1 end else op=1 end
if op==0 then if op==0 then
Duel.SendtoHand(sc,nil,REASON_EFFECT) Duel.SendtoHand(sc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,sc) Duel.ConfirmCards(1-tp,sc)
......
...@@ -39,7 +39,7 @@ function c44335251.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -39,7 +39,7 @@ function c44335251.operation(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.SelectMatchingCard(tp,c44335251.cfilter,tp,LOCATION_DECK,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c44335251.cfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then if g:GetCount()>0 then
local tc=g:GetFirst() local tc=g:GetFirst()
if tc and tc:IsAbleToHand() and (not tc:IsAbleToGrave() or Duel.SelectYesNo(tp,aux.Stringid(44335251,3))) then if tc and tc:IsAbleToHand() and (not tc:IsAbleToGrave() or Duel.SelectOption(tp,1190,1191)==0) then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc) Duel.ConfirmCards(1-tp,tc)
else else
......
...@@ -31,7 +31,7 @@ function c57312333.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -31,7 +31,7 @@ function c57312333.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c57312333.filter,tp,LOCATION_DECK,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c57312333.filter,tp,LOCATION_DECK,0,1,1,nil)
local tc=g:GetFirst() local tc=g:GetFirst()
if tc and tc:IsAbleToHand() and (not tc:IsAbleToGrave() or Duel.SelectYesNo(tp,aux.Stringid(57312333,0))) then if tc and tc:IsAbleToHand() and (not tc:IsAbleToGrave() or Duel.SelectOption(tp,1190,1191)==0) then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc) Duel.ConfirmCards(1-tp,tc)
else else
......
...@@ -40,7 +40,7 @@ function c58984738.thop(e,tp,eg,ep,ev,re,r,rp) ...@@ -40,7 +40,7 @@ function c58984738.thop(e,tp,eg,ep,ev,re,r,rp)
if tc then if tc then
local b1=tc:IsAbleToHand() local b1=tc:IsAbleToHand()
local b2=tc:GetActivateEffect():IsActivatable(tp) local b2=tc:GetActivateEffect():IsActivatable(tp)
if b1 and (not b2 or Duel.SelectYesNo(tp,aux.Stringid(58984738,2))) then if b1 and (not b2 or Duel.SelectOption(tp,1190,1150)==0) then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc) Duel.ConfirmCards(1-tp,tc)
else else
......
...@@ -41,7 +41,7 @@ function c62834295.tgop(e,tp,eg,ep,ev,re,r,rp) ...@@ -41,7 +41,7 @@ function c62834295.tgop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.SelectMatchingCard(tp,c62834295.tgfilter,tp,LOCATION_DECK,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c62834295.tgfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then if g:GetCount()>0 then
local tc=g:GetFirst() local tc=g:GetFirst()
if tc and tc:IsAbleToGrave() and (not tc:IsAbleToRemove() or Duel.SelectYesNo(tp,aux.Stringid(62834295,2))) then if tc and tc:IsAbleToGrave() and (not tc:IsAbleToRemove() or Duel.SelectOption(tp,1191,1192)==0) then
Duel.SendtoGrave(tc,REASON_EFFECT) Duel.SendtoGrave(tc,REASON_EFFECT)
else else
Duel.Remove(tc,POS_FACEUP,REASON_EFFECT) Duel.Remove(tc,POS_FACEUP,REASON_EFFECT)
......
...@@ -64,7 +64,7 @@ function c63509474.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -64,7 +64,7 @@ function c63509474.operation(e,tp,eg,ep,ev,re,r,rp)
local sc=g:GetFirst() local sc=g:GetFirst()
if sc then if sc then
if sc:IsCanBeSpecialSummoned(e,0,tp,false,false) if sc:IsCanBeSpecialSummoned(e,0,tp,false,false)
and (not sc:IsAbleToHand() or Duel.SelectYesNo(tp,aux.Stringid(63509474,2))) then and (not sc:IsAbleToHand() or Duel.SelectOption(tp,1190,1152)==1) then
Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP)
else else
Duel.SendtoHand(sc,nil,REASON_EFFECT) Duel.SendtoHand(sc,nil,REASON_EFFECT)
......
...@@ -36,7 +36,7 @@ function c75840616.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -36,7 +36,7 @@ function c75840616.operation(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,c75840616.filter,tp,LOCATION_DECK,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c75840616.filter,tp,LOCATION_DECK,0,1,1,nil)
local tc=g:GetFirst() local tc=g:GetFirst()
if tc and tc:IsAbleToHand() and (not tc:IsAbleToGrave() or Duel.SelectYesNo(tp,aux.Stringid(75840616,1))) then if tc and tc:IsAbleToHand() and (not tc:IsAbleToGrave() or Duel.SelectOption(tp,1190,1191)==0) then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc) Duel.ConfirmCards(1-tp,tc)
else else
......
...@@ -79,7 +79,7 @@ function c81470373.sumop(e,tp,eg,ep,ev,re,r,rp) ...@@ -79,7 +79,7 @@ function c81470373.sumop(e,tp,eg,ep,ev,re,r,rp)
e2:SetCondition(c81470373.ttcon) e2:SetCondition(c81470373.ttcon)
c:RegisterEffect(e2) c:RegisterEffect(e2)
if c:IsSummonable(true,nil) if c:IsSummonable(true,nil)
and (not c:IsAbleToGrave() or Duel.SelectYesNo(tp,aux.Stringid(81470373,1))) then and (not c:IsAbleToGrave() or Duel.SelectOption(tp,1151,1191)==0) then
Duel.BreakEffect() Duel.BreakEffect()
Duel.Summon(tp,c,true,nil) Duel.Summon(tp,c,true,nil)
else else
......
...@@ -79,7 +79,7 @@ function c8165596.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -79,7 +79,7 @@ function c8165596.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local g=Duel.SelectMatchingCard(tp,c8165596.filter,tp,LOCATION_DECK,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c8165596.filter,tp,LOCATION_DECK,0,1,1,nil)
local tc=g:GetFirst() local tc=g:GetFirst()
if tc and (tc:IsAbleToHand() and Duel.SelectYesNo(tp,aux.Stringid(8165596,2))) then if tc and (tc:IsAbleToHand() and Duel.SelectOption(tp,1190,aux.Stringid(8165596,2))==0) then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc) Duel.ConfirmCards(1-tp,tc)
else else
......
...@@ -24,7 +24,7 @@ function c89208725.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -24,7 +24,7 @@ function c89208725.activate(e,tp,eg,ep,ev,re,r,rp)
local te=tc:GetActivateEffect() local te=tc:GetActivateEffect()
local b1=tc:IsAbleToHand() local b1=tc:IsAbleToHand()
local b2=te:IsActivatable(tp) local b2=te:IsActivatable(tp)
if b1 and (not b2 or Duel.SelectYesNo(tp,aux.Stringid(89208725,1))) then if b1 and (not b2 or Duel.SelectOption(tp,1190,1150)==0) then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc) Duel.ConfirmCards(1-tp,tc)
else else
......
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