Commit 95c0257
committed
fix: don't allow treeform over deep water
80ed8d6 added a check to allow transformations over dangerous
terrain when the player has tempflight, but this missed an interaction
with treeform. Treeform disables all sources of flight immediately, so
if the player had tempflight (e.g. via !flight), this would lead to
sequences like the following:
You turn into a tree. Your roots penetrate the ground.
You fall into the water!
You can't survive in this terrain! You fly above the water, but the process is
draining.
Splash!
You fall into the deep water. You sink to the bottom.
For the duration the player is in deep water, they get emergency flight
draining. (Permaflight had a correct version of this check.) To fix,
move the tempflight check into `_flying_in_new_form` so the interaction
with forms forbidding flight is handled correctly.
Also, remove an obsolete Xom death check that looked at deep water/lava.1 parent d37427b commit 95c0257
3 files changed
+6
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1478 | 1478 | | |
1479 | 1479 | | |
1480 | 1480 | | |
1481 | | - | |
1482 | | - | |
| 1481 | + | |
1483 | 1482 | | |
1484 | 1483 | | |
1485 | 1484 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1463 | 1463 | | |
1464 | 1464 | | |
1465 | 1465 | | |
| 1466 | + | |
| 1467 | + | |
| 1468 | + | |
| 1469 | + | |
1466 | 1470 | | |
1467 | 1471 | | |
1468 | 1472 | | |
| |||
1535 | 1539 | | |
1536 | 1540 | | |
1537 | 1541 | | |
1538 | | - | |
| 1542 | + | |
1539 | 1543 | | |
1540 | 1544 | | |
1541 | 1545 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
920 | 920 | | |
921 | 921 | | |
922 | 922 | | |
923 | | - | |
924 | 923 | | |
925 | 924 | | |
926 | 925 | | |
| |||
0 commit comments