summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2024-02-14 12:43:33 -0300
committerJesusalva Jesusalva <jesusalva@themanaworld.org>2024-02-20 01:46:08 +0000
commitf4ecfac28ac822af7732346eca3dad0365f38994 (patch)
tree6758b8df6b8cf64d4d502d9e73a1c08fdf06bca4
parent775392e472933be8d1d76619894efc0671f0c02d (diff)
downloadplus-f4ecfac28ac822af7732346eca3dad0365f38994.tar.gz
plus-f4ecfac28ac822af7732346eca3dad0365f38994.tar.bz2
plus-f4ecfac28ac822af7732346eca3dad0365f38994.tar.xz
plus-f4ecfac28ac822af7732346eca3dad0365f38994.zip
Emotes: Only load client emotes if the server is lacking them
-rw-r--r--src/resources/db/emotedb.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/resources/db/emotedb.cpp b/src/resources/db/emotedb.cpp
index 25501eaa1..92ad983e5 100644
--- a/src/resources/db/emotedb.cpp
+++ b/src/resources/db/emotedb.cpp
@@ -64,8 +64,12 @@ void EmoteDB::load()
loadXmlFile(paths.getStringValue("emotesFile"), SkipError_false);
loadXmlFile(paths.getStringValue("emotesPatchFile"), SkipError_true);
loadXmlDir("emotesPatchDir", loadXmlFile)
- loadSpecialXmlFile("graphics/sprites/manaplus_emotes.xml",
- SkipError_false);
+ // Only load client emotes if they're missing in server
+ if (mLastEmote < 20)
+ {
+ loadSpecialXmlFile("graphics/sprites/manaplus_emotes.xml",
+ SkipError_false);
+ }
mLoaded = true;
}
@@ -99,9 +103,6 @@ void EmoteDB::loadXmlFile(const std::string &fileName,
}
const int id = XML::getProperty(emoteNode, "id", -1);
- // skip hight images
- if (id > 19 || (Client::isTmw() && id > 13))
- continue;
if (id == -1)
{