From: Eric S. Raymond Date: Fri, 9 Jun 2017 15:19:47 +0000 (-0400) Subject: Eliminate a global variable. X-Git-Tag: 1.1~477 X-Git-Url: https://jxself.org/git/?a=commitdiff_plain;h=0a4325ce456f3633ade892c40093133da78d5603;p=open-adventure.git Eliminate a global variable. --- diff --git a/actions.c b/actions.c index e878c89..6a6448b 100644 --- a/actions.c +++ b/actions.c @@ -3,6 +3,8 @@ #include "advent.h" #include "database.h" +#define VRSION 25 /* bump on save format change */ + /* * Action handlers. Eventually we'll do lookup through a method table * that calls these. Absolutely nothing like the original FORTRAN. diff --git a/advent.h b/advent.h index 576ae4a..41e8a87 100644 --- a/advent.h +++ b/advent.h @@ -185,5 +185,5 @@ extern long AMBER, ATTACK, AXE, BACK, BATTER, BEAR, STEPS, STICK, STREAM, THROW, TRIDNT, TROLL, TROLL2, URN, VASE, VEND, VOLCAN, WATER; /* everything else */ -extern long I, K, SPK, VRSION, WD1, WD1X, WD2, WD2X; +extern long I, K, SPK, WD1, WD1X, WD2, WD2X; diff --git a/main.c b/main.c index c052c61..c780cd7 100644 --- a/main.c +++ b/main.c @@ -28,7 +28,7 @@ long AMBER, AXE, BACK, BATTER, BEAR, BIRD, BLOOD, RUBY, RUG, SAPPH, SAY, SECT, SIGN, SNAKE, SPK, STEPS, STREAM, THROW, TRIDNT, TROLL, TROLL2, URN, VASE, VEND, - VOLCAN, VRSION = 25, WATER, WD1, WD1X, WD2, WD2X; + VOLCAN, WATER, WD1, WD1X, WD2, WD2X; FILE *logfp; bool oldstyle = false; lcg_state lcgstate;