Skip to content

Commit d276c66

Browse files
authored
"Card.NegateEffects" update
Fixed an issue where if the effects of a Trap Monster that is still a Trap were negated the negation effect would wear off when the Trap Monster was placed in the Spell & Trap Zone.
1 parent ebf5fc9 commit d276c66

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

utility.lua

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -767,6 +767,8 @@ end
767767
function Card.NegateEffects(tc,c,reset,negates_cards,ct)
768768
if not reset then reset=RESET_EVENT|RESETS_STANDARD end
769769
reset=reset|(RESET_EVENT|RESETS_STANDARD)
770+
local trap_monster_chk=negates_cards and tc:IsType(TYPE_TRAPMONSTER)
771+
if trap_monster_chk then reset=reset&~(RESET_TOFIELD|RESET_LEAVE|RESET_TURN_SET) end
770772
if not ct then ct=1 end
771773
Duel.NegateRelatedChain(tc,RESET_TURN_SET)
772774
--Negate its effects
@@ -780,7 +782,7 @@ function Card.NegateEffects(tc,c,reset,negates_cards,ct)
780782
e2:SetCode(EFFECT_DISABLE_EFFECT)
781783
e2:SetValue(RESET_TURN_SET)
782784
tc:RegisterEffect(e2)
783-
if negates_cards and tc:IsType(TYPE_TRAPMONSTER) then
785+
if trap_monster_chk then
784786
local e3=e1:Clone()
785787
e3:SetCode(EFFECT_DISABLE_TRAPMONSTER)
786788
tc:RegisterEffect(e3)

0 commit comments

Comments
 (0)