summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorEugenio Favalli <elvenprogrammer@gmail.com>2006-06-27 19:27:44 +0000
committerEugenio Favalli <elvenprogrammer@gmail.com>2006-06-27 19:27:44 +0000
commit4cd69c6a9327108a07d282011c14562e57aa9e86 (patch)
tree32c1008319910385d7c84039be987208d69c1290 /src
parentfc328ac48b9ca8b4fff2878f37cc56795ed25dca (diff)
downloadmana-4cd69c6a9327108a07d282011c14562e57aa9e86.tar.gz
mana-4cd69c6a9327108a07d282011c14562e57aa9e86.tar.bz2
mana-4cd69c6a9327108a07d282011c14562e57aa9e86.tar.xz
mana-4cd69c6a9327108a07d282011c14562e57aa9e86.zip
Equipment window now show all the slots, and adapted visible shirts to head (middle) equipments.
Diffstat (limited to 'src')
-rw-r--r--src/being.cpp2
-rw-r--r--src/gui/equipmentwindow.cpp4
-rw-r--r--src/player.cpp3
3 files changed, 5 insertions, 4 deletions
diff --git a/src/being.cpp b/src/being.cpp
index 8963ed3c..f5d03563 100644
--- a/src/being.cpp
+++ b/src/being.cpp
@@ -304,7 +304,7 @@ void Being::setWeaponById(Uint16 weapon)
break;
default:
- logger->log("unknown item equiped : %d", weapon);
+ logger->log("Not a weapon: %d", weapon);
}
}
diff --git a/src/gui/equipmentwindow.cpp b/src/gui/equipmentwindow.cpp
index 1b9cfc55..fd979beb 100644
--- a/src/gui/equipmentwindow.cpp
+++ b/src/gui/equipmentwindow.cpp
@@ -39,7 +39,7 @@ EquipmentWindow::EquipmentWindow(Equipment *equipment):
Window("Equipment"), mEquipment(equipment)
{
setWindowName("Equipment");
- setDefaultSize(5, 230, 200, 90);
+ setDefaultSize(5, 230, 200, 120);
loadWindowState();
mItemset = ResourceManager::getInstance()->createSpriteset(
@@ -63,7 +63,7 @@ void EquipmentWindow::draw(gcn::Graphics *graphics)
// Rectangles around items are black
graphics->setColor(gcn::Color(0, 0, 0));
- for (int i = 0; i < 8; i++) {
+ for (int i = 0; i < EQUIPMENT_SIZE; i++) {
graphics->drawRectangle(gcn::Rectangle(10 + 36 * (i % 4),
36 * (i / 4) + 25, 32, 32));
diff --git a/src/player.cpp b/src/player.cpp
index 830c92aa..847137e0 100644
--- a/src/player.cpp
+++ b/src/player.cpp
@@ -131,7 +131,8 @@ void Player::draw(Graphics *graphics, int offsetX, int offsetY)
graphics->drawImage(playerset[mSex]->get(frame + 18 * dir),
px - 16, py - 32);
- Item *item = mEquipment->getEquipment(3);
+ // Display a shirt if equipped
+ Item *item = mEquipment->getEquipment(8);
if (item)
{
graphics->drawImage(equipmentset->get(frame + 18 * dir),