diff options
Diffstat (limited to 'src/shopitem.cpp')
-rw-r--r-- | src/shopitem.cpp | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/src/shopitem.cpp b/src/shopitem.cpp index 00875a2d..ee55799f 100644 --- a/src/shopitem.cpp +++ b/src/shopitem.cpp @@ -1,9 +1,8 @@ /* - * Aethyra + * The Mana World * Copyright (C) 2004 The Mana World Development Team * - * This file is part of Aethyra based on original code - * from The Mana World. + * This file is part of The Mana World. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -22,19 +21,22 @@ #include "shopitem.h" -#include "utils/stringutils.h" +#include "units.h" -ShopItem::ShopItem (int inventoryIndex, int id, int quantity, int price) : +ShopItem::ShopItem (int inventoryIndex, int id, + int quantity, int price) : Item (id, 0), mPrice(price) { - mDisplayName = getInfo().getName() + " (" + toString(mPrice) + " GP)"; + mDisplayName = getInfo().getName() + + " (" + Units::formatCurrency(mPrice).c_str() + ")"; setInvIndex(inventoryIndex); addDuplicate(inventoryIndex, quantity); } ShopItem::ShopItem (int id, int price) : Item (id, 0), mPrice(price) { - mDisplayName = getInfo().getName() + " (" + toString(mPrice) + " GP)"; + mDisplayName = getInfo().getName() + + " (" + Units::formatCurrency(mPrice).c_str() + ")"; setInvIndex(-1); addDuplicate(-1, 0); } @@ -80,4 +82,3 @@ int ShopItem::sellCurrentDuplicate(int quantity) } return sellCount; } - |