summaryrefslogtreecommitdiff
path: root/src/gui/charcreatedialog.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-07-17 23:26:59 +0300
committerAndrei Karas <akaras@inbox.ru>2012-07-17 23:26:59 +0300
commit7e0a97d2521b9ce57003176e82a0b5564aa003c2 (patch)
tree5b2cfe1afe09bea1063f783050c1fb549daee76d /src/gui/charcreatedialog.cpp
parentf68cbf700a99f2f184715a5b8025bcb4b6525391 (diff)
downloadplus-7e0a97d2521b9ce57003176e82a0b5564aa003c2.tar.gz
plus-7e0a97d2521b9ce57003176e82a0b5564aa003c2.tar.bz2
plus-7e0a97d2521b9ce57003176e82a0b5564aa003c2.tar.xz
plus-7e0a97d2521b9ce57003176e82a0b5564aa003c2.zip
Fix more code style and additional warnings.
Diffstat (limited to 'src/gui/charcreatedialog.cpp')
-rw-r--r--src/gui/charcreatedialog.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gui/charcreatedialog.cpp b/src/gui/charcreatedialog.cpp
index 5611efa4c..b71b812d2 100644
--- a/src/gui/charcreatedialog.cpp
+++ b/src/gui/charcreatedialog.cpp
@@ -63,7 +63,7 @@ const static Being::Action actions[] =
Being::STAND, Being::SIT, Being::MOVE, Being::ATTACK, Being::DEAD
};
-const static int directions[] =
+const static uint8_t directions[] =
{
Being::DOWN, Being::RIGHT, Being::UP, Being::LEFT
};
@@ -282,7 +282,8 @@ void CharCreateDialog::action(const gcn::ActionEvent &event)
#endif
Net::getCharHandler()->newCharacter(getName(), characterSlot,
- mFemale->isSelected(), mHairStyle, mHairColor, mRace, atts);
+ mFemale->isSelected(), mHairStyle, mHairColor,
+ static_cast<uint16_t>(mRace), atts);
}
else
{
@@ -543,7 +544,7 @@ void CharCreateDialog::updateRace()
mRace = -100 - id;
}
- mPlayer->setSubtype(mRace);
+ mPlayer->setSubtype(static_cast<uint16_t>(mRace));
const ItemInfo &item = ItemDB::get(id);
mRaceNameLabel->setCaption(item.getName());
mRaceNameLabel->adjustSize();