A downloadable game for Windows

  • The purpose of this was to create a binary file format from the existing human readable format and use it.
  • I moved my existing Lua loading files to cGeeometryBuilder inside the .cpp class and write the data received into binary after converting it to a .bin format. I use ofstream::write to write binary data.
  • I am using uint16_t to save the vertex and index format, and using an s3dobject for the vertex data, and an array of uint16_t for the index data. Im using uint16 because it auto aligns the data we get from the binary file so we dont need to manually align our data.

Here is how I extract data from the binary chunk and store it locally:

The two advantages I found to using this binary file format as opposed to the traditional LUA file format are:

  • It highly reduces the size of the file(mine went from 180 bytes to 46 bytes).
  • Overhead time is lesser so by extension the time to build the assets to and hence the time when the game starts will be a lot faster with binary as opposed to LUA file format in this context. File formats like LUA are still important because we need file formats that are easy to use and readable, which is why they are still in our game, but at run time we can convert them to binary and load that using a builder to make our program faster to run.

Download

This game is currently unavailable

Leave a comment

Log in with itch.io to leave a comment.