Configuration Tips

As you get further into the quarter, you will likely find that you have a variety of configuration parameters for your game. These can range from paths to data (e.g., models, audio clips, images, etc.) to network configuration (e.g., IP addresses and ports) and values associated with game play (e.g., movement values, initial positions, number of objects, etc.). We can think of these as being global variables in the program, and early on it's convenient to set these parameters by changing their values in the source and recompiling.

Later in the quarter you will likely want to experiment with different values and perhaps change them every time you run the program. Rather than re-compiling, you can instead use configuration files and incorporate a library that reads, parses, and sets values from a configuration file when the program runs. There are many configuration libraries available, and choosing which one to use mostly depends on what you want the format of the configuration file to be. Below are links to a variety of configuration libraries, but you can also find more by searching online.