]> git.cameronkatri.com Git - bsdgames-darwin.git/blobdiff - adventure/io.c
Whn ths cd ws wrttn, thr ws bt shrtg nd vwls wr xtrml xpnsv. Nowadays,
[bsdgames-darwin.git] / adventure / io.c
index 7382f5a9a7174f145da01f75329822592ec998ec..eae7695c5a379e0f3ab64b87c3ae02f2af015eff 100644 (file)
@@ -1,4 +1,4 @@
-/*     $NetBSD: io.c,v 1.21 2009/08/12 04:28:27 dholland Exp $ */
+/*     $NetBSD: io.c,v 1.22 2009/08/25 06:56:52 dholland Exp $ */
 
 /*-
  * Copyright (c) 1991, 1993
@@ -39,7 +39,7 @@
 #if 0
 static char sccsid[] = "@(#)io.c       8.1 (Berkeley) 5/31/93";
 #else
-__RCSID("$NetBSD: io.c,v 1.21 2009/08/12 04:28:27 dholland Exp $");
+__RCSID("$NetBSD: io.c,v 1.22 2009/08/25 06:56:52 dholland Exp $");
 #endif
 #endif /* not lint */
 
@@ -54,7 +54,7 @@ __RCSID("$NetBSD: io.c,v 1.21 2009/08/12 04:28:27 dholland Exp $");
 
 static int next(void);
 static void rdesc(int);
-static void rdflt(void);
+static void rdefault(void);
 static void rhints(void);
 static void rliq(void);
 static void rlocs(void);
@@ -203,7 +203,7 @@ rdata(void)
        inptr = data_file;      /* Pointer to virtual data file */
        srandom(SEED);          /* which is lightly encrypted.  */
 
-       clsses = 1;
+       classes = 1;
        for (;;) {              /* read data sections           */
                sect = next() - '0';    /* 1st digit of section number  */
 #ifdef VERBOSE
@@ -244,7 +244,7 @@ rdata(void)
                        rlocs();
                        break;
                case 8: /* action defaults              */
-                       rdflt();
+                       rdefault();
                        break;
                case 9: /* liquid assets                */
                        rliq();
@@ -316,18 +316,18 @@ rdesc(int sect)
                                ptext[oldloc].txtlen = maystart - seekstart;
                                break;
                        case 6:/* random messages              */
-                               if (oldloc >= RTXSIZ) 
+                               if (oldloc >= RTXSIZE
                                        errx(1,"Too many random msgs");
                                rtext[oldloc].seekadr = seekhere;
                                rtext[oldloc].txtlen = maystart - seekstart;
                                break;
                        case 10:        /* class messages               */
-                               ctext[clsses].seekadr = seekhere;
-                               ctext[clsses].txtlen = maystart - seekstart;
-                               cval[clsses++] = oldloc;
+                               ctext[classes].seekadr = seekhere;
+                               ctext[classes].txtlen = maystart - seekstart;
+                               cval[classes++] = oldloc;
                                break;
                        case 12:        /* magic messages               */
-                               if (oldloc >= MAGSIZ)
+                               if (oldloc >= MAGSIZE)
                                        errx(1,"Too many magic msgs");
                                mtext[oldloc].seekadr = seekhere;
                                mtext[oldloc].txtlen = maystart - seekstart;
@@ -474,12 +474,12 @@ rlocs(void)
 
 /* default verb messages        */
 static void
-rdflt(void)
+rdefault(void)
 {      
        for (;;) {
                if ((verb = rnum()) < 0)
                        break;
-               actspk[verb] = rnum();
+               actspeak[verb] = rnum();
        }
 }
 
@@ -506,14 +506,14 @@ static void
 rhints(void)
 {
        int     hintnum, i;
-       hntmax = 0;
+       hintmax = 0;
        for (;;) {
                if ((hintnum = rnum()) < 0)
                        break;
                for (i = 1; i < 5; i++)
                        hints[hintnum][i] = rnum();
-               if (hintnum > hntmax)
-                       hntmax = hintnum;
+               if (hintnum > hintmax)
+                       hintmax = hintnum;
        }
 }