+/*
+ * Actions for the duneon-running code.
+ *
+ * Copyright (c) 1977, 2005 by Will Crowther and Don Woods
+ * Copyright (c) 2017 by Eric S. Raymond
+ * SPDX-License-Identifier: BSD-2-clause
+ */
+
#include <stdlib.h>
#include <stdbool.h>
#include <string.h>
# %s = an ASCII string
# %S = The letter 's' or nothing (if a previous %d value is exactly 1)
# %V = substitute program version string
+#
+# Copyright (c) 2017 by Eric S. Raymond
+# SPDX-License-Identifier: BSD-2-clause
motions: !!omap
- MOT_0:
* not happen. It leverages chunks of advent, mostly initialize() and
* savefile(), so we know we're always outputing save files that advent
* can import.
+ *
+ * Copyright (c) 1977, 2005 by Will Crowther and Don Woods
+ * Copyright (c) 2017 by Eric S. Raymond
+ * SPDX-License-Identifier: BSD-2-clause
*/
#include <getopt.h>
#include <stdlib.h>
+/*
+ * Initialisation
+ *
+ * Copyright (c) 1977, 2005 by Will Crowther and Don Woods
+ * Copyright (c) 2017 by Eric S. Raymond
+ * SPDX-License-Identifier: BSD-2-clause
+ */
+
#include <unistd.h>
#include <stdlib.h>
#include <stdio.h>
#include "advent.h"
-/*
- * Initialisation
- */
-
struct settings_t settings = {
.logfp = NULL,
.oldstyle = false,
* ESR apologizes for the remaing gotos (now confined to one function
* in this file - there used to be over 350 of them, *everywhere*).
* Applying the Structured Program Theorem can be hard.
+ *
+ * Copyright (c) 1977, 2005 by Will Crowther and Don Woods
+ * Copyright (c) 2017 by Eric S. Raymond
+ * SPDX-License-Identifier: BSD-2-clause
*/
#include <stdlib.h>
# The nontrivial part of this is the compilation of the YAML for
# movement rules to the travel array that's actually used by
# playermove().
+#
+# Copyright (c) 2017 by Eric S. Raymond
+# SPDX-License-Identifier: BSD-2-clause
import sys, yaml
+/*
+ * I/O and support riutines.
+ *
+ * Copyright (c) 1977, 2005 by Will Crowther and Don Woods
+ * Copyright (c) 2017 by Eric S. Raymond
+ * SPDX-License-Identifier: BSD-2-clause
+ */
+
#include <unistd.h>
#include <stdlib.h>
#include <stdio.h>
+/*
+ * Saving and resuming.
+ *
+ * (ESR) This replaces a bunch of particularly nasty FORTRAN-derived code;
+ * see the history.adoc file in the source distribution for discussion.
+ *
+ * Copyright (c) 1977, 2005 by Will Crowther and Don Woods
+ * Copyright (c) 2017 by Eric S. Raymond
+ * SPDX-License-Identifier: BSD-2-clause
+ */
+
#include <stdlib.h>
#include <string.h>
#include <editline/readline.h>
#include "advent.h"
#include "dungeon.h"
-/*
- * (ESR) This replaces a bunch of particularly nasty FORTRAN-derived code;
- * see the history.adoc file in the source distribution for discussion.
- */
-
#define VRSION 28 /* bump on save format change */
/*
+/*
+ * Scoring and wrap-up.
+ *
+ * Copyright (c) 1977, 2005 by Will Crowther and Don Woods
+ * Copyright (c) 2017 by Eric S. Raymond
+ * SPDX-License-Identifier: BSD-2-clause
+ */
#include <stdlib.h>
#include "advent.h"
#include "dungeon.h"
-/*
- * scoring and wrap-up
- */
-
static int mxscor; /* ugh..the price for having score() not exit. */
long score(enum termination mode)