Glitch City Laboratories Archives

Glitch City Laboratories closed on 1 September 2020 (announcement). This is an archived copy of a thread from Glitch City Laboratories Forums.

You can join Glitch City Research Institute to ask questions or discuss current developments.

You may also download the archive of this forum in .tar.gz, .sql.gz, or .sqlite.gz formats.

Generation II Glitch Discussion

Tile 0x3E bump noise glitch - Page 1

Tile 0x3E bump noise glitch

Posted by: Torchickens
Date: 2018-03-23 17:51:16
Is anybody able to replicate this?


No bump noise if standing on tile $3E
This is a bug with DoPlayerMovement.CheckWarp in engine/player_movement.asm:

; Bug: Since no case is made for STANDING here, it will check
; [.edgewarps + $ff]. This resolves to $3e at $8035a.
; This causes wd041 to be nonzero when standing on tile $3e,
; making bumps silent.

ld a, [wWalkingDirection]
; jr z, .not_warp
ld e, a
ld d, 0
ld hl, .EdgeWarps
add hl, de
ld a, [wPlayerStandingTile]
cp [hl]
jr nz, .not_warp

ld a, 1
ld [wd041], a
ld a, [wWalkingDirection]
; This is in the wrong place.
jr z, .not_warp

I don't quite know how to replicate this bug and what type of tile or event the page is referring to here.
(Is it to do with things like exit mat warps?)

However the 0x3E sub-tile varies between tilesets and can easily be found with BGB.



When I lock D041 to 01 the bump sound for touching a wall still persists. Setting a breakpoint to D041 on read confirms it is read while touching a wall or using a warp though.

I tried bumping into a wall while I was standing on a tree (which contains the 0x3E sub-tile on the bottom-right) but with no luck unfortunately, the 'bump' noise still occurred.

I wonder if 'tile' could be referring to objects that consist of the 'sub-tiles' in a 2x2 pattern like the sub-tiles on the VRAM viewer in the image above, but haven't been able to test if you can manipulate those. I imagine though that these may be arranged in blocks, as was the case in Generation I.

This glitch block top-left edited in is the first block, the tall grass block the second block, the greenery the third block, greenery on the left and bushes on the right the fourth block and so on.