Skip to content

Commit fde880a

Browse files
committed
Fix: certain monster steeds should only be ridden by certain monster riders.
For the player, only as a Drow can you ride spiders or cave lizards, or only as an Orc can you ride a warg, and so on. Monster rider/steed pairs didn't have this restriction, which seemed incorrect. This commit addresses this, and brings monster rider/steed pairs to be more inline with what the player can ride or not ride.
1 parent c881c2f commit fde880a

File tree

3 files changed

+15
-1
lines changed

3 files changed

+15
-1
lines changed

doc/evilhack-changelog.md

+2
Original file line numberDiff line numberDiff line change
@@ -3398,4 +3398,6 @@ The following changes to date are:
33983398
- Fix: various monsters showing as having claws when they don't
33993399
- Fix: update to last commit (claws)
34003400
- Hippocrates (Healer quest leader) additional gear
3401+
- Fix: certain monster steeds should only be ridden by certain monster
3402+
riders
34013403

include/mondata.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -551,7 +551,7 @@
551551
&& !(mon)->mtame && (mon) != u.ustuck && !(mon)->mpeaceful \
552552
&& !(mon)->mtrapped && (mon)->mcanmove && !(mon)->msleeping \
553553
&& !is_shapeshifter((mon)->data) && !is_were((mon)->data) \
554-
&& !(mon)->isshk && (mon)->data->mlet != S_DOG && (mon)->cham == NON_PM \
554+
&& !(mon)->isshk && (mon)->cham == NON_PM \
555555
&& !((mon)->mstrategy & STRAT_WAITFORU))
556556

557557
/* Used for conduct with corpses, tins, and digestion attacks */

src/steed.c

+12
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,18 @@ struct monst *rider;
9494
if (nmon == rider)
9595
nmon = rider->nmon;
9696
/* criteria for an acceptable steed */
97+
if (!is_drow(rider->data) && is_spider(steed->data))
98+
continue;
99+
if (!is_drow(rider->data)
100+
&& (steed->data == &mons[PM_CAVE_LIZARD]
101+
|| steed->data == &mons[PM_LARGE_CAVE_LIZARD]))
102+
continue;
103+
if (!is_orc(rider->data) && steed->data == &mons[PM_WARG])
104+
continue;
105+
if (!(rider->data == &mons[PM_CAVEMAN]
106+
|| rider->data == &mons[PM_CAVEWOMAN])
107+
&& steed->data == &mons[PM_SABER_TOOTHED_TIGER])
108+
continue;
97109
if (monnear(rider, steed->mx, steed->my) && mon_can_be_ridden(steed)
98110
&& !steed->ridden_by) {
99111
break;

0 commit comments

Comments
 (0)