Replace motion word VOCWRD() calls with enums.
This commit is contained in:
parent
3476d69806
commit
3c1348c736
5 changed files with 9 additions and 43 deletions
8
advent.h
8
advent.h
|
@ -167,17 +167,9 @@ extern int restore(FILE *);
|
||||||
#define INDEEP(LOC) ((LOC) >= LOC_MISTHALL && !OUTSID(LOC))
|
#define INDEEP(LOC) ((LOC) >= LOC_MISTHALL && !OUTSID(LOC))
|
||||||
|
|
||||||
/* vocabulary items */
|
/* vocabulary items */
|
||||||
extern long NUL;
|
|
||||||
extern long BACK;
|
|
||||||
extern long LOOK;
|
|
||||||
extern long CAVE;
|
|
||||||
extern long FIND;
|
extern long FIND;
|
||||||
extern long INVENT;
|
extern long INVENT;
|
||||||
extern long SAY;
|
extern long SAY;
|
||||||
extern long ENTER;
|
|
||||||
extern long STREAM;
|
|
||||||
extern long DPRSSN;
|
|
||||||
extern long ENTRNC;
|
|
||||||
extern long LOCK;
|
extern long LOCK;
|
||||||
extern long THROW;
|
extern long THROW;
|
||||||
|
|
||||||
|
|
|
@ -385,7 +385,7 @@ motions: !!omap
|
||||||
words: !!null
|
words: !!null
|
||||||
- MOT_2:
|
- MOT_2:
|
||||||
words: ['road', 'hill']
|
words: ['road', 'hill']
|
||||||
- MOT_3:
|
- ENTER:
|
||||||
words: ['enter']
|
words: ['enter']
|
||||||
- MOT_4:
|
- MOT_4:
|
||||||
words: ['upstr']
|
words: ['upstr']
|
||||||
|
@ -395,7 +395,7 @@ motions: !!omap
|
||||||
words: ['fores']
|
words: ['fores']
|
||||||
- MOT_7:
|
- MOT_7:
|
||||||
words: ['forwa', 'conti', 'onwar']
|
words: ['forwa', 'conti', 'onwar']
|
||||||
- MOT_8:
|
- BACK:
|
||||||
words: ['back', 'retur', 'retre']
|
words: ['back', 'retur', 'retre']
|
||||||
- MOT_9:
|
- MOT_9:
|
||||||
words: ['valle']
|
words: ['valle']
|
||||||
|
@ -407,7 +407,7 @@ motions: !!omap
|
||||||
words: ['build', 'house']
|
words: ['build', 'house']
|
||||||
- MOT_13:
|
- MOT_13:
|
||||||
words: ['gully']
|
words: ['gully']
|
||||||
- MOT_14:
|
- STREAM:
|
||||||
words: ['strea']
|
words: ['strea']
|
||||||
- MOT_15:
|
- MOT_15:
|
||||||
words: ['fork']
|
words: ['fork']
|
||||||
|
@ -421,7 +421,7 @@ motions: !!omap
|
||||||
words: ['inwar', 'insid', 'in']
|
words: ['inwar', 'insid', 'in']
|
||||||
- MOT_20:
|
- MOT_20:
|
||||||
words: ['surfa']
|
words: ['surfa']
|
||||||
- MOT_21:
|
- NUL:
|
||||||
words: ['null', 'nowhe']
|
words: ['null', 'nowhe']
|
||||||
- MOT_22:
|
- MOT_22:
|
||||||
words: ['dark']
|
words: ['dark']
|
||||||
|
@ -493,7 +493,7 @@ motions: !!omap
|
||||||
words: ['y2']
|
words: ['y2']
|
||||||
- MOT_56:
|
- MOT_56:
|
||||||
words: ['climb']
|
words: ['climb']
|
||||||
- MOT_57:
|
- LOOK:
|
||||||
words: ['look', 'exami', 'touch', 'descr']
|
words: ['look', 'exami', 'touch', 'descr']
|
||||||
- MOT_58:
|
- MOT_58:
|
||||||
words: ['floor']
|
words: ['floor']
|
||||||
|
@ -505,15 +505,15 @@ motions: !!omap
|
||||||
words: ['slab', 'slabr']
|
words: ['slab', 'slabr']
|
||||||
- MOT_62:
|
- MOT_62:
|
||||||
words: ['xyzzy']
|
words: ['xyzzy']
|
||||||
- MOT_63:
|
- DPRSSN:
|
||||||
words: ['depre']
|
words: ['depre']
|
||||||
- MOT_64:
|
- ENTRNC:
|
||||||
words: ['entra']
|
words: ['entra']
|
||||||
- MOT_65:
|
- MOT_65:
|
||||||
words: ['plugh']
|
words: ['plugh']
|
||||||
- MOT_66:
|
- MOT_66:
|
||||||
words: ['secre']
|
words: ['secre']
|
||||||
- MOT_67:
|
- CAVE:
|
||||||
words: ['cave']
|
words: ['cave']
|
||||||
- MOT_68:
|
- MOT_68:
|
||||||
words: !!null
|
words: !!null
|
||||||
|
|
8
cheat.c
8
cheat.c
|
@ -13,17 +13,9 @@ struct game_t game;
|
||||||
long LNLENG, LNPOSN;
|
long LNLENG, LNPOSN;
|
||||||
char rawbuf[LINESIZE], INLINE[LINESIZE + 1];
|
char rawbuf[LINESIZE], INLINE[LINESIZE + 1];
|
||||||
|
|
||||||
long NUL;
|
|
||||||
long BACK;
|
|
||||||
long LOOK;
|
|
||||||
long CAVE;
|
|
||||||
long FIND;
|
long FIND;
|
||||||
long INVENT;
|
long INVENT;
|
||||||
long SAY;
|
long SAY;
|
||||||
long ENTER;
|
|
||||||
long STREAM;
|
|
||||||
long DPRSSN;
|
|
||||||
long ENTRNC;
|
|
||||||
long LOCK;
|
long LOCK;
|
||||||
long THROW;
|
long THROW;
|
||||||
|
|
||||||
|
|
12
init.c
12
init.c
|
@ -74,17 +74,7 @@ void initialise(void)
|
||||||
|
|
||||||
/* Define some handy mnemonics. */
|
/* Define some handy mnemonics. */
|
||||||
|
|
||||||
/* These are motion-verb numbers. */
|
/* Some action verbs. */
|
||||||
BACK = VOCWRD(WORD_BACK, 0);
|
|
||||||
CAVE = VOCWRD(WORD_CAVE, 0);
|
|
||||||
DPRSSN = VOCWRD(WORD_DPRSSN, 0);
|
|
||||||
ENTER = VOCWRD(WORD_ENTER, 0);
|
|
||||||
ENTRNC = VOCWRD(WORD_ENTRNC, 0);
|
|
||||||
LOOK = VOCWRD(WORD_LOOK, 0);
|
|
||||||
NUL = VOCWRD(WORD_NUL, 0);
|
|
||||||
STREAM = VOCWRD(WORD_STREAM, 0);
|
|
||||||
|
|
||||||
/* And some action verbs. */
|
|
||||||
FIND = VOCWRD(WORD_FIND, 2);
|
FIND = VOCWRD(WORD_FIND, 2);
|
||||||
INVENT = VOCWRD(WORD_INVENT, 2);
|
INVENT = VOCWRD(WORD_INVENT, 2);
|
||||||
LOCK = VOCWRD(WORD_LOCK, 2);
|
LOCK = VOCWRD(WORD_LOCK, 2);
|
||||||
|
|
8
main.c
8
main.c
|
@ -43,17 +43,9 @@ struct game_t game;
|
||||||
long LNLENG, LNPOSN;
|
long LNLENG, LNPOSN;
|
||||||
char rawbuf[LINESIZE], INLINE[LINESIZE + 1];
|
char rawbuf[LINESIZE], INLINE[LINESIZE + 1];
|
||||||
|
|
||||||
long NUL;
|
|
||||||
long BACK;
|
|
||||||
long LOOK;
|
|
||||||
long CAVE;
|
|
||||||
long FIND;
|
long FIND;
|
||||||
long INVENT;
|
long INVENT;
|
||||||
long SAY;
|
long SAY;
|
||||||
long ENTER;
|
|
||||||
long STREAM;
|
|
||||||
long DPRSSN;
|
|
||||||
long ENTRNC;
|
|
||||||
long LOCK;
|
long LOCK;
|
||||||
long THROW;
|
long THROW;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue