autopickup_exceptions enhancement
An enhancement to the original to allow
two types of exceptions:
always pickup
never pickup
To specify "never pickup", begin the pattern string with '>'
which is NetHack's down direction symbol (for "leave it down")
To specify "always pickup", begin the pattern string with '<'
which is NetHack's up direction symbol.
For example, to pick up all arrows, regardless of the pickup_
types setting:
autopickup_exception = "<*arrows"
This commit is contained in:
@@ -372,10 +372,11 @@ E char *fqn_prefix_names[PREFIX_COUNT];
|
||||
#ifdef AUTOPICKUP_EXCEPTIONS
|
||||
struct autopickup_exception {
|
||||
char *pattern;
|
||||
boolean grab;
|
||||
struct autopickup_exception *next;
|
||||
};
|
||||
|
||||
#endif /* AUTOPICKUP_EXCEPTIONS */
|
||||
|
||||
#undef E
|
||||
|
||||
#endif /* DECL_H */
|
||||
|
||||
@@ -1513,6 +1513,7 @@ E int FDECL(loot_mon, (struct monst *,int *,boolean *));
|
||||
E int NDECL(dotip);
|
||||
E const char *FDECL(safe_qbuf, (const char *,unsigned,
|
||||
const char *,const char *,const char *));
|
||||
E boolean FDECL(is_autopickup_exception, (struct obj *, BOOLEAN_P));
|
||||
|
||||
/* ### pline.c ### */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user