From 5bd4017e0b0454a36a113ac1fd13b2b03371132f Mon Sep 17 00:00:00 2001 From: Eduardo Dantas Date: Fri, 15 Sep 2023 16:49:05 -0300 Subject: [PATCH] fix: adjust bestiary logic to add kill monster only --- src/creatures/players/player.cpp | 3 --- src/io/iobestiary.cpp | 8 ++------ 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/src/creatures/players/player.cpp b/src/creatures/players/player.cpp index c99d06f7bdf..9d9a5e9c54d 100644 --- a/src/creatures/players/player.cpp +++ b/src/creatures/players/player.cpp @@ -1654,9 +1654,6 @@ void Player::onCreatureAppear(Creature* creature, bool isLogin) { } } - // Reload bestiary tracker - refreshCyclopediaMonsterTracker(); - g_game().checkPlayersRecord(); IOLoginData::updateOnlineStatus(guid, true); if (getLevel() < g_configManager().getNumber(ADVENTURERSBLESSING_LEVEL)) { diff --git a/src/io/iobestiary.cpp b/src/io/iobestiary.cpp index 2cb73b40e7e..acfeb561ae6 100644 --- a/src/io/iobestiary.cpp +++ b/src/io/iobestiary.cpp @@ -237,12 +237,8 @@ void IOBestiary::addBestiaryKill(Player* player, const std::shared_ptrgetCyclopediaMonsterTrackerSet(false); - for (const auto mType : trackerUnorderedSet) { - if (raceid == mType->info.raceid) { - player->refreshCyclopediaMonsterTracker(trackerUnorderedSet, false); - } - } + // Reload bestiary tracker + player->refreshCyclopediaMonsterTracker(); } charmRune_t IOBestiary::getCharmFromTarget(Player* player, const std::shared_ptr mtype) {