U846 - xorns and pits
Change pit behavior to always mark a non-flying poly'd player as trapped in a pit, even when Passes_walls is set. This allows players polymorphed into xorns to descend into pits and pick things up. In this case, any attempt to move out of the pit now takes a turn but always succeeds. Also fixed a related bug (w/o ID) that a player could become trapped as if in a pit when leaving xorn form because u.utrap wasn't checked, and simplified the code since the extra Passes_walls checks are no longer needed. Also updated code in sit.c that duplicated uteetering_at_seen_pit.
This commit is contained in:
10
src/dokick.c
10
src/dokick.c
@@ -663,9 +663,12 @@ dokick()
|
||||
Your("slow motion kick doesn't hit anything.");
|
||||
no_kick = TRUE;
|
||||
} else if (u.utrap) {
|
||||
no_kick = TRUE;
|
||||
switch (u.utraptype) {
|
||||
case TT_PIT:
|
||||
pline("There's not enough room to kick down here.");
|
||||
if (!Passes_walls)
|
||||
pline("There's not enough room to kick down here.");
|
||||
else no_kick = FALSE;
|
||||
break;
|
||||
case TT_WEB:
|
||||
case TT_BEARTRAP:
|
||||
@@ -674,7 +677,6 @@ dokick()
|
||||
default:
|
||||
break;
|
||||
}
|
||||
no_kick = TRUE;
|
||||
}
|
||||
|
||||
if (no_kick) {
|
||||
@@ -706,6 +708,10 @@ dokick()
|
||||
default: Your("feeble kick has no effect."); break;
|
||||
}
|
||||
return(1);
|
||||
} else if(u.utrap && u.utraptype == TT_PIT) {
|
||||
/* must be Passes_walls */
|
||||
You("kick at the side of the pit.");
|
||||
return 1;
|
||||
}
|
||||
if (Levitation) {
|
||||
int xx, yy;
|
||||
|
||||
Reference in New Issue
Block a user