Advanced Rogue 5: convert to ANSI function declarations.
This still leaves over a thousand lines of warning messages, mostly related to the return types of daemons and fuses.
This commit is contained in:
parent
59f448e92e
commit
f38b2223c8
37 changed files with 977 additions and 733 deletions
|
|
@ -35,16 +35,16 @@ struct optstruct {
|
|||
|
||||
typedef struct optstruct OPTION;
|
||||
|
||||
int put_bool(),
|
||||
get_bool(),
|
||||
put_str(),
|
||||
get_str(),
|
||||
get_restr(),
|
||||
get_score(),
|
||||
put_abil(),
|
||||
get_abil(),
|
||||
get_quest(),
|
||||
put_quest();
|
||||
int get_ro(WINDOW *win, int oy, int ox);
|
||||
int get_restr(char *optstr, WINDOW *win);
|
||||
int get_score(char *optstr, WINDOW *win);
|
||||
void put_abil(int *ability, WINDOW *win);
|
||||
void get_abil(int *abil, WINDOW *win);
|
||||
void put_quest(int *quest, WINDOW *win);
|
||||
void get_quest(int *quest, WINDOW *win);
|
||||
void put_bool(bool *b, WINDOW *win);
|
||||
int get_bool(bool *bp, WINDOW *win);
|
||||
void put_str(char *str, WINDOW *win);
|
||||
|
||||
OPTION optlist[] = {
|
||||
{"terse", "Terse output: ",
|
||||
|
|
@ -111,9 +111,8 @@ int get_score(char *optstr, WINDOW *win)
|
|||
/*
|
||||
* The ability field is read-only
|
||||
*/
|
||||
get_abil(abil, win)
|
||||
int *abil;
|
||||
WINDOW *win;
|
||||
void
|
||||
get_abil(int *abil, WINDOW *win)
|
||||
{
|
||||
register int oy, ox;
|
||||
|
||||
|
|
@ -125,9 +124,8 @@ WINDOW *win;
|
|||
/*
|
||||
* The quest field is read-only
|
||||
*/
|
||||
get_quest(quest, win)
|
||||
int *quest;
|
||||
WINDOW *win;
|
||||
void
|
||||
get_quest(int *quest, WINDOW *win)
|
||||
{
|
||||
register int oy, ox;
|
||||
|
||||
|
|
@ -141,9 +139,8 @@ WINDOW *win;
|
|||
* "Get" a read-only value.
|
||||
*/
|
||||
|
||||
get_ro(win, oy, ox)
|
||||
WINDOW *win;
|
||||
register int oy, ox;
|
||||
int
|
||||
get_ro(WINDOW *win, int oy, int ox)
|
||||
{
|
||||
register int ny, nx;
|
||||
register bool op_bad;
|
||||
|
|
@ -180,9 +177,8 @@ register int oy, ox;
|
|||
* allow changing a boolean option and print it out
|
||||
*/
|
||||
|
||||
get_bool(bp, win)
|
||||
bool *bp;
|
||||
WINDOW *win;
|
||||
int
|
||||
get_bool(bool *bp, WINDOW *win)
|
||||
{
|
||||
register int oy, ox;
|
||||
register bool op_bad;
|
||||
|
|
@ -230,9 +226,8 @@ WINDOW *win;
|
|||
/*
|
||||
* set a string option
|
||||
*/
|
||||
get_str(opt, win)
|
||||
register char *opt;
|
||||
WINDOW *win;
|
||||
int
|
||||
get_str(char *opt, WINDOW *win)
|
||||
{
|
||||
register char *sp;
|
||||
register int c, oy, ox;
|
||||
|
|
@ -306,7 +301,8 @@ WINDOW *win;
|
|||
/*
|
||||
* print and then set options from the terminal
|
||||
*/
|
||||
option()
|
||||
void
|
||||
option(void)
|
||||
{
|
||||
register OPTION *op;
|
||||
register int retval;
|
||||
|
|
@ -362,8 +358,8 @@ option()
|
|||
* or the end of the entire option string.
|
||||
*/
|
||||
|
||||
parse_opts(str)
|
||||
register char *str;
|
||||
void
|
||||
parse_opts(char *str)
|
||||
{
|
||||
register char *sp;
|
||||
register OPTION *op;
|
||||
|
|
@ -459,9 +455,8 @@ register char *str;
|
|||
/*
|
||||
* print the character type
|
||||
*/
|
||||
put_abil(ability, win)
|
||||
int *ability;
|
||||
WINDOW *win;
|
||||
void
|
||||
put_abil(int *ability, WINDOW *win)
|
||||
{
|
||||
char *abil;
|
||||
|
||||
|
|
@ -480,9 +475,8 @@ WINDOW *win;
|
|||
* print out the quest
|
||||
*/
|
||||
|
||||
put_quest(quest, win)
|
||||
int *quest;
|
||||
WINDOW *win;
|
||||
void
|
||||
put_quest(int *quest, WINDOW *win)
|
||||
{
|
||||
waddstr(win, rel_magic[*quest].mi_name);
|
||||
}
|
||||
|
|
@ -491,9 +485,8 @@ WINDOW *win;
|
|||
/*
|
||||
* put out a boolean
|
||||
*/
|
||||
put_bool(b, win)
|
||||
bool *b;
|
||||
WINDOW *win;
|
||||
void
|
||||
put_bool(bool *b, WINDOW *win)
|
||||
{
|
||||
waddstr(win, *b ? "True" : "False");
|
||||
}
|
||||
|
|
@ -504,9 +497,8 @@ WINDOW *win;
|
|||
/*
|
||||
* put out a string
|
||||
*/
|
||||
put_str(str, win)
|
||||
char *str;
|
||||
WINDOW *win;
|
||||
void
|
||||
put_str(char *str, WINDOW *win)
|
||||
{
|
||||
waddstr(win, str);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue