comparison arogue5/passages.c @ 218:56e748983fa8

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.
author John "Elwin" Edwards
date Sun, 07 Feb 2016 14:39:21 -0500
parents 0ed67132cf10
children e52a8a7ad4c5
comparison
equal deleted inserted replaced
217:94a0d9dd5ce1 218:56e748983fa8
12 * All rights reserved. 12 * All rights reserved.
13 * 13 *
14 * See the file LICENSE.TXT for full copyright and licensing information. 14 * See the file LICENSE.TXT for full copyright and licensing information.
15 */ 15 */
16 16
17 #include <stdlib.h>
17 #include "curses.h" 18 #include "curses.h"
18 #include "rogue.h" 19 #include "rogue.h"
19 20
21 void conn(int r1, int r2);
22 void door(struct room *rm, coord *cp);
23
20 /* 24 /*
21 * do_passages: 25 * do_passages:
22 * Draw all the passages on a level. 26 * Draw all the passages on a level.
23 */ 27 */
24 28
25 do_passages() 29 void
30 do_passages(void)
26 { 31 {
27 register struct rdes *r1, *r2 = NULL; 32 register struct rdes *r1, *r2 = NULL;
28 register int i, j; 33 register int i, j;
29 register int roomcount; 34 register int roomcount;
30 static struct rdes 35 static struct rdes
128 /* 133 /*
129 * conn: 134 * conn:
130 * Draw a corridor from a room in a certain direction. 135 * Draw a corridor from a room in a certain direction.
131 */ 136 */
132 137
133 conn(r1, r2) 138 void
134 int r1, r2; 139 conn(int r1, int r2)
135 { 140 {
136 register struct room *rpf, *rpt = NULL; 141 register struct room *rpf, *rpt = NULL;
137 register char rmt; 142 register char rmt;
138 register int distance = 0, turn_spot = 0, turn_distance = 0; 143 register int distance = 0, turn_spot = 0, turn_distance = 0;
139 register int rm; 144 register int rm;
264 /* 269 /*
265 * Add a door or possibly a secret door 270 * Add a door or possibly a secret door
266 * also enters the door in the exits array of the room. 271 * also enters the door in the exits array of the room.
267 */ 272 */
268 273
269 door(rm, cp) 274 void
270 register struct room *rm; 275 door(struct room *rm, coord *cp)
271 register coord *cp;
272 { 276 {
273 struct linked_list *newroom; 277 struct linked_list *newroom;
274 coord *exit; 278 coord *exit;
275 279
276 cmov(*cp); 280 cmov(*cp);