Add optionsfull extended command
This is the previous, full options list. Adding it as an extended command, so users can do BIND=O:optionsfull to go back to the old behaviour.
This commit is contained in:
@@ -1388,6 +1388,8 @@ Default key is \(oqo\(cq.
|
||||
Show and change option settings.
|
||||
Default key is \(oqO\(cq.
|
||||
Precede with the \(oqm\(cq prefix to show advanced options.
|
||||
.lp "#optionsfull"
|
||||
Show advanced game option settings.
|
||||
.lp #overview
|
||||
Display information you've discovered about the dungeon.
|
||||
Any visited
|
||||
|
||||
@@ -1498,6 +1498,9 @@ Open a door. Default key is `{\tt o}'.
|
||||
Show and change option settings. Default key is `{\tt O}'.
|
||||
Precede with the {\tt m} prefix to show advanced options.
|
||||
%.lp
|
||||
\item[\tb{\#optionsfull}]
|
||||
Show advanced game option settings.
|
||||
%.lp
|
||||
\item[\tb{\#overview}]
|
||||
Display information you've discovered about the dungeon. Any visited
|
||||
level (unless forgotten due to amnesia) with an annotation is included,
|
||||
|
||||
@@ -1954,6 +1954,7 @@ extern void initoptions_init(void);
|
||||
extern void initoptions_finish(void);
|
||||
extern boolean parseoptions(char *, boolean, boolean);
|
||||
extern char *get_option_value(const char *);
|
||||
extern int doset_simple(void);
|
||||
extern int doset(void);
|
||||
extern int dotogglepickup(void);
|
||||
extern void option_help(void);
|
||||
|
||||
@@ -58,6 +58,7 @@ extern int doclose(void); /**/
|
||||
extern int dosh(void); /**/
|
||||
extern int dodiscovered(void); /**/
|
||||
extern int doclassdisco(void); /**/
|
||||
extern int doset_simple(void); /**/
|
||||
extern int doset(void); /**/
|
||||
extern int dotogglepickup(void); /**/
|
||||
extern int dowhatis(void); /**/
|
||||
@@ -2528,8 +2529,10 @@ struct ext_func_tab extcmdlist[] = {
|
||||
dosacrifice, AUTOCOMPLETE | CMD_M_PREFIX, NULL },
|
||||
{ 'o', "open", "open a door",
|
||||
doopen, 0, NULL },
|
||||
{ 'O', "options", "show option settings, possibly change them",
|
||||
doset, IFBURIED | GENERALCMD | CMD_M_PREFIX, NULL },
|
||||
{ 'O', "options", "show option settings",
|
||||
doset_simple, IFBURIED | GENERALCMD | CMD_M_PREFIX, NULL },
|
||||
{ '\0', "optionsfull", "show all option settings, possibly change them",
|
||||
doset, IFBURIED | GENERALCMD, NULL },
|
||||
/* #overview used to need autocomplete and has retained that even
|
||||
after being assigned to ^O [old wizard mode ^O is now #wizwhere] */
|
||||
{ C('o'), "overview", "show a summary of the explored dungeon",
|
||||
|
||||
@@ -302,7 +302,6 @@ static void free_one_menu_coloring(int);
|
||||
static int count_menucolors(void);
|
||||
static boolean parse_role_opts(int, boolean, const char *,
|
||||
char *, char **);
|
||||
static int doset_simple(void);
|
||||
static unsigned int longest_option_name(int, int);
|
||||
static void doset_add_menu(winid, const char *, int, int);
|
||||
static int handle_add_list_remove(const char *, int);
|
||||
@@ -7721,7 +7720,7 @@ longest_option_name(int startpass, int endpass)
|
||||
}
|
||||
|
||||
/* #options - the user friendly version */
|
||||
static int
|
||||
int
|
||||
doset_simple(void)
|
||||
{
|
||||
static boolean made_fmtstr = FALSE;
|
||||
@@ -7734,6 +7733,9 @@ doset_simple(void)
|
||||
boolean *bool_p;
|
||||
const char *name;
|
||||
|
||||
if (iflags.menu_requested)
|
||||
return doset();
|
||||
|
||||
if (!made_fmtstr) {
|
||||
Sprintf(fmtstr_doset, "%%s%%-%us [%%s]",
|
||||
longest_option_name(set_gameview, set_in_game));
|
||||
@@ -7855,7 +7857,7 @@ rerun:
|
||||
return ECMD_OK;
|
||||
}
|
||||
|
||||
/* the #options command */
|
||||
/* the #optionsfull command */
|
||||
int
|
||||
doset(void) /* changing options via menu by Per Liboriussen */
|
||||
{
|
||||
@@ -7872,9 +7874,6 @@ doset(void) /* changing options via menu by Per Liboriussen */
|
||||
gavehelp = FALSE, skiphelp = !iflags.cmdassist;
|
||||
int clr = 0;
|
||||
|
||||
if (!iflags.menu_requested)
|
||||
return doset_simple();
|
||||
|
||||
/* if we offer '?' as a choice and it is the only thing chosen,
|
||||
we'll end up coming back here after showing the explanatory text */
|
||||
rerun:
|
||||
|
||||
Reference in New Issue
Block a user