diff options
Diffstat (limited to 'src/core/item.cc')
-rw-r--r-- | src/core/item.cc | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/core/item.cc b/src/core/item.cc index a6cc89f..3528c1a 100644 --- a/src/core/item.cc +++ b/src/core/item.cc @@ -16,6 +16,7 @@ Item::Item(const Info *info) { item_info = info; item_amount = 0; + item_price = 0; } Item::~Item() @@ -29,5 +30,20 @@ void Item::set_amount(const int amount) item_amount = amount; } +void Item::inc_amount(const int amount) +{ + item_amount += amount; +} + +void Item::dec_amount(const int amount) +{ + item_amount -= amount; +} + +void Item::set_price(const long price) +{ + item_price = price; +} + } // namespace core |