Action word mnemonics are now enums from adventure.yaml.
#define PCT(N) (randrange(100) < (N))
#define GSTONE(OBJ) ((OBJ) == EMERALD || (OBJ) == RUBY || (OBJ) == AMBER || (OBJ) == SAPPH)
#define FOREST(LOC) CNDBIT(LOC, COND_FOREST)
-#define VOCWRD(LETTRS,SECT) (vocab(MAKEWD(LETTRS),SECT))
#define SPECIAL(LOC) ((LOC) > SPECIALBASE)
#define OUTSID(LOC) (CNDBIT(LOC, COND_ABOVE) || FOREST(LOC))
#define INDEEP(LOC) ((LOC) >= LOC_MISTHALL && !OUTSID(LOC))
-/* vocabulary items */
-extern long FIND;
-extern long INVENT;
-extern long SAY;
-extern long LOCK;
-extern long THROW;
-
enum speechpart {unknown, intransitive, transitive};
struct command_t {
- ACT_2:
message: ARENT_CARRYING
words: ['drop', 'relea', 'free', 'disca', 'dump']
-- ACT_3:
+- SAY:
message: NO_MESSAGE
words: ['say', 'chant', 'sing', 'utter', 'mumbl']
- ACT_4:
- ACT_5:
message: NO_MESSAGE
words: ['nothi']
-- ACT_6:
+- LOCK:
message: NOT_LOCKABLE
words: ['lock', 'close']
- ACT_7:
- ACT_16:
message: RUB_NOGO
words: ['rub']
-- ACT_17:
+- THROW:
message: ARENT_CARRYING
words: ['throw', 'toss']
- ACT_18:
message: HUH_MAN
words: ['quit']
-- ACT_19:
+- FIND:
message: NEARBY
words: ['find', 'where']
-- ACT_20:
+- INVENT:
message: NEARBY
words: ['inven']
- ACT_21:
long LNLENG, LNPOSN;
char rawbuf[LINESIZE], INLINE[LINESIZE + 1];
-long FIND;
-long INVENT;
-long SAY;
-long LOCK;
-long THROW;
-
FILE *logfp = NULL, *rfp = NULL;
bool oldstyle = false;
bool editline = true;
game.hintlc[i] = 0;
}
- /* Define some handy mnemonics. */
-
- /* Some action verbs. */
- FIND = VOCWRD(WORD_FIND, 2);
- INVENT = VOCWRD(WORD_INVENT, 2);
- LOCK = VOCWRD(WORD_LOCK, 2);
- SAY = VOCWRD(WORD_SAY, 2);
- THROW = VOCWRD(WORD_THROW, 2);
-
/* Initialise the dwarves. game.dloc is loc of dwarves,
* hard-wired in. game.odloc is prior loc of each dwarf,
* initially garbage. DALTLC is alternate initial loc for dwarf,
long LNLENG, LNPOSN;
char rawbuf[LINESIZE], INLINE[LINESIZE + 1];
-long FIND;
-long INVENT;
-long SAY;
-long LOCK;
-long THROW;
-
FILE *logfp = NULL, *rfp = NULL;
bool oldstyle = false;
bool editline = true;