Summary

In this chapter we discovered C++ references that are special variables that act as an alias to another variable. When we pass a variable by reference instead of by value, then any work we do on the reference happens to the variable back in the calling function.

We also learnt about vertex arrays and created a vertex array full of quads to draw the tiles from a sprite sheet as a background.

The elephant in the room, of course, is that our zombie game doesn't have any zombies. Let's fix that now by learning about C++ pointers and the Standard Template Library.

Get Beginning C++ Game Programming now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.