Closed Xanthus1 closed 7 months ago
Hmm, it doesn't seem like there's a clear pattern to how much you have to subtract (or add) to get the correct value.
<Room:00-00-0C>, layer 1, scroll mode 0x0D, height difference 0x200
<Room:00-00-0F>, layer 2, scroll mode 0x0D, height difference 0x80
<Room:00-00-14>, layer 2, scroll mode 0x0D, height difference 0x40
<Room:00-00-17>, layer 2, scroll mode 0x0D, height difference -0xA0
<Room:00-00-19>, layer 1, scroll mode 0x0D, height difference 0x50
<Room:00-00-1A>, layer 2, scroll mode 0x0D, height difference 0x00
<Room:00-00-26>, layer 2, scroll mode 0x0D, height difference 0x80
<Room:00-01-05>, layer 1, scroll mode 0x0D, height difference 0xC0
<Room:00-01-05>, layer 2, scroll mode 0x0D, height difference 0xC0
<Room:00-01-06>, layer 1, scroll mode 0x0D, height difference 0x100
<Room:00-01-06>, layer 2, scroll mode 0x0D, height difference 0x100
<Room:00-02-01>, layer 1, scroll mode 0x0D, height difference 0x40
<Room:00-02-01>, layer 2, scroll mode 0x0D, height difference 0x40
<Room:00-02-0A>, layer 1, scroll mode 0x0D, height difference 0x40
<Room:00-02-0A>, layer 2, scroll mode 0x0D, height difference 0x40
<Room:00-04-01>, layer 2, scroll mode 0x0D, height difference 0x80
<Room:00-04-03>, layer 2, scroll mode 0x0C, height difference 0xE8
<Room:00-04-04>, layer 2, scroll mode 0x0C, height difference 0x30
<Room:00-04-11>, layer 2, scroll mode 0x0C, height difference 0x80
<Room:00-05-02>, layer 2, scroll mode 0x0D, height difference 0x00
<Room:00-05-03>, layer 2, scroll mode 0x0D, height difference 0x00
<Room:00-07-00>, layer 1, scroll mode 0x0C, height difference 0x80
<Room:00-07-0A>, layer 1, scroll mode 0x0C, height difference 0x30
<Room:00-07-0A>, layer 2, scroll mode 0x0C, height difference 0x30
<Room:00-07-0B>, layer 1, scroll mode 0x0C, height difference 0x30
<Room:00-07-0B>, layer 2, scroll mode 0x0C, height difference 0x30
<Room:00-07-11>, layer 2, scroll mode 0x0D, height difference 0x80
<Room:00-07-13>, layer 2, scroll mode 0x0D, height difference 0x30
<Room:00-07-19>, layer 2, scroll mode 0x0D, height difference 0x100
<Room:00-07-1D>, layer 2, scroll mode 0x0D, height difference 0x30
<Room:00-07-21>, layer 2, scroll mode 0x0D, height difference 0x30
<Room:00-07-2B>, layer 1, scroll mode 0x0C, height difference 0x50
<Room:00-07-2D>, layer 2, scroll mode 0x0D, height difference 0xAC
<Room:00-09-01>, layer 2, scroll mode 0x0D, height difference 0x00
<Room:00-09-17>, layer 2, scroll mode 0x0D, height difference 0x40
<Room:00-0A-02>, layer 2, scroll mode 0x0C, height difference 0x40
<Room:00-0A-09>, layer 1, scroll mode 0x0C, height difference 0x30
<Room:00-0A-09>, layer 2, scroll mode 0x0C, height difference 0x30
<Room:00-0A-0B>, layer 1, scroll mode 0x0C, height difference 0x30
<Room:00-0A-0B>, layer 2, scroll mode 0x0C, height difference 0x30
<Room:00-0B-1F>, layer 1, scroll mode 0x0C, height difference 0x30
<Room:00-0B-1F>, layer 2, scroll mode 0x0C, height difference 0x30
<Room:00-0B-25>, layer 1, scroll mode 0x0C, height difference 0x30
<Room:00-0B-25>, layer 2, scroll mode 0x0C, height difference 0x30
I might need to disable recalculating the height in pixels for layers with certain scroll modes and have the user manually input the value depending on how much they want the layer to scroll.
0851C32C
or0851C4CC
that have scroll modes0xC
or0xD
with no edits, there would be gaps in the background introduced in game play.I spot checked some of the layers with 0xC and 0xD scroll modes, and found they used a slightly lesser
height_in_pixels
setting that actually affects how it displays. Tested with this code and it fixed those issues.