mirror of
https://github.com/moparisthebest/minetest
synced 2024-11-16 06:15:06 -05:00
Fix calculation of selected item (for not drawing it) in formspec
The previous code did not work when the list did not start at index 0 of the inventory list (issue #779).
This commit is contained in:
parent
816ffa99ba
commit
c8ed61b281
@ -698,7 +698,7 @@ void GUIFormSpecMenu::drawList(const ListDrawSpec &s, int phase)
|
||||
bool selected = m_selected_item
|
||||
&& m_invmgr->getInventory(m_selected_item->inventoryloc) == inv
|
||||
&& m_selected_item->listname == s.listname
|
||||
&& m_selected_item->i == i;
|
||||
&& m_selected_item->i == item_i;
|
||||
bool hovering = rect.isPointInside(m_pointer);
|
||||
|
||||
if(phase == 0)
|
||||
|
Loading…
Reference in New Issue
Block a user