summaryrefslogtreecommitdiff
path: root/src/being/being.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/being/being.cpp')
-rw-r--r--src/being/being.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/being/being.cpp b/src/being/being.cpp
index f3976a20e..c503e94d5 100644
--- a/src/being/being.cpp
+++ b/src/being/being.cpp
@@ -1902,6 +1902,21 @@ void Being::updateColors()
}
}
+void Being::updateSprite(const unsigned int slot, const int id,
+ std::string color, const unsigned char colorId,
+ const bool isWeapon, const bool isTempSprite)
+{
+ if (slot >= Net::getCharServerHandler()->maxSprite())
+ return;
+
+ if (slot >= mSpriteIDs.size())
+ mSpriteIDs.resize(slot + 1, 0);
+
+ if (slot && mSpriteIDs[slot] == id)
+ return;
+ setSprite(slot, id, color, colorId, isWeapon, isTempSprite);
+}
+
void Being::setSprite(const unsigned int slot, const int id,
std::string color, const unsigned char colorId,
const bool isWeapon, const bool isTempSprite)