Unify impaired movement direction checks

This commit is contained in:
Pasi Kallinen
2022-07-17 12:23:49 +03:00
parent 1ae2bc7063
commit 6fe0f7c132
5 changed files with 22 additions and 16 deletions

View File

@@ -1058,8 +1058,7 @@ use_pick_axe2(struct obj *obj)
g.context.botl = 1;
return ECMD_TIME;
} else if (u.dz == 0) {
if (Stunned || (Confusion && !rn2(5)))
confdir();
confdir(FALSE);
rx = u.ux + u.dx;
ry = u.uy + u.dy;
if (!isok(rx, ry)) {