diff options
Diffstat (limited to 'src/items.h')
-rw-r--r-- | src/items.h | 51 |
1 files changed, 28 insertions, 23 deletions
diff --git a/src/items.h b/src/items.h index 1b973566..99afba3f 100644 --- a/src/items.h +++ b/src/items.h @@ -31,29 +31,34 @@ */ class Item : public Object { - //Item type - unsigned int type; - - public: - /** - * Enumeration of available Item types. - */ - enum { - Usable, - Equipment - }; - - virtual ~Item() throw() { } - - /** - * The function called to use an item - */ - void use(); - - /** - * Return type of item - */ - unsigned int getType() { return type; } + public: + /** + * Enumeration of available Item types. + */ + enum { + Usable, + Equipment + }; + + Item(int type, int id): + Object(type, id) + {} + + virtual ~Item() throw() { } + + /** + * The function called to use an item + */ + void use(); + + /** + * Return type of item + */ + unsigned int getType() const { return type; } + + private: + //Item type + unsigned int type; }; #endif |