Outline the Game

Let’s think about how we can organize our code. To have made it this far in the book, you’ve written a lot of code. At times, it must have gotten difficult to move through the code to see what you’ve done. You’re not the first programmer to run into this problem, and you won’t be the last. Thankfully, you can learn from the mistakes of programmers before you.

Keep Your Code Organized

images/callout-icons/tip.png

Programming is hard enough on its own. Don’t make it harder by writing messy code. Organizing code doesn’t matter too much with short programs. But code grows as new stuff is added. Organized code—indented and with functions defined ...

Get 3D Game Programming for Kids, 2nd Edition 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.