-/* $NetBSD: pl_main.c,v 1.23 2009/03/14 19:36:42 dholland Exp $ */
+/* $NetBSD: pl_main.c,v 1.26 2009/03/15 03:33:56 dholland Exp $ */
/*
* Copyright (c) 1983, 1993
#if 0
static char sccsid[] = "@(#)pl_main.c 8.1 (Berkeley) 5/31/93";
#else
-__RCSID("$NetBSD: pl_main.c,v 1.23 2009/03/14 19:36:42 dholland Exp $");
+__RCSID("$NetBSD: pl_main.c,v 1.26 2009/03/15 03:33:56 dholland Exp $");
#endif
#endif /* not lint */
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
+#include "display.h"
#include "extern.h"
#include "player.h"
#include "restart.h"
mf = ms->file;
mc = ms->specs;
- Write(W_BEGIN, ms, 0, 0, 0, 0);
+ send_begin(ms);
if (Sync() < 0)
leave(LEAVE_SYNC);
longjmp(restart, MODE_DRIVER);
/*NOTREACHED*/
case -1:
- perror("fork");
+ warn("fork");
leave(LEAVE_FORK);
break;
default:
else
captain[strlen(captain) - 1] = '\0';
}
- Writestr(W_CAPTAIN, ms, captain);
+ send_captain(ms, captain);
for (n = 0; n < 2; n++) {
char buf[10];
printf("\n");
fflush(stdout);
initscreen();
- draw_board();
+ display_redraw();
snprintf(message, sizeof message, "Captain %s assuming command",
captain);
- Writestr(W_SIGNAL, ms, message);
+ send_signal(ms, message);
newturn(0);
}