// exclude from coverage analysis because it requires interactivity to test
static void sig_handler(int signo) {
if (signo == SIGINT) {
// exclude from coverage analysis because it requires interactivity to test
static void sig_handler(int signo) {
if (signo == SIGINT) {
* tally=1 for an unseen chest, let the pirate be spotted. Note
* that game.objexts,place[CHEST] = LOC_NOWHERE might mean that he's
* thrown it to the troll, but in that case he's seen the chest
* tally=1 for an unseen chest, let the pirate be spotted. Note
* that game.objexts,place[CHEST] = LOC_NOWHERE might mean that he's
* thrown it to the troll, but in that case he's seen the chest
do {
enum desttype_t desttype = travel[kk].desttype;
game.newloc = travel[kk].destval;
/* Have we avoided a dwarf encounter? */
do {
enum desttype_t desttype = travel[kk].desttype;
game.newloc = travel[kk].destval;
/* Have we avoided a dwarf encounter? */
- else if (i == PIRATE &&
- CNDBIT(game.newloc, COND_NOARRR))
+ } else if (i == PIRATE &&
+ CNDBIT(game.newloc, COND_NOARRR)) {
const char *msg = locations[game.loc].description.small;
if (MOD(game.locs[game.loc].abbrev, game.abbnum) == 0 ||
const char *msg = locations[game.loc].description.small;
if (MOD(game.locs[game.loc].abbrev, game.abbnum) == 0 ||
game.oldlc2 = game.oldloc;
game.oldloc = game.loc;
if (CNDBIT(game.loc, COND_NOBACK)) {
game.oldlc2 = game.oldloc;
game.oldloc = game.loc;
if (CNDBIT(game.loc, COND_NOBACK)) {
if (desttype == dest_goto) {
if (FORCED(scratchloc) &&
travel[tkey[scratchloc]].destval ==
if (desttype == dest_goto) {
if (FORCED(scratchloc) &&
travel[tkey[scratchloc]].destval ==
* indexes the beginning of the motion entries for here (game.loc). */
for (;;) {
if ((travel[travel_entry].motion == HERE) ||
* indexes the beginning of the motion entries for here (game.loc). */
for (;;) {
if ((travel[travel_entry].motion == HERE) ||
if (travel[travel_entry].stop) {
/* Couldn't find an entry matching the motion word
* passed in. Various messages depending on word given.
if (travel[travel_entry].stop) {
/* Couldn't find an entry matching the motion word
* passed in. Various messages depending on word given.
/* else fall through */
}
/* YAML [with OBJ] clause */
else if (TOTING(condarg1) ||
(condtype == cond_with &&
/* else fall through */
}
/* YAML [with OBJ] clause */
else if (TOTING(condarg1) ||
(condtype == cond_with &&
if (game.clock2 == 0) {
/* Once he's panicked, and clock2 has run out, we come here
* to set up the storage room. The room has two locs,
if (game.clock2 == 0) {
/* Once he's panicked, and clock2 has run out, we come here
* to set up the storage room. The room has two locs,
* way objects won't be described until they've
* been picked up and put down separate from
* their respective piles. */
* way objects won't be described until they've
* been picked up and put down separate from
* their respective piles. */
TOTING(OYSTER)) {
pspeak(OYSTER, look, true, 1);
}
for (size_t i = 1; i <= NOBJECTS; i++) {
TOTING(OYSTER)) {
pspeak(OYSTER, look, true, 1);
}
for (size_t i = 1; i <= NOBJECTS; i++) {
game.novice = yes_or_no(arbitrary_messages[WELCOME_YOU],
arbitrary_messages[CAVE_NEARBY],
arbitrary_messages[NO_MESSAGE]);
game.novice = yes_or_no(arbitrary_messages[WELCOME_YOU],
arbitrary_messages[CAVE_NEARBY],
arbitrary_messages[NO_MESSAGE]);