Game Development Reference
In-Depth Information
ance information, and then load it in when the game is loaded. To serial-
ize/deserialize the JSON, the most popular library in C# is JSON.NET.
Once you get this working, you could move even more of the data (such
as level data or the button grid) into separate JSON files.
Summary
The sample game in this chapter was a culmination of many of the algorithms and
techniques discussed in the earlier chapters. A game object model was implemen-
ted (as in
Chapter 1
,
“
Game Programming Overview
”
), and the objects construct
their world transform matrix from a scale, rotation, and translation (as in
Chapter
mouse picking (as in
Chapter 8
). A* pathfinding is used to determine the paths of
the enemies as they travel toward the home base (as in
Chapter 9
). Finally, both
the input and UI systems implemented for
__Defense
are very similar to the sys-
tems discussed in
Chapters 5
and
10
,
respectively. Hopefully, the discussion in this
chapter has given you a sense of how you can make a more complex game now
that you've completed all the chapters of this topic.