fix #2253 - shk dismissing kops from other level (trunk only)
From a bug report, if you rob a shop, let the angry shopkeeper catch up with you outside his shop, escape to another level with adjacent shk tagging along, then pacify the shk by paying him off, he will dismiss kops on the present level and return to his shop but when you return to his shop level there'll still be kops chasing you there. This fix adds an extra flag to the eshk structure so that kops can be dismissed a second time when the shk migrates back to shop level. The first dismisal (on the "wrong" level) still takes place in case any kops are around. Neither dismissal actually occurs if there happens to be another angry shk present on the level where dismissal is being done.
This commit is contained in:
@@ -2051,6 +2051,7 @@ E void FDECL(delete_contents, (struct obj *));
|
||||
E void FDECL(obfree, (struct obj *,struct obj *));
|
||||
E void FDECL(home_shk, (struct monst *,BOOLEAN_P));
|
||||
E void FDECL(make_happy_shk, (struct monst *,BOOLEAN_P));
|
||||
E void FDECL(make_happy_shoppers, (BOOLEAN_P));
|
||||
E void FDECL(hot_pursuit, (struct monst *));
|
||||
E void FDECL(make_angry_shk, (struct monst *,XCHAR_P,XCHAR_P));
|
||||
E int NDECL(dopay);
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
/* NetHack 3.5 mextra.h $Date$ $Revision$ */
|
||||
/* SCCS Id: @(#)mextra.h 3.5 2009/01/30 */
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
|
||||
@@ -119,6 +118,7 @@ struct eshk {
|
||||
schar unused; /* to force alignment for stupid compilers */
|
||||
boolean following; /* following customer since he owes us sth */
|
||||
boolean surcharge; /* angry shk inflates prices */
|
||||
boolean dismiss_kops; /* pacified shk sends kops away */
|
||||
coord shk; /* usual position shopkeeper */
|
||||
coord shd; /* position shop door */
|
||||
d_level shoplevel; /* level (& dungeon) of his shop */
|
||||
|
||||
Reference in New Issue
Block a user