In this chapter, we're going to use a JSON configuration file to give enemies unique movement patterns and use an XML file to make our user interface text easily changeable. Adding movement patterns to enemies will make the game feel fairer to players instead of being purely random. This will also give us a way to easily add new content to the game without writing new code.
These two changes will also make the game updates and changes more accessible, allowing people who aren't programmers to work directly on the game.
Here's a rundown of the sections in this chapter:
JSON versus XML
Project updates
Understanding the JSON configuration file
Building the enemy spawner
Adding movement patterns to enemies
Updating
PlayState
Understanding the XML file
Pulling string data from XML
Replacing strings