Commit 64c7a586 authored by Amiya's avatar Amiya

修复

parents 0c85760f 6f3ac656
Pipeline #28347 passed with stages
in 59 seconds
No preview for this file type
...@@ -94,7 +94,8 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -94,7 +94,8 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
local c=e:GetHandler() local c=e:GetHandler()
if tc and tc:IsRelateToEffect(e) and Duel.SendtoHand(tc,nil,REASON_EFFECT)~=0 then if tc and tc:IsRelateToEffect(e) and Duel.SendtoHand(tc,nil,REASON_EFFECT)~=0 then
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false) and c:IsRelateToEffect(e) and c:IsLocation(LOCATION_PZONE) and Duel.SelectYesNo(tp,aux.Stringid(id,3)) then if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,false,false)
and c:IsRelateToEffect(e) and c:IsLocation(LOCATION_PZONE) and Duel.SelectYesNo(tp,aux.Stringid(id,3)) then
Duel.BreakEffect() Duel.BreakEffect()
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end end
......
...@@ -36,7 +36,7 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -36,7 +36,7 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
if not c:IsRelateToEffect(e) then return end if not c:IsRelateToEffect(e) then return end
local b1=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false) local b1=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
local b2=Duel.GetLocationCount(1-tp,LOCATION_MZONE)>0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP,1-tp) local b2=Duel.GetLocationCount(1-tp,LOCATION_MZONE)>0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP,1-tp)
local op=0 local op=-1
if b1 and b2 then if b1 and b2 then
op=Duel.SelectOption(tp,aux.Stringid(id,1),aux.Stringid(id,2)) op=Duel.SelectOption(tp,aux.Stringid(id,1),aux.Stringid(id,2))
elseif b1 then elseif b1 then
...@@ -46,14 +46,14 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -46,14 +46,14 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
else else
Duel.SendtoGrave(c,REASON_RULE) Duel.SendtoGrave(c,REASON_RULE)
end end
local sp=0 local sp=nil
if op==0 then if op==0 then
sp=Duel.SpecialSummonStep(c,0,tp,tp,false,false,POS_FACEUP) sp=Duel.SpecialSummonStep(c,0,tp,tp,false,false,POS_FACEUP)
else elseif op==1 then
sp=Duel.SpecialSummonStep(c,0,tp,1-tp,false,false,POS_FACEUP) sp=Duel.SpecialSummonStep(c,0,tp,1-tp,false,false,POS_FACEUP)
end end
local att=e:GetLabel() local att=e:GetLabel()
if sp~=0 then if sp~=nil then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CHANGE_ATTRIBUTE) e1:SetCode(EFFECT_CHANGE_ATTRIBUTE)
...@@ -61,14 +61,14 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -61,14 +61,14 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
Duel.SpecialSummonComplete() if op>=0 then Duel.SpecialSummonComplete() end
if op==1 and Duel.GetMZoneCount(tp,e:GetHandler())>0 if op==1 and Duel.GetMZoneCount(tp,e:GetHandler())>0
and Duel.IsExistingMatchingCard(aux.NecroValleyFilter(s.spfilter),tp,LOCATION_HAND+LOCATION_GRAVE,0,1,nil,e,tp,att) and Duel.IsExistingMatchingCard(aux.NecroValleyFilter(s.spfilter),tp,LOCATION_HAND+LOCATION_GRAVE,0,1,nil,e,tp,att)
and Duel.SelectYesNo(tp,aux.Stringid(id,3)) then and Duel.SelectYesNo(tp,aux.Stringid(id,3)) then
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_HAND+LOCATION_GRAVE,0,1,1,nil,e,tp,att) local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_HAND+LOCATION_GRAVE,0,1,1,nil,e,tp,att)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.BreakEffect()
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end end
end end
......
...@@ -12,7 +12,7 @@ function s.initial_effect(c) ...@@ -12,7 +12,7 @@ function s.initial_effect(c)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetValue(s.splimit) e1:SetValue(s.splimit)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--to hand or spsummon --equip or draw
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(id,0)) e2:SetDescription(aux.Stringid(id,0))
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
...@@ -63,8 +63,10 @@ function s.tstg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -63,8 +63,10 @@ function s.tstg(e,tp,eg,ep,ev,re,r,rp,chk)
end end
e:SetLabel(op) e:SetLabel(op)
if op==0 then if op==0 then
e:SetCategory(CATEGORY_EQUIP)
Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,nil,1,0,0) Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,nil,1,0,0)
else else
e:SetCategory(CATEGORY_DRAW)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1) Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
end end
end end
......
...@@ -53,7 +53,7 @@ function s.indescon(e) ...@@ -53,7 +53,7 @@ function s.indescon(e)
or Duel.IsExistingMatchingCard(s.cfilter2,tp,0,LOCATION_MZONE,1,nil) or Duel.IsExistingMatchingCard(s.cfilter2,tp,0,LOCATION_MZONE,1,nil)
end end
function s.thfilter(c) function s.thfilter(c)
return c:IsSetCard(0x2be) and not c:IsCode(id) and c:IsAbleToHand() return c:IsSetCard(0x2be) and c:IsType(TYPE_MONSTER) and not c:IsCode(id) and c:IsAbleToHand()
end end
function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) 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