summaryrefslogtreecommitdiff
path: root/src/inventory.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-04-12 18:39:00 +0300
committerAndrei Karas <akaras@inbox.ru>2013-04-12 18:39:00 +0300
commit351821c1f18f9285be58df0a05339936311f6490 (patch)
tree47a60cad4f61f63c5ac2faf98dcae24760d7fe11 /src/inventory.cpp
parente50632a83a3c679cffd372656277a304d5d853f8 (diff)
downloadmanaverse-351821c1f18f9285be58df0a05339936311f6490.tar.gz
manaverse-351821c1f18f9285be58df0a05339936311f6490.tar.bz2
manaverse-351821c1f18f9285be58df0a05339936311f6490.tar.xz
manaverse-351821c1f18f9285be58df0a05339936311f6490.zip
first part of style fixed after cpplint checks.
Diffstat (limited to 'src/inventory.cpp')
-rw-r--r--src/inventory.cpp8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/inventory.cpp b/src/inventory.cpp
index 3dce0e079..0a82aae7b 100644
--- a/src/inventory.cpp
+++ b/src/inventory.cpp
@@ -154,7 +154,7 @@ void Inventory::removeItemAt(const int index)
delete mItems[index];
mItems[index] = nullptr;
mUsed--;
- if (mUsed < 0) // Already at 0, no need to distribute event
+ if (mUsed < 0) // Already at 0, no need to distribute event
mUsed = 0;
else
distributeSlotsChangedEvent();
@@ -216,10 +216,8 @@ const Item *Inventory::findItemBySprite(std::string spritePath,
const int race) const
{
spritePath = removeSpriteIndex(spritePath);
-// logger->log1("Inventory::FindItemBySprite sprite: " + spritePath);
const std::string spritePathShort = extractNameFromSprite(spritePath);
-// logger->log1("Inventory::FindItemBySprite spriteShort: " + spritePathShort);
int partialIndex = -1;
for (unsigned i = 0; i < mSize; i++)
@@ -231,14 +229,10 @@ const Item *Inventory::findItemBySprite(std::string spritePath,
if (!path.empty())
{
path = removeSpriteIndex(path);
-
-// logger->log("Inventory::FindItemBySprite normal: " + path);
-
if (spritePath == path)
return item;
path = extractNameFromSprite(path);
-// logger->log("Inventory::FindItemBySprite short: " + path);
if (spritePathShort == path)
partialIndex = i;
}