B15005 narrow openings and hurtling
Narrow openings are currently not checked for by hurtle_step() or mhurtle_step. This has the consequence that you can jump or use Newton's 3rd to get through somewhere you can't get through on the ground, and monsters can stagger or be jousted through somewhere they wouldn't attempt under their own steam. This patch fixes hurtle_step(). It does not address mhurtle_step.
This commit is contained in:
@@ -353,6 +353,8 @@ really add artifacts inside carried containers to final score (3.3.1 fix
|
||||
drop alternate weapon to terminate twoweapon combat if the alternate
|
||||
weapon gets cursed
|
||||
restore monster creation sanity checks to wizard mode ^G command
|
||||
prevent recoil from hurtling you through narrow areas that you wouldn't
|
||||
be able to move through intentionally
|
||||
|
||||
|
||||
Platform- and/or Interface-Specific Fixes
|
||||
|
||||
@@ -471,6 +471,17 @@ hurtle_step(arg, x, y)
|
||||
losehp(rnd(2+*range), "touching the edge of the universe", KILLED_BY);
|
||||
return FALSE;
|
||||
}
|
||||
if ((u.ux - x) && (u.uy - y) &&
|
||||
bad_rock(youmonst.data,u.ux,y) && bad_rock(youmonst.data,x,u.uy)) {
|
||||
boolean too_much = (invent && (inv_weight() + weight_cap() > 600));
|
||||
/* Move at a diagonal. */
|
||||
if (bigmonst(youmonst.data) || too_much) {
|
||||
You("%sget forcefully wedged into a crevice.",
|
||||
too_much ? "and all your belongings " : "");
|
||||
losehp(rnd(2+*range), "wedging into a narrow crevice", KILLED_BY);
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ((mon = m_at(x, y)) != 0) {
|
||||
|
||||
Reference in New Issue
Block a user