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
Other glitch categories

References/Resources
Databases
Disassembly projects
The Big HEX List
Interactive tools
Reference documents
Terminology

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: Brock Through Walls addendums  (Read 274 times)

0 Members and 1 Guest are viewing this topic.

Evie the Bird Mother 🌸 ☽

  • Veteran Contributor
  • *
  • Offline Offline
  • Gender: Female
  • ああ、紅茶がおいしい。 ~ ^^
    • View Profile
Brock Through Walls addendums
« on: August 25, 2019, 11:58:54 pm »
As documented, Brock Through Walls will read your coordinates (if they align at xxx2, xxx6, xxxA, or xxxE) before reading the little endian script pointer that follows. But what exactly is this script pointer?

An answer to this can be found here:

https://github.com/pret/pokered/blob/6ba3765c5932996f5da6417ae703794ff10bb1cb/engine/overworld/pewter_guys.asm

Before the Pewter Gym guy (or Pewter Museum guy! hence the Yellow walk through walls glitch with him and TheZZAZZGlitch's recent finds) can walk their main paths, they must perform a smaller path based on the player's coordinates so that both the player and the NPC are guided correctly.

The actions in the scripts are based on a string of bytes terminated by 0xFF, such as:

.one
   db D_LEFT, D_DOWN, D_DOWN, D_RIGHT, $ff
.two
   db D_LEFT, D_DOWN, D_RIGHT, D_LEFT, $ff
.three
   db D_LEFT, D_LEFT, D_LEFT, $00, $00, $00, $00, $00, $00, $00, $00, $ff
.four
   db D_LEFT, D_LEFT, D_UP, D_LEFT, $ff
.five
   db D_LEFT, D_DOWN, D_LEFT, $00, $00, $00, $00, $00, $00, $00, $00, $ff

The actions seem to occur in reverse order. Hence, preliminary path one (facing Gym guide from left) is actually Right>Down>Down>Left.

As for the main paths, they appear to be stored in a special format so that Game Freak didn't have to write the same direction multiple times;

An example from; https://github.com/pret/pokered/blob/725b86ebbec23bd1f53fd60bf0201c904fee951d/engine/overworld/npc_movement.asm

RLEList_PewterMuseumGuy:

   db NPC_MOVEMENT_UP, $06
   db NPC_MOVEMENT_LEFT, $0D
   db NPC_MOVEMENT_UP, $03
   db NPC_MOVEMENT_LEFT, $01
   db $FF

; So the direction is defined, followed by a byte indicating how many times it must be taken.

When you follow the path, the directions are stored at a buffer from CCD3 (however directions are stored backwards; with the last at CCD3 or CCD4). It seems (??) this works with CD38 to determine which direction from the buffer to choose, which is decremented afterwards until CD38 is 0, and if you use a memory editor to change the CCD3 buffer while moving, you can temporarily create custom paths. However, it would seem because CD38 is one byte; paths can only be a maximum of one byte.

So it seems the Brock Through Walls paths (at least with the main non ACE method) are not a main glitch script pointer, but a glitch preliminary script pointer.

When the mass corruption occurs (including hold B for walk through walls), it is also because the CCD3 size is too large.

I tried creating an Oak Through Walls, but it appears he may work differently. I tried setting D5F0 (D5F1's Yellow equivalent) to 1 to enable the "Hey! Wait! Don't go out!" message (which is possible with expanded PC items) when entering Pallet Town, and I changed D35D (map) to 0x00 on Pewter City (which uses the same bank as Pallet Town so is safe even if you don't change D36D-E) on the same coordinates used for Brock Through Walls, then used 9F to load Pallet Town with those coordinates.

Surprisingly, after a while the Start menu opened like in Brock Through Walls. Sadly, possibly only the x-coordinate is checked here, and I couldn't find any walk through walls stuff. But x-coordinate 0x77 enabled me to fight a wild MissingNo. (like hooked Dragonite). It froze the game so I couldn't tell whether it was hooked or if you could fight it.

Additionally, in corrupting CD2D/CD2E with Brock Through Walls, we can get Pokémon normally unavailable with the Trainer escape glitch. https://forums.glitchcity.info/index.php?topic=8872.0
« Last Edit: August 26, 2019, 12:13:15 am by Princess Torchic Owl Lover ☽ ❤ »
(I was former joint head admin but stepped down)
✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿
Here have some free flowers on every post. ^^
✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿
Love, faith, hope are free. If all is lost friends save us.
Thanks fans for lovely Torchic artwork. ♡ First image thanks Nyapon.

Parzival

  • The Laziest Malware Enthusiast
  • Banned
  • *
  • Offline Offline
  • Gender: Male
  • who posted nudes in upstream
    • View Profile
    • (null)
Re: Brock Through Walls addendums
« Reply #1 on: August 26, 2019, 12:12:45 am »
You can't fight any of them as controls are disabled, it's stated in the video.

i'm also on keybase and bitchute but i don't have nifty buttons for those. Bitchute isn't ready yet, but will be eventually.

mood

Evie the Bird Mother 🌸 ☽

  • Veteran Contributor
  • *
  • Offline Offline
  • Gender: Female
  • ああ、紅茶がおいしい。 ~ ^^
    • View Profile
Re: Brock Through Walls addendums
« Reply #2 on: August 26, 2019, 12:14:58 am »
You can't fight any of them as controls are disabled, it's stated in the video.


Probably, but I wondered as the MissingNo. was for a bad Oak path, not Pewter Museum. Thanks though.
« Last Edit: August 26, 2019, 12:32:46 am by Princess Torchic Owl Lover ☽ ❤ »
(I was former joint head admin but stepped down)
✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿
Here have some free flowers on every post. ^^
✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿✿
Love, faith, hope are free. If all is lost friends save us.
Thanks fans for lovely Torchic artwork. ♡ First image thanks Nyapon.

Parzival

  • The Laziest Malware Enthusiast
  • Banned
  • *
  • Offline Offline
  • Gender: Male
  • who posted nudes in upstream
    • View Profile
    • (null)
Re: Brock Through Walls addendums
« Reply #3 on: August 26, 2019, 01:35:45 pm »
You can't fight any of them as controls are disabled, it's stated in the video.


Probably, but I wondered as the MissingNo. was for a bad Oak path, not Pewter Museum. Thanks though.
OH. my bad.

i'm also on keybase and bitchute but i don't have nifty buttons for those. Bitchute isn't ready yet, but will be eventually.

mood