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:
John "Elwin" Edwards 2016-02-07 14:39:21 -05:00
parent 59f448e92e
commit f38b2223c8
37 changed files with 977 additions and 733 deletions

View file

@ -15,6 +15,7 @@
#include "curses.h"
#include <ctype.h>
#include <string.h>
#include <stdlib.h>
#include "rogue.h"
@ -23,9 +24,8 @@
* create_obj:
* Create any object for wizard, scroll, magician, or cleric
*/
create_obj(prompt, which_item, which_type)
bool prompt;
int which_item, which_type;
void
create_obj(bool prompt, int which_item, int which_type)
{
reg struct linked_list *item;
reg struct object *obj;
@ -311,7 +311,8 @@ int which_item, which_type;
* getbless:
* Get a blessing for a wizards object
*/
getbless()
int
getbless(void)
{
reg char bless;
@ -328,7 +329,8 @@ getbless()
/*
* get a non-monster death type
*/
getdeath()
int
getdeath(void)
{
register int i;
int which_death;
@ -358,8 +360,8 @@ getdeath()
/*
* make a monster for the wizard
*/
makemonster(create)
bool create;
short
makemonster(bool create)
{
register int i;
register short which_monst;
@ -368,7 +370,7 @@ bool create;
/* Print out the monsters */
while (num_monst > 0) {
register left_limit;
register int left_limit;
if (num_monst < num_lines) left_limit = (num_monst+1)/2;
else left_limit = num_lines/2;
@ -430,7 +432,8 @@ get_monst:
* see if user knows password
*/
passwd()
bool
passwd(void)
{
register char *sp, c;
char buf[LINELEN];
@ -457,7 +460,8 @@ passwd()
* Bamf the hero someplace else
*/
teleport()
int
teleport(void)
{
register struct room *new_rp, *old_rp = roomin(&hero);
register int rm;
@ -525,8 +529,8 @@ teleport()
* What a certin object is
*/
whatis(what)
struct linked_list *what;
void
whatis(struct linked_list *what)
{
register struct object *obj;
register struct linked_list *item;