diff --git a/L2BotDll/Versions/Interlude/Factories/AbnormalEffectFactory.h b/L2BotDll/Versions/Interlude/Factories/AbnormalEffectFactory.h index 81a2c0b..d864de0 100644 --- a/L2BotDll/Versions/Interlude/Factories/AbnormalEffectFactory.h +++ b/L2BotDll/Versions/Interlude/Factories/AbnormalEffectFactory.h @@ -29,17 +29,13 @@ namespace Interlude { const auto data = m_L2GameData.GetMSData(skillId, level); - if (!data) { - throw RuntimeException(std::format(L"cannot load MSData for abnormal effect {}", skillId)); - } - - const auto iconEntry = m_FName.GetEntry(data->iconNameIndex); + const auto iconEntry = data ? m_FName.GetEntry(data->iconNameIndex) : nullptr; return std::make_shared( skillId, static_cast(level), - data->name ? std::wstring(data->name) : L"", - data->description ? std::wstring(data->description) : L"", + data && data->name ? std::wstring(data->name) : L"", + data && data->description ? std::wstring(data->description) : L"", iconEntry ? std::wstring(iconEntry->value) : L"" ); } diff --git a/L2BotDll/Versions/VersionAbstractFactory.h b/L2BotDll/Versions/VersionAbstractFactory.h index 3ebd79f..9ad4b68 100644 --- a/L2BotDll/Versions/VersionAbstractFactory.h +++ b/L2BotDll/Versions/VersionAbstractFactory.h @@ -42,7 +42,7 @@ public: {L"player", GetPlayerRepository()}, {L"skill", GetSkillRepository()}, {L"item", GetItemRepository()}, - {L"abnormalEffect", GetAbnormalEffectRepository()}, + //{L"abnormalEffect", GetAbnormalEffectRepository()}, {L"chat", GetChatMessageRepository()} }; }