diff --git a/wadsrc/static/zscript/engine/ui/menu/optionmenu.zs b/wadsrc/static/zscript/engine/ui/menu/optionmenu.zs index 305dcddb42..33cb6f081f 100644 --- a/wadsrc/static/zscript/engine/ui/menu/optionmenu.zs +++ b/wadsrc/static/zscript/engine/ui/menu/optionmenu.zs @@ -218,6 +218,11 @@ class OptionMenu : Menu break; } } + if (mDesc.mSelectedItem <= mDesc.mScrollTop + mDesc.mScrollPos + || mDesc.mSelectedItem >= VisBottom) + { + mDesc.mScrollPos = MAX(mDesc.mSelectedItem - mDesc.mScrollTop - 1, 0); + } } return Super.OnUIEvent(ev); }