Difference between revisions of "Beginner C++ Game Programming Tutorial 22"
From Chilipedia
(→Source Code Download) |
|||
| Line 11: | Line 11: | ||
== Source Code Download == | == Source Code Download == | ||
| − | [https://github.com/planetchili/snek Snek Repository] | + | [https://github.com/planetchili/snek Snek Repository]<br /> |
[https://github.com/planetchili/Fart-Annoyed Fart-Annoyed Repository] | [https://github.com/planetchili/Fart-Annoyed Fart-Annoyed Repository] | ||
Revision as of 01:17, 19 February 2017
We learn how to use enum to get rid of all the magic number bullshit for representing a number of options or states, and we learn how to use switch/case as an alternative to long if ... else chains. I also give the sermon on the mount (c:).
Topics Covered
- Declaring and using
enum class - Writing a
switchstatement - The evils of premature eja... optimization
Video Timestamp Index
Source Code Download
Snek Repository
Fart-Annoyed Repository
Homework
The goal for this video's homework is to modify apply the concepts learned in this tutorial to Fart-Annoyed.
The solution to this homework is coming soon.