Write Up 05





Game running at default resolution:


























Game running at 128 x 128 resolution:





Press Escape to quit the application.

The main objective of Assignment05 was integrating lua functionality for generating assets. In this case, lua was used to generate the vertex and fragment shaders.

It was required to complete the definition of lua functions from C to allow a settings.ini file generated in the output directory to be copied to the game install directory. This allows the user to open the settings.ini file to adjust the resolution width and height of the game without having to recompile the game itself. I find it to be very useful from the use’s perspective as I have had to make adjustments in some cases to the screen resolution of games I have played. One example that comes to mind is the PC port of Devil May Cry 3 that came with many issues, including a locked screen resolution. However, in the game’s install directory, I could change the dmc3se.ini file to adjust the screen width and height resolution to get the resolution I wanted.

Compiled AssetBuildFunctions.lua from Release x64 build:

The benefits of having the compiled lua file is that lua source code is compiled into lua byte code which is smaller than text and faster to execute. Another benefit is that compiling the file before running it can also catch errors thought it should not be relied upon due to the fact that many errors will not show themselves until a script is actually run.

A disadvantage to this that I can think of is that if the amount of lua files to compile increases, the total program compilation time will increase too. 

The settings.ini file does not need to be compiled because if it was then the output would be in byte code which is not user friendly.

The time it took me to complete this assignment was 10 hours.

© Jean-Paul Peschard. Proudly created with Wix.com