Bunker Bustin' Level Code Optimizer


About

Bunker Bustin' is the "twelfth and final game in [of the] 12 months Dev Diary challenge", developed by Ben "Yahtzee" Croshaw (link). The game features a level editor, where a level can be shared via a string of characters, so called "level codes".

This small application allows you to optimize these level codes, shortening them while still being perfectly interpreted by the game. The optimization is done by correcting a flaw with the level code generation, and exploiting some quirks of the game's interpretation logic.

To understand what is being optimized, it is important to know how a level codes is generated, and what quirks exists in the level generation code. Yahtzee goes into great detail how the level code generation works in his final installment of the first Dev Diary video series. However, it is never mentioned that the 16×9 level grid actually stored as a 17×10 grid. Optimizations can be performed due to this flaw.

In summary, here are the optimization strategies:

  • Discard the last row of the level.
  • Replace the last tile of each row to the tile before it.
  • Ignore material changes if a tile is empty.
  • Disregard the first material and/or shape for for the first tiles if they are of grey material and/or empty tiles.

Source code for this tool can be found here. Optimization tool created by @vladdeSV, in no affiliation with the game developer or game publisher.