Commit 22d4dcc0 authored by Crescent/毛虫's avatar Crescent/毛虫

Fix 亜空間物質回送装置

parent d3ea9136
...@@ -38,6 +38,7 @@ function s.initial_effect(c) ...@@ -38,6 +38,7 @@ function s.initial_effect(c)
e5:SetRange(LOCATION_SZONE) e5:SetRange(LOCATION_SZONE)
e5:SetCode(EVENT_CHAIN_SOLVING) e5:SetCode(EVENT_CHAIN_SOLVING)
e5:SetCountLimit(1,id+o*2) e5:SetCountLimit(1,id+o*2)
e5:SetCondition(s.rmcon3)
e5:SetOperation(s.rmop3) e5:SetOperation(s.rmop3)
c:RegisterEffect(e5) c:RegisterEffect(e5)
end end
...@@ -78,13 +79,17 @@ function s.rmop2(e,tp,eg,ep,ev,re,r,rp) ...@@ -78,13 +79,17 @@ function s.rmop2(e,tp,eg,ep,ev,re,r,rp)
Duel.ReturnToField(tc) Duel.ReturnToField(tc)
end end
end end
function s.rmop3(e,tp,eg,ep,ev,re,r,rp) function s.rmcon3(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if c:GetFlagEffect(FLAG_ID_CHAINING)==0 then return end if c:GetFlagEffect(FLAG_ID_CHAINING)==0 then return false end
if ep==tp then return end if ep==tp then return false end
if not re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) then return end if not re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) then return false end
local g=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS) local g=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS)
if g and g:IsContains(c) then if not g or not g:IsContains(c)then return false end
return true
end
function s.rmop3(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsAbleToRemove() and Duel.Remove(c,0,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:GetOriginalCode()==id then if c:IsAbleToRemove() and Duel.Remove(c,0,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:GetOriginalCode()==id then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
...@@ -96,7 +101,6 @@ function s.rmop3(e,tp,eg,ep,ev,re,r,rp) ...@@ -96,7 +101,6 @@ function s.rmop3(e,tp,eg,ep,ev,re,r,rp)
e1:SetOperation(s.retop) e1:SetOperation(s.retop)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
end end
end
end end
function s.retop(e,tp,eg,ep,ev,re,r,rp) function s.retop(e,tp,eg,ep,ev,re,r,rp)
local ec=e:GetLabelObject() local ec=e:GetLabelObject()
......
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