diff --git a/sonic-boost.love/core/modules/menusystem/flowbox.lua b/sonic-boost.love/core/modules/menusystem/flowbox.lua index ebfa53f..aa55788 100644 --- a/sonic-boost.love/core/modules/menusystem/flowbox.lua +++ b/sonic-boost.love/core/modules/menusystem/flowbox.lua @@ -167,11 +167,12 @@ function FlowBox:draw() end function FlowBox:drawCursor() + local begincol, beginline = self:getCoord(self.view.firstSlot) if (self.widget.selected >= 1 and self.widget.selected <= #self.widget.list) then local w, h = self:getWidgetSize() local col, line = self:getCoord(self.widget.selected) local x = (col) * h - local y = (line) * h + local y = (line - beginline) * h menuutils.drawCursor(self.x + x, self.y + y, w, h) end end diff --git a/sonic-boost.love/core/modules/menusystem/listbox.lua b/sonic-boost.love/core/modules/menusystem/listbox.lua index eb5f797..3234963 100644 --- a/sonic-boost.love/core/modules/menusystem/listbox.lua +++ b/sonic-boost.love/core/modules/menusystem/listbox.lua @@ -90,7 +90,7 @@ end function ListBox:drawCursor() if (self.widget.selected >= 1 and self.widget.selected <= #self.widget.list) then local w, h = self:getWidgetSize() - local y = (self.widget.selected - 1) * h + local y = (self.widget.selected - self.view.firstSlot) * h menuutils.drawCursor(self.x,self.y + y, w, h) end end