More switch reformatting.
[open-adventure.git] / init.c
diff --git a/init.c b/init.c
index 240ad92f001e52514ee84e89a2fed9662f03eaa2..65a47d5307d2c2829f4e2957e9cad0f80baef15f 100644 (file)
--- a/init.c
+++ b/init.c
@@ -218,7 +218,7 @@ L1001:      /*etc*/ ;
 /*  Start new data section.  Sect is the section number. */
 
 L1002: SECT=GETNUM(OPENED);
-       OLDLOC= -1;
+       game.oldloc= -1;
        switch (SECT) { case 0: return(0); case 1: goto L1004; case 2: goto
                L1004; case 3: goto L1030; case 4: goto L1040; case 5: goto L1004;
                case 6: goto L1004; case 7: goto L1050; case 8: goto L1060; case
@@ -241,8 +241,8 @@ L1006:      KK=KK+1;
        LINES[KK]=GETTXT(false,false,false,KK);
        if(LINES[KK] != -1) goto L1006;
        LINES[LINUSE]=KK;
-       if(LOC == OLDLOC) goto L1005;
-       OLDLOC=LOC;
+       if(LOC == game.oldloc) goto L1005;
+       game.oldloc=LOC;
        LINES[LINUSE]= -KK;
        if(SECT == 14) goto L1014;
        if(SECT == 10) goto L1012;
@@ -417,14 +417,14 @@ L1106:    /*etc*/ ;
 
 /*  Treasures, as noted earlier, are objects 50 through MAXTRS (CURRENTLY 79).
  *  Their props are initially -1, and are set to 0 the first time they are
- *  described.  TALLY keeps track of how many are not yet found, so we know
+ *  described.  game.tally keeps track of how many are not yet found, so we know
  *  when to close the cave. */
 
        MAXTRS=79;
-       TALLY=0;
+       game.tally=0;
        for (I=50; I<=MAXTRS; I++) {
        if(PTEXT[I] != 0)PROP[I]= -1;
-       TALLY=TALLY-PROP[I];
+       game.tally=game.tally-PROP[I];
        } /* end loop */
 
 /*  Clear the hint stuff.  HINTLC(I) is how long he's been at LOC with cond bit
@@ -532,7 +532,7 @@ L1106:      /*etc*/ ;
        CHLOC=114;
        CHLOC2=140;
        for (I=1; I<=6; I++) {
-       DSEEN[I]=false;
+       game.dseen[I]=false;
        } /* end loop */
        game.dflag=0;
        DLOC[1]=19;
@@ -559,17 +559,17 @@ L1106:    /*etc*/ ;
  *     game.limit      Lifetime of lamp (not set here)
  *     MAXDIE  Number of reincarnation messages available (up to 5)
  *     game.numdie     Number of times killed so far
- *     THRESH  Next #turns threshhold (-1 if none)
- *     TRNDEX  Index in TRNVAL of next threshhold (section 14 of database)
- *     TRNLUZ  # points lost so far due to number of turns used
- *     TURNS   Tallies how many commands he's given (ignores yes/no)
+ *     game.thresh     Next #turns threshhold (-1 if none)
+ *     game.trndex     Index in TRNVAL of next threshhold (section 14 of database)
+ *     game.trnluz     # points lost so far due to number of turns used
+ *     game.turns      Tallies how many commands he's given (ignores yes/no)
  *     Logicals were explained earlier */
 
-       TURNS=0;
-       TRNDEX=1;
-       THRESH= -1;
-       if(TRNVLS > 0)THRESH=MOD(TRNVAL[1],100000)+1;
-       TRNLUZ=0;
+       game.turns=0;
+       game.trndex=1;
+       game.thresh= -1;
+       if(TRNVLS > 0)game.thresh=MOD(TRNVAL[1],100000)+1;
+       game.trnluz=0;
        game.lmwarn=false;
        IGO=0;
        game.iwest=0;
@@ -587,13 +587,13 @@ L1106:    /*etc*/ ;
        game.clock1=30;
        game.clock2=50;
        CONDS=SETBIT(11);
-       SAVED=0;
+       game.saved=0;
        game.closng=false;
-       PANIC=false;
+       game.panic=false;
        game.closed=false;
-       CLSHNT=false;
-       NOVICE=false;
-       SETUP=1;
+       game.clshint=false;
+       game.novice=false;
+       game.setup=1;
 
        /* if we can ever think of how, we should save it at this point */