diff rogue4/init.c @ 215:1b73a8641b37

rogue4: fix most GCC5 warnings. Converting all function definitions to ANSI style accounts for most of the change. This has exposed other problems, such as daemons not actually being their stated type, that will require more careful solutions.
author John "Elwin" Edwards
date Wed, 27 Jan 2016 19:41:05 -0500
parents 9535a08ddc39
children
line wrap: on
line diff
--- a/rogue4/init.c	Sat Jan 23 09:35:14 2016 -0500
+++ b/rogue4/init.c	Wed Jan 27 19:41:05 2016 -0500
@@ -16,11 +16,16 @@
 #include <string.h>
 #include "rogue.h"
 
+#ifdef WIZARD
+void badcheck(char *name, struct magic_item *magic, int bound);
+#endif
+
 /*
  * init_player:
  *	Roll up the rogue
  */
-init_player()
+void
+init_player(void)
 {
     register THING *obj;
 
@@ -236,7 +241,8 @@
  * init_things
  *	Initialize the probabilities for types of things
  */
-init_things()
+void
+init_things(void)
 {
     register struct magic_item *mp;
 
@@ -251,7 +257,8 @@
  * init_colors:
  *	Initialize the potion color scheme for this time
  */
-init_colors()
+void
+init_colors(void)
 {
     register int i, j;
     bool used[NCOLORS];
@@ -281,7 +288,8 @@
  */
 #define MAXNAME	40	/* Max number of characters in a name */
 
-init_names()
+void
+init_names(void)
 {
     register int nsyl;
     register char *cp;
@@ -322,7 +330,8 @@
  * init_stones:
  *	Initialize the ring stone setting scheme for this time
  */
-init_stones()
+void
+init_stones(void)
 {
     register int i, j;
     bool used[NSTONES];
@@ -351,7 +360,8 @@
  * init_materials:
  *	Initialize the construction materials for wands and staffs
  */
-init_materials()
+void
+init_materials(void)
 {
     register int i, j;
     register const char *str;
@@ -402,10 +412,8 @@
  * badcheck:
  *	Check to see if a series of probabilities sums to 100
  */
-badcheck(name, magic, bound)
-char *name;
-register struct magic_item *magic;
-register int bound;
+void
+badcheck(char *name, struct magic_item *magic, int bound)
 {
     register struct magic_item *end;