Commit 1ac9d6f0 authored by DailyShana's avatar DailyShana

fix nagate activation of spell/trap

They should be sent to grave immediately after being negated.
parent 1b983145
...@@ -80,6 +80,9 @@ function c15180041.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -80,6 +80,9 @@ function c15180041.target(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function c15180041.operation(e,tp,eg,ep,ev,re,r,rp) function c15180041.operation(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateActivation(ev) Duel.NegateActivation(ev)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:GetHandler():IsRelateToEffect(re) then
Duel.SendtoGrave(eg,REASON_RULE)
end
end end
function c15180041.spcon2(e,tp,eg,ep,ev,re,r,rp) function c15180041.spcon2(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
......
...@@ -71,6 +71,9 @@ function c41175645.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -71,6 +71,9 @@ function c41175645.target(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function c41175645.operation(e,tp,eg,ep,ev,re,r,rp) function c41175645.operation(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateActivation(ev) Duel.NegateActivation(ev)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:GetHandler():IsRelateToEffect(re) then
Duel.SendtoGrave(eg,REASON_RULE)
end
end end
function c41175645.spcon2(e,tp,eg,ep,ev,re,r,rp) function c41175645.spcon2(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
......
...@@ -21,6 +21,9 @@ function c46031686.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -21,6 +21,9 @@ function c46031686.target(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function c46031686.activate(e,tp,eg,ep,ev,re,r,rp) function c46031686.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateActivation(ev) Duel.NegateActivation(ev)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:GetHandler():IsRelateToEffect(re) then
Duel.SendtoGrave(eg,REASON_RULE)
end
Duel.Draw(tp,1,REASON_EFFECT) Duel.Draw(tp,1,REASON_EFFECT)
Duel.Draw(1-tp,1,REASON_EFFECT) Duel.Draw(1-tp,1,REASON_EFFECT)
end end
...@@ -55,6 +55,9 @@ function c52068432.negtg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -55,6 +55,9 @@ function c52068432.negtg(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function c52068432.negop(e,tp,eg,ep,ev,re,r,rp) function c52068432.negop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateActivation(ev) Duel.NegateActivation(ev)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:GetHandler():IsRelateToEffect(re) then
Duel.SendtoGrave(eg,REASON_RULE)
end
end end
function c52068432.remcon(e,tp,eg,ep,ev,re,r,rp) function c52068432.remcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_RITUAL return e:GetHandler():GetSummonType()==SUMMON_TYPE_RITUAL
......
...@@ -32,5 +32,8 @@ end ...@@ -32,5 +32,8 @@ end
function c65240384.negop(e,tp,eg,ep,ev,re,r,rp) function c65240384.negop(e,tp,eg,ep,ev,re,r,rp)
if Duel.ChangePosition(e:GetHandler(),POS_FACEUP_DEFENSE) then if Duel.ChangePosition(e:GetHandler(),POS_FACEUP_DEFENSE) then
Duel.NegateActivation(ev) Duel.NegateActivation(ev)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:GetHandler():IsRelateToEffect(re) then
Duel.SendtoGrave(eg,REASON_RULE)
end
end end
end end
...@@ -70,4 +70,7 @@ function c66547759.distg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -70,4 +70,7 @@ function c66547759.distg(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function c66547759.disop(e,tp,eg,ep,ev,re,r,rp) function c66547759.disop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateActivation(ev) Duel.NegateActivation(ev)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:GetHandler():IsRelateToEffect(re) then
Duel.SendtoGrave(eg,REASON_RULE)
end
end end
...@@ -24,6 +24,9 @@ function c73026394.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -24,6 +24,9 @@ function c73026394.target(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function c73026394.activate(e,tp,eg,ep,ev,re,r,rp) function c73026394.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateActivation(ev) Duel.NegateActivation(ev)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:GetHandler():IsRelateToEffect(re) then
Duel.SendtoGrave(eg,REASON_RULE)
end
local g=Duel.GetMatchingGroup(c73026394.filter,tp,LOCATION_EXTRA,0,nil):RandomSelect(tp,1) local g=Duel.GetMatchingGroup(c73026394.filter,tp,LOCATION_EXTRA,0,nil):RandomSelect(tp,1)
Duel.SendtoGrave(g,REASON_EFFECT) Duel.SendtoGrave(g,REASON_EFFECT)
end end
...@@ -40,5 +40,8 @@ function c75487237.negcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -40,5 +40,8 @@ function c75487237.negcon(e,tp,eg,ep,ev,re,r,rp)
end end
function c75487237.negop(e,tp,eg,ep,ev,re,r,rp) function c75487237.negop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateActivation(ev) Duel.NegateActivation(ev)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:GetHandler():IsRelateToEffect(re) then
Duel.SendtoGrave(eg,REASON_RULE)
end
Duel.ChangePosition(e:GetHandler(),POS_FACEUP_DEFENSE) Duel.ChangePosition(e:GetHandler(),POS_FACEUP_DEFENSE)
end end
...@@ -131,6 +131,9 @@ function c7841112.negtg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -131,6 +131,9 @@ function c7841112.negtg(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function c7841112.negop(e,tp,eg,ep,ev,re,r,rp) function c7841112.negop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateActivation(ev) Duel.NegateActivation(ev)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:GetHandler():IsRelateToEffect(re) then
Duel.SendtoGrave(eg,REASON_RULE)
end
local g=Duel.GetMatchingGroup(Card.IsDestructable,tp,0,LOCATION_ONFIELD,nil) local g=Duel.GetMatchingGroup(Card.IsDestructable,tp,0,LOCATION_ONFIELD,nil)
Duel.Destroy(g,REASON_EFFECT) Duel.Destroy(g,REASON_EFFECT)
end end
......
...@@ -27,7 +27,7 @@ function c82744076.initial_effect(c) ...@@ -27,7 +27,7 @@ function c82744076.initial_effect(c)
Duel.AddCustomActivityCounter(82744076,ACTIVITY_ATTACK,c82744076.counterfilter) Duel.AddCustomActivityCounter(82744076,ACTIVITY_ATTACK,c82744076.counterfilter)
end end
function c82744076.counterfilter(c) function c82744076.counterfilter(c)
return c:IsType(TYPE_SYNCHRO) return c:IsType(TYPE_SYNCHRO)
end end
function c82744076.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c82744076.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetCustomActivityCount(82744076,tp,ACTIVITY_ATTACK)==0 end if chk==0 then return Duel.GetCustomActivityCount(82744076,tp,ACTIVITY_ATTACK)==0 end
...@@ -85,4 +85,7 @@ function c82744076.negtg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -85,4 +85,7 @@ function c82744076.negtg(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function c82744076.negop(e,tp,eg,ep,ev,re,r,rp) function c82744076.negop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateActivation(ev) Duel.NegateActivation(ev)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:GetHandler():IsRelateToEffect(re) then
Duel.SendtoGrave(eg,REASON_RULE)
end
end end
...@@ -65,6 +65,9 @@ function c94919024.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -65,6 +65,9 @@ function c94919024.target(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function c94919024.operation(e,tp,eg,ep,ev,re,r,rp) function c94919024.operation(e,tp,eg,ep,ev,re,r,rp)
if Duel.NegateActivation(ev) then if Duel.NegateActivation(ev) then
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:GetHandler():IsRelateToEffect(re) then
Duel.SendtoGrave(eg,REASON_RULE)
end
Duel.Recover(tp,1000,REASON_EFFECT) Duel.Recover(tp,1000,REASON_EFFECT)
Duel.Recover(1-tp,1000,REASON_EFFECT) Duel.Recover(1-tp,1000,REASON_EFFECT)
end 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