-/* $NetBSD: pl_7.c,v 1.27 2003/08/07 09:37:44 agc Exp $ */
+/* $NetBSD: pl_7.c,v 1.31 2009/03/14 19:57:14 dholland Exp $ */
/*
* Copyright (c) 1983, 1993
#if 0
static char sccsid[] = "@(#)pl_7.c 8.1 (Berkeley) 5/31/93";
#else
-__RCSID("$NetBSD: pl_7.c,v 1.27 2003/08/07 09:37:44 agc Exp $");
+__RCSID("$NetBSD: pl_7.c,v 1.31 2009/03/14 19:57:14 dholland Exp $");
#endif
#endif /* not lint */
#include <curses.h>
+#include <err.h>
#include <signal.h>
#include <stdarg.h>
#include <stdio.h>
#include "player.h"
#include "display.h"
-static void Scroll(void);
-static void endprompt(int);
-static void adjustview(void);
+static void Scroll(void);
+static void endprompt(int);
+static void adjustview(void);
/*
* Display interface
initscreen(void)
{
if (!SCREENTEST()) {
- printf("Can't sail on this terminal.\n");
- exit(1);
+ errx(1, "Can't sail on this terminal.");
}
/* initscr() already done in SCREENTEST() */
view_w = newwin(VIEW_Y, VIEW_X, VIEW_T, VIEW_L);
/*ARGSUSED*/
void
-newturn(int n __attribute__((__unused__)))
+newturn(int n __unused)
{
repaired = loaded = fired = changed = 0;
movebuf[0] = '\0';
if (!done_curses)
return;
va_start(ap, ship);
- if (*fmt == '\7')
+ if (*fmt == '\a')
putchar(*fmt++);
fmtship(format, sizeof(format), fmt, ship);
vwprintw(scroll_w, format, ap);
if (!done_curses)
return;
va_start(ap, fmt);
- if (*fmt == '\7')
+ if (*fmt == '\a')
putchar(*fmt++);
vwprintw(scroll_w, fmt, ap);
va_end(ap);