subs: Don't hardcode impassable sector types
Check for d_mob0 < 0 instead, like we do elsewhere. Signed-off-by: Markus Armbruster <armbru@pond.sub.org>
This commit is contained in:
parent
d89825116e
commit
7fa0334c25
1 changed files with 3 additions and 5 deletions
|
@ -975,11 +975,9 @@ lnd_mar_one_sector(struct emp_qelem *list, int dir, natid actor,
|
|||
newy = ynorm(llp->unit.land.lnd_y + dy);
|
||||
getsect(newx, newy, §);
|
||||
rel = relations_with(sect.sct_own, actor);
|
||||
if ((rel != ALLIED &&
|
||||
!(lchr[(int)llp->unit.land.lnd_type].l_flags & L_SPY) &&
|
||||
sect.sct_own) || (sect.sct_type == SCT_WATER ||
|
||||
sect.sct_type == SCT_SANCT ||
|
||||
sect.sct_type == SCT_WASTE)) {
|
||||
if ((rel != ALLIED && sect.sct_own
|
||||
&& !(lchr[llp->unit.land.lnd_type].l_flags & L_SPY))
|
||||
|| dchr[sect.sct_type].d_mob0 < 0) {
|
||||
if (together) {
|
||||
mpr(actor, "can't go to %s\n", xyas(newx, newy, actor));
|
||||
return 1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue