Substitute drain move not missing glitch

From Glitch City Wiki
Revision as of 09:08, 20 January 2017 by >ISSOtm (Created the page for the glitch.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Miscellaneous glitches of Pokémon Red and Blue and Pokémon Yellow

Amazing Man (Red and Blue only) | Cable Club escape glitch | Celadon looping map trick | Champion Blue music muting glitch | Coastal Flooding | Confusion and Substitute glitch | Cooltrainer move | Cycling based glitch maps | Escape sprite handling glitch | Evolve without an evolutionary stone (Red and Blue only) | Evolving Raichu (Red and Blue only) | Expanded item pack | Expanded Pokédex | Focus Energy glitch | Get stuck in a wall | Ghost Bicycle glitch | Glitch encounter system | Glitch City RAM Manipulation | Infinite Blaine Door | Introduction Nidorino glitch (Red and Blue only) | Invisible PCs (Red and Blue only) | Invisible tree glitch | Item stack duplication glitch | Mute the music in the Pokémon League | Partial trapping move link battle glitch | Pokémon Tower Pokédex glitch | PP underflow glitches | Recovery move glitch | Rival's effect | See a Ghost without a Silph Scope | Selfdestruct and Substitute glitch | Silph Co. PC Glitch | Slot machine glitch | Stand on a tree | Statue behavior glitch (Red and Blue only) | Super effective move AI flaw (Red and Blue only) | Super Glitch | Surf down glitch | Swift miss glitch | Transform assumption glitch | Transform Empty Move Glitch | Trick Zone | Vending machine purchase glitch | Walk around with only fainted Pokémon (Red and Blue only) | Walking lag glitch | Walk on water through Surf | Walking Pikachu happiness glitch (Yellow only) | Wild appeared! | ZZAZZ Glitch

(view, talk, edit)

The Substitute drain move not missing is a minor battle glitch in English Pokémon Red, Blue, and Yellow, where HP draining moves don't miss against a Subsitute, even though they should (and they do in Pokémon Red, Green, and Pokémon Blue (Japanese) as well as in Pokémon Yellow (Japanese)).


How to perform

When a Pokémon is under the effect of the attack Substitute and the opposing Pokémon uses an HP-draining move (such as Absorb, Mega Drain or Dream Eater), the move may hit.

Note that this glitch does not exist in any of the Japanese games.


Involved code

Source : Pokéred, Pokéyellow

 	ld a,[de]
 	cp a,SWIFT_EFFECT
 	ret z
 	call CheckTargetSubstitute
 	jr z,.checkForDigOrFlyStatus
 	cp a,DRAIN_HP_EFFECT
 	jp z,.moveMissed
 	cp a,DREAM_EATER_EFFECT
 	jp z,.moveMissed
 .checkForDigOrFlyStatus

[de] contains the move effect, which makes the SWIFT_EFFECT check successful.

However, CheckTargetSubstitute overwrites a with either 0 or 1, so the following comparisons fail.


Video demonstration

YouTube video by ChickasaurusGL