When ChunksInROM is set to 0, collision fails. The issue stems from the lookup table. I'm unsure of why, but a dirty fix is to simply use vanilla Sonic 1's method of getting tile IDs:
Path: _incObj/sub FindNearestTile.asm
if ChunksInROM=1 ; Mercury Chunks in ROM
add.w d1,d1
move.w word_1E5D0(pc,d1.w),d1
else
andi.w #$FF,d1 ; MJ: keep within FF
lsl.w #7,d1 ; MJ: multiply by 80
endif
This, as the comments of the subroutine mentions, is unoptimal though.
Thank you for that catch. I tried convierting directly to Sonic 2's system like I did in my old build but it didn't work here. I've got some work to do in this area.
When ChunksInROM is set to 0, collision fails. The issue stems from the lookup table. I'm unsure of why, but a dirty fix is to simply use vanilla Sonic 1's method of getting tile IDs:
This, as the comments of the subroutine mentions, is unoptimal though.