Pikachu glitch emote ACE set up with ws m (Yellow only)

1,862 views · Published 21 April 2015 · 12:50 · Indexed 22 September 2026

Channel: Evie (ChickasaurusGL) 🌺 · 2015 · Gaming

Watch on YouTube

Read description for more information:
A novelty arbitrary code execution method. I don't know how to do it without another form of arbitrary code execution, but I thought I'd document it because I thought it was interesting.

The address D49B gives Pikachu a special emote. Normal values range from 01-05 and include 'wink and hand up' (appears after catching a Pokémon), 'bucket' (appears after fishing), 'puzzled' (appears during the Bill's house event I think), 'disapproval' (appears when you try to give a Thunderstone to a normal walking Pikachu). and 'thunder' (appears after Pikachu learns Thunderbolt or Thunder). After you walk a few steps you have to repeat the relevant action to see the emote again.

Values in D49B greater than 05 are glitch emotes; some of which cause the game to execute code in writable memory. Some bring up a text box or emote box, others do not.

The FF glitch emote (appearing as a copy of 01 for me) is probably accessible with the Pikachu off-screen glitch (video: https://www.youtube.com/watch?v=l7FBp1BOEM0), but I unfortunately don't know how to access a suitable glitch emote with that.

In this video I use ws m to:
1) Set D49B to 1A which executes code at D513 when you talk to Pikachu.
2) Write 3E 15 EA 58 D0 C9 into D513; code that will give me Mew.
3) Write 05 58 D0 at D14F. This is required to avoid a freeze for reasons I don't know; other than the game ends up executing D14F at some point.

I decided to store my code (42 bytes) at DC01 (in stored Pokémon 12's data but does not interfere with the ws m set up) and then execute it.

This was my procedure which you can replicate, which involves writing the data byte by byte and executing it later.

1) Have Pikachu following you.
2) Have a relevant payload to redirect ws m from stored Pokémon data into your items. My save file still had the old set up as can be found here (http://forums.glitchcity.info/index.php/topic,6638.msg189586.html#msg189586), but you can probably use this simpler set up http://forums.glitchcity.info/index.php?topic=6638.120

3) Prepare the following items:
:-Items in position 1 and 2 that can be tossed. You can have item 1 quantity ('value') as FF to start, so that you can choose almost any value (1-255) for your first byte by tossing from FF. Item 2's quantity should be 01 if you want to write your code at DC01.

:-Items 3 onward:
Carbos x220
TM50 x32
TM11 x111
Poké Ball x250
Repel x211
Ice Heal x119
Carbos x211
X Accuracy x32
Full Heal x11
Lemonade x255
Fresh Water x4
TM34 x30
TM11 x 201
TM33 x 201
ws m x(anything)

i.e. 26 DC FA 20 D3 6F 04 FA 1E D3 0D 77 26 D3 2E 20 34 0B 3E FF 3C 04 EA 1E D3 C9 E9 C9 63 01

4) Toss all but one of item 2 (note: here I'm referring to the actual item 1 and item 2, not the second item starting from item 3 I wanted to be clear to avoid potential confusion). Then make item 1's quantity (in hexadecimal), be the first value of the following code (i.e. C3, so you should have 195 left). If you had 255 of item 1 initially you'd need to toss 60. Use ws m to write your first byte at DC01.

Code:
C3 0D DC 05 58 D0 3E 15 EA 58 D0 C9 01 03 00 21
04 DC 11 4F D1 CD B5 00 01 06 00 21 07 DC 11 13
D5 CD B5 00 3E 1A EA 9B D4 C9

5) Item 2's quantity will increase. This means you're ready to write the second byte (0D) and using ws m again would let you write the third byte, and so on. Don't change item 2 quantity from now on (however, you can decrease it by 1 if you accidentally wrote the wrong byte so you can write it again), because this controls where in the code we're at e.g. second byte=02). Also, item 1's quantity will be raised to 0 (i.e. 256) so you can write any value, this time including 0.

Change item 1 quantity to 0D (13 in decimal) and use ws m. Repeat this process for bytes 3 (DC) through 42 (C9), and be careful to write the correct values. This will take some time.

Example: For byte 3, assuming you have 0 of item 1, you do hex:100 (dec:256)-hex:DC (dec:220)=toss 36.

6) Prepare these items from item 3 (you should not need to get any more):

i3. Carbos x220 (from the old code)
i4. X Accuracy x1 (you can toss from your existing stack of 32)
i5. TM33 x201 (in the old code but unused until now)

7) Use ws m with the set up in step 6, don't move, and then talk to Pikachu. He should trigger a Mew encounter! You can get another Mew encounter if you talk to him again after the battle ends. But if you want to get another Mew after walking you need to use ws m again (however, you don't need to do steps 2-6 again).

Codes in ASM, annotated.
http://i3.minus.com/ibdSllCap9V8PS.png

Note: At 11:57 I unintentionally showed off an unrelated glitch. Whenever a Pokémon uses Transform (including Mew or Pokémon that used it via Mirror Move), it will become a Ditto, so I caught a "Mew" that became Ditto. If a wild Mew encountered with this glitch (or the Trainer-Fly Mew glitch etc.) doesn't use Transform, it won't become a Ditto.

More from this channel