aboutsummaryrefslogtreecommitdiff
path: root/Minecraft.Client/Common/UI
diff options
context:
space:
mode:
authorAlezito2008 <92759854+Alezito2008@users.noreply.github.com>2026-03-05 04:17:17 -0300
committerGitHub <noreply@github.com>2026-03-05 14:17:17 +0700
commit87e3bd193cf36c60d411b50ceead4cd6d5079441 (patch)
tree44e078b439aabbf3f420d5052037df349a24fa8f /Minecraft.Client/Common/UI
parent8cdbf08900a2344c28bca0ae9549d40ea58989fd (diff)
Fix beacon crash (#512)
Diffstat (limited to 'Minecraft.Client/Common/UI')
-rw-r--r--Minecraft.Client/Common/UI/IUIScene_BeaconMenu.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/Minecraft.Client/Common/UI/IUIScene_BeaconMenu.cpp b/Minecraft.Client/Common/UI/IUIScene_BeaconMenu.cpp
index 76d21406..bb13deb8 100644
--- a/Minecraft.Client/Common/UI/IUIScene_BeaconMenu.cpp
+++ b/Minecraft.Client/Common/UI/IUIScene_BeaconMenu.cpp
@@ -387,8 +387,10 @@ vector<HtmlString> *IUIScene_BeaconMenu::GetSectionHoverText(ESceneSection eSect
desc = new vector<HtmlString>();
- HtmlString string( app.GetString(MobEffect::effects[effectId]->getDescriptionId()), eHTMLColor_White );
- desc->push_back( string );
+ if (effectId < MobEffect::e_MobEffectIcon_COUNT && MobEffect::effects[effectId]) {
+ HtmlString string( app.GetString(MobEffect::effects[effectId]->getDescriptionId()), eHTMLColor_White );
+ desc->push_back( string );
+ }
}
break;
}