#define EXTRA_INIT
#define EXTRA_RESET
#define EXTRA_LONG
#define EXTRA_MOVE1
#define EXTRA_MOVE2
#define EXTRA_MOVE3
#define EXTRA_MOVE4
#define EXTRA_MOVE5
#define EXTRA_MOVE6
#define EXTRA_MOVE7
#define EXTRA_MOVE8
#define ONE_EXIT(DEST, DIR, SH, LO, LIGHT)\
reset(arg) { EXTRA_RESET if (arg) return; set_light(LIGHT); }\
short() {\
if (set_light(0))\
return SH;\
return "It is too dark to see here";\
}\
\
init() {\
add_action("move"); add_verb(DIR);\
EXTRA_INIT\
}\
\
move() {\
EXTRA_MOVE1\
call_other(this_player(), "move_player", DIR + "#" +DEST);\
return 1;\
}\
\
long(str) {\
if (set_light(0) == 0){\
write("It really is dark you know.\n");\
return;\
}\
EXTRA_LONG\
write(LO);\
write(" The only obvious exit is " + DIR + ".\n");\
}
#define TWO_EXIT(DEST1, DIR1, DEST2, DIR2, SH, LO, LIGHT)\
reset(arg) { EXTRA_RESET if (arg) return; set_light(LIGHT); }\
short() {\
if (set_light(0))\
return SH;\
return "It is too dark to see here";\
}\
\
init() {\
add_action("move1"); add_verb(DIR1);\
add_action("move2"); add_verb(DIR2);\
EXTRA_INIT\
}\
\
move1() {\
EXTRA_MOVE1\
call_other(this_player(), "move_player", DIR1 + "#" + DEST1);\
return 1;\
}\
\
move2() {\
EXTRA_MOVE2\
call_other(this_player(), "move_player", DIR2 + "#" + DEST2);\
return 1;\
}\
\
long(str) {\
if (set_light(0) == 0){\
write("It really is dark you know.\n");\
return;\
}\
EXTRA_LONG\
write(LO);\
write("There are two obvious exits:\n " + DIR1 + " and " + DIR2 + ".\n");\
}
#define THREE_EXIT(DEST1, DIR1, DEST2, DIR2, DEST3, DIR3, SH, LO, LIGHT)\
reset(arg) { EXTRA_RESET if (arg) return; set_light(LIGHT); }\
short() {\
if (set_light(0))\
return SH;\
return "It is too dark to see here";\
}\
\
init() {\
add_action("move1"); add_verb(DIR1);\
add_action("move2"); add_verb(DIR2);\
add_action("move3"); add_verb(DIR3);\
EXTRA_INIT\
}\
\
move1() {\
EXTRA_MOVE1\
call_other(this_player(), "move_player", DIR1 + "#" + DEST1);\
return 1;\
}\
\
move2() {\
EXTRA_MOVE2\
call_other(this_player(), "move_player", DIR2 + "#" + DEST2);\
return 1;\
}\
\
move3() {\
EXTRA_MOVE3\
call_other(this_player(), "move_player", DIR3 + "#" + DEST3);\
return 1;\
}\
\
long(str) {\
if (set_light(0) == 0){\
write("It really is dark you know.\n");\
return;\
}\
EXTRA_LONG\
write(LO);\
write("There are three obvious exits:\n " + DIR1 + ", " + DIR2 +\
" and " + DIR3 + ".\n");\
}
#define FOUR_EXIT(DEST1, DIR1, DEST2, DIR2, DEST3, DIR3, DEST4, DIR4, SH, LO, LIGHT)\
reset(arg) { EXTRA_RESET if (arg) return; set_light(LIGHT); }\
short() {\
if (set_light(0))\
return SH;\
return "It is too dark to see here";\
}\
\
init() {\
add_action("move1"); add_verb(DIR1);\
add_action("move2"); add_verb(DIR2);\
add_action("move3"); add_verb(DIR3);\
add_action("move4"); add_verb(DIR4);\
EXTRA_INIT\
}\
\
move1() {\
EXTRA_MOVE1\
call_other(this_player(), "move_player", DIR1 + "#" + DEST1);\
return 1;\
}\
\
move2() {\
EXTRA_MOVE2\
call_other(this_player(), "move_player", DIR2 + "#" + DEST2);\
return 1;\
}\
\
move3() {\
EXTRA_MOVE3\
call_other(this_player(), "move_player", DIR3 + "#" + DEST3);\
return 1;\
}\
\
move4() {\
EXTRA_MOVE4\
call_other(this_player(), "move_player", DIR4 + "#" + DEST4);\
return 1;\
}\
\
long(str) {\
if (set_light(0) == 0){\
write("It really is dark you know.\n");\
return;\
}\
EXTRA_LONG\
write(LO);\
write("There are four obvious exits:\n " + DIR1 + ", " + DIR2 + ", " +\
DIR3 + " and " + DIR4 + ".\n");\
}
#define FIVE_EXIT(DEST1, DIR1, DEST2, DIR2, DEST3, DIR3, DEST4, DIR4, DEST5, DIR5, SH, LO, LIGHT)\
reset(arg) { EXTRA_RESET if (arg) return; set_light(LIGHT); }\
short() {\
if (set_light(0))\
return SH;\
return "It is too dark to see here";\
}\
\
init() {\
add_action("move1"); add_verb(DIR1);\
add_action("move2"); add_verb(DIR2);\
add_action("move3"); add_verb(DIR3);\
add_action("move4"); add_verb(DIR4);\
add_action("move5"); add_verb(DIR5);\
EXTRA_INIT\
}\
\
move1() {\
EXTRA_MOVE1\
call_other(this_player(), "move_player", DIR1 + "#" + DEST1);\
return 1;\
}\
\
move2() {\
EXTRA_MOVE2\
call_other(this_player(), "move_player", DIR2 + "#" + DEST2);\
return 1;\
}\
\
move3() {\
EXTRA_MOVE3\
call_other(this_player(), "move_player", DIR3 + "#" + DEST3);\
return 1;\
}\
\
move4() {\
EXTRA_MOVE4\
call_other(this_player(), "move_player", DIR4 + "#" + DEST4);\
return 1;\
}\
\
move5() {\
EXTRA_MOVE5\
call_other(this_player(), "move_player", DIR5 + "#" + DEST5);\
return 1;\
}\
\
long(str) {\
if (set_light(0) == 0){\
write("It really is dark you know.\n");\
return;\
}\
EXTRA_LONG\
write(LO);\
write("There are five obvious exits:\n " + DIR1 + ", " + DIR2 + ", " +\
DIR3 + ", " + DIR4 + " and " + DIR5 + ".\n");\
}
#define SIX_EXIT(DEST1, DIR1, DEST2, DIR2, DEST3, DIR3, DEST4, DIR4, DEST5, DIR5, DEST6, DIR6, SH, LO, LIGHT)\
reset(arg) { EXTRA_RESET if (arg) return; set_light(LIGHT); }\
short() {\
if (set_light(0))\
return SH;\
return "It is too dark to see here";\
}\
\
init() {\
add_action("move1"); add_verb(DIR1);\
add_action("move2"); add_verb(DIR2);\
add_action("move3"); add_verb(DIR3);\
add_action("move4"); add_verb(DIR4);\
add_action("move5"); add_verb(DIR5);\
add_action("move6"); add_verb(DIR6);\
EXTRA_INIT\
}\
\
move1() {\
EXTRA_MOVE1\
call_other(this_player(), "move_player", DIR1 + "#" + DEST1);\
return 1;\
}\
\
move2() {\
EXTRA_MOVE2\
call_other(this_player(), "move_player", DIR2 + "#" + DEST2);\
return 1;\
}\
\
move3() {\
EXTRA_MOVE3\
call_other(this_player(), "move_player", DIR3 + "#" + DEST3);\
return 1;\
}\
\
move4() {\
EXTRA_MOVE4\
call_other(this_player(), "move_player", DIR4 + "#" + DEST4);\
return 1;\
}\
\
move5() {\
EXTRA_MOVE5\
call_other(this_player(), "move_player", DIR5 + "#" + DEST5);\
return 1;\
}\
\
move6() {\
EXTRA_MOVE6\
call_other(this_player(), "move_player", DIR6 + "#" + DEST6);\
return 1;\
}\
\
long(str) {\
if (set_light(0) == 0){\
write("It really is dark you know.\n");\
return;\
}\
EXTRA_LONG\
write(LO);\
write("There are six obvious exits:\n " + DIR1 + ", " + DIR2 + ", " +\
DIR3 + ", " + DIR4 + ", " + DIR5 + " and " + DIR6 + ".\n");\
}
#define SEVEN_EXIT(DEST1, DIR1, DEST2, DIR2, DEST3, DIR3, DEST4, DIR4, DEST5, DIR5, DEST6, DIR6, DEST7, DIR7, SH, LO, LIGHT)\
reset(arg) { EXTRA_RESET if (arg) return; set_light(LIGHT); }\
short() {\
if (set_light(0))\
return SH;\
return "It is too dark to see here";\
}\
\
init() {\
add_action("move1"); add_verb(DIR1);\
add_action("move2"); add_verb(DIR2);\
add_action("move3"); add_verb(DIR3);\
add_action("move4"); add_verb(DIR4);\
add_action("move5"); add_verb(DIR5);\
add_action("move6"); add_verb(DIR6);\
add_action("move7"); add_verb(DIR8);\
EXTRA_INIT\
}\
\
move1() {\
EXTRA_MOVE1\
call_other(this_player(), "move_player", DIR1 + "#" + DEST1);\
return 1;\
}\
\
move2() {\
EXTRA_MOVE2\
call_other(this_player(), "move_player", DIR2 + "#" + DEST2);\
return 1;\
}\
\
move3() {\
EXTRA_MOVE3\
call_other(this_player(), "move_player", DIR3 + "#" + DEST3);\
return 1;\
}\
\
move4() {\
EXTRA_MOVE4\
call_other(this_player(), "move_player", DIR4 + "#" + DEST4);\
return 1;\
}\
\
move5() {\
EXTRA_MOVE5\
call_other(this_player(), "move_player", DIR5 + "#" + DEST5);\
return 1;\
}\
\
move6() {\
EXTRA_MOVE6\
call_other(this_player(), "move_player", DIR6 + "#" + DEST6);\
return 1;\
}\
\
move7() {\
EXTRA_MOVE7\
call_other(this_player(), "move_player", DIR7 + "#" + DEST7);\
return 1;\
}\
\
long(str) {\
if (set_light(0) == 0){\
write("It really is dark you know.\n");\
return;\
}\
EXTRA_LONG\
write(LO);\
write("There are seven obvious exits:\n " + DIR1 + ", " + DIR2 + ", " +\
DIR3 + ", " + DIR4 + ", " + DIR5 + ", " + DIR6 + " and " + DIR7 + ".\n");\
}
#define EIGHT_EXIT(DEST1, DIR1, DEST2, DIR2, DEST3, DIR3, DEST4, DIR4, DEST5, DIR5 , DEST6, DIR6, DEST7, DIR7, SH, LO, LIGHT)\
reset(arg) { EXTRA_RESET if (arg) return; set_light(LIGHT); }\
short() {\
if (set_light(0))\
return SH;\
return "It is too dark to see here";\
}\
\
init() {\
add_action("move1"); add_verb(DIR1);\
add_action("move2"); add_verb(DIR2);\
add_action("move3"); add_verb(DIR3);\
add_action("move4"); add_verb(DIR4);\
add_action("move5"); add_verb(DIR5);\
add_action("move6"); add_verb(DIR6);\
add_action("move7"); add_verb(DIR7);\
add_action("move8"); add_verb(DIR8);\
EXTRA_INIT\
}\
\
move1() {\
EXTRA_MOVE1\
call_other(this_player(), "move_player", DIR1 + "#" + DEST1);\
return 1;\
}\
\
move2() {\
EXTRA_MOVE2\
call_other(this_player(), "move_player", DIR2 + "#" + DEST2);\
return 1;\
}\
\
move3() {\
EXTRA_MOVE3\
call_other(this_player(), "move_player", DIR3 + "#" + DEST3);\
return 1;\
}\
\
move4() {\
EXTRA_MOVE4\
call_other(this_player(), "move_player", DIR4 + "#" + DEST4);\
return 1;\
}\
\
move5() {\
EXTRA_MOVE5\
call_other(this_player(), "move_player", DIR5 + "#" + DEST5);\
return 1;\
}\
\
move6() {\
EXTRA_MOVE6\
call_other(this_player(), "move_player", DIR6 + "#" + DEST6);\
return 1;\
}\
\
move7() {\
EXTRA_MOVE7\
call_other(this_player(), "move_player", DIR7 + "#" + DEST7);\
return 1;\
}\
\
move8() {\
EXTRA_MOVE8\
call_other(this_player(), "move_player", DIR8 + "#" + DEST8);\
return 1;\
}\
\
long(str) {\
if (set_light(0) == 0){\
write("It really is dark you know.\n");\
return;\
}\
EXTRA_LONG\
write(LO);\
write("There are eight obvious exits:\n " + DIR1 + ", " + DIR2 + ", " +\
DIR3 + ", " + DIR4 + ", " + DIR5 + ", " + DIR6 + "," + DIR7 + " and " + DIR8 + ".\n");\
}