diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | src/gui/buy.cpp | 10 |
2 files changed, 10 insertions, 5 deletions
@@ -1,5 +1,10 @@ 2008-08-17 Lloyd Bryant ("Sanga") <sanga@aethyra.com> + * Correctly show GP remaining after buying from NPC + vendor (from TMW svn, r4449) + +2008-08-17 Lloyd Bryant ("Sanga") <sanga@aethyra.com> + * Fixed issues with unequipping some arrows failing. * Removed hard-coded item ID's from several files diff --git a/src/gui/buy.cpp b/src/gui/buy.cpp index 0e48ea29..8e2a7a7a 100644 --- a/src/gui/buy.cpp +++ b/src/gui/buy.cpp @@ -171,15 +171,15 @@ void BuyDialog::action(const gcn::ActionEvent &event) outMsg.writeInt16(mAmountItems); outMsg.writeInt16(mShopItems->at(selectedItem)->getId()); - // Reset selection - mAmountItems = 1; - mSlider->setValue(1); - mSlider->gcn::Slider::setScale(1, mMaxItems); - // Update money and adjust the max number of items that can be bought mMaxItems -= mAmountItems; setMoney(mMoney - mAmountItems * mShopItems->at(selectedItem)->getPrice()); + + // Reset selection + mAmountItems = 1; + mSlider->setValue(1); + mSlider->gcn::Slider::setScale(1, mMaxItems); } } |