summaryrefslogtreecommitdiff
path: root/src/gui/outfitwindow.cpp
diff options
context:
space:
mode:
authorJared Adams <jaxad0127@gmail.com>2010-08-15 21:28:10 -0600
committerJared Adams <jaxad0127@gmail.com>2010-08-16 13:19:09 -0600
commitd8d9232a67a03548b827bdb0515fe7a620a488f8 (patch)
treed6e0644f99e0ff89f9b320c0b479ba5a4e398125 /src/gui/outfitwindow.cpp
parenta6c2b90c2dabac18ad8052d948bc540406b3a613 (diff)
downloadmana-client-d8d9232a67a03548b827bdb0515fe7a620a488f8.tar.gz
mana-client-d8d9232a67a03548b827bdb0515fe7a620a488f8.tar.bz2
mana-client-d8d9232a67a03548b827bdb0515fe7a620a488f8.tar.xz
mana-client-d8d9232a67a03548b827bdb0515fe7a620a488f8.zip
Move more to the event system
Most of Net::InventoryHandler is now done through events. The ActorSpriteManager was also replaced by events. A few odds and ends were taken care of too. Reviewed-by: Bertram
Diffstat (limited to 'src/gui/outfitwindow.cpp')
-rw-r--r--src/gui/outfitwindow.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/gui/outfitwindow.cpp b/src/gui/outfitwindow.cpp
index ad3342ee..f16ebd39 100644
--- a/src/gui/outfitwindow.cpp
+++ b/src/gui/outfitwindow.cpp
@@ -171,7 +171,7 @@ void OutfitWindow::wearOutfit(int outfit)
if (item && !item->isEquipped() && item->getQuantity())
{
if (item->isEquipment())
- Net::getInventoryHandler()->equipItem(item);
+ item->doEvent("doEquip");
}
}
}
@@ -337,7 +337,10 @@ void OutfitWindow::unequipNotInOutfit(int outfit)
}
if (!found)
{
- Net::getInventoryHandler()->unequipItem(inventory->getItem(i));
+ Item *item = inventory->getItem(i);
+
+ if (item)
+ item->doEvent("doUnequip");
}
}
}