J
junkmonkey
Hey everyone. This is much more of a general question than a
code-specific one. For class, I need to write a text-based adventure
game. I know that I will be using classes to implement different
aspects of the game (player, rooms, traps, etc.) and was wondering what
are the limitations on classes. As of now, I know they basically
define a user-defined type, and have elements of that type. These
members can also be used in class specific functions called methods. I
guess what I'm getting at is how do I know what to make a class, and
what to make a simple variable. Secondly, how do I use pointers to
navigate from room to room?
Sorry about the broadness of this question, but I've been perusing
my notes and my understanding of classes is within my grasp, but
something fundamental is ultimately missing. Thanks again!
~junk
code-specific one. For class, I need to write a text-based adventure
game. I know that I will be using classes to implement different
aspects of the game (player, rooms, traps, etc.) and was wondering what
are the limitations on classes. As of now, I know they basically
define a user-defined type, and have elements of that type. These
members can also be used in class specific functions called methods. I
guess what I'm getting at is how do I know what to make a class, and
what to make a simple variable. Secondly, how do I use pointers to
navigate from room to room?
Sorry about the broadness of this question, but I've been perusing
my notes and my understanding of classes is within my grasp, but
something fundamental is ultimately missing. Thanks again!
~junk