Okay, maybe we could actually HELP the poor fellow.
But first, what are you doing, none bothred to ask that.
Mabe you should make classes for the objects FIRST and then slap them into you're room
Also, maybe you should do without rooms for now. It would do better for a learning
expirance to just wok on the basics. I'm working on a text based
RPG right now, I have classes for all types of items, then classes
n'such for spells and crap like that. You should work on the little
stuff before you write the big stuff. Like, for examle, the ellefant
wasn't made all at once. It's made up of tiny cells, that make bigger cells that make bigger cells. In a similer way you should
make classes that are used in other classes and more and more
like this
Code:
class WEAPON {
//weapon code
};
class ARMOR {
//armor code
};
class POTION {
//potion code
};
class ITEM {
int type // 0 for potion 1 for weapon....
POTION P;
WEAPON W;
ARMOR A;
};
class INV {
ITEM Items[5];
long GOLD;
//..........
};
class PLAYER {
INV Invintory;
int HP, CON, DEX, STR, WIS, CHA, INT, MANNA, ....
};
See what I mean... Don't make the player before you make the ARMOR.