Fix mouse menu movement
When using mouse to move to a location next to the hero, the test_move result was reversed, causing the click to fall in to the travel case instead of normal movement.
This commit is contained in:
@@ -6014,7 +6014,7 @@ there_cmd_menu(coordxy x, coordxy y, int mod)
|
|||||||
|
|
||||||
if (!K) {
|
if (!K) {
|
||||||
/* no menu options, try to move */
|
/* no menu options, try to move */
|
||||||
if (next2u(x, y) && !test_move(u.ux, u.uy, dx, dy, TEST_MOVE)) {
|
if (next2u(x, y) && test_move(u.ux, u.uy, dx, dy, TEST_MOVE)) {
|
||||||
int dir = xytod(dx, dy);
|
int dir = xytod(dx, dy);
|
||||||
|
|
||||||
cmdq_add_ec(CQ_CANNED, move_funcs[dir][MV_WALK]);
|
cmdq_add_ec(CQ_CANNED, move_funcs[dir][MV_WALK]);
|
||||||
|
|||||||
Reference in New Issue
Block a user