diff options
author | Kahrl <kahrl@gmx.net> | 2014-11-02 21:59:56 +0100 |
---|---|---|
committer | Kahrl <kahrl@gmx.net> | 2014-11-02 21:59:56 +0100 |
commit | 817e3a6c647326dc619018488308a51271ee6763 (patch) | |
tree | bffc74ea3c1ad0486b79060198a0a66156ad884b /src | |
parent | 43bf4324d5f639f338f88a599fe862630f85f787 (diff) | |
download | minetest-817e3a6c647326dc619018488308a51271ee6763.tar.gz minetest-817e3a6c647326dc619018488308a51271ee6763.tar.bz2 minetest-817e3a6c647326dc619018488308a51271ee6763.zip |
Fix regression: mouse wheel couldn't scroll from last hotbar item to first
Diffstat (limited to 'src')
-rw-r--r-- | src/game.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/game.cpp b/src/game.cpp index a700da8cd..983605448 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -2402,7 +2402,7 @@ void MinetestApp::processItemSelection(u16 *new_playeritem) player->hud_hotbar_itemcount - 1); if (wheel < 0) - *new_playeritem = *new_playeritem < max_item ? *new_playeritem + 1 : max_item; + *new_playeritem = *new_playeritem < max_item ? *new_playeritem + 1 : 0; else if (wheel > 0) *new_playeritem = *new_playeritem > 0 ? *new_playeritem - 1 : max_item; // else wheel == 0 |