When you play most games, you're typically attacked by hordes of hostile aliens, trolls, pushy insurance salespeople, or whatever. For each individual character, your game must declare a variable. That can add up to a lot of variables. Wouldn't it be nice if C++ offered an easy way to declare a group of variables all of the same type? Well, as a matter of fact, C++ provides arrays for just that purpose.
|