Mercurial > hg > early-roguelike
diff rogue4/command.c @ 225:4f6e056438eb
Merge the GCC5 and build fix branches.
author | John "Elwin" Edwards |
---|---|
date | Wed, 02 Mar 2016 21:28:34 -0500 |
parents | 1b73a8641b37 |
children | e52a8a7ad4c5 |
line wrap: on
line diff
--- a/rogue4/command.c Fri Feb 26 17:30:30 2016 -0500 +++ b/rogue4/command.c Wed Mar 02 21:28:34 2016 -0500 @@ -19,15 +19,30 @@ char countch, direction, newcount = FALSE; +void call(void); +void d_level(void); +void help(void); +void identify(void); +void illcom(char ch); +void search(void); +void u_level(void); + +#ifdef WIZARD +extern void add_pass(void); +extern void create_obj(void); +extern bool passwd(void); +extern void show_map(void); +#endif + /* * command: * Process the user commands */ -command() +void +command(void) { register char ch; register int ntimes = 1; /* Number of player moves */ - char *unctrol(); if (on(player, ISHASTE)) ntimes++; @@ -344,8 +359,8 @@ * illcom: * What to do with an illegal command */ -illcom(ch) -char ch; +void +illcom(char ch) { save_msg = FALSE; count = 0; @@ -357,7 +372,8 @@ * search: * Player gropes about him to find hidden things. */ -search() +void +search(void) { register int y, x; register char *fp; @@ -400,7 +416,8 @@ * help: * Give single character help, or the whole mess if he wants it */ -help() +void +help(void) { register const struct h_list *strp = helpstr; register char helpch; @@ -457,7 +474,8 @@ * identify: * Tell the player what a certain thing is. */ -identify() +void +identify(void) { register char ch; register const char *str; @@ -502,7 +520,8 @@ * d_level: * He wants to go down a level */ -d_level() +void +d_level(void) { if (chat(hero.y, hero.x) != STAIRS) msg("I see no way down"); @@ -517,7 +536,8 @@ * u_level: * He wants to go up a level */ -u_level() +void +u_level(void) { if (chat(hero.y, hero.x) == STAIRS) if (amulet) @@ -538,7 +558,8 @@ * call: * Allow a user to call a potion, scroll, or ring something */ -call() +void +call(void) { register THING *obj; register char **guess;