jumping over sokoban pits

reported to the list.  The code in hurtle_step was returning FALSE one
step too early, resulting in the player not actually ending up in the pit.
This commit is contained in:
cohrs
2003-03-24 21:56:59 +00:00
parent 213bd793fd
commit 7fa28ea693
2 changed files with 5 additions and 1 deletions

View File

@@ -448,6 +448,8 @@ hurtle_step(arg, x, y)
return FALSE;
} else if (!in_out_region(x, y)) {
return FALSE;
} else if (*range == 0) {
return FALSE; /* previous step wants to stop now */
}
if (!Passes_walls || !(may_pass = may_passwall(x, y))) {
@@ -533,7 +535,8 @@ hurtle_step(arg, x, y)
In_sokoban(&u.uz)) {
/* Air currents overcome the recoil */
dotrap(ttmp,0);
return FALSE;
*range = 0;
return TRUE;
} else {
if (ttmp->tseen)
You("pass right over %s %s.",