From 278d9aa7eb084bd6f93e6ac1fd84033dc316ab5e Mon Sep 17 00:00:00 2001 From: Thorbjørn Lindeijer Date: Thu, 15 Feb 2024 14:15:27 +0100 Subject: Fix handling of non-consecutive emote IDs Previous code was assuming there would be no gaps in the emote IDs. Also cleaned up some confusion where the "emote ID" being passed around in the code was often offset by 1. Now it is only offset in communication with tmwAthena and when saving the shortcuts. --- src/net/tmwa/playerhandler.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/net/tmwa/playerhandler.cpp') diff --git a/src/net/tmwa/playerhandler.cpp b/src/net/tmwa/playerhandler.cpp index 9c1a7135..431137fd 100644 --- a/src/net/tmwa/playerhandler.cpp +++ b/src/net/tmwa/playerhandler.cpp @@ -534,7 +534,7 @@ void PlayerHandler::attack(int id) void PlayerHandler::emote(int emoteId) { MessageOut outMsg(CMSG_PLAYER_EMOTE); - outMsg.writeInt8(emoteId); + outMsg.writeInt8(emoteId + 1); } void PlayerHandler::increaseAttribute(int attr) -- cgit v1.2.3-70-g09d2