Commit f69af112 authored by wind2009's avatar wind2009

Fix 磁石の戦士Ω+

parent f4d5671c
Pipeline #40909 passed with stages
in 1 minute and 17 seconds
No preview for this file type
...@@ -2,4 +2,5 @@ ...@@ -2,4 +2,5 @@
100248019 100248019
100248041 100248041
100249001 100249001
100238301 100238301
\ No newline at end of file 100200280
\ No newline at end of file
--磁石の戦士Ω --磁石の戦士Ω
local s,id,o=GetID() local s,id,o=GetID()
function s.initial_effect(c) function s.initial_effect(c)
--spsummon --spsummon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,0)) e1:SetDescription(aux.Stringid(id,0))
e1:SetCategory(CATEGORY_DESTROY+CATEGORY_SPECIAL_SUMMON) e1:SetCategory(CATEGORY_DESTROY+CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_QUICK_O) e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_HAND+LOCATION_GRAVE) e1:SetRange(LOCATION_HAND+LOCATION_GRAVE)
e1:SetCountLimit(1,id) e1:SetCountLimit(1,id)
e1:SetTarget(s.sptg) e1:SetTarget(s.sptg)
...@@ -41,7 +40,7 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -41,7 +40,7 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectMatchingCard(tp,s.desfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,1,1,aux.ExceptThisCard(e),tp) local g=Duel.SelectMatchingCard(tp,s.desfilter,tp,LOCATION_HAND+LOCATION_MZONE,0,1,1,aux.ExceptThisCard(e),tp)
if Duel.Destroy(g,REASON_EFFECT)>0 and c:IsRelateToChain() if Duel.Destroy(g,REASON_EFFECT)>0 and c:IsRelateToChain() and aux.NecroValleyFilter()(c)
and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)~=0 then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
...@@ -77,4 +76,4 @@ function s.posop(e,tp,eg,ep,ev,re,r,rp) ...@@ -77,4 +76,4 @@ function s.posop(e,tp,eg,ep,ev,re,r,rp)
if tc:IsRelateToChain() and tc:IsLocation(LOCATION_MZONE) and tc:IsFaceup() then if tc:IsRelateToChain() and tc:IsLocation(LOCATION_MZONE) and tc:IsFaceup() then
Duel.ChangePosition(tc,POS_FACEDOWN_DEFENSE) Duel.ChangePosition(tc,POS_FACEDOWN_DEFENSE)
end end
end end
\ No newline at end of file
...@@ -183,4 +183,4 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -183,4 +183,4 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
e1:SetValue(LOCATION_REMOVED) e1:SetValue(LOCATION_REMOVED)
c:RegisterEffect(e1,true) c:RegisterEffect(e1,true)
end end
end end
\ No newline at end of file
...@@ -77,4 +77,4 @@ function s.disop(e,tp,eg,ep,ev,re,r,rp) ...@@ -77,4 +77,4 @@ function s.disop(e,tp,eg,ep,ev,re,r,rp)
Duel.Destroy(sg,REASON_EFFECT) Duel.Destroy(sg,REASON_EFFECT)
end end
end end
end end
\ No newline at end of file
...@@ -110,4 +110,4 @@ function s.setop(e,tp,eg,ep,ev,re,r,rp) ...@@ -110,4 +110,4 @@ function s.setop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD)
local tc=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.pfilter),tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil,tp):GetFirst() local tc=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.pfilter),tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil,tp):GetFirst()
if tc then Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) end if tc then Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) end
end end
\ No newline at end of file
...@@ -98,4 +98,4 @@ function s.tgop(e,tp,eg,ep,ev,re,r,rp) ...@@ -98,4 +98,4 @@ function s.tgop(e,tp,eg,ep,ev,re,r,rp)
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.SendtoGrave(g,REASON_EFFECT) Duel.SendtoGrave(g,REASON_EFFECT)
end end
end end
\ No newline at end of file
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