-/* $NetBSD: gomoku.h,v 1.14 2009/06/04 06:41:50 dholland Exp $ */
+/* $NetBSD: gomoku.h,v 1.19 2010/03/29 04:28:47 dholland Exp $ */
/*
* Copyright (c) 1994
#define BSZ 19
#define BSZ1 (BSZ+1)
#define BSZ2 (BSZ+2)
+#define BSZ3 (BSZ+3)
+#define BSZ4 (BSZ+4)
#define BAREA (BSZ2*BSZ1+1)
-/* frame dimentions (based on 5 in a row) */
+#define TRANSCRIPT_COL 46 /* necessarily == 2*BSZ4 */
+
+/* interactive curses stuff */
+#define BGOTO(y,x) move(BSZ - (y), 2 * (x) + 3)
+
+/* frame dimensions (based on 5 in a row) */
#define FSZ1 BSZ
#define FSZ2 (BSZ-4)
#define FAREA (FSZ1*FSZ2 + FSZ2*FSZ2 + FSZ1*FSZ2 + FSZ2*FSZ2)
};
extern const char *letters;
-extern char fmtbuf[];
extern const char pdir[];
extern const int dd[4];
#define ASSERT(x)
void bdinit(struct spotstr *);
-void init_overlap(void);
-int getline(char *, int);
+int get_coord(void);
+int get_key(const char *allowedkeys);
+int get_line(char *, int);
void ask(const char *);
void dislog(const char *);
void bdump(FILE *);
void cursinit(void);
void bdwho(int);
void panic(const char *, ...) __printflike(1, 2) __dead;
-void misclog(const char *, ...) __printflike(1, 2);
void debuglog(const char *, ...) __printflike(1, 2);
-void quit(void) __dead;
-void quitsig(int) __dead;
void whatsup(int);
-int readinput(FILE *);
const char *stoc(int);
-int lton(int);
int ctos(const char *);
-void update_overlap(struct spotstr *);
int makemove(int, int);
int list_eq(struct combostr **, struct combostr **, int);
void clearcombo(struct combostr *, int);
-void makeempty(struct combostr *);
-void appendcombo(struct combostr *, int);
-void updatecombo(struct combostr *, int);
void markcombo(struct combostr *);
-void printcombo(struct combostr *, char *, size_t);
-void makecombo(struct combostr *, struct spotstr *, int, int);
-void makecombo2(struct combostr *, struct spotstr *, int, int);
-int sortcombo(struct combostr **, struct combostr **, struct combostr *);
-int checkframes(struct combostr *, struct combostr *, struct spotstr *,
- int, struct overlap_info *);
-void addframes(int);
-void scanframes(int);
-int better(const struct spotstr *, const struct spotstr *, int);
int pickmove(int);