Commit 755b2293 authored by DailyShana's avatar DailyShana

revert and fix

parent 6fb24228
...@@ -31,7 +31,7 @@ function c23581825.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -31,7 +31,7 @@ function c23581825.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
and Duel.IsExistingTarget(c23581825.filter1,tp,LOCATION_GRAVE,0,1,nil,e,tp) end and Duel.IsExistingTarget(c23581825.filter1,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c23581825.filter1,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) local g=Duel.SelectTarget(tp,c23581825.filter1,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g:GetFirst(),1,tp,LOCATION_GRAVE) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,2,tp,LOCATION_GRAVE+LOCATION_EXTRA)
end end
function c23581825.activate(e,tp,eg,ep,ev,re,r,rp) function c23581825.activate(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
......
...@@ -51,7 +51,7 @@ function c43383478.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -51,7 +51,7 @@ function c43383478.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
and Duel.IsExistingTarget(c43383478.filter1,tp,LOCATION_GRAVE,0,1,nil,e,tp) end and Duel.IsExistingTarget(c43383478.filter1,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c43383478.filter1,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) local g=Duel.SelectTarget(tp,c43383478.filter1,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g:GetFirst(),1,tp,LOCATION_GRAVE) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,2,tp,LOCATION_GRAVE+LOCATION_EXTRA)
end end
function c43383478.activate(e,tp,eg,ep,ev,re,r,rp) function c43383478.activate(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
......
...@@ -67,18 +67,22 @@ end ...@@ -67,18 +67,22 @@ end
function c47355498.conntp(e) function c47355498.conntp(e)
return not Duel.IsPlayerAffectedByEffect(1-e:GetHandler():GetControler(),EFFECT_NECRO_VALLEY_IM) return not Duel.IsPlayerAffectedByEffect(1-e:GetHandler():GetControler(),EFFECT_NECRO_VALLEY_IM)
end end
function c47355498.disfilter(c,im0,im1) function c47355498.disfilter1(c,im0,im1,targets)
if c:IsControler(0) then return im0 and targets:IsContains(c) and c:IsHasEffect(EFFECT_NECRO_VALLEY)
else return im1 and targets:IsContains(c) and c:IsHasEffect(EFFECT_NECRO_VALLEY) end
end
function c47355498.disfilter2(c,im0,im1)
if c:IsControler(0) then return im0 and c:IsHasEffect(EFFECT_NECRO_VALLEY) if c:IsControler(0) then return im0 and c:IsHasEffect(EFFECT_NECRO_VALLEY)
else return im1 and c:IsHasEffect(EFFECT_NECRO_VALLEY) end else return im1 and c:IsHasEffect(EFFECT_NECRO_VALLEY) end
end end
function c47355498.discheck(ev,category,re,im0,im1) function c47355498.discheck(ev,category,re,im0,im1,targets)
local ex,tg,ct,p,v=Duel.GetOperationInfo(ev,category) local ex,tg,ct,p,v=Duel.GetOperationInfo(ev,category)
if not ex then return false end if not ex then return false end
if tg and tg:GetCount()>0 then if tg and tg:GetCount()>0 then
if re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) then if targets then
return tg:IsExists(c47355498.disfilter,1,nil,im0,im1) return tg:IsExists(c47355498.disfilter1,1,nil,im0,im1,targets)
else else
return tg:IsExists(c47355498.disfilter,1,re:GetHandler(),im0,im1) return tg:IsExists(c47355498.disfilter2,1,re:GetHandler(),im0,im1)
end end
end end
if v~=LOCATION_GRAVE then return false end if v~=LOCATION_GRAVE then return false end
...@@ -91,12 +95,16 @@ function c47355498.disop(e,tp,eg,ep,ev,re,r,rp) ...@@ -91,12 +95,16 @@ function c47355498.disop(e,tp,eg,ep,ev,re,r,rp)
local tc=re:GetHandler() local tc=re:GetHandler()
if not Duel.IsChainDisablable(ev) or tc:IsHasEffect(EFFECT_NECRO_VALLEY_IM) then return end if not Duel.IsChainDisablable(ev) or tc:IsHasEffect(EFFECT_NECRO_VALLEY_IM) then return end
local res=false local res=false
local targets=nil
if re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) then
targets=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS)
end
local im0=not Duel.IsPlayerAffectedByEffect(0,EFFECT_NECRO_VALLEY_IM) local im0=not Duel.IsPlayerAffectedByEffect(0,EFFECT_NECRO_VALLEY_IM)
local im1=not Duel.IsPlayerAffectedByEffect(1,EFFECT_NECRO_VALLEY_IM) local im1=not Duel.IsPlayerAffectedByEffect(1,EFFECT_NECRO_VALLEY_IM)
if not res and c47355498.discheck(ev,CATEGORY_SPECIAL_SUMMON,re,im0,im1) then res=true end if not res and c47355498.discheck(ev,CATEGORY_SPECIAL_SUMMON,re,im0,im1,targets) then res=true end
if not res and c47355498.discheck(ev,CATEGORY_REMOVE,re,im0,im1) then res=true end if not res and c47355498.discheck(ev,CATEGORY_REMOVE,re,im0,im1,targets) then res=true end
if not res and c47355498.discheck(ev,CATEGORY_TOHAND,re,im0,im1) then res=true end if not res and c47355498.discheck(ev,CATEGORY_TOHAND,re,im0,im1,targets) then res=true end
if not res and c47355498.discheck(ev,CATEGORY_TODECK,re,im0,im1) then res=true end if not res and c47355498.discheck(ev,CATEGORY_TODECK,re,im0,im1,targets) then res=true end
if not res and c47355498.discheck(ev,CATEGORY_LEAVE_GRAVE,re,im0,im1) then res=true end if not res and c47355498.discheck(ev,CATEGORY_LEAVE_GRAVE,re,im0,im1,targets) then res=true end
if res then Duel.NegateEffect(ev) end if res then Duel.NegateEffect(ev) end
end end
...@@ -43,7 +43,7 @@ function c86196216.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -43,7 +43,7 @@ function c86196216.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
and Duel.IsExistingTarget(c86196216.filter1,tp,LOCATION_GRAVE,0,1,nil,e,tp) end and Duel.IsExistingTarget(c86196216.filter1,tp,LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectTarget(tp,c86196216.filter1,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) local g=Duel.SelectTarget(tp,c86196216.filter1,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g:GetFirst(),1,tp,LOCATION_GRAVE) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,2,tp,LOCATION_EXTRA+LOCATION_GRAVE)
end end
function c86196216.activate(e,tp,eg,ep,ev,re,r,rp) function c86196216.activate(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return 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