diff options
61 files changed, 534 insertions, 534 deletions
diff --git a/games/adventure/crc.c b/games/adventure/crc.c index 45e43036045..34020907e69 100644 --- a/games/adventure/crc.c +++ b/games/adventure/crc.c @@ -136,5 +136,5 @@ int nr; } crcval = (crcval << 8) ^ crctab[i]; } - return crcval & 0xffffffff; /* Mask to 32 bits. */ + return crcval & 0xffffffff; /* Mask to 32 bits. */ } diff --git a/games/adventure/done.c b/games/adventure/done.c index 464d606fb89..fad18181b5b 100644 --- a/games/adventure/done.c +++ b/games/adventure/done.c @@ -46,11 +46,11 @@ static char rcsid[] = "$NetBSD: done.c,v 1.2 1995/03/21 12:05:01 cgd Exp $"; #endif #endif /* not lint */ -/* Re-coding of advent in C: termination routines */ +/* Re-coding of advent in C: termination routines */ #include "hdr.h" -score() /* sort of like 20000 */ +score() /* sort of like 20000 */ { register int scor,i; mxscor=scor=0; for (i=50; i<=maxtrs; i++) @@ -86,7 +86,7 @@ score() /* sort of like 20000 */ return(scor); } -done(entry) /* entry=1 means goto 13000 */ /* game is over */ +done(entry) /* entry=1 means goto 13000 */ /* game is over */ int entry; /* entry=2 means goto 20000 */ /* 3=19000 */ { register int i,sc; if (entry==1) mspeak(1); @@ -114,14 +114,14 @@ int entry; /* entry=2 means goto 20000 */ /* 3=19000 */ } -die(entry) /* label 90 */ +die(entry) /* label 90 */ int entry; { register int i; if (entry != 99) { rspeak(23); oldlc2=loc; } - if (closng) /* 99 */ + if (closng) /* 99 */ { rspeak(131); numdie++; done(2); diff --git a/games/adventure/hdr.h b/games/adventure/hdr.h index 0143e561e0f..bfea417e047 100644 --- a/games/adventure/hdr.h +++ b/games/adventure/hdr.h @@ -57,10 +57,10 @@ #include <sys/types.h> #include <stdio.h> -int datfd; /* message file descriptor */ +int datfd; /* message file descriptor */ int delhit; int yea; -extern char data_file[]; /* Virtual data file */ +extern char data_file[]; /* Virtual data file */ #define TAB 011 #define LF 012 @@ -68,79 +68,79 @@ extern char data_file[]; /* Virtual data file */ #define FLUSHLF while (next()!=LF) int loc,newloc,oldloc,oldlc2,wzdark,gaveup,kq,k,k2; -char *wd1,*wd2; /* the complete words */ +char *wd1,*wd2; /* the complete words */ int verb,obj,spk; extern int blklin; int saved,savet,mxscor,latncy; -#define SHORT 50 /* How short is a demo game? */ +#define SHORT 50 /* How short is a demo game? */ -#define MAXSTR 20 /* max length of user's words */ +#define MAXSTR 20 /* max length of user's words */ -#define HTSIZE 512 /* max number of vocab words */ -struct hashtab /* hash table for vocabulary */ -{ int val; /* word type &index (ktab) */ - char *atab; /* pointer to actual string */ +#define HTSIZE 512 /* max number of vocab words */ +struct hashtab /* hash table for vocabulary */ +{ int val; /* word type &index (ktab) */ + char *atab; /* pointer to actual string */ } voc[HTSIZE]; -#define SEED 1815622 /* "Encryption" seed */ +#define SEED 1815622 /* "Encryption" seed */ struct text #ifdef OLDSTUFF -{ int seekadr; /* DATFILE must be < 2**16 */ +{ int seekadr; /* DATFILE must be < 2**16 */ #endif OLDSTUFF -{ char *seekadr; /* Msg start in virtual disk */ - int txtlen; /* length of msg starting here */ +{ char *seekadr; /* Msg start in virtual disk */ + int txtlen; /* length of msg starting here */ }; #define RTXSIZ 205 -struct text rtext[RTXSIZ]; /* random text messages */ +struct text rtext[RTXSIZ]; /* random text messages */ #define MAGSIZ 35 -struct text mtext[MAGSIZ]; /* magic messages */ +struct text mtext[MAGSIZ]; /* magic messages */ int clsses; #define CLSMAX 12 -struct text ctext[CLSMAX]; /* classes of adventurer */ +struct text ctext[CLSMAX]; /* classes of adventurer */ int cval[CLSMAX]; -struct text ptext[101]; /* object descriptions */ +struct text ptext[101]; /* object descriptions */ -#define LOCSIZ 141 /* number of locations */ -struct text ltext[LOCSIZ]; /* long loc description */ -struct text stext[LOCSIZ]; /* short loc descriptions */ +#define LOCSIZ 141 /* number of locations */ +struct text ltext[LOCSIZ]; /* long loc description */ +struct text stext[LOCSIZ]; /* short loc descriptions */ -struct travlist /* direcs & conditions of travel*/ -{ struct travlist *next; /* ptr to next list entry */ - int conditions; /* m in writeup (newloc / 1000) */ - int tloc; /* n in writeup (newloc % 1000) */ - int tverb; /* the verb that takes you there*/ -} *travel[LOCSIZ],*tkk; /* travel is closer to keys(...)*/ +struct travlist /* direcs & conditions of travel*/ +{ struct travlist *next; /* ptr to next list entry */ + int conditions; /* m in writeup (newloc / 1000) */ + int tloc; /* n in writeup (newloc % 1000) */ + int tverb; /* the verb that takes you there*/ +} *travel[LOCSIZ],*tkk; /* travel is closer to keys(...)*/ int atloc[LOCSIZ]; -int plac[101]; /* initial object placement */ -int fixd[101],fixed[101]; /* location fixed? */ +int plac[101]; /* initial object placement */ +int fixd[101],fixed[101]; /* location fixed? */ -int actspk[35]; /* rtext msg for verb <n> */ +int actspk[35]; /* rtext msg for verb <n> */ -int cond[LOCSIZ]; /* various condition bits */ +int cond[LOCSIZ]; /* various condition bits */ -extern int setbit[16]; /* bit defn masks 1,2,4,... */ +extern int setbit[16]; /* bit defn masks 1,2,4,... */ int hntmax; -int hints[20][5]; /* info on hints */ +int hints[20][5]; /* info on hints */ int hinted[20],hintlc[20]; int place[101], prop[101],linkx[201]; int abb[LOCSIZ]; -int maxtrs,tally,tally2; /* treasure values */ +int maxtrs,tally,tally2; /* treasure values */ #define FALSE 0 #define TRUE 1 -int keys,lamp,grate,cage,rod,rod2,steps,/* mnemonics */ +int keys,lamp,grate,cage,rod,rod2,steps,/* mnemonics */ bird,door,pillow,snake,fissur,tablet,clam,oyster,magzin, dwarf,knife,food,bottle,water,oil,plant,plant2,axe,mirror,dragon, chasm,troll,troll2,bear,messag,vend,batter, @@ -150,7 +150,7 @@ int keys,lamp,grate,cage,rod,rod2,steps,/* mnemonics */ enter, stream, pour, say,lock,throw,find,invent; -int chloc,chloc2,dseen[7],dloc[7], /* dwarf stuff */ +int chloc,chloc2,dseen[7],dloc[7], /* dwarf stuff */ odloc[7],dflag,daltlc; int tk[21],stick,dtotal,attack; diff --git a/games/adventure/init.c b/games/adventure/init.c index 298dc3b0a04..16bbe034d27 100644 --- a/games/adventure/init.c +++ b/games/adventure/init.c @@ -46,7 +46,7 @@ static char rcsid[] = "$NetBSD: init.c,v 1.4 1996/05/21 21:53:05 mrg Exp $"; #endif #endif /* not lint */ -/* Re-coding of advent in C: data initialization */ +/* Re-coding of advent in C: data initialization */ #include <sys/types.h> #include <signal.h> @@ -59,10 +59,10 @@ int setbit[16] = {1,2,4,010,020,040,0100,0200,0400,01000,02000,04000, 010000,020000,040000,0100000}; -init(command) /* everything for 1st time run */ -char *command; /* command we were called with */ +init(command) /* everything for 1st time run */ +char *command; /* command we were called with */ { - rdata(); /* read data from orig. file */ + rdata(); /* read data from orig. file */ linkdata(); poof(); } @@ -81,10 +81,10 @@ char a,b,c,d,e; return buf; } -linkdata() /* secondary data manipulation */ +linkdata() /* secondary data manipulation */ { register int i,j; - /* array linkages */ + /* array linkages */ for (i=1; i<=LOCSIZ; i++) if (ltext[i].seekadr!=0 && travel[i] != 0) if ((travel[i]->tverb)==1) cond[i]=2; @@ -202,9 +202,9 @@ linkdata() /* secondary data manipulation */ -trapdel() /* come here if he hits a del */ +trapdel() /* come here if he hits a del */ { delhit++; /* main checks, treats as QUIT */ - signal(SIGINT,trapdel); /* catch subsequent DELs */ + signal(SIGINT,trapdel); /* catch subsequent DELs */ } diff --git a/games/adventure/io.c b/games/adventure/io.c index fb7686ffacc..8137f2d4a92 100644 --- a/games/adventure/io.c +++ b/games/adventure/io.c @@ -46,26 +46,26 @@ static char rcsid[] = "$NetBSD: io.c,v 1.3 1995/04/24 12:21:37 cgd Exp $"; #endif #endif /* not lint */ -/* Re-coding of advent in C: file i/o and user i/o */ +/* Re-coding of advent in C: file i/o and user i/o */ #include "hdr.h" #include <stdio.h> #include <string.h> -getin(wrd1,wrd2) /* get command from user */ -char **wrd1,**wrd2; /* no prompt, usually */ +getin(wrd1,wrd2) /* get command from user */ +char **wrd1,**wrd2; /* no prompt, usually */ { register char *s; static char wd1buf[MAXSTR],wd2buf[MAXSTR]; int first, numch; - *wrd1=wd1buf; /* return ptr to internal string*/ + *wrd1=wd1buf; /* return ptr to internal string*/ *wrd2=wd2buf; - wd2buf[0]=0; /* in case it isn't set here */ + wd2buf[0]=0; /* in case it isn't set here */ for (s=wd1buf, first=1, numch=0;;) { if ((*s=getchar())>='A' && *s <='Z') *s = *s - ('A' -'a'); - /* convert to upper case */ - switch(*s) /* start reading from user */ + /* convert to upper case */ + switch(*s) /* start reading from user */ { case '\n': *s=0; return; @@ -78,7 +78,7 @@ char **wrd1,**wrd2; /* no prompt, usually */ s=wd2buf; break; } - else /* finished 2nd word */ + else /* finished 2nd word */ { FLUSHLINE; *s=0; return; @@ -99,12 +99,12 @@ char **wrd1,**wrd2; /* no prompt, usually */ } -confirm(mesg) /* confirm irreversible action */ +confirm(mesg) /* confirm irreversible action */ char *mesg; { register int result; register int c; - printf("%s",mesg); /* tell him what he did */ - if ((c = getchar())=='y') /* was his first letter a 'y'? */ + printf("%s",mesg); /* tell him what he did */ + if ((c = getchar())=='y') /* was his first letter a 'y'? */ result=1; else if (c == EOF) { printf("user closed input stream, quitting...\n"); @@ -114,12 +114,12 @@ char *mesg; return(result); } -yes(x,y,z) /* confirm with rspeak */ +yes(x,y,z) /* confirm with rspeak */ int x,y,z; { register int result; register int ch; for (;;) - { rspeak(x); /* tell him what we want*/ + { rspeak(x); /* tell him what we want*/ if ((ch=getchar())=='y') result=TRUE; else if (ch=='n') result=FALSE; @@ -136,12 +136,12 @@ int x,y,z; return(result); } -yesm(x,y,z) /* confirm with mspeak */ +yesm(x,y,z) /* confirm with mspeak */ int x,y,z; { register int result; register char ch; for (;;) - { mspeak(x); /* tell him what we want*/ + { mspeak(x); /* tell him what we want*/ if ((ch=getchar())=='y') result=TRUE; else if (ch=='n') result=FALSE; @@ -160,19 +160,19 @@ int x,y,z; /* FILE *inbuf,*outbuf; */ -char *inptr; /* Pointer into virtual disk */ +char *inptr; /* Pointer into virtual disk */ int outsw = 0; /* putting stuff to data file? */ char iotape[] = "Ax3F'\003tt$8h\315qer*h\017nGKrX\207:!l"; char *tape = iotape; /* pointer to encryption tape */ -next() /* next virtual char, bump adr */ +next() /* next virtual char, bump adr */ { int ch; - ch=(*inptr ^ random()) & 0xFF; /* Decrypt input data */ - if (outsw) /* putting data in tmp file */ + ch=(*inptr ^ random()) & 0xFF; /* Decrypt input data */ + if (outsw) /* putting data in tmp file */ { if (*tape==0) tape=iotape; /* rewind encryption tape */ *inptr = ch ^ *tape++; /* re-encrypt and replace value */ } @@ -180,18 +180,18 @@ next() /* next virtual char, bump adr */ return(ch); } -char breakch; /* tell which char ended rnum */ +char breakch; /* tell which char ended rnum */ -rdata() /* "read" data from virtual file*/ +rdata() /* "read" data from virtual file*/ { register int sect; register char ch; - inptr = data_file; /* Pointer to virtual data file */ - srandom(SEED); /* which is lightly encrypted. */ + inptr = data_file; /* Pointer to virtual data file */ + srandom(SEED); /* which is lightly encrypted. */ clsses=1; - for (;;) /* read data sections */ - { sect=next()-'0'; /* 1st digit of section number */ + for (;;) /* read data sections */ + { sect=next()-'0'; /* 1st digit of section number */ #ifdef VERBOSE printf("Section %c",sect+'0'); #endif @@ -207,44 +207,44 @@ rdata() /* "read" data from virtual file*/ putchar('\n'); #endif switch(sect) - { case 0: /* finished reading database */ + { case 0: /* finished reading database */ return; - case 1: /* long form descriptions */ + case 1: /* long form descriptions */ rdesc(1); break; - case 2: /* short form descriptions */ + case 2: /* short form descriptions */ rdesc(2); break; - case 3: /* travel table */ + case 3: /* travel table */ rtrav(); break; - case 4: /* vocabulary */ + case 4: /* vocabulary */ rvoc(); break; - case 5: /* object descriptions */ + case 5: /* object descriptions */ rdesc(5); break; - case 6: /* arbitrary messages */ + case 6: /* arbitrary messages */ rdesc(6); break; - case 7: /* object locations */ + case 7: /* object locations */ rlocs(); break; - case 8: /* action defaults */ + case 8: /* action defaults */ rdflt(); break; - case 9: /* liquid assets */ + case 9: /* liquid assets */ rliq(); break; - case 10: /* class messages */ + case 10: /* class messages */ rdesc(10); break; - case 11: /* hints */ + case 11: /* hints */ rhints(); break; - case 12: /* magic messages */ + case 12: /* magic messages */ rdesc(12); break; default: printf("Invalid data section number: %d\n",sect); for (;;) putchar(next()); } - if (breakch!=LF) /* routines return after "-1" */ + if (breakch!=LF) /* routines return after "-1" */ FLUSHLF; } } @@ -252,47 +252,47 @@ rdata() /* "read" data from virtual file*/ char nbf[12]; -rnum() /* read initial location num */ +rnum() /* read initial location num */ { register char *s; - tape = iotape; /* restart encryption tape */ + tape = iotape; /* restart encryption tape */ for (s=nbf,*s=0;; s++) if ((*s=next())==TAB || *s=='\n' || *s==LF) break; - breakch= *s; /* save char for rtrav() */ - *s=0; /* got the number as ascii */ - if (nbf[0]=='-') return(-1); /* end of data */ - return(atoi(nbf)); /* convert it to integer */ + breakch= *s; /* save char for rtrav() */ + *s=0; /* got the number as ascii */ + if (nbf[0]=='-') return(-1); /* end of data */ + return(atoi(nbf)); /* convert it to integer */ } char *seekhere; -rdesc(sect) /* read description-format msgs */ +rdesc(sect) /* read description-format msgs */ int sect; { register char *s,*t; register int locc; char *seekstart, *maystart, *adrstart; char *entry; - seekhere = inptr; /* Where are we in virtual file?*/ - outsw=1; /* these msgs go into tmp file */ + seekhere = inptr; /* Where are we in virtual file?*/ + outsw=1; /* these msgs go into tmp file */ for (oldloc= -1, seekstart=seekhere;;) - { maystart=inptr; /* maybe starting new entry */ + { maystart=inptr; /* maybe starting new entry */ if ((locc=rnum())!=oldloc && oldloc>=0 /* finished msg */ && ! (sect==5 && (locc==0 || locc>=100)))/* unless sect 5*/ { switch(sect) /* now put it into right table */ - { case 1: /* long descriptions */ + { case 1: /* long descriptions */ ltext[oldloc].seekadr=seekhere; ltext[oldloc].txtlen=maystart-seekstart; break; - case 2: /* short descriptions */ + case 2: /* short descriptions */ stext[oldloc].seekadr=seekhere; stext[oldloc].txtlen=maystart-seekstart; break; - case 5: /* object descriptions */ + case 5: /* object descriptions */ ptext[oldloc].seekadr=seekhere; ptext[oldloc].txtlen=maystart-seekstart; break; - case 6: /* random messages */ + case 6: /* random messages */ if (oldloc>RTXSIZ) { printf("Too many random msgs\n"); exit(0); @@ -300,12 +300,12 @@ int sect; rtext[oldloc].seekadr=seekhere; rtext[oldloc].txtlen=maystart-seekstart; break; - case 10: /* class messages */ + case 10: /* class messages */ ctext[clsses].seekadr=seekhere; ctext[clsses].txtlen=maystart-seekstart; cval[clsses++]=oldloc; break; - case 12: /* magic messages */ + case 12: /* magic messages */ if (oldloc>MAGSIZ) { printf("Too many magic msgs\n"); exit(0); @@ -320,8 +320,8 @@ int sect; seekhere += maystart-seekstart; } if (locc<0) - { outsw=0; /* turn off output */ - seekhere += 3; /* -1<delimiter> */ + { outsw=0; /* turn off output */ + seekhere += 3; /* -1<delimiter> */ return; } if (sect!=5 || (locc>0 && locc<100)) @@ -329,28 +329,28 @@ int sect; seekstart=maystart; oldloc=locc; } - FLUSHLF; /* scan the line */ + FLUSHLF; /* scan the line */ } } -rtrav() /* read travel table */ +rtrav() /* read travel table */ { register int locc; register struct travlist *t; register char *s; char buf[12]; int len,m,n,entries; - for (oldloc= -1;;) /* get another line */ + for (oldloc= -1;;) /* get another line */ { if ((locc=rnum())!=oldloc && oldloc>=0) /* end of entry */ { t->next = 0; /* terminate the old entry */ /* printf("%d:%d entries\n",oldloc,entries); */ - /* twrite(oldloc); */ + /* twrite(oldloc); */ } if (locc== -1) return; - if (locc!=oldloc) /* getting a new entry */ + if (locc!=oldloc) /* getting a new entry */ { t=travel[locc]=(struct travlist *) malloc(sizeof (struct travlist)); - /* printf("New travel list for %d\n",locc); */ + /* printf("New travel list for %d\n",locc); */ entries=0; oldloc=locc; } @@ -358,21 +358,21 @@ rtrav() /* read travel table */ if ((*s=next())==TAB || *s==LF) break; *s=0; len=length(buf)-1; /* quad long number handling */ - /* printf("Newloc: %s (%d chars)\n",buf,len); */ - if (len<4) /* no "m" conditions */ + /* printf("Newloc: %s (%d chars)\n",buf,len); */ + if (len<4) /* no "m" conditions */ { m=0; n=atoi(buf); /* newloc mod 1000 = newloc */ } - else /* a long integer */ + else /* a long integer */ { n=atoi(buf+len-3); - buf[len-3]=0; /* terminate newloc/1000 */ + buf[len-3]=0; /* terminate newloc/1000 */ m=atoi(buf); } while (breakch!=LF) /* only do one line at a time */ { if (entries++) t=t->next=(struct travlist *) malloc(sizeof (struct travlist)); t->tverb=rnum();/* get verb from the file */ - t->tloc=n; /* table entry mod 1000 */ - t->conditions=m;/* table entry / 1000 */ + t->tloc=n; /* table entry mod 1000 */ + t->conditions=m;/* table entry / 1000 */ /* printf("entry %d for %d\n",entries,locc); */ } } @@ -380,7 +380,7 @@ rtrav() /* read travel table */ #ifdef DEBUG -twrite(loq) /* travel options from this loc */ +twrite(loq) /* travel options from this loc */ int loq; { register struct travlist *t; printf("If"); @@ -401,13 +401,13 @@ int loq; #endif DEBUG rvoc() -{ register char *s; /* read the vocabulary */ +{ register char *s; /* read the vocabulary */ register int index; char buf[6]; for (;;) { index=rnum(); if (index<0) break; - for (s=buf,*s=0;; s++) /* get the word */ + for (s=buf,*s=0;; s++) /* get the word */ if ((*s=next())==TAB || *s=='\n' || *s==LF || *s==' ') break; /* terminate word with newline, LF, tab, blank */ @@ -420,28 +420,28 @@ rvoc() } -rlocs() /* initial object locations */ +rlocs() /* initial object locations */ { for (;;) { if ((obj=rnum())<0) break; plac[obj]=rnum(); /* initial loc for this obj */ - if (breakch==TAB) /* there's another entry */ + if (breakch==TAB) /* there's another entry */ fixd[obj]=rnum(); else fixd[obj]=0; } } -rdflt() /* default verb messages */ +rdflt() /* default verb messages */ { for (;;) { if ((verb=rnum())<0) break; actspk[verb]=rnum(); } } -rliq() /* liquid assets &c: cond bits */ +rliq() /* liquid assets &c: cond bits */ { register int bitnum; - for (;;) /* read new bit list */ + for (;;) /* read new bit list */ { if ((bitnum=rnum())<0) break; - for (;;) /* read locs for bits */ + for (;;) /* read locs for bits */ { cond[rnum()] |= setbit[bitnum]; if (breakch==LF) break; } @@ -480,10 +480,10 @@ struct text *msg;/* msg is a pointer to seek address and length of mess */ s = msg->seekadr; nonfirst=0; while (s - msg->seekadr < msg->txtlen) /* read a line at a time */ - { tape=iotape; /* restart decryption tape */ + { tape=iotape; /* restart decryption tape */ while ((*s++ ^ *tape++) != TAB); /* read past loc num */ - /* assume tape is longer than location number */ - /* plus the lookahead put together */ + /* assume tape is longer than location number */ + /* plus the lookahead put together */ if ((*s ^ *tape) == '>' && (*(s+1) ^ *(tape+1)) == '$' && (*(s+2) ^ *(tape+2)) == '<') break; @@ -496,8 +496,8 @@ struct text *msg;/* msg is a pointer to seek address and length of mess */ } -pspeak(m,skip) /* read, decrypt an print a ptext message */ -int m; /* msg is the number of all the p msgs for this place */ +pspeak(m,skip) /* read, decrypt an print a ptext message */ +int m; /* msg is the number of all the p msgs for this place */ int skip; /* assumes object 1 doesn't have prop 1, obj 2 no prop 2 &c*/ { register char *s,nonfirst; @@ -512,11 +512,11 @@ int skip; /* assumes object 1 doesn't have prop 1, obj 2 no prop 2 &c*/ nonfirst=0; while (s - tbuf < msg->txtlen) /* read line at a time */ - { tape=iotape; /* restart decryption tape */ + { tape=iotape; /* restart decryption tape */ for (numst=s; (*s^= *tape++)!=TAB; s++); /* get number */ save = *s; /* Temporarily trash the string (cringe) */ - *s++ = 0; /* decrypting number within the string */ + *s++ = 0; /* decrypting number within the string */ if (atoi(numst) != 100 * skip && skip >= 0) { while ((*s++^*tape++)!=LF) /* flush the line */ diff --git a/games/adventure/main.c b/games/adventure/main.c index aa113f85c7c..ca72b7530d8 100644 --- a/games/adventure/main.c +++ b/games/adventure/main.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: main.c,v 1.5 1996/05/21 21:53:09 mrg Exp $"; #endif #endif /* not lint */ -/* Re-coding of advent in C: main program */ +/* Re-coding of advent in C: main program */ #include <sys/file.h> #include <signal.h> @@ -71,11 +71,11 @@ char **argv; egid = getegid(); setegid(getgid()); - init(); /* Initialize everything */ + init(); /* Initialize everything */ signal(SIGINT,trapdel); if (argc > 1) /* Restore file specified */ - { /* Restart is label 8305 (Fortran) */ + { /* Restart is label 8305 (Fortran) */ i = restore(argv[1]); /* See what we've got */ switch(i) { @@ -83,29 +83,29 @@ char **argv; yea=Start(0); k=null; unlink(argv[1]);/* Don't re-use the save */ - goto l8; /* Get where we're going */ - case 1: /* Couldn't open it */ - exit(0); /* So give up */ - case 2: /* Oops -- file was altered */ + goto l8; /* Get where we're going */ + case 1: /* Couldn't open it */ + exit(0); /* So give up */ + case 2: /* Oops -- file was altered */ rspeak(202); /* You dissolve */ - exit(0); /* File could be non-adventure */ - } /* So don't unlink it. */ + exit(0); /* File could be non-adventure */ + } /* So don't unlink it. */ } - startup(); /* prepare for a user */ + startup(); /* prepare for a user */ - for (;;) /* main command loop (label 2) */ + for (;;) /* main command loop (label 2) */ { if (newloc<9 && newloc!=0 && closng) { rspeak(130); /* if closing leave only by */ - newloc=loc; /* main office */ + newloc=loc; /* main office */ if (!panic) clock2=15; panic=TRUE; } - rval=fdwarf(); /* dwarf stuff */ + rval=fdwarf(); /* dwarf stuff */ if (rval==99) die(99); - l2000: if (loc==0) die(99); /* label 2000 */ + l2000: if (loc==0) die(99); /* label 2000 */ kk = &stext[loc]; if ((abb[loc]%abbnum)==0 || kk->seekadr==0) kk = <ext[loc]; @@ -116,7 +116,7 @@ char **argv; } kk = &rtext[16]; } - l2001: if (toting(bear)) rspeak(141); /* 2001 */ + l2001: if (toting(bear)) rspeak(141); /* 2001 */ speak(kk); k=1; if (forced(loc)) @@ -137,19 +137,19 @@ char **argv; if (tally==tally2 && tally != 0) if (limit>35) limit=35; } - ll = prop[obj]; /* 2006 */ + ll = prop[obj]; /* 2006 */ if (obj==steps && loc==fixed[steps]) ll = 1; pspeak(obj, ll); - } /* 2008 */ + } /* 2008 */ goto l2012; - l2009: k=54; /* 2009 */ - l2010: spk=k; - l2011: rspeak(spk); + l2009: k=54; /* 2009 */ + l2010: spk=k; + l2011: rspeak(spk); } - l2012: verb=0; /* 2012 */ + l2012: verb=0; /* 2012 */ obj=0; - l2600: checkhints(); /* to 2600-2602 */ + l2600: checkhints(); /* to 2600-2602 */ if (closed) { if (prop[oyster]<0 && toting(oyster)) pspeak(oyster,1); @@ -157,16 +157,16 @@ char **argv; if (toting(i)&&prop[i]<0) /*2604 */ prop[i] = -1-prop[i]; } - wzdark=dark(0); /* 2605 */ + wzdark=dark(0); /* 2605 */ if (knfloc>0 && knfloc!=loc) knfloc=1; getin(&wd1,&wd2); - if (delhit) /* user typed a DEL */ - { delhit=0; /* reset counter */ + if (delhit) /* user typed a DEL */ + { delhit=0; /* reset counter */ copystr("quit",wd1); /* pretend he's quitting*/ *wd2=0; } - l2608: if ((foobar = -foobar)>0) foobar=0; /* 2608 */ - /* should check here for "magic mode" */ + l2608: if ((foobar = -foobar)>0) foobar=0; /* 2608 */ + /* should check here for "magic mode" */ turns++; if (demo && turns>=SHORT) done(1); /* to 13000 */ @@ -175,18 +175,18 @@ char **argv; goto l4090; if (tally==0 && loc>=15 && loc!=33) clock1--; if (clock1==0) - { closing(); /* to 10000 */ + { closing(); /* to 10000 */ goto l19999; } if (clock1<0) clock2--; if (clock2==0) - { caveclose(); /* to 11000 */ - continue; /* back to 2 */ + { caveclose(); /* to 11000 */ + continue; /* back to 2 */ } if (prop[lamp]==1) limit--; if (limit<=30 && here(batter) && prop[batter]==0 && here(lamp)) - { rspeak(188); /* 12000 */ + { rspeak(188); /* 12000 */ prop[batter]=1; if (toting(batter)) drop(batter,loc); limit=limit+2500; @@ -194,15 +194,15 @@ char **argv; goto l19999; } if (limit==0) - { limit = -1; /* 12400 */ + { limit = -1; /* 12400 */ prop[lamp]=0; rspeak(184); goto l19999; } if (limit<0&&loc<=8) - { rspeak(185); /* 12600 */ + { rspeak(185); /* 12600 */ gaveup=TRUE; - done(2); /* to 20000 */ + done(2); /* to 20000 */ } if (limit<=30) { if (lmwarn|| !here(lamp)) goto l19999; /*12200*/ @@ -227,7 +227,7 @@ char **argv; if (++iwest==10) rspeak(17); l2630: i=vocab(wd1,-1); if (i== -1) - { spk=60; /* 3000 */ + { spk=60; /* 3000 */ if (pct(20)) spk=61; if (pct(20)) spk=13; rspeak(spk); @@ -247,7 +247,7 @@ char **argv; l8: switch(march()) - { case 2: continue; /* i.e. goto l2 */ + { case 2: continue; /* i.e. goto l2 */ case 99: switch(die(99)) { case 2000: goto l2000; @@ -267,20 +267,20 @@ char **argv; if (obj!=0) goto l4090; l4080: switch(verb) - { case 1: /* take = 8010 */ + { case 1: /* take = 8010 */ if (atloc[loc]==0||linkx[atloc[loc]]!=0) goto l8000; for (i=1; i<=5; i++) if (dloc[i]==loc&&dflag>=2) goto l8000; obj=atloc[loc]; goto l9010; case 2: case 3: case 9: /* 8000 : drop,say,wave */ - case 10: case 16: case 17: /* calm,rub,toss */ + case 10: case 16: case 17: /* calm,rub,toss */ case 19: case 21: case 28: /* find,feed,break */ - case 29: /* wake */ + case 29: /* wake */ l8000: printf("%s what?\n",wd1); obj=0; goto l2600; - case 4: case 6: /* 8040 open,lock */ + case 4: case 6: /* 8040 open,lock */ spk=28; if (here(clam)) obj=clam; if (here(oyster)) obj=oyster; @@ -290,23 +290,23 @@ char **argv; if (here(chain)) obj=chain; if (obj==0) goto l2011; goto l9040; - case 5: goto l2009; /* nothing */ - case 7: goto l9070; /* on */ - case 8: goto l9080; /* off */ - case 11: goto l8000; /* walk */ - case 12: goto l9120; /* kill */ - case 13: goto l9130; /* pour */ - case 14: /* eat: 8140 */ + case 5: goto l2009; /* nothing */ + case 7: goto l9070; /* on */ + case 8: goto l9080; /* off */ + case 11: goto l8000; /* walk */ + case 12: goto l9120; /* kill */ + case 13: goto l9130; /* pour */ + case 14: /* eat: 8140 */ if (!here(food)) goto l8000; l8142: dstroy(food); spk=72; goto l2011; - case 15: goto l9150; /* drink */ - case 18: /* quit: 8180 */ + case 15: goto l9150; /* drink */ + case 18: /* quit: 8180 */ gaveup=yes(22,54,54); - if (gaveup) done(2); /* 8185 */ + if (gaveup) done(2); /* 8185 */ goto l2012; - case 20: /* invent=8200 */ + case 20: /* invent=8200 */ spk=98; for (i=1; i<=100; i++) { if (i!=bear && toting(i)) @@ -319,9 +319,9 @@ char **argv; } if (toting(bear)) spk=141; goto l2011; - case 22: goto l9220; /* fill */ - case 23: goto l9230; /* blast */ - case 24: /* score: 8240 */ + case 22: goto l9220; /* fill */ + case 23: goto l9230; /* blast */ + case 24: /* score: 8240 */ scorng=TRUE; printf("If you were to quit now, you would score"); printf(" %d out of a possible ",score()); @@ -330,7 +330,7 @@ char **argv; gaveup=yes(143,54,54); if (gaveup) done(2); goto l2012; - case 25: /* foo: 8250 */ + case 25: /* foo: 8250 */ k=vocab(wd1,3); spk=42; if (foobar==1-k) goto l8252; @@ -349,19 +349,19 @@ char **argv; move(eggs,plac[eggs]); pspeak(eggs,k); goto l2012; - case 26: /* brief=8260 */ + case 26: /* brief=8260 */ spk=156; abbnum=10000; detail=3; goto l2011; - case 27: /* read=8270 */ + case 27: /* read=8270 */ if (here(magzin)) obj=magzin; if (here(tablet)) obj=obj*100+tablet; if (here(messag)) obj=obj*100+messag; if (closed&&toting(oyster)) obj=oyster; if (obj>100||obj==0||dark(0)) goto l8000; goto l9270; - case 30: /* suspend=8300 */ + case 30: /* suspend=8300 */ spk=201; if (demo) goto l2011; printf("I can suspend your adventure for you so"); @@ -370,9 +370,9 @@ char **argv; printf(" %d minutes before continuing.",latncy); if (!yes(200,54,54)) goto l2012; datime(&saved,&savet); - ciao(argv[0]); /* Do we quit? */ - continue; /* Maybe not */ - case 31: /* hours=8310 */ + ciao(argv[0]); /* Do we quit? */ + continue; /* Maybe not */ + case 31: /* hours=8310 */ printf("Colossal cave is closed 9am-5pm Mon "); printf("through Fri except holidays.\n"); goto l2012; @@ -381,15 +381,15 @@ char **argv; l4090: switch(verb) - { case 1: /* take = 9010 */ - l9010: switch(trtake()) + { case 1: /* take = 9010 */ + l9010: switch(trtake()) { case 2011: goto l2011; case 9220: goto l9220; case 2009: goto l2009; case 2012: goto l2012; default: bug(102); } - l9020: case 2: /* drop = 9020 */ + l9020: case 2: /* drop = 9020 */ switch(trdrop()) { case 2011: goto l2011; case 19000: done(3); @@ -402,15 +402,15 @@ char **argv; case 2630: goto l2630; default: bug(107); } - l9040: case 4: case 6: /* open, close */ + l9040: case 4: case 6: /* open, close */ switch(tropen()) { case 2011: goto l2011; case 2010: goto l2010; default: bug(106); } - case 5: goto l2009; /* nothing */ - case 7: /* on 9070 */ - l9070: if (!here(lamp)) goto l2011; + case 5: goto l2009; /* nothing */ + case 7: /* on 9070 */ + l9070: if (!here(lamp)) goto l2011; spk=184; if (limit<0) goto l2011; prop[lamp]=1; @@ -418,14 +418,14 @@ char **argv; if (wzdark) goto l2000; goto l2012; - case 8: /* off */ - l9080: if (!here(lamp)) goto l2011; + case 8: /* off */ + l9080: if (!here(lamp)) goto l2011; prop[lamp]=0; rspeak(40); if (dark(0)) rspeak(16); goto l2012; - case 9: /* wave */ + case 9: /* wave */ if ((!toting(obj))&&(obj!=rod||!toting(rod2))) spk=29; if (obj!=rod||!at(fissur)||!toting(obj)||closng) @@ -435,9 +435,9 @@ char **argv; goto l2012; case 10: case 11: case 18: /* calm, walk, quit */ case 24: case 25: case 26: /* score, foo, brief */ - case 30: case 31: /* suspend, hours */ + case 30: case 31: /* suspend, hours */ goto l2011; - l9120: case 12: /* kill */ + l9120: case 12: /* kill */ switch(trkill()) { case 8000: goto l8000; case 8: goto l8; @@ -446,7 +446,7 @@ char **argv; case 19000: done(3); default: bug(112); } - l9130: case 13: /* pour */ + l9130: case 13: /* pour */ if (obj==bottle||obj==0) obj=liq(0); if (obj==0) goto l8000; if (!toting(obj)) goto l2011; @@ -457,7 +457,7 @@ char **argv; spk=77; if (!(at(plant)||at(door))) goto l2011; if (at(door)) - { prop[door]=0; /* 9132 */ + { prop[door]=0; /* 9132 */ if (obj==oil) prop[door]=1; spk=113+prop[door]; goto l2011; @@ -469,13 +469,13 @@ char **argv; prop[plant2]=prop[plant]/2; k=null; goto l8; - case 14: /* 9140 - eat */ + case 14: /* 9140 - eat */ if (obj==food) goto l8142; if (obj==bird||obj==snake||obj==clam||obj==oyster ||obj==dwarf||obj==dragon||obj==troll ||obj==bear) spk=71; goto l2011; - l9150: case 15: /* 9150 - drink */ + l9150: case 15: /* 9150 - drink */ if (obj==0&&liqloc(loc)!=water&&(liq(0)!=water ||!here(bottle))) goto l8000; if (obj!=0&&obj!=water) spk=110; @@ -485,10 +485,10 @@ char **argv; place[water]=0; spk=74; goto l2011; - case 16: /* 9160: rub */ + case 16: /* 9160: rub */ if (obj!=lamp) spk=76; goto l2011; - case 17: /* 9170: throw */ + case 17: /* 9170: throw */ switch(trtoss()) { case 2011: goto l2011; case 9020: goto l9020; @@ -497,7 +497,7 @@ char **argv; case 9210: goto l9210; default: bug(113); } - case 19: case 20: /* 9190: find, invent */ + case 19: case 20: /* 9190: find, invent */ if (at(obj)||(liq(0)==obj&&at(bottle)) ||k==liqloc(loc)) spk=94; for (i=1; i<=5; i++) @@ -506,26 +506,26 @@ char **argv; if (closed) spk=138; if (toting(obj)) spk=24; goto l2011; - l9210: case 21: /* feed */ + l9210: case 21: /* feed */ switch(trfeed()) { case 2011: goto l2011; default: bug(114); } - l9220: case 22: /* fill */ + l9220: case 22: /* fill */ switch(trfill()) { case 2011: goto l2011; case 8000: goto l8000; case 9020: goto l9020; default: bug(115); } - l9230: case 23: /* blast */ + l9230: case 23: /* blast */ if (prop[rod2]<0||!closed) goto l2011; bonus=133; if (loc==115) bonus=134; if (here(rod2)) bonus=135; rspeak(bonus); done(2); - l9270: case 27: /* read */ + l9270: case 27: /* read */ if (dark(0)) goto l5190; if (obj==magzin) spk=190; if (obj==tablet) spk=196; @@ -535,7 +535,7 @@ char **argv; ||!closed) goto l2011; hinted[2]=yes(192,193,54); goto l2012; - l9280: case 28: /* break */ + l9280: case 28: /* break */ if (obj==mirror) spk=148; if (obj==vase&&prop[vase]==0) { spk=198; @@ -548,7 +548,7 @@ char **argv; rspeak(197); done(3); - l9290: case 29: /* wake */ + l9290: case 29: /* wake */ if (obj!=dwarf||!closed) goto l2011; rspeak(199); done(3); diff --git a/games/adventure/save.c b/games/adventure/save.c index 77f36f09c3d..f4bbb5c2660 100644 --- a/games/adventure/save.c +++ b/games/adventure/save.c @@ -59,66 +59,66 @@ struct savestruct struct savestruct save_array[] = { - &abbnum, sizeof(abbnum), - &attack, sizeof(attack), - &blklin, sizeof(blklin), - &bonus, sizeof(bonus), - &chloc, sizeof(chloc), - &chloc2, sizeof(chloc2), - &clock1, sizeof(clock1), - &clock2, sizeof(clock2), - &closed, sizeof(closed), - &closng, sizeof(closng), - &daltlc, sizeof(daltlc), - &demo, sizeof(demo), - &detail, sizeof(detail), - &dflag, sizeof(dflag), - &dkill, sizeof(dkill), - &dtotal, sizeof(dtotal), - &foobar, sizeof(foobar), - &gaveup, sizeof(gaveup), - &holdng, sizeof(holdng), - &iwest, sizeof(iwest), - &k, sizeof(k), - &k2, sizeof(k2), - &knfloc, sizeof(knfloc), - &kq, sizeof(kq), - &latncy, sizeof(latncy), - &limit, sizeof(limit), - &lmwarn, sizeof(lmwarn), - &loc, sizeof(loc), - &maxdie, sizeof(maxdie), - &mxscor, sizeof(mxscor), - &newloc, sizeof(newloc), - &numdie, sizeof(numdie), - &obj, sizeof(obj), - &oldlc2, sizeof(oldlc2), - &oldloc, sizeof(oldloc), - &panic, sizeof(panic), - &saved, sizeof(saved), - &savet, sizeof(savet), - &scorng, sizeof(scorng), - &spk, sizeof(spk), - &stick, sizeof(stick), - &tally, sizeof(tally), - &tally2, sizeof(tally2), - &tkk, sizeof(tkk), - &turns, sizeof(turns), - &verb, sizeof(verb), - &wd1, sizeof(wd1), - &wd2, sizeof(wd2), - &wzdark, sizeof(wzdark), - &yea, sizeof(yea), - atloc, sizeof(atloc), - dloc, sizeof(dloc), - dseen, sizeof(dseen), - fixed, sizeof(fixed), - hinted, sizeof(hinted), - linkx, sizeof(linkx), - odloc, sizeof(odloc), - place, sizeof(place), - prop, sizeof(prop), - tk, sizeof(tk), + &abbnum, sizeof(abbnum), + &attack, sizeof(attack), + &blklin, sizeof(blklin), + &bonus, sizeof(bonus), + &chloc, sizeof(chloc), + &chloc2, sizeof(chloc2), + &clock1, sizeof(clock1), + &clock2, sizeof(clock2), + &closed, sizeof(closed), + &closng, sizeof(closng), + &daltlc, sizeof(daltlc), + &demo, sizeof(demo), + &detail, sizeof(detail), + &dflag, sizeof(dflag), + &dkill, sizeof(dkill), + &dtotal, sizeof(dtotal), + &foobar, sizeof(foobar), + &gaveup, sizeof(gaveup), + &holdng, sizeof(holdng), + &iwest, sizeof(iwest), + &k, sizeof(k), + &k2, sizeof(k2), + &knfloc, sizeof(knfloc), + &kq, sizeof(kq), + &latncy, sizeof(latncy), + &limit, sizeof(limit), + &lmwarn, sizeof(lmwarn), + &loc, sizeof(loc), + &maxdie, sizeof(maxdie), + &mxscor, sizeof(mxscor), + &newloc, sizeof(newloc), + &numdie, sizeof(numdie), + &obj, sizeof(obj), + &oldlc2, sizeof(oldlc2), + &oldloc, sizeof(oldloc), + &panic, sizeof(panic), + &saved, sizeof(saved), + &savet, sizeof(savet), + &scorng, sizeof(scorng), + &spk, sizeof(spk), + &stick, sizeof(stick), + &tally, sizeof(tally), + &tally2, sizeof(tally2), + &tkk, sizeof(tkk), + &turns, sizeof(turns), + &verb, sizeof(verb), + &wd1, sizeof(wd1), + &wd2, sizeof(wd2), + &wzdark, sizeof(wzdark), + &yea, sizeof(yea), + atloc, sizeof(atloc), + dloc, sizeof(dloc), + dseen, sizeof(dseen), + fixed, sizeof(fixed), + hinted, sizeof(hinted), + linkx, sizeof(linkx), + odloc, sizeof(odloc), + place, sizeof(place), + prop, sizeof(prop), + tk, sizeof(tk), NULL, 0 }; @@ -179,7 +179,7 @@ char *infile; } setegid(getgid()); - fread(&sum, sizeof(sum), 1, in); /* Get the seed */ + fread(&sum, sizeof(sum), 1, in); /* Get the seed */ srandom((int) sum); for (p = save_array; p->address != NULL; p++) { @@ -189,11 +189,11 @@ char *infile; } fclose(in); - crc_start(); /* See if she cheated */ + crc_start(); /* See if she cheated */ for (p = save_array; p->address != NULL; p++) cksum = crc(p->address, p->width); - if (sum != cksum) /* Tsk tsk */ - return 2; /* Altered the file */ + if (sum != cksum) /* Tsk tsk */ + return 2; /* Altered the file */ /* We successfully restored, so this really was a save file */ /* Get rid of the file, but don't bother checking that we did */ return 0; diff --git a/games/adventure/setup.c b/games/adventure/setup.c index c5c4a96c182..a5a520c07b7 100644 --- a/games/adventure/setup.c +++ b/games/adventure/setup.c @@ -64,7 +64,7 @@ static char rcsid[] = "$NetBSD: setup.c,v 1.2 1995/03/21 12:05:10 cgd Exp $"; #define SIG2 " * Sterday, 6 Thrimidge S.R. 1993, 15:24" #include <stdio.h> -#include "hdr.h" /* SEED lives in there; keep them coordinated. */ +#include "hdr.h" /* SEED lives in there; keep them coordinated. */ #define USAGE "Usage: setup file > data.c (file is typically glorkz)\n" @@ -73,7 +73,7 @@ static char rcsid[] = "$NetBSD: setup.c,v 1.2 1995/03/21 12:05:10 cgd Exp $"; void fatal(); -#define LINE 10 /* How many values do we get on a line? */ +#define LINE 10 /* How many values do we get on a line? */ main(argc, argv) int argc; diff --git a/games/adventure/subr.c b/games/adventure/subr.c index 9ee6d6f728b..4101c3223b6 100644 --- a/games/adventure/subr.c +++ b/games/adventure/subr.c @@ -46,11 +46,11 @@ static char rcsid[] = "$NetBSD: subr.c,v 1.2 1995/03/21 12:05:11 cgd Exp $"; #endif #endif /* not lint */ -/* Re-coding of advent in C: subroutines from main */ +/* Re-coding of advent in C: subroutines from main */ # include "hdr.h" -/* Statement functions */ +/* Statement functions */ toting(objj) int objj; { if (place[objj] == -1) return(TRUE); @@ -150,7 +150,7 @@ fdwarf() /* 71 */ return(2000); } dtotal=attack=stick=0; /* 6010 */ - for (i=1; i<=6; i++) /* loop to 6030 */ + for (i=1; i<=6; i++) /* loop to 6030 */ { if (dloc[i]==0) continue; j=1; for (kk=travel[dloc[i]]; kk!=0; kk=kk->next) @@ -162,15 +162,15 @@ fdwarf() /* 71 */ ||kk->conditions==100) continue; tk[j++]=newloc; } - tk[j]=odloc[i]; /* 6016 */ + tk[j]=odloc[i]; /* 6016 */ if (j>=2) j--; j=1+ran(j); odloc[i]=dloc[i]; dloc[i]=tk[j]; dseen[i]=(dseen[i]&&loc>=15)||(dloc[i]==loc||odloc[i]==loc); - if (!dseen[i]) continue; /* i.e. goto 6030 */ + if (!dseen[i]) continue; /* i.e. goto 6030 */ dloc[i]=loc; - if (i==6) /* pirate's spotted him */ + if (i==6) /* pirate's spotted him */ { if (loc==chloc||prop[chest]>=0) continue; k=0; for (j=50; j<=maxtrs; j++) /* loop to 6020 */ @@ -178,7 +178,7 @@ fdwarf() /* 71 */ || loc==plac[emrald])) goto l6020; if (toting(j)) goto l6022; l6020: if (here(j)) k=1; - } /* 6020 */ + } /* 6020 */ if (tally==tally2+1 && k==0 && place[chest]==0 &&here(lamp) && prop[lamp]==1) goto l6025; if (odloc[6]!=dloc[6]&&pct(20)) @@ -201,12 +201,12 @@ fdwarf() /* 71 */ move(messag,chloc2); goto l6024; } - dtotal++; /* 6027 */ + dtotal++; /* 6027 */ if (odloc[i]!=dloc[i]) continue; attack++; if (knfloc>=0) knfloc=loc; if (ran(1000)<95*(dflag-2)) stick++; - } /* 6030 */ + } /* 6030 */ if (dtotal==0) return(2000); if (dtotal!=1) { printf("There are %d threatening little dwarves ",dtotal); @@ -219,7 +219,7 @@ fdwarf() /* 71 */ if (attack!=1) { printf("%d of them throw knives at you!\n",attack); k=6; - l82: if (stick<=1) /* 82 */ + l82: if (stick<=1) /* 82 */ { rspeak(k+stick); if (stick==0) return(2000); } @@ -234,23 +234,23 @@ fdwarf() /* 71 */ } -march() /* label 8 */ +march() /* label 8 */ { register int ll1,ll2; if ((tkk=travel[newloc=loc])==0) bug(26); if (k==null) return(2); - if (k==cave) /* 40 */ + if (k==cave) /* 40 */ { if (loc<8) rspeak(57); if (loc>=8) rspeak(58); return(2); } - if (k==look) /* 30 */ + if (k==look) /* 30 */ { if (detail++<3) rspeak(15); wzdark=FALSE; abb[loc]=0; return(2); } - if (k==back) /* 20 */ + if (k==back) /* 20 */ { switch(mback()) { case 2: return(2); case 9: goto l9; @@ -266,17 +266,17 @@ l9: { badmove(); return(2); } -l11: ll1=tkk->conditions; /* 11 */ +l11: ll1=tkk->conditions; /* 11 */ ll2=tkk->tloc; - newloc=ll1; /* newloc=conditions */ - k=newloc%100; /* k used for prob */ + newloc=ll1; /* newloc=conditions */ + k=newloc%100; /* k used for prob */ if (newloc<=300) - { if (newloc<=100) /* 13 */ + { if (newloc<=100) /* 13 */ { if (newloc!=0&&!pct(newloc)) goto l12; /* 14 */ - l16: newloc=ll2; /* newloc=location */ + l16: newloc=ll2; /* newloc=location */ if (newloc<=300) return(2); if (newloc<=500) - switch(specials())/* to 30000 */ + switch(specials())/* to 30000 */ { case 2: return(2); case 12: goto l12; case 99: return(99); @@ -299,10 +299,10 @@ l12: /* alternative to probability move */ -mback() /* 20 */ +mback() /* 20 */ { register struct travlist *tk2,*j; register int ll; - if (forced(k=oldloc)) k=oldlc2; /* k=location */ + if (forced(k=oldloc)) k=oldlc2; /* k=location */ oldlc2=oldloc; oldloc=loc; tk2=0; @@ -310,10 +310,10 @@ mback() /* 20 */ { rspeak(91); return(2); } - for (; tkk!=0; tkk=tkk->next) /* 21 */ + for (; tkk!=0; tkk=tkk->next) /* 21 */ { ll=tkk->tloc; if (ll==k) - { k=tkk->tverb; /* k back to verb */ + { k=tkk->tverb; /* k back to verb */ tkk=travel[loc]; return(9); } @@ -322,7 +322,7 @@ mback() /* 20 */ if (forced(ll) && k==j->tloc) tk2=tkk; } } - tkk=tk2; /* 23 */ + tkk=tk2; /* 23 */ if (tkk!=0) { k=tkk->tverb; tkk=travel[loc]; @@ -333,25 +333,25 @@ mback() /* 20 */ } -specials() /* 30000 */ +specials() /* 30000 */ { switch(newloc -= 300) - { case 1: /* 30100 */ + { case 1: /* 30100 */ newloc = 99+100-loc; if (holdng==0||(holdng==1&&toting(emrald))) return(2); newloc=loc; rspeak(117); return(2); - case 2: /* 30200 */ + case 2: /* 30200 */ drop(emrald,loc); return(12); - case 3: /* to 30300 */ + case 3: /* to 30300 */ return(trbridge()); default: bug(29); } } -trbridge() /* 30300 */ +trbridge() /* 30300 */ { if (prop[troll]==1) { pspeak(troll,1); prop[troll]=0; @@ -363,7 +363,7 @@ trbridge() /* 30300 */ newloc=loc; return(2); } - newloc=plac[troll]+fixd[troll]-loc; /* 30310 */ + newloc=plac[troll]+fixd[troll]-loc; /* 30310 */ if (prop[troll]==0) prop[troll]=1; if (!toting(bear)) return(2); rspeak(162); @@ -378,7 +378,7 @@ trbridge() /* 30300 */ } -badmove() /* 20 */ +badmove() /* 20 */ { spk=12; if (k>=43 && k<=50) spk=9; if (k==29||k==30) spk=9; @@ -398,7 +398,7 @@ int n; } -checkhints() /* 2600 &c */ +checkhints() /* 2600 &c */ { register int hint; for (hint=4; hint<=hntmax; hint++) { if (hinted[hint]) continue; @@ -436,7 +436,7 @@ checkhints() /* 2600 &c */ } -trsay() /* 9030 */ +trsay() /* 9030 */ { register int i; if (*wd2!=0) copystr(wd2,wd1); i=vocab(wd1,-1); @@ -450,7 +450,7 @@ trsay() /* 9030 */ } -trtake() /* 9010 */ +trtake() /* 9010 */ { register int i; if (toting(obj)) return(2011); /* 9010 */ spk=25; @@ -484,7 +484,7 @@ l9017: if (holdng>=7) { rspeak(27); return(2012); } - prop[bird]=1; /* 9015 */ + prop[bird]=1; /* 9015 */ } l9014: if ((obj==bird||obj==cage)&&prop[bird]!=0) carry(bird+cage-obj,loc); @@ -495,7 +495,7 @@ l9014: if ((obj==bird||obj==cage)&&prop[bird]!=0) } -dropper() /* 9021 */ +dropper() /* 9021 */ { k=liq(0); if (k==obj) obj=bottle; if (obj==bottle&&k!=0) place[k]=0; @@ -505,7 +505,7 @@ dropper() /* 9021 */ return(2012); } -trdrop() /* 9020 */ +trdrop() /* 9020 */ { if (toting(rod2)&&obj==rod&&!toting(rod)) obj=rod2; if (!toting(obj)) return(2011); @@ -516,20 +516,20 @@ trdrop() /* 9020 */ prop[snake]=1; return(dropper()); } - if (obj==coins&&here(vend)) /* 9024 */ + if (obj==coins&&here(vend)) /* 9024 */ { dstroy(coins); drop(batter,loc); pspeak(batter,0); return(2012); } - if (obj==bird&&at(dragon)&&prop[dragon]==0) /* 9025 */ + if (obj==bird&&at(dragon)&&prop[dragon]==0) /* 9025 */ { rspeak(154); dstroy(bird); prop[bird]=0; if (place[snake]==plac[snake]) tally2--; return(2012); } - if (obj==bear&&at(troll)) /* 9026 */ + if (obj==bear&&at(troll)) /* 9026 */ { rspeak(163); move(troll,0); move(troll+100,0); @@ -539,11 +539,11 @@ trdrop() /* 9020 */ prop[troll]=2; return(dropper()); } - if (obj!=vase||loc==plac[pillow]) /* 9027 */ + if (obj!=vase||loc==plac[pillow]) /* 9027 */ { rspeak(54); return(dropper()); } - prop[vase]=2; /* 9028 */ + prop[vase]=2; /* 9028 */ if (at(pillow)) prop[vase]=0; pspeak(vase,prop[vase]+1); if (prop[vase]!=0) fixed[vase] = -1; @@ -551,9 +551,9 @@ trdrop() /* 9020 */ } -tropen() /* 9040 */ +tropen() /* 9040 */ { if (obj==clam||obj==oyster) - { k=0; /* 9046 */ + { k=0; /* 9046 */ if (obj==oyster) k=1; spk=124+k; if (toting(obj)) spk=120+k; @@ -573,7 +573,7 @@ tropen() /* 9040 */ if (spk!=31||!here(keys)) return(2011); if (obj==chain) { if (verb==lock) - { spk=172; /* 9049: lock */ + { spk=172; /* 9049: lock */ if (prop[chain]!=0) spk=34; if (loc!=plac[chain]) spk=173; if (spk!=172) return(2011); @@ -598,7 +598,7 @@ tropen() /* 9040 */ panic=TRUE; return(2010); } - k=34+prop[grate]; /* 9043 */ + k=34+prop[grate]; /* 9043 */ prop[grate]=1; if (verb==lock) prop[grate]=0; k=k+2*prop[grate]; @@ -606,12 +606,12 @@ tropen() /* 9040 */ } -trkill() /* 9120 */ +trkill() /* 9120 */ { register int i; for (i=1; i<=5; i++) if (dloc[i]==loc&&dflag>=2) break; if (i==6) i=0; - if (obj==0) /* 9122 */ + if (obj==0) /* 9122 */ { if (i!=0) obj=dwarf; if (here(snake)) obj=obj*100+snake; if (at(dragon)&&prop[dragon]==0) obj=obj*100+dragon; @@ -624,7 +624,7 @@ trkill() /* 9120 */ if (obj>100) return(8000); } } - if (obj==bird) /* 9124 */ + if (obj==bird) /* 9124 */ { spk=137; if (closed) return(2011); dstroy(bird); @@ -632,7 +632,7 @@ trkill() /* 9120 */ if (place[snake]==plac[snake]) tally2++; spk=45; } - if (obj==0) spk=44; /* 9125 */ + if (obj==0) spk=44; /* 9125 */ if (obj==clam||obj==oyster) spk=150; if (obj==snake) spk=46; if (obj==dwarf) spk=49; @@ -663,12 +663,12 @@ trkill() /* 9120 */ } -trtoss() /* 9170: throw */ +trtoss() /* 9170: throw */ { register int i; if (toting(rod2)&&obj==rod&&!toting(rod)) obj=rod2; if (!toting(obj)) return(2011); if (obj>=50&&obj<=maxtrs&&at(troll)) - { spk=159; /* 9178 */ + { spk=159; /* 9178 */ drop(obj,0); move(troll,0); move(troll+100,0); @@ -678,13 +678,13 @@ trtoss() /* 9170: throw */ return(2011); } if (obj==food&&here(bear)) - { obj=bear; /* 9177 */ + { obj=bear; /* 9177 */ return(9210); } if (obj!=axe) return(9020); for (i=1; i<=5; i++) { if (dloc[i]==loc) - { spk=48; /* 9172 */ + { spk=48; /* 9172 */ if (ran(3)==0||saved!= -1) l9175: { rspeak(spk); drop(axe,loc); @@ -717,7 +717,7 @@ trtoss() /* 9170: throw */ } -trfeed() /* 9210 */ +trfeed() /* 9210 */ { if (obj==bird) { spk=100; return(2011); @@ -755,7 +755,7 @@ trfeed() /* 9210 */ } -trfill() /* 9220 */ +trfill() /* 9220 */ { if (obj==vase) { spk=29; if (liqloc(loc)==0) spk=144; @@ -763,7 +763,7 @@ trfill() /* 9220 */ rspeak(145); prop[vase]=2; fixed[vase]= -1; - return(9020); /* advent/10 goes to 9024 */ + return(9020); /* advent/10 goes to 9024 */ } if (obj!=0&&obj!=bottle) return(2011); if (obj==0&&!here(bottle)) return(8000); @@ -779,7 +779,7 @@ trfill() /* 9220 */ } -closing() /* 10000 */ +closing() /* 10000 */ { register int i; prop[grate]=prop[fissur]=0; @@ -804,7 +804,7 @@ closing() /* 10000 */ } -caveclose() /* 11000 */ +caveclose() /* 11000 */ { register int i; prop[bottle]=put(bottle,115,1); prop[plant]=put(plant,115,0); diff --git a/games/adventure/vocab.c b/games/adventure/vocab.c index 84478182c2a..404c258af69 100644 --- a/games/adventure/vocab.c +++ b/games/adventure/vocab.c @@ -46,7 +46,7 @@ static char rcsid[] = "$NetBSD: vocab.c,v 1.2 1995/03/21 12:05:13 cgd Exp $"; #endif #endif /* not lint */ -/* Re-coding of advent in C: data structure routines */ +/* Re-coding of advent in C: data structure routines */ #include <stdlib.h> #include "hdr.h" @@ -117,26 +117,26 @@ int object,where; } -vocab(word,type,value) /* look up or store a word */ +vocab(word,type,value) /* look up or store a word */ char *word; int type; /* -2 for store, -1 for user word, >=0 for canned lookup*/ -int value; /* used for storing only */ +int value; /* used for storing only */ { register int adr; register char *s,*t; int hash, i; struct hashtab *h; for (hash=0,s=word,i=0; i<5 &&*s; i++) /* some kind of hash */ - hash += *s++; /* add all chars in the word */ + hash += *s++; /* add all chars in the word */ hash = (hash*3719)&077777; /* pulled that one out of a hat */ - hash %= HTSIZE; /* put it into range of table */ + hash %= HTSIZE; /* put it into range of table */ - for(adr=hash;; adr++) /* look for entry in table */ - { if (adr==HTSIZE) adr=0; /* wrap around */ - h = &voc[adr]; /* point at the entry */ + for(adr=hash;; adr++) /* look for entry in table */ + { if (adr==HTSIZE) adr=0; /* wrap around */ + h = &voc[adr]; /* point at the entry */ switch(type) - { case -2: /* fill in entry */ - if (h->val) /* already got an entry? */ + { case -2: /* fill in entry */ + if (h->val) /* already got an entry? */ goto exitloop2; h->val=value; h->atab=malloc(length(word)); @@ -145,29 +145,29 @@ int value; /* used for storing only */ *t=0^'='; /* encrypt slightly to thwart core reader */ /* printf("Stored \"%s\" (%d ch) as entry %d\n", */ - /* word, length(word), adr); */ - return(0); /* entry unused */ - case -1: /* looking up user word */ + /* word, length(word), adr); */ + return(0); /* entry unused */ + case -1: /* looking up user word */ if (h->val==0) return(-1); /* not found */ for (s=word, t=h->atab;*t ^ '=';) if ((*s++ ^ '=') != *t++) goto exitloop2; if ((*s ^ '=') != *t && s-word<5) goto exitloop2; - /* the word matched o.k. */ + /* the word matched o.k. */ return(h->val); - default: /* looking up known word */ + default: /* looking up known word */ if (h->val==0) { printf("Unable to find %s in vocab\n",word); exit(0); } for (s=word, t=h->atab;*t ^ '=';) if ((*s++ ^ '=') != *t++) goto exitloop2; - /* the word matched o.k. */ + /* the word matched o.k. */ if (h->val/1000 != type) continue; return(h->val%1000); } - exitloop2: /* hashed entry does not match */ + exitloop2: /* hashed entry does not match */ if (adr+1==hash || (adr==HTSIZE && hash==0)) { printf("Hash table overflow\n"); exit(0); @@ -176,7 +176,7 @@ int value; /* used for storing only */ } -copystr(w1,w2) /* copy one string to another */ +copystr(w1,w2) /* copy one string to another */ char *w1,*w2; { register char *s,*t; for (s=w1,t=w2; *s;) @@ -184,13 +184,13 @@ char *w1,*w2; *t=0; } -weq(w1,w2) /* compare words */ -char *w1,*w2; /* w1 is user, w2 is system */ +weq(w1,w2) /* compare words */ +char *w1,*w2; /* w1 is user, w2 is system */ { register char *s,*t; register int i; s=w1; t=w2; - for (i=0; i<5; i++) /* compare at most 5 chars */ + for (i=0; i<5; i++) /* compare at most 5 chars */ { if (*t==0 && *s==0) return(TRUE); if (*s++ != *t++) return(FALSE); @@ -199,7 +199,7 @@ char *w1,*w2; /* w1 is user, w2 is system */ } -length(str) /* includes 0 at end */ +length(str) /* includes 0 at end */ char *str; { register char *s; register int n; @@ -207,7 +207,7 @@ char *str; return(n+1); } -prht() /* print hash table */ +prht() /* print hash table */ { register int i,j,l; char *c; struct hashtab *h; diff --git a/games/adventure/wizard.c b/games/adventure/wizard.c index aad20539674..c01a76509e2 100644 --- a/games/adventure/wizard.c +++ b/games/adventure/wizard.c @@ -46,7 +46,7 @@ static char rcsid[] = "$NetBSD: wizard.c,v 1.3 1995/04/24 12:21:41 cgd Exp $"; #endif #endif /* not lint */ -/* Re-coding of advent in C: privileged operations */ +/* Re-coding of advent in C: privileged operations */ # include "hdr.h" #include <string.h> @@ -59,10 +59,10 @@ int *d,*t; time(tvec); tptr=(int *)localtime(tvec); *d=tptr[7]+365*(tptr[5]-77); /* day since 1977 (mod leap) */ - /* bug: this will overflow in the year 2066 AD */ + /* bug: this will overflow in the year 2066 AD */ /* it will be attributed to Wm the C's millenial celebration */ - *t=tptr[2]*60+tptr[1]; /* and minutes since midnite */ -} /* pretty painless */ + *t=tptr[2]*60+tptr[1]; /* and minutes since midnite */ +} /* pretty painless */ char magic[6]; @@ -98,7 +98,7 @@ Start(n) return(FALSE); } -wizard() /* not as complex as advent/10 (for now) */ +wizard() /* not as complex as advent/10 (for now) */ { register int wiz; char *word,*x; if (!yesm(16,0,7)) return(FALSE); @@ -123,7 +123,7 @@ char *cmdfile; for (c=fname;; c++) if ((*c=getchar())=='\n' || *c == EOF) break; *c=0; - if (save(fname) != 0) return; /* Save failed */ + if (save(fname) != 0) return; /* Save failed */ printf("To resume, say \"adventure %s\".\n", fname); printf("\"With these rooms I might now have been familiarly acquainted.\"\n"); exit(0); diff --git a/games/atc/input.c b/games/atc/input.c index 4eec8410001..542df807306 100644 --- a/games/atc/input.c +++ b/games/atc/input.c @@ -162,7 +162,7 @@ RULE state0[] = { { ALPHATOKEN, 1, "%c:", setplane}, { HELPTOKEN, 12, " @a<dir><ret>",NULL }}, state7[] = { { RETTOKEN, -1, "", NULL }, #ifdef SYSV - { CRTOKEN, -1, "", NULL }, + { CRTOKEN, -1, "", NULL }, #endif { HELPTOKEN, 12, " <ret>", NULL }}, state8[] = { { NUMTOKEN, 4, "%c", benum }, diff --git a/games/backgammon/common_source/subs.c b/games/backgammon/common_source/subs.c index 901071586bf..b85d2b4e394 100644 --- a/games/backgammon/common_source/subs.c +++ b/games/backgammon/common_source/subs.c @@ -372,7 +372,7 @@ register char ***arg; if (s[0][2] == 'b') bflag = 0; } - i++; /* Blindly skip next char */ + i++; /* Blindly skip next char */ break; /* use spec'd term from /etc/termcap */ diff --git a/games/banner/banner.c b/games/banner/banner.c index 275aa9479bb..0632e61d2d6 100644 --- a/games/banner/banner.c +++ b/games/banner/banner.c @@ -92,7 +92,7 @@ int asc_ptr[NCHARS] = { * next element in array. */ char data_table[NBYTES] = { -/* 0 1 2 3 4 5 6 7 8 9 */ +/* 0 1 2 3 4 5 6 7 8 9 */ /* 0 */ 129, 227, 130, 34, 6, 90, 19, 129, 32, 10, /* 10 */ 74, 40, 129, 31, 12, 64, 53, 129, 30, 14, /* 20 */ 54, 65, 129, 30, 14, 53, 67, 129, 30, 14, diff --git a/games/battlestar/parse.c b/games/battlestar/parse.c index bec5d471952..387e2dcb75b 100644 --- a/games/battlestar/parse.c +++ b/games/battlestar/parse.c @@ -1,4 +1,4 @@ -/* $OpenBSD: parse.c,v 1.2 1997/06/30 19:56:39 kstailey Exp $ */ +/* $OpenBSD: parse.c,v 1.3 1997/07/23 20:04:47 kstailey Exp $ */ /* $NetBSD: parse.c,v 1.3 1995/03/21 15:07:48 cgd Exp $ */ /* @@ -95,7 +95,7 @@ parse() register struct wlist *wp; register n; - wordnumber = 0; /* for cypher */ + wordnumber = 0; /* for cypher */ for (n = 0; n <= wordcount; n++) { if ((wp = lookup(words[n])) == NULL) { wordvalue[n] = -1; diff --git a/games/boggle/boggle/bog.c b/games/boggle/boggle/bog.c index a523aba910a..9c2213bab1b 100644 --- a/games/boggle/boggle/bog.c +++ b/games/boggle/boggle/bog.c @@ -73,7 +73,7 @@ struct dictindex dictindex[26]; * C D E F */ static int adjacency[16][16] = { -/* 0 1 2 3 4 5 6 7 8 9 A B C D E F */ +/* 0 1 2 3 4 5 6 7 8 9 A B C D E F */ { 0, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, /* 0 */ { 1, 0, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, /* 1 */ { 0, 1, 0, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0 }, /* 2 */ diff --git a/games/boggle/boggle/mach.c b/games/boggle/boggle/mach.c index 73c919c6974..74e0ecaa3d9 100644 --- a/games/boggle/boggle/mach.c +++ b/games/boggle/boggle/mach.c @@ -140,9 +140,9 @@ results() move(SCORE_LINE, SCORE_COL); printw("Percentage: %0.2f%% (%0.2f%% over %d game%s)\n", - denom1 ? (100.0 * npwords) / (double) (npwords + nmwords) : 0.0, - denom2 ? (100.0 * tnpwords) / (double) (tnpwords + tnmwords) : 0.0, - ngames, ngames > 1 ? "s" : ""); + denom1 ? (100.0 * npwords) / (double) (npwords + nmwords) : 0.0, + denom2 ? (100.0 * tnpwords) / (double) (tnpwords + tnmwords) : 0.0, + ngames, ngames > 1 ? "s" : ""); } static void diff --git a/games/boggle/boggle/prtable.c b/games/boggle/boggle/prtable.c index d5b29cbc574..9017b9decc3 100644 --- a/games/boggle/boggle/prtable.c +++ b/games/boggle/boggle/prtable.c @@ -68,12 +68,12 @@ prtable(base, num, d_cols, width, prentry, length) void (*prentry) __P((char *[], int)); int (*length) __P((char *[], int)); { - register int c, j; - register int a, b, cols, loc, maxlen, nrows, z; + register int c, j; + register int a, b, cols, loc, maxlen, nrows, z; int col, row; - if (num == 0) - return; + if (num == 0) + return; maxlen = get_maxlen(base, num, length) + 1; if (d_cols > 0) cols = d_cols; @@ -81,34 +81,34 @@ prtable(base, num, d_cols, width, prentry, length) cols = width / maxlen; if (cols == 0) cols = NCOLS; - nrows = (num - 1) / cols + 1; - for (a = 1; a <= nrows; a++) { - b = c = z = loc = 0; - for (j = 0; j < num; j++) { - c++; - if (c >= a + b) - break; - } - while (j < num) { - (*prentry)(base, j); + nrows = (num - 1) / cols + 1; + for (a = 1; a <= nrows; a++) { + b = c = z = loc = 0; + for (j = 0; j < num; j++) { + c++; + if (c >= a + b) + break; + } + while (j < num) { + (*prentry)(base, j); loc += (*length)(base, j); - z++; - b += nrows; - for (j++; j < num; j++) { - c++; - if (c >= a + b) - break; - } - if (j < num) { - while (loc < z * maxlen) { + z++; + b += nrows; + for (j++; j < num; j++) { + c++; + if (c >= a + b) + break; + } + if (j < num) { + while (loc < z * maxlen) { addch(' '); - loc++; - } + loc++; + } } - } + } getyx(stdscr, row, col); move(row + 1, 0); - } + } refresh(); } diff --git a/games/bs/bs.c b/games/bs/bs.c index ba74767b772..2e555c5d2a7 100644 --- a/games/bs/bs.c +++ b/games/bs/bs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bs.c,v 1.4 1997/02/14 10:28:17 niklas Exp $ */ +/* $OpenBSD: bs.c,v 1.5 1997/07/23 20:04:49 kstailey Exp $ */ /* * bs.c - original author: Bruce Holloway * salvo option by: Chuck A DeGaul @@ -557,19 +557,19 @@ int atcpu; #ifdef KEY_MIN case KEY_DOWN: #endif /* KEY_MIN */ - ny = cury+1; nx = curx; + ny = cury+1; nx = curx; break; case 'h': case '4': #ifdef KEY_MIN case KEY_LEFT: #endif /* KEY_MIN */ - ny = cury; nx = curx+BWIDTH-1; + ny = cury; nx = curx+BWIDTH-1; break; case 'l': case '6': #ifdef KEY_MIN case KEY_RIGHT: #endif /* KEY_MIN */ - ny = cury; nx = curx+1; + ny = cury; nx = curx+1; break; case 'y': case '7': #ifdef KEY_MIN @@ -581,7 +581,7 @@ int atcpu; #ifdef KEY_MIN case KEY_C1: #endif /* KEY_MIN */ - ny = cury+1; nx = curx+BWIDTH-1; + ny = cury+1; nx = curx+BWIDTH-1; break; case 'u': case '9': #ifdef KEY_MIN @@ -593,7 +593,7 @@ int atcpu; #ifdef KEY_MIN case KEY_C3: #endif /* KEY_MIN */ - ny = cury+1; nx = curx+1; + ny = cury+1; nx = curx+1; break; case FF: nx = curx; ny = cury; diff --git a/games/fortune/fortune/fortune.c b/games/fortune/fortune/fortune.c index 6c596b59725..349d1ea4eff 100644 --- a/games/fortune/fortune/fortune.c +++ b/games/fortune/fortune/fortune.c @@ -1163,7 +1163,7 @@ FILEDESC *fp; "fortune: %s corrupted\n", fp->path); exit(1); } - if (read(fd, fp->tbl.stuff, sizeof(fp->tbl.stuff)) != + if (read(fd, fp->tbl.stuff, sizeof(fp->tbl.stuff)) != sizeof(fp->tbl.stuff)) { (void)fprintf(stderr, "fortune: %s corrupted\n", fp->path); diff --git a/games/fortune/strfile/strfile.c b/games/fortune/strfile/strfile.c index 48ee4bfe375..a1866a433e3 100644 --- a/games/fortune/strfile/strfile.c +++ b/games/fortune/strfile/strfile.c @@ -251,7 +251,7 @@ char **av; (void) fwrite(&Tbl.str_longlen, sizeof(Tbl.str_longlen), 1, outf); (void) fwrite(&Tbl.str_shortlen, sizeof(Tbl.str_shortlen), 1, outf); (void) fwrite(&Tbl.str_flags, sizeof(Tbl.str_flags), 1, outf); - (void) fwrite( Tbl.stuff, sizeof(Tbl.stuff), 1, outf); + (void) fwrite( Tbl.stuff, sizeof(Tbl.stuff), 1, outf); if (STORING_PTRS) for (p = Seekpts, cnt = Num_pts; cnt--; ++p) { *p = htonl(*p); diff --git a/games/fortune/unstr/unstr.c b/games/fortune/unstr/unstr.c index fe4b307375d..eb7e72e787f 100644 --- a/games/fortune/unstr/unstr.c +++ b/games/fortune/unstr/unstr.c @@ -98,7 +98,7 @@ char **av; (void) fread(&tbl.str_longlen, sizeof(tbl.str_longlen), 1, Dataf); (void) fread(&tbl.str_shortlen, sizeof(tbl.str_shortlen), 1, Dataf); (void) fread(&tbl.str_flags, sizeof(tbl.str_flags), 1, Dataf); - (void) fread( tbl.stuff, sizeof(tbl.stuff), 1, Dataf); + (void) fread( tbl.stuff, sizeof(tbl.stuff), 1, Dataf); if (!(tbl.str_flags & (STR_ORDERED | STR_RANDOM))) { fprintf(stderr, "nothing to do -- table in file order\n"); exit(1); diff --git a/games/hack/def.objclass.h b/games/hack/def.objclass.h index 15f7f98d975..3a8d99c44db 100644 --- a/games/hack/def.objclass.h +++ b/games/hack/def.objclass.h @@ -58,6 +58,6 @@ extern struct objclass objects[]; * hack.mkobj.c: char mkobjstr[] = "))[[!!!!????%%%%/=**"; * hack.apply.c: otmp = getobj("0#%", "put in"); * hack.eat.c: otmp = getobj("%", "eat"); - * hack.invent.c: if(index("!%?[)=*(0/\"", sym)){ + * hack.invent.c: if(index("!%?[)=*(0/\"", sym)){ * hack.invent.c: || index("%?!*",otmp->olet))){ */ diff --git a/games/hack/hack.fix b/games/hack/hack.fix index c01616ce1b1..ddfdebbcfdc 100644 --- a/games/hack/hack.fix +++ b/games/hack/hack.fix @@ -29,8 +29,8 @@ but I think the other fix was intended by the now deleted lines. Andreas -- -Andreas Bormann ab@unido.UUCP -University of Dortmund N 51 29' 05" E 07 24' 42" +Andreas Bormann ab@unido.UUCP +University of Dortmund N 51 29' 05" E 07 24' 42" West Germany ------ the diff follows: diff --git a/games/hack/hack.shk.c b/games/hack/hack.shk.c index ab4e3f81017..5fbd8d622e3 100644 --- a/games/hack/hack.shk.c +++ b/games/hack/hack.shk.c @@ -429,8 +429,8 @@ int pass, tmp; } /* return 1 if paid successfully */ -/* 0 if not enough money */ -/* -1 if object could not be found (but was paid) */ +/* 0 if not enough money */ +/* -1 if object could not be found (but was paid) */ static dopayobj(bp) register struct bill_x *bp; { register struct obj *obj; diff --git a/games/hack/hack.wield.c b/games/hack/hack.wield.c index e0f40b64339..39ec6b0300b 100644 --- a/games/hack/hack.wield.c +++ b/games/hack/hack.wield.c @@ -91,7 +91,7 @@ register char *time; aobjnam(uwep, "glow"), plur(uwep->quan)); while(uwep) /* let all of them disappear */ /* note: uwep->quan = 1 is nogood if unpaid */ - useup(uwep); + useup(uwep); return(1); } if(!rn2(6)) amount *= 2; diff --git a/games/larn/config.c b/games/larn/config.c index 3746c09c3eb..54f3f4d4ca7 100644 --- a/games/larn/config.c +++ b/games/larn/config.c @@ -3,10 +3,10 @@ static char rcsid[] = "$NetBSD: config.c,v 1.4 1995/04/22 07:34:04 cgd Exp $"; #endif /* not lint */ /* - * config.c -- This defines the installation dependent variables. - * Some strings are modified later. ANSI C would - * allow compile time string concatenation, we must - * do runtime concatenation, in main. + * config.c -- This defines the installation dependent variables. + * Some strings are modified later. ANSI C would + * allow compile time string concatenation, we must + * do runtime concatenation, in main. * * Larn is copyrighted 1986 by Noah Morgan. */ diff --git a/games/larn/data.c b/games/larn/data.c index acef0ca61f7..e840085d987 100644 --- a/games/larn/data.c +++ b/games/larn/data.c @@ -100,9 +100,9 @@ char *class[]= */ #define MEG 1000000 long skill[] = { -0, 10, 20, 40, 80, 160, 320, 640, 1280, 2560, 5120, /* 1-11 */ -10240, 20480, 40960, 100000, 200000, 400000, 700000, 1*MEG, /* 12-19 */ -2*MEG,3*MEG,4*MEG,5*MEG,6*MEG,8*MEG,10*MEG, /* 20-26 */ +0, 10, 20, 40, 80, 160, 320, 640, 1280, 2560, 5120, /* 1-11 */ +10240, 20480, 40960, 100000, 200000, 400000, 700000, 1*MEG, /* 12-19 */ +2*MEG,3*MEG,4*MEG,5*MEG,6*MEG,8*MEG,10*MEG, /* 20-26 */ 12*MEG,14*MEG,16*MEG,18*MEG,20*MEG,22*MEG,24*MEG,26*MEG,28*MEG, /* 27-35 */ 30*MEG,32*MEG,34*MEG,36*MEG,38*MEG,40*MEG,42*MEG,44*MEG,46*MEG, /* 36-44 */ 48*MEG,50*MEG,52*MEG,54*MEG,56*MEG,58*MEG,60*MEG,62*MEG,64*MEG, /* 45-53 */ @@ -111,7 +111,7 @@ long skill[] = { 105*MEG,110*MEG,115*MEG,120*MEG, 125*MEG, 130*MEG, 135*MEG, 140*MEG, /* 72-79 */ 145*MEG,150*MEG,155*MEG,160*MEG, 165*MEG, 170*MEG, 175*MEG, 180*MEG, /* 80-87 */ 185*MEG,190*MEG,195*MEG,200*MEG, 210*MEG, 220*MEG, 230*MEG, 240*MEG, /* 88-95 */ -250*MEG,260*MEG,270*MEG,280*MEG, 290*MEG, 300*MEG /* 96-101*/ +250*MEG,260*MEG,270*MEG,280*MEG, 290*MEG, 300*MEG /* 96-101*/ }; #undef MEG @@ -466,56 +466,56 @@ char *speldescript[]={ }; char spelweird[MAXMONST+8][SPNUM] = { -/* p m d s c s w s e h c c p i b c p c h c v d l d g f f s h s t m s g s w a p */ -/* r l e l h s e t n e b r h n a l l a a k p r i r l l g c l t e f p e u t l e */ -/* o e x e m p b r l l l e a v l d y n s l r y t l o o r a d p l i h n m w t r */ +/* p m d s c s w s e h c c p i b c p c h c v d l d g f f s h s t m s g s w a p */ +/* r l e l h s e t n e b r h n a l l a a k p r i r l l g c l t e f p e u t l e */ +/* o e x e m p b r l l l e a v l d y n s l r y t l o o r a d p l i h n m w t r */ -/* bat */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* gnome */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* hobgoblin */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* jackal */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* kobold */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* bat */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* gnome */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* hobgoblin */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* jackal */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* kobold */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* orc */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 4,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* snake */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* orc */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 4,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* snake */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /*giant centipede */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* jaculi */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* jaculi */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* troglodyte */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* giant ant */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* floating eye */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* leprechaun */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* nymph */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* quasit */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* nymph */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* quasit */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* rust monster */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 4,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* zombie */ { 0,0,0,8,0,4, 0,0,0,0,0,0,0,0, 0,0,0,0,0,4,0, 4,0,0,0,0,4, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* zombie */ { 0,0,0,8,0,4, 0,0,0,0,0,0,0,0, 0,0,0,0,0,4,0, 4,0,0,0,0,4, 0,0,0,0,0, 0,0,0,0,0,0 }, /* assassin bug */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* bugbear */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* bugbear */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* hell hound */ { 0,6,0,0,0,0, 12,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* ice lizard */ { 0,0,0,0,0,0, 11,0,0,0,0,0,0,0, 0,15,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* centaur */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* troll */ { 0,7,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 4,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* yeti */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,15,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* centaur */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* troll */ { 0,7,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 4,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* yeti */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,15,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* white dragon */ { 0,0,0,0,0,0, 0,0,0,0,0,0,14,0, 0,15,0,0,0,0,0, 4,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* elf */ { 0,0,0,0,0,0, 0,0,0,0,0,0,14,5, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* elf */ { 0,0,0,0,0,0, 0,0,0,0,0,0,14,5, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /*gelatinous cube */ { 0,0,0,0,0,0, 2,0,0,0,0,0,0,0, 0,0,0,0,0,4,0, 0,0,0,0,0,4, 0,0,0,0,0, 0,0,0,0,0,0 }, /* metamorph */ { 0,13,0,0,0,0, 2,0,0,0,0,0,0,0, 0,0,0,0,0,4,0, 4,0,0,0,0,4, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* vortex */ { 0,13,0,0,0,10, 1,0,0,0,0,0,0,0, 0,0,0,0,0,4,0, 4,0,0,0,4,4, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* ziller */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* vortex */ { 0,13,0,0,0,10, 1,0,0,0,0,0,0,0, 0,0,0,0,0,4,0, 4,0,0,0,4,4, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* ziller */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* violet fungi */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* wraith */ { 0,0,0,8,0,4, 0,0,0,0,0,0,0,0, 0,0,0,0,0,4,0, 4,0,0,0,0,4, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* wraith */ { 0,0,0,8,0,4, 0,0,0,0,0,0,0,0, 0,0,0,0,0,4,0, 4,0,0,0,0,4, 0,0,0,0,0, 0,0,0,0,0,0 }, /* forvalaka */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* lama nobe */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* osequip */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* osequip */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* rothe */ { 0,7,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* xorn */ { 0,7,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 4,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* vampire */ { 0,0,0,8,0,4, 0,0,0,0,0,0,0,0, 0,0,0,0,0,4,0, 0,0,0,0,0,4, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* rothe */ { 0,7,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* xorn */ { 0,7,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 4,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* vampire */ { 0,0,0,8,0,4, 0,0,0,0,0,0,0,0, 0,0,0,0,0,4,0, 0,0,0,0,0,4, 0,0,0,0,0, 0,0,0,0,0,0 }, /*invisible staker*/ { 0,0,0,0,0,0, 1,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* poltergeist */ { 0,13,0,8,0,4, 1,0,0,0,0,0,0,0, 0,4,0,0,0,4,0, 4,0,0,0,4,4, 0,0,0,0,0, 0,0,0,0,0,0 }, @@ -525,22 +525,22 @@ char spelweird[MAXMONST+8][SPNUM] = { /* umber hulk */ { 0,7,0,0,0,0, 0,0,0,0,0,0,0,5, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* gnome king */ { 0,7,0,0,3,0, 0,0,0,0,0,0,0,5, 0,0,9,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* mimic */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* mimic */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* water lord */ { 0,13,0,8,3,4, 1,0,0,0,0,0,0,0, 0,0,9,0,0,4,0, 0,0,0,0,16,4, 0,0,0,0,0, 0,0,0,0,0,0 }, /* bronze dragon */ { 0,7,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* green dragon */ { 0,7,0,0,0,0, 11,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* purple worm */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* xvart */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, +/* xvart */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* spirit naga */ { 0,13,0,8,3,4, 1,0,0,0,0,0,0,5, 0,4,9,0,0,4,0, 4,0,0,0,4,4, 0,0,0,0,0, 0,0,0,0,0,0 }, /* silver dragon */ { 0,6,0,9,0,0, 12,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /*platinum dragon */ { 0,7,0,9,0,0, 11,0,0,0,0,0,14,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* green urchin */ { 0,0,0,0,0,0, 0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, /* red dragon */ { 0,6,0,0,0,0, 12,0,0,0,0,0,0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0, 0,0,0,0,0, 0,0,0,0,0,0 }, -/* p m d s c s w s e h c c p i b c p c h c v d l d g f f s h s t m s g s w a p */ -/* r l e l h s e t n e b r h n a l l a a k p r i r l l g c l t e f p e u t l e */ -/* o e x e m p b r l l l e a v l d y n s l r y t l o o r a d p l i h n m w t r */ +/* p m d s c s w s e h c c p i b c p c h c v d l d g f f s h s t m s g s w a p */ +/* r l e l h s e t n e b r h n a l l a a k p r i r l l g c l t e f p e u t l e */ +/* o e x e m p b r l l l e a v l d y n s l r y t l o o r a d p l i h n m w t r */ /* demon lord */ { 0,7,0,4,3,0, 1,0,0,0,0,0,14,5, 0,0,4,0,0,4,0, 4,0,0,0,4,4, 0,0,0,0,0, 9,0,0,0,0,0 }, /* demon lord */ { 0,7,0,4,3,0, 1,0,0,0,0,0,14,5, 0,0,4,0,0,4,0, 4,0,0,0,4,4, 0,0,0,0,0, 9,0,0,0,0,0 }, diff --git a/games/larn/header.h b/games/larn/header.h index eb6fca897ed..907a4e95f65 100644 --- a/games/larn/header.h +++ b/games/larn/header.h @@ -222,7 +222,7 @@ struct sphere #define OSCROLL 41 #define OPOTION 42 #define OBOOK 43 -#define OCHEST 44 +#define OCHEST 44 #define OAMULET 45 #define OORBOFDRAGON 46 diff --git a/games/larn/io.c b/games/larn/io.c index 53c4c187ed5..167c7fbc4e7 100644 --- a/games/larn/io.c +++ b/games/larn/io.c @@ -45,7 +45,7 @@ static char rcsid[] = "$NetBSD: io.c,v 1.4 1995/04/24 12:23:57 cgd Exp $"; * * cursor(x,y) position cursor at [x,y] * cursors() position cursor at [1,24] (saves memory) - * cl_line(x,y) Clear line at [1,y] and leave cursor at [x,y] + * cl_line(x,y) Clear line at [1,y] and leave cursor at [x,y] * cl_up(x,y) Clear screen from [x,1] to current line. * cl_dn(x,y) Clear screen from [1,y] to end of display. * standout(str) Print the string in standout mode. @@ -341,10 +341,10 @@ long lgetc() if (ipoint != iepoint) return(inbuffer[ipoint++]); if (iepoint!=MAXIBUF) return(0); if ((i=read(fd,inbuffer,MAXIBUF))<=0) - { - if (i!=0) write(1,"error reading from input file\n",30); + { + if (i!=0) write(1,"error reading from input file\n",30); iepoint = ipoint = 0; return(0); - } + } ipoint=1; iepoint=i; return(*inbuffer); } @@ -767,7 +767,7 @@ lflush () if (enable_scroll <= -1) { flush_buf(); - if (write(lfd,lpbuf,lpoint) != lpoint) + if (write(lfd,lpbuf,lpoint) != lpoint) write(2,"error writing to output file\n",29); lpnt = lpbuf; /* point back to beginning of buffer */ return; @@ -842,13 +842,13 @@ lflush() { register int lpoint; if ((lpoint = lpnt - lpbuf) > 0) - { + { #ifdef EXTRA c[BYTESOUT] += lpoint; #endif - if (write(lfd,lpbuf,lpoint) != lpoint) + if (write(lfd,lpbuf,lpoint) != lpoint) write(2,"error writing to output file\n",29); - } + } lpnt = lpbuf; /* point back to beginning of buffer */ } #endif VT100 diff --git a/games/larn/store.c b/games/larn/store.c index 35f49f1ab9d..76a657d35c0 100644 --- a/games/larn/store.c +++ b/games/larn/store.c @@ -302,21 +302,21 @@ sch_hed() lprcat("all inhabitants of the caves. Here is a list of the class schedule:\n\n\n"); lprcat("\t\t Course Name \t Time Needed\n\n"); - if (course[0]==0) lprcat("\t\ta) Fighters Training I 10 mobuls"); /*line 7 of crt*/ + if (course[0]==0) lprcat("\t\ta) Fighters Training I 10 mobuls"); /*line 7 of crt*/ lprc('\n'); - if (course[1]==0) lprcat("\t\tb) Fighters Training II 15 mobuls"); + if (course[1]==0) lprcat("\t\tb) Fighters Training II 15 mobuls"); lprc('\n'); if (course[2]==0) lprcat("\t\tc) Introduction to Wizardry 10 mobuls"); lprc('\n'); - if (course[3]==0) lprcat("\t\td) Applied Wizardry 20 mobuls"); + if (course[3]==0) lprcat("\t\td) Applied Wizardry 20 mobuls"); lprc('\n'); if (course[4]==0) lprcat("\t\te) Behavioral Psychology 10 mobuls"); lprc('\n'); - if (course[5]==0) lprcat("\t\tf) Faith for Today 10 mobuls"); + if (course[5]==0) lprcat("\t\tf) Faith for Today 10 mobuls"); lprc('\n'); - if (course[6]==0) lprcat("\t\tg) Contemporary Dance 10 mobuls"); + if (course[6]==0) lprcat("\t\tg) Contemporary Dance 10 mobuls"); lprc('\n'); - if (course[7]==0) lprcat("\t\th) History of Larn 5 mobuls"); + if (course[7]==0) lprcat("\t\th) History of Larn 5 mobuls"); lprcat("\n\n\t\tAll courses cost 250 gold pieces."); cursor(30,18); @@ -690,7 +690,7 @@ nxt: cursor(1,6); if (outstanding_taxes>0) lprintf("You presently owe %d gp in taxes. ",(long)outstanding_taxes); else - lprcat("You do not owe us any taxes. "); + lprcat("You do not owe us any taxes. "); cursor(1,8); if (c[GOLD]>0) lprintf("You have %6d gp. ",(long)c[GOLD]); diff --git a/games/phantasia/misc.c b/games/phantasia/misc.c index d409fa2e5a2..2a9635a51e9 100644 --- a/games/phantasia/misc.c +++ b/games/phantasia/misc.c @@ -1260,7 +1260,7 @@ double dtemp; /* for temporary calculations */ /* rest to max */ Player.p_energy = Player.p_maxenergy + Player.p_shield; - if (Player.p_ring.ring_duration <= 0) + if (Player.p_ring.ring_duration <= 0) /* clean up expired rings */ switch (Player.p_ring.ring_type) { diff --git a/games/primes/pattern.c b/games/primes/pattern.c index c770791ced8..a3beb53fe8b 100644 --- a/games/primes/pattern.c +++ b/games/primes/pattern.c @@ -47,7 +47,7 @@ static char rcsid[] = "$NetBSD: pattern.c,v 1.3 1995/03/23 08:35:47 cgd Exp $"; /* * pattern - the Eratosthenes sieve on odd numbers for 3,5,7,11 and 13 * - * By: Landon Curt Noll chongo@toad.com + * By: Landon Curt Noll chongo@toad.com * * chongo <for a good prime call: 391581 * 2^216193 - 1> /\oo/\ * diff --git a/games/rogue/curses.c b/games/rogue/curses.c index 743e9ee53fb..bbae37b5d50 100644 --- a/games/rogue/curses.c +++ b/games/rogue/curses.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: curses.c,v 1.3 1995/04/22 10:27:27 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/hit.c b/games/rogue/hit.c index cbcd869124c..c9113b314c7 100644 --- a/games/rogue/hit.c +++ b/games/rogue/hit.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: hit.c,v 1.3 1995/04/22 10:27:30 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/init.c b/games/rogue/init.c index 60b7b24fc9e..75a66d1d6f0 100644 --- a/games/rogue/init.c +++ b/games/rogue/init.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: init.c,v 1.4 1995/04/28 23:49:19 mycroft Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/inventory.c b/games/rogue/inventory.c index c36f923542d..bb6ae627a93 100644 --- a/games/rogue/inventory.c +++ b/games/rogue/inventory.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: inventory.c,v 1.3 1995/04/22 10:27:35 cgd Exp $" * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/level.c b/games/rogue/level.c index b298bb044a1..1c524fce273 100644 --- a/games/rogue/level.c +++ b/games/rogue/level.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: level.c,v 1.3 1995/04/22 10:27:37 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/machdep.c b/games/rogue/machdep.c index b969f58bdb7..4704986cfc8 100644 --- a/games/rogue/machdep.c +++ b/games/rogue/machdep.c @@ -52,14 +52,14 @@ static char rcsid[] = "$NetBSD: machdep.c,v 1.5 1995/04/28 23:49:22 mycroft Exp * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ /* Included in this file are all system dependent routines. Extensive use * of #ifdef's will be used to compile the appropriate code on each system: * - * UNIX: all UNIX systems. + * UNIX: all UNIX systems. * UNIX_BSD4_2: UNIX BSD 4.2 and later, UTEK, (4.1 BSD too?) * UNIX_SYSV: UNIX system V * UNIX_V7: UNIX version 7 @@ -75,15 +75,15 @@ static char rcsid[] = "$NetBSD: machdep.c,v 1.5 1995/04/28 23:49:22 mycroft Exp * * md_function() * { - * code; + * code; * } * * md_function() * { * #ifdef UNIX_SYSV - * sys5code; + * sys5code; * #else - * code; + * code; * #endif * } * @@ -512,10 +512,10 @@ char *shell; * 1.) Not echo input. * 2.) Transmit input characters immediately upon typing. (cbreak mode) * 3.) Move the cursor down one line, without changing column, and - * without generating a carriage-return, when it - * sees a line-feed. This is only necessary if line-feed is ever - * used in the termcap 'do' (cursor down) entry, in which case, - * your system should must have a way of accomplishing this. + * without generating a carriage-return, when it + * sees a line-feed. This is only necessary if line-feed is ever + * used in the termcap 'do' (cursor down) entry, in which case, + * your system should must have a way of accomplishing this. * * When the parameter 'on' is true, the terminal is set up as specified * above. When this parameter is false, the terminal is restored to the diff --git a/games/rogue/main.c b/games/rogue/main.c index 5e472e15ac0..27783c5559f 100644 --- a/games/rogue/main.c +++ b/games/rogue/main.c @@ -58,7 +58,7 @@ static char rcsid[] = "$NetBSD: main.c,v 1.3 1995/04/22 10:27:41 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/message.c b/games/rogue/message.c index 3e12c51c9f7..e9048afd9ba 100644 --- a/games/rogue/message.c +++ b/games/rogue/message.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: message.c,v 1.5 1995/04/22 10:27:43 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/monster.c b/games/rogue/monster.c index 176ac756923..968e153d284 100644 --- a/games/rogue/monster.c +++ b/games/rogue/monster.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: monster.c,v 1.3 1995/04/22 10:27:45 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/move.c b/games/rogue/move.c index 86e36cf7523..42c08ecf787 100644 --- a/games/rogue/move.c +++ b/games/rogue/move.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: move.c,v 1.3 1995/04/22 10:27:47 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/object.c b/games/rogue/object.c index b6f5043ade6..03b63a5c18b 100644 --- a/games/rogue/object.c +++ b/games/rogue/object.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: object.c,v 1.3 1995/04/22 10:27:50 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/pack.c b/games/rogue/pack.c index b91bc5a827a..5151e5d8c77 100644 --- a/games/rogue/pack.c +++ b/games/rogue/pack.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: pack.c,v 1.3 1995/04/22 10:27:54 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/play.c b/games/rogue/play.c index 601f8924901..0106446901b 100644 --- a/games/rogue/play.c +++ b/games/rogue/play.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: play.c,v 1.3 1995/04/22 10:28:04 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/random.c b/games/rogue/random.c index 6e2abc6025a..3f549c3755f 100644 --- a/games/rogue/random.c +++ b/games/rogue/random.c @@ -52,12 +52,12 @@ static char rcsid[] = "$NetBSD: random.c,v 1.3 1995/04/22 10:28:06 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ static long rntb[32] = { - 3, 0x9a319039, 0x32d9c024, 0x9b663182, 0x5da1f342, + 3, 0x9a319039, 0x32d9c024, 0x9b663182, 0x5da1f342, 0xde3b81e0, 0xdf0a6fb5, 0xf103bc02, 0x48f340fb, 0x7449e56b, 0xbeb1dbb0, 0xab5c5918, 0x946554fd, 0x8c2e680f, 0xeb3d799f, 0xb11ee0b7, 0x2d436b86, 0xda672e2a, 0x1588ca88, 0xe369735d, diff --git a/games/rogue/ring.c b/games/rogue/ring.c index b531fa474e3..2d8059a9468 100644 --- a/games/rogue/ring.c +++ b/games/rogue/ring.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: ring.c,v 1.3 1995/04/22 10:28:09 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/rogue.h b/games/rogue/rogue.h index c9b098746ed..e3632952dc2 100644 --- a/games/rogue/rogue.h +++ b/games/rogue/rogue.h @@ -46,7 +46,7 @@ * 1.) This notice shall not be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. */ #define boolean char diff --git a/games/rogue/room.c b/games/rogue/room.c index 88cd0e36dd8..83d061fa5e1 100644 --- a/games/rogue/room.c +++ b/games/rogue/room.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: room.c,v 1.3 1995/04/22 10:28:17 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/save.c b/games/rogue/save.c index efd531fd40b..73008b3987c 100644 --- a/games/rogue/save.c +++ b/games/rogue/save.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: save.c,v 1.3 1995/04/22 10:28:21 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/score.c b/games/rogue/score.c index 98635ab3f87..01e5a5ed5f2 100644 --- a/games/rogue/score.c +++ b/games/rogue/score.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: score.c,v 1.5 1995/04/22 10:28:26 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/spec_hit.c b/games/rogue/spec_hit.c index e4de5a03b88..7893d32667f 100644 --- a/games/rogue/spec_hit.c +++ b/games/rogue/spec_hit.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: spec_hit.c,v 1.3 1995/04/22 10:28:29 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/throw.c b/games/rogue/throw.c index a5cf0dadfb8..399ddeacabb 100644 --- a/games/rogue/throw.c +++ b/games/rogue/throw.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: throw.c,v 1.3 1995/04/22 10:28:32 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/trap.c b/games/rogue/trap.c index bd2aff3723f..7cfa6eb893e 100644 --- a/games/rogue/trap.c +++ b/games/rogue/trap.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: trap.c,v 1.3 1995/04/22 10:28:35 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/use.c b/games/rogue/use.c index 365e2744e13..e089c12d500 100644 --- a/games/rogue/use.c +++ b/games/rogue/use.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: use.c,v 1.3 1995/04/22 10:28:38 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/rogue/zap.c b/games/rogue/zap.c index 401d44932fa..9bda4dddac2 100644 --- a/games/rogue/zap.c +++ b/games/rogue/zap.c @@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: zap.c,v 1.3 1995/04/22 10:28:41 cgd Exp $"; * 1.) No portion of this notice shall be removed. * 2.) Credit shall not be taken for the creation of this source. * 3.) This code is not to be traded, sold, or used for personal - * gain or profit. + * gain or profit. * */ diff --git a/games/sail/globals.c b/games/sail/globals.c index a9e2fd30ac7..82b7c0817a4 100644 --- a/games/sail/globals.c +++ b/games/sail/globals.c @@ -284,7 +284,7 @@ int nscene = sizeof scene / sizeof (struct scenario); struct shipspecs specs[] = { /* bs fs ta guns hull crew1 crew3 gunR carR rig2 rig4 pts */ -/* class qual crew2 gunL carL rig1 rig3 */ +/* class qual crew2 gunL carL rig1 rig3 */ /*00*/ 4, 7, 3, 19, 5, 5, 4, 2, 2, 2, 2, 2, 0, 0, 4, 4, 4, 4, 7, /*01*/ 4, 7, 3, 17, 5, 5, 4, 2, 2, 2, 0, 0, 4, 4, 3, 3, 3, 3, 6, /*02*/ 3, 5, 2, 42, 4, 7, 4, 2, 2, 2, 2, 2, 0, 0, 5, 5, 5, -1, 11, @@ -370,7 +370,7 @@ struct shipspecs specs[] = { /*82*/ 4, 7, 3, 450, 1, 99, 5, 50, 40, 40, 50, 50,25,25, 9, 9, 9, -1, 75, /*83*/ 4, 7, 3, 450, 1, 99, 5, 50, 40, 40, 50, 50,25,25, 9, 9, 9, -1, 75, /* bs fs ta guns hull crew1 crew3 gunR carR rig2 rig4 pts */ -/* class qual crew2 gunL carL rig1 rig3 */ +/* class qual crew2 gunL carL rig1 rig3 */ }; struct windeffects WET[7][6] = { diff --git a/games/sail/player.h b/games/sail/player.h index 15c2fd43653..10df412ca50 100644 --- a/games/sail/player.h +++ b/games/sail/player.h @@ -68,8 +68,8 @@ #define STAT_Y (STAT_B-STAT_T+1) #define STAT_R (STAT_L+STAT_X-1) #define STAT_1 0 -#define STAT_2 (STAT_1+4) -#define STAT_3 (STAT_2+7) +#define STAT_2 (STAT_1+4) +#define STAT_3 (STAT_2+7) #define SCROLL_T (BOX_B+1) #define SCROLL_L 0 diff --git a/games/trek/main.c b/games/trek/main.c index 6843ef99bdf..bd9c307ed20 100644 --- a/games/trek/main.c +++ b/games/trek/main.c @@ -57,11 +57,11 @@ static char rcsid[] = "$NetBSD: main.c,v 1.4 1995/04/22 10:59:10 cgd Exp $"; int Mother = 51 + (51 << 8); /* -** #### ##### # #### ##### #### ##### # # -** # # # # # # # # # # # # -** ### # ##### #### # #### ### ### -** # # # # # # # # # # # # -** #### # # # # # # # # ##### # # +** #### ##### # #### ##### #### ##### # # +** # # # # # # # # # # # # +** ### # ##### #### # #### ### ### +** # # # # # # # # # # # # +** #### # # # # # # # # ##### # # ** ** C version by Eric P. Allman 5/76 (U.C. Berkeley) with help ** from Jeff Poskanzer and Pete Rubinstein. diff --git a/games/worms/worms.c b/games/worms/worms.c index ad42e1a0b70..f99c232b886 100644 --- a/games/worms/worms.c +++ b/games/worms/worms.c @@ -49,15 +49,15 @@ static char rcsid[] = "$NetBSD: worms.c,v 1.8 1995/04/22 08:09:22 cgd Exp $"; /* * - * @@@ @@@ @@@@@@@@@@ @@@@@@@@@@@ @@@@@@@@@@@@ - * @@@ @@@ @@@@@@@@@@@@ @@@@@@@@@@@@ @@@@@@@@@@@@@ - * @@@ @@@ @@@@ @@@@ @@@@ @@@@ @@@ @@@@ - * @@@ @@ @@@ @@@ @@@ @@@ @@@ @@@ @@@ - * @@@ @@@@ @@@ @@@ @@@ @@@ @@@ @@@ @@@ - * @@@@ @@@@ @@@@ @@@ @@@ @@@ @@@ @@@ @@@ - * @@@@@@@@@@@@ @@@@ @@@@ @@@ @@@ @@@ @@@ - * @@@@ @@@@ @@@@@@@@@@@@ @@@ @@@ @@@ @@@ - * @@ @@ @@@@@@@@@@ @@@ @@@ @@@ @@@ + * @@@ @@@ @@@@@@@@@@ @@@@@@@@@@@ @@@@@@@@@@@@ + * @@@ @@@ @@@@@@@@@@@@ @@@@@@@@@@@@ @@@@@@@@@@@@@ + * @@@ @@@ @@@@ @@@@ @@@@ @@@@ @@@ @@@@ + * @@@ @@ @@@ @@@ @@@ @@@ @@@ @@@ @@@ + * @@@ @@@@ @@@ @@@ @@@ @@@ @@@ @@@ @@@ + * @@@@ @@@@ @@@@ @@@ @@@ @@@ @@@ @@@ @@@ + * @@@@@@@@@@@@ @@@@ @@@@ @@@ @@@ @@@ @@@ + * @@@@ @@@@ @@@@@@@@@@@@ @@@ @@@ @@@ @@@ + * @@ @@ @@@@@@@@@@ @@@ @@@ @@@ @@@ * * Eric P. Scott * Caltech High Energy Physics |