Rework autopickup exceptions to override one another like menucolors

This commit is contained in:
HMM
2019-09-24 18:20:49 -04:00
parent 8cf70f7771
commit 2fb9cf7a1c
5 changed files with 60 additions and 76 deletions

View File

@@ -1893,7 +1893,7 @@ E boolean NDECL(u_handsy);
E int FDECL(use_container, (struct obj **, int, BOOLEAN_P));
E int FDECL(loot_mon, (struct monst *, int *, boolean *));
E int NDECL(dotip);
E boolean FDECL(is_autopickup_exception, (struct obj *, BOOLEAN_P));
E struct autopickup_exception *FDECL(check_autopickup_exceptions, (struct obj *));
E boolean FDECL(autopick_testobj, (struct obj *, BOOLEAN_P));
/* ### pline.c ### */

View File

@@ -423,9 +423,12 @@ struct instance_flags {
int wc2_statuslines; /* default = 2, curses can handle 3 */
int wc2_windowborders; /* display borders on NetHack windows */
int wc2_petattr; /* text attributes for pet */
struct autopickup_exception *autopickup_exceptions[2];
/* VE edit: APE overhaul */
struct autopickup_exception *autopickup_exceptions;
/*
#define AP_LEAVE 0
#define AP_GRAB 1
*/
#ifdef WIN32
#define MAX_ALTKEYHANDLER 25
char altkeyhandler[MAX_ALTKEYHANDLER];