summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-04-15 13:52:07 +0300
committerAndrei Karas <akaras@inbox.ru>2015-04-15 13:52:07 +0300
commite39ac061384a0877367b9a7fbd24b1a01626be3d (patch)
treea1de64c672bbdc8fc57aa5e08651bf8892057498 /src
parenta239e426893cb1526769bb65719f9bb673ea14a4 (diff)
downloadmanaplus-e39ac061384a0877367b9a7fbd24b1a01626be3d.tar.gz
manaplus-e39ac061384a0877367b9a7fbd24b1a01626be3d.tar.bz2
manaplus-e39ac061384a0877367b9a7fbd24b1a01626be3d.tar.xz
manaplus-e39ac061384a0877367b9a7fbd24b1a01626be3d.zip
Remove hideShield setting.
Diffstat (limited to 'src')
-rw-r--r--src/configuration.cpp1
-rw-r--r--src/defaults.cpp1
-rw-r--r--src/gui/widgets/tabs/setup_other.cpp4
-rw-r--r--src/net/ea/beinghandler.cpp2
-rw-r--r--src/net/ea/beinghandler.h1
-rw-r--r--src/net/eathena/beinghandler.cpp19
-rw-r--r--src/net/eathena/charserverhandler.cpp4
-rw-r--r--src/net/tmwa/beinghandler.cpp25
-rw-r--r--src/net/tmwa/charserverhandler.cpp18
9 files changed, 19 insertions, 56 deletions
diff --git a/src/configuration.cpp b/src/configuration.cpp
index 8a9caae60..f1691baad 100644
--- a/src/configuration.cpp
+++ b/src/configuration.cpp
@@ -48,6 +48,7 @@ Configuration paths; // XML default paths information reader
const std::string unusedKeys[] =
{
+ "hideShield",
"AttackRange",
"emoteshortcut0",
"screenshotDirectory2",
diff --git a/src/defaults.cpp b/src/defaults.cpp
index 8a4d70999..80a798edc 100644
--- a/src/defaults.cpp
+++ b/src/defaults.cpp
@@ -209,7 +209,6 @@ DefaultsData* getConfigDefaults()
AddDEF("showChatHistory", true);
AddDEF("chatMaxLinesLimit", 40);
AddDEF("chatColor", 0);
- AddDEF("hideShield", true);
AddDEF("showJob", true);
AddDEF("updateOnlineList", true);
AddDEF("targetOnlyReachable", true);
diff --git a/src/gui/widgets/tabs/setup_other.cpp b/src/gui/widgets/tabs/setup_other.cpp
index a20d4472b..afa0e9987 100644
--- a/src/gui/widgets/tabs/setup_other.cpp
+++ b/src/gui/widgets/tabs/setup_other.cpp
@@ -385,10 +385,6 @@ Setup_Other::Setup_Other(const Widget2 *const widget) :
new SetupItemCheckBox(_("Low traffic mode"), "", "lowTraffic",
this, "lowTrafficEvent");
- // TRANSLATORS: settings option
- new SetupItemCheckBox(_("Hide shield sprite"), "", "hideShield",
- this, "hideShieldEvent");
-
#ifndef ANDROID
// TRANSLATORS: settings option
new SetupItemCheckBox(_("Use FBO for screenshots (only for opengl)"),
diff --git a/src/net/ea/beinghandler.cpp b/src/net/ea/beinghandler.cpp
index 40ee477a0..ec8ce3673 100644
--- a/src/net/ea/beinghandler.cpp
+++ b/src/net/ea/beinghandler.cpp
@@ -48,13 +48,11 @@ namespace Ea
{
int BeingHandler::mSpawnId = 0;
bool BeingHandler::mSync = false;
-bool BeingHandler::mHideShield = false;
BeingHandler::BeingHandler(const bool enableSync)
{
mSync = enableSync;
mSpawnId = 0;
- mHideShield = config.getBoolValue("hideShield");
}
Being *BeingHandler::createBeing(const int id, const int16_t job)
diff --git a/src/net/ea/beinghandler.h b/src/net/ea/beinghandler.h
index f9d787e72..ca575e506 100644
--- a/src/net/ea/beinghandler.h
+++ b/src/net/ea/beinghandler.h
@@ -73,7 +73,6 @@ class BeingHandler notfinal : public Net::BeingHandler
// Should we honor server "Stop Walking" packets
static int mSpawnId;
static bool mSync;
- static bool mHideShield;
};
} // namespace Ea
diff --git a/src/net/eathena/beinghandler.cpp b/src/net/eathena/beinghandler.cpp
index 6e1a38d4d..1c913a691 100644
--- a/src/net/eathena/beinghandler.cpp
+++ b/src/net/eathena/beinghandler.cpp
@@ -531,8 +531,7 @@ void BeingHandler::processBeingChangeLookContinue(Net::MessageIn &msg,
break;
case 2: // LOOK_WEAPON Weapon ID in id, Shield ID in id2
dstBeing->setSprite(SPRITE_BODY, id, "", 1, true);
- if (!mHideShield)
- dstBeing->setSprite(SPRITE_FLOOR, id2);
+ dstBeing->setSprite(SPRITE_FLOOR, id2);
localPlayer->imitateOutfit(dstBeing, SPRITE_FLOOR);
break;
case 3: // LOOK_HEAD_BOTTOM
@@ -561,11 +560,8 @@ void BeingHandler::processBeingChangeLookContinue(Net::MessageIn &msg,
dstBeing->setLook(static_cast<uint8_t>(id));
break;
case 8: // eAthena LOOK_SHIELD
- if (!mHideShield)
- {
- dstBeing->setSprite(SPRITE_FLOOR, id, color,
- static_cast<unsigned char>(id2));
- }
+ dstBeing->setSprite(SPRITE_FLOOR, id, color,
+ static_cast<unsigned char>(id2));
localPlayer->imitateOutfit(dstBeing, SPRITE_FLOOR);
break;
case 9: // eAthena LOOK_SHOES
@@ -728,8 +724,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
setSprite(dstBeing, SPRITE_HAIR, shoes);
setSprite(dstBeing, SPRITE_SHOES, gloves);
setSprite(dstBeing, SPRITE_BODY, weapon, "", 1, true);
-// if (!mHideShield)
-// setSprite(dstBeing, SPRITE_FLOOR, shield);
+// setSprite(dstBeing, SPRITE_FLOOR, shield);
}
else if (dstBeing->getType() == ActorType::Npc
&& serverFeatures->haveNpcGender())
@@ -894,8 +889,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
setSprite(dstBeing, SPRITE_SHOES, gloves);
setSprite(dstBeing, SPRITE_BODY, weapon, "", 1, true);
}
-// if (!mHideShield)
-// setSprite(dstBeing, SPRITE_FLOOR, shield);
+// setSprite(dstBeing, SPRITE_FLOOR, shield);
}
else if (dstBeing->getType() == ActorType::Npc
&& serverFeatures->haveNpcGender())
@@ -1062,8 +1056,7 @@ void BeingHandler::processBeingSpawn(Net::MessageIn &msg)
setSprite(dstBeing, SPRITE_HAIR, shoes);
setSprite(dstBeing, SPRITE_SHOES, gloves);
setSprite(dstBeing, SPRITE_BODY, weapon, "", 1, true);
-// if (!mHideShield)
-// setSprite(dstBeing, SPRITE_FLOOR, shield);
+// setSprite(dstBeing, SPRITE_FLOOR, shield);
}
else if (dstBeing->getType() == ActorType::Npc
&& serverFeatures->haveNpcGender())
diff --git a/src/net/eathena/charserverhandler.cpp b/src/net/eathena/charserverhandler.cpp
index f01c3abae..6896b860d 100644
--- a/src/net/eathena/charserverhandler.cpp
+++ b/src/net/eathena/charserverhandler.cpp
@@ -272,9 +272,7 @@ void CharServerHandler::readPlayerData(Net::MessageIn &msg,
tempPlayer->setSprite(SPRITE_SHIELD, cape);
tempPlayer->setSprite(SPRITE_HEAD_TOP, misc1);
tempPlayer->setSprite(SPRITE_WEAPON, bottomClothes);
- // to avoid show error (error.xml) need remove this sprite
- if (!config.getBoolValue("hideShield"))
- tempPlayer->setSprite(SPRITE_FLOOR, shield);
+ tempPlayer->setSprite(SPRITE_FLOOR, shield);
tempPlayer->setSprite(SPRITE_CLOTHES_COLOR, hat);
tempPlayer->setSprite(SPRITE_HEAD_BOTTOM, topClothes);
diff --git a/src/net/tmwa/beinghandler.cpp b/src/net/tmwa/beinghandler.cpp
index 27cad62ba..e6bb54f53 100644
--- a/src/net/tmwa/beinghandler.cpp
+++ b/src/net/tmwa/beinghandler.cpp
@@ -342,8 +342,7 @@ void BeingHandler::processBeingChangeLookContinue(Net::MessageIn &msg,
}
case 2: // Weapon ID in id, Shield ID in id2
dstBeing->setSprite(SPRITE_BODY, id, "", 1, true);
- if (!mHideShield)
- dstBeing->setSprite(SPRITE_FLOOR, id2);
+ dstBeing->setSprite(SPRITE_FLOOR, id2);
localPlayer->imitateOutfit(dstBeing, SPRITE_FLOOR);
break;
case 3: // Change lower headgear for eAthena, pants for us
@@ -369,11 +368,8 @@ void BeingHandler::processBeingChangeLookContinue(Net::MessageIn &msg,
// ignoring it
break;
case 8: // eAthena LOOK_SHIELD
- if (!mHideShield)
- {
- dstBeing->setSprite(SPRITE_FLOOR, id, color,
- static_cast<unsigned char>(id2));
- }
+ dstBeing->setSprite(SPRITE_FLOOR, id, color,
+ static_cast<unsigned char>(id2));
localPlayer->imitateOutfit(dstBeing, SPRITE_FLOOR);
break;
case 9: // eAthena LOOK_SHOES
@@ -521,8 +517,7 @@ void BeingHandler::processPlayerUpdate1(Net::MessageIn &msg)
{
// Set these after the gender, as the sprites may be gender-specific
dstBeing->updateSprite(SPRITE_BODY, weapon, "", 1, true);
- if (!mHideShield)
- dstBeing->updateSprite(SPRITE_FLOOR, shield);
+ dstBeing->updateSprite(SPRITE_FLOOR, shield);
if (serverFeatures->haveItemColors())
{
dstBeing->updateSprite(SPRITE_WEAPON, headBottom,
@@ -673,8 +668,7 @@ void BeingHandler::processPlayerUpdate2(Net::MessageIn &msg)
{
// Set these after the gender, as the sprites may be gender-specific
dstBeing->updateSprite(SPRITE_BODY, weapon, "", 1, true);
- if (!mHideShield)
- dstBeing->updateSprite(SPRITE_FLOOR, shield);
+ dstBeing->updateSprite(SPRITE_FLOOR, shield);
if (serverFeatures->haveItemColors())
{
dstBeing->updateSprite(SPRITE_WEAPON, headBottom,
@@ -825,8 +819,7 @@ void BeingHandler::processPlayerMove(Net::MessageIn &msg)
{
// Set these after the gender, as the sprites may be gender-specific
dstBeing->updateSprite(SPRITE_BODY, weapon, "", 1, true);
- if (!mHideShield)
- dstBeing->updateSprite(SPRITE_FLOOR, shield);
+ dstBeing->updateSprite(SPRITE_FLOOR, shield);
if (serverFeatures->haveItemColors())
{
dstBeing->updateSprite(SPRITE_WEAPON, headBottom,
@@ -1068,8 +1061,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
setSprite(dstBeing, SPRITE_HAIR, shoes);
setSprite(dstBeing, SPRITE_SHOES, gloves);
setSprite(dstBeing, SPRITE_BODY, weapon, "", 1, true);
- if (!mHideShield)
- setSprite(dstBeing, SPRITE_FLOOR, shield);
+ setSprite(dstBeing, SPRITE_FLOOR, shield);
}
else if (dstBeing->getType() == ActorType::Npc
&& serverFeatures->haveNpcGender())
@@ -1273,8 +1265,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
setSprite(dstBeing, SPRITE_HAIR, shoes);
setSprite(dstBeing, SPRITE_SHOES, gloves);
setSprite(dstBeing, SPRITE_BODY, weapon, "", 1, true);
- if (!mHideShield)
- setSprite(dstBeing, SPRITE_FLOOR, shield);
+ setSprite(dstBeing, SPRITE_FLOOR, shield);
}
else if (dstBeing->getType() == ActorType::Npc
&& serverFeatures->haveNpcGender())
diff --git a/src/net/tmwa/charserverhandler.cpp b/src/net/tmwa/charserverhandler.cpp
index 57e7eea1b..37dc4828e 100644
--- a/src/net/tmwa/charserverhandler.cpp
+++ b/src/net/tmwa/charserverhandler.cpp
@@ -215,17 +215,8 @@ void CharServerHandler::readPlayerData(Net::MessageIn &msg,
msg.readUInt8("misc1 color"));
tempPlayer->setSprite(SPRITE_WEAPON, bottomClothes,
"", msg.readUInt8("bottom clothes color"));
- // to avoid show error (error.xml) need remove this sprite
- if (!config.getBoolValue("hideShield"))
- {
- tempPlayer->setSprite(SPRITE_FLOOR, shield, "",
- msg.readUInt8("shield color"));
- }
- else
- {
- msg.readUInt8("shield color");
- }
-
+ tempPlayer->setSprite(SPRITE_FLOOR, shield, "",
+ msg.readUInt8("shield color"));
tempPlayer->setSprite(SPRITE_CLOTHES_COLOR, hat, "",
msg.readUInt8("head option top color"));
tempPlayer->setSprite(SPRITE_HEAD_BOTTOM, topClothes, "",
@@ -241,10 +232,7 @@ void CharServerHandler::readPlayerData(Net::MessageIn &msg,
tempPlayer->setSprite(SPRITE_SHIELD, cape);
tempPlayer->setSprite(SPRITE_HEAD_TOP, misc1);
tempPlayer->setSprite(SPRITE_WEAPON, bottomClothes);
- // to avoid show error (error.xml) need remove this sprite
- if (!config.getBoolValue("hideShield"))
- tempPlayer->setSprite(SPRITE_FLOOR, shield);
-
+ tempPlayer->setSprite(SPRITE_FLOOR, shield);
tempPlayer->setSprite(SPRITE_CLOTHES_COLOR, hat); // head option top
tempPlayer->setSprite(SPRITE_HEAD_BOTTOM, topClothes);
tempPlayer->setSprite(SPRITE_HEAD_MID, misc2);