Skip to main content

Background Scrolling Data Info

TODO: Info for BG start position nybble. Would also be nice to know which BG speeds are all used.

Foregrounds and backgrounds scroll differently in many levels  sometimes they have a fast speed ratio and sometimes they can be completely static. This can be adjusted by hex editing your level.

  • Background only --> Change block 3 only.
  • Foreground only --> Change block 5 only.
  • Both --> Change both blocks 3 and 5.

NSMBe screenshot of the level hex editor open to block 5. The leftmost nybbles of byte 11 and 13 are labeled as "BG starting position" while the rightmost nybbles are labeled as "Speed".

  • Byte 11: Control BG horizontal scrolling.
  • Byte 13: Control BG vertical scrolling.

And for each byte:

  • First Nybble: Control where the background starts when the player enters the views.
  • Second Nybble: Control speed.

(Image source: MarioSunshine)

Scroll speed data
  • 0x0: Same as FG speed. Used in w2-3 (sewer level) for example.
  • 0x1: 50% FG speed.
  • 0x2: 25% FG speed. Common for top backgrounds.
  • 0x3: 12.5% FG speed. Common for bottom backgrounds.
  • 0x4: 120% FG speed. Unused.
  • 0x5: 75% FG speed.
  • 0x6: 6.25% FG speed.
  • 0x7: 9.375% FG speed.
  • 0x8: 20.3125% FG speed.
  • 0x9: Same as FG speed.
  • 0xA: Same as FG speed.
  • 0xB: Same as FG speed.
  • 0xC: Same as FG speed.
  • 0xD: 200% FG speed. Unused.
  • 0xE: 400% FG speed. Unused.
  • 0xF: 800% FG speed. Unused.

(Source: RoadrunnerWMC)

Disabling vertical scrolling

  • Background only --> Change both bytes 13 and 16 of block 3 only.
  • Foreground only --> Change both bytes 13 and 16 of block 5 only.
  • Both --> Change both bytes 13 and 16 of both blocks 3 and 5.

  • Byte 13: enters 40.
  • Byte 16: enters 10.

(Source: MeroMero)

Automatic horizontal scrolling

Works for both foregrounds and backgrounds.

It only works for backgrounds that already have a horizontal animation, this can be achieved by putting a value of 10 for byte 16 and it will animate the whole background instead of partially animating it.
(Note: if byte 13 value is somewhere between 40 and 4F, this effect will be overridden and instead the vertical scrolling will be disabled).
(Source: MeroMero)