Commit 9bb0b59b

fix drawing after re-setting floor dimensions, improve debugging output, style changes

Does the above and also adds the implementation of the aforementioned WallManager – the file was apparently not staged to be added in the previous commit. Similar to the TileManager it is intended to keep a state of all the walls that exist. This change also includes a WallType, similar to TileTypes that define basic properties like a name and file path to the texture selected. The WallManager adds two additional dimensions though that the tiles do not care about:

  • Position – as in TOP, BOTTOM, LEFT, RIGHT on a given tile
  • Side – which side of a wall are we referring to, we want to be able to assign different WalllTypes to either side

By default a single WallType (“blank”) is defined which sports a concrete texture. Internally, when a wall is being added we merely add this default type on both sides (see above) to the wall data. If the wall is being removed the value is set back to 0. Assigning a new WallType (or in gameplay speech) putting a new wallpaper on a wall means resetting it to 0.

Leave a Reply

Your email address will not be published. Required fields are marked *