Main Menu
Main Page
Forums
New pages
Recent changes
Random page
Help

Glitches
Arbitrary code execution
Pokémon cloning
Pomeg glitch and Glitzer Popping
Tweaking and voiding
Glitches by generation
Glitch categories

References/Resources
Databases
Disassembly projects
The Big HEX List
Pokémon cheat codes
Pokémon glitch terminology
Useful tools
More

Affiliates
Legendary Star Blob 2 (Hakuda) (日本語/Japanese)
Pokémon Speedruns wiki (English)
PRAMA Initiative (Français/French)
MissingNo. Glitch City (Italiano/Italian)
Become an affiliate!

Technical
Site source code

Search Wiki

 

Search Forums

 

Author Topic: Underlying glitch for "NPC and Cable Club lady glitch"  (Read 317 times)

0 Members and 1 Guest are viewing this topic.

bbbbbbbbba

  • Staff
  • *****
  • Offline Offline
  • ... but things won’t change if you don’t speak!
    • View Profile
Underlying glitch for "NPC and Cable Club lady glitch"
« on: February 21, 2019, 10:28:16 pm »
Today I was scanning through the Generation I natural glitches list when I realized something fishy about this one. The attached GIF begins at the exact point the NPC starts to move, not a moment earlier. Then I opened the YouTube video and saw that the glitch was reproduced from a specific save file.

After some failed attempts to reproduce this glitch, I realized that this glitch may only work from a save file.

From here it's easy to guess what really happened. The game was saved exactly at the frame when the walking NPC was ready to move, but hadn't decided in which direction yet. When the save file is loaded, both NPCs are loaded, but they are not correctly marked as visible. Since the walking NPC is updated first, if it decides to move up, the collision check isn't going to stop it.

I then found a way to semi-reliably reproduce this in an emulator. With the two NPCs adjacent to each other, begin frame advancing, watching the RAM address $C2x8 ("time until next step") of the walking NPC. When it becomes 0x01, begin holding Start. There is a one-frame delay for the Start menu, so when it pops up, the countdown will go to 0x00 exactly. Saving from this Start menu gives a save file from where this glitch may happen.

Of course, this doesn't only work in the Cerulean Pokémon Center, but in almost any place where two NPCs may go to the same square, and the NPC with lower ID (i.e. that is updated first) can walk. See attachment for an example in Pallet Town.

There is one more small question to ask. Why are the NPCs marked as invisible in the save file? Of course, because they are hidden by the Start menu. At this point I realized that it may not be necessary to have a save file after all. Sure enough, further testing showed that the glitch can also be triggered simply by bringing up the Start menu at the same exact frame to hide the NPCs, and then just closing it.

Presumably, if the "stationary" NPC is not hidden when the game is saved, then this glitch won't work. And this glitch may work in other situations where multiple NPCs are loaded at the same time; I haven't checked yet.


If everyone agrees that this is the same glitch as the current "NPC and Cable Club lady glitch", I'll probably edit the wiki and rename the page in a few days. Of course, if someone else would help me do it, I will be thankful. Further research is also welcome.

Evie the Mother Hen ☽ ❤

  • Head Administrator
  • *****
  • Offline Offline
  • Gender: Female
  • I love My Melody. 🦋 ✿
    • View Profile
Re: Underlying glitch for "NPC and Cable Club lady glitch"
« Reply #1 on: February 22, 2019, 06:05:19 am »
Wow, great research!

Yeah, this was one of those glitches that was reported by a friend of mine, but I knew nothing about. It's likely then it is the C2x8/Start menu/save glitch you describe. It may be good then to move it to a title such as "NPC walk through people glitch" or similar.

Edit: Please see https://glitchcity.info/wiki/NPC_collision_bypassing_glitches
« Last Edit: February 22, 2019, 06:33:33 am by Quirky Flower Chicken ❤✿ »

✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿
Here have some free flowers on every post :)
✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿



(Images © Sanrio, Nintendo, Pokémon, HAL Laboratory)

✿ Hi, I'm Evie. Transgender woman but spiritually doesn't believe 'male'/'female' needs to be defined; lives more stereotypically like a woman/I'm a 'girly' nerd who discovered herself. Call me whichever pronouns you like. :)

Feel free to contact me here about anything regarding the site.

Forgiveness. I feel that the more people pray to our greatest source/God/mathematical equality for world peace, the more and more it manifests into reality (until our next spiritual death).

Thank you Nyapon for this lovely artwork. :3

bbbbbbbbba

  • Staff
  • *****
  • Offline Offline
  • ... but things won’t change if you don’t speak!
    • View Profile
Re: Underlying glitch for "NPC and Cable Club lady glitch"
« Reply #2 on: February 22, 2019, 11:16:19 am »
Thanks!

I have edited a little to make the article clearer, and also included some new research about using the PC interface. It may also work with other text boxed, but they are harder to control.

Also, is there a page for the known glitch that NPCs get stuck when they walk upwards too far? (See: https://github.com/pret/pokered/blob/6ba3765c5932996f5da6417ae703794ff10bb1cb/engine/overworld/movement.asm#L644) This explains why the Cerulean Pokémon Center NPC would be completely stuck behind the Cable Club lady, instead of being able to walk left and right. The place he is stuck at is 4 steps above his initial position, which means that he would only be able to walk up or down, not left or right. (At 5 steps above the initial position, NPCs would only be able to walk up, not in any other direction, until they are completely stuck at 8 steps above the initial position.)

Evie the Mother Hen ☽ ❤

  • Head Administrator
  • *****
  • Offline Offline
  • Gender: Female
  • I love My Melody. 🦋 ✿
    • View Profile
Re: Underlying glitch for "NPC and Cable Club lady glitch"
« Reply #3 on: February 22, 2019, 11:25:01 am »
Thanks!

I have edited a little to make the article clearer, and also included some new research about using the PC interface. It may also work with other text boxed, but they are harder to control.

Also, is there a page for the known glitch that NPCs get stuck when they walk upwards too far? (See: https://github.com/pret/pokered/blob/6ba3765c5932996f5da6417ae703794ff10bb1cb/engine/overworld/movement.asm#L644) This explains why the Cerulean Pokémon Center NPC would be completely stuck behind the Cable Club lady, instead of being able to walk left and right. The place he is stuck at is 4 steps above his initial position, which means that he would only be able to walk up or down, not left or right. (At 5 steps above the initial position, NPCs would only be able to walk up, not in any other direction, until they are completely stuck at 8 steps above the initial position.)

You're welcome! :) Thank you!

Ah, I think I remember Crystal_ making a video about NPC movements. I don't think there is a page, feel free to add one. ^^

✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿
Here have some free flowers on every post :)
✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿



(Images © Sanrio, Nintendo, Pokémon, HAL Laboratory)

✿ Hi, I'm Evie. Transgender woman but spiritually doesn't believe 'male'/'female' needs to be defined; lives more stereotypically like a woman/I'm a 'girly' nerd who discovered herself. Call me whichever pronouns you like. :)

Feel free to contact me here about anything regarding the site.

Forgiveness. I feel that the more people pray to our greatest source/God/mathematical equality for world peace, the more and more it manifests into reality (until our next spiritual death).

Thank you Nyapon for this lovely artwork. :3