Advanced Rogue 7: convert to ANSI-style function declarations.
Almost 1500 lines of compiler warnings remain, and the GCC developers are already working on a new version with even more warnings turned on by default.
This commit is contained in:
parent
f38b2223c8
commit
e8e6e604c3
39 changed files with 1181 additions and 889 deletions
|
|
@ -20,13 +20,14 @@
|
|||
#include "curses.h"
|
||||
#include "rogue.h"
|
||||
|
||||
int packweight(struct thing *tp);
|
||||
|
||||
/*
|
||||
* updpack:
|
||||
* Update his pack weight and adjust fooduse accordingly
|
||||
*/
|
||||
updpack(getmax, tp)
|
||||
int getmax;
|
||||
struct thing *tp;
|
||||
void
|
||||
updpack(int getmax, struct thing *tp)
|
||||
{
|
||||
|
||||
reg int topcarry, curcarry;
|
||||
|
|
@ -55,8 +56,8 @@ struct thing *tp;
|
|||
* packweight:
|
||||
* Get the total weight of the hero's pack
|
||||
*/
|
||||
packweight(tp)
|
||||
register struct thing *tp;
|
||||
int
|
||||
packweight(struct thing *tp)
|
||||
{
|
||||
reg struct object *obj;
|
||||
reg struct linked_list *pc;
|
||||
|
|
@ -92,8 +93,8 @@ register struct thing *tp;
|
|||
* itemweight:
|
||||
* Get the weight of an object
|
||||
*/
|
||||
itemweight(wh)
|
||||
reg struct object *wh;
|
||||
int
|
||||
itemweight(struct object *wh)
|
||||
{
|
||||
reg int weight;
|
||||
reg int ac;
|
||||
|
|
@ -123,8 +124,8 @@ reg struct object *wh;
|
|||
* playenc:
|
||||
* Get hero's carrying ability above norm
|
||||
*/
|
||||
playenc(tp)
|
||||
register struct thing *tp;
|
||||
int
|
||||
playenc(struct thing *tp)
|
||||
{
|
||||
register int strength;
|
||||
|
||||
|
|
@ -139,8 +140,8 @@ register struct thing *tp;
|
|||
* totalenc:
|
||||
* Get total weight that the hero can carry
|
||||
*/
|
||||
totalenc(tp)
|
||||
register struct thing *tp;
|
||||
int
|
||||
totalenc(struct thing *tp)
|
||||
{
|
||||
reg int wtotal;
|
||||
|
||||
|
|
@ -162,11 +163,11 @@ register struct thing *tp;
|
|||
* See if the hero can carry his pack
|
||||
*/
|
||||
|
||||
wghtchk()
|
||||
void
|
||||
wghtchk(void)
|
||||
{
|
||||
reg int dropchk, err = TRUE;
|
||||
reg char ch;
|
||||
int wghtchk();
|
||||
|
||||
inwhgt = TRUE;
|
||||
if (pstats.s_pack > pstats.s_carry) {
|
||||
|
|
@ -201,7 +202,8 @@ wghtchk()
|
|||
* -1 hit for heavy pack weight
|
||||
*/
|
||||
|
||||
hitweight()
|
||||
int
|
||||
hitweight(void)
|
||||
{
|
||||
return(2 - foodlev);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue