summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorvictor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2003-08-22 16:24:17 +0800
committervictor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2003-08-22 16:24:17 +0800
commitcbcbd2d01d2fa76ea963d9a823abc95b01e5a576 (patch)
tree50ee6ce969294bf3b51da45edf32324b588ec9f9
parent1423cfc70e613ed1e97cba4faa83f26ec6d32eb1 (diff)
downloadpttbbs-cbcbd2d01d2fa76ea963d9a823abc95b01e5a576.tar
pttbbs-cbcbd2d01d2fa76ea963d9a823abc95b01e5a576.tar.gz
pttbbs-cbcbd2d01d2fa76ea963d9a823abc95b01e5a576.tar.bz2
pttbbs-cbcbd2d01d2fa76ea963d9a823abc95b01e5a576.tar.lz
pttbbs-cbcbd2d01d2fa76ea963d9a823abc95b01e5a576.tar.xz
pttbbs-cbcbd2d01d2fa76ea963d9a823abc95b01e5a576.tar.zst
pttbbs-cbcbd2d01d2fa76ea963d9a823abc95b01e5a576.zip
merge from my branch
git-svn-id: http://opensvn.csie.org/pttbbs/trunk@1125 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r--pttbbs/include/modes.h7
-rw-r--r--pttbbs/include/proto.h6
-rw-r--r--pttbbs/include/pttstruct.h10
3 files changed, 18 insertions, 5 deletions
diff --git a/pttbbs/include/modes.h b/pttbbs/include/modes.h
index 3606cb1a..a70e7047 100644
--- a/pttbbs/include/modes.h
+++ b/pttbbs/include/modes.h
@@ -1,4 +1,4 @@
-/* $Id: modes.h,v 1.3 2003/05/26 05:23:13 in2 Exp $ */
+/* $Id$ */
#ifndef INCLUDE_MODES_H
#define INCLUDE_MODES_H
@@ -97,6 +97,11 @@
#define REEDIT 79
#define BLOGGING 80
+/* 象棋 */
+#define CHC_VERSUS 0 /* 雙人 */
+#define CHC_WATCH 1 /* 觀棋 */
+#define CHC_PERSONAL 2 /* 打譜 */
+
/* menu.c 中的模式 */
#define QUIT 0x666 /* Return value to abort recursive functions */
#define XEASY 0x333 /* Return value to un-redraw screen */
diff --git a/pttbbs/include/proto.h b/pttbbs/include/proto.h
index 5e902289..84db664c 100644
--- a/pttbbs/include/proto.h
+++ b/pttbbs/include/proto.h
@@ -165,16 +165,16 @@ int card_99();
int t_chat();
/* chc_draw */
-void chc_drawline(board_t board, int line);
+void chc_drawline(board_t board, chcusr_t *user1, chcusr_t *user2, int line);
void chc_movecur(int r, int c);
-void chc_redraw(board_t board);
+void chc_redraw(chcusr_t *user1, chcusr_t *user2, board_t board);
/* chc_net */
void chc_sendmove(int s);
int chc_recvmove(int s);
/* chc_play */
-void chc(int s);
+void chc(int s, int mode);
/* chc_rule */
void chc_movechess(board_t board);
diff --git a/pttbbs/include/pttstruct.h b/pttbbs/include/pttstruct.h
index 2401c26b..1cb59f85 100644
--- a/pttbbs/include/pttstruct.h
+++ b/pttbbs/include/pttstruct.h
@@ -1,4 +1,4 @@
-/* $Id: pttstruct.h,v 1.43 2003/07/20 00:55:34 in2 Exp $ */
+/* $Id$ */
#ifndef INCLUDE_STRUCT_H
#define INCLUDE_STRUCT_H
@@ -425,4 +425,12 @@ typedef struct
int recno;
} TagItem;
+/* 象棋 */
+typedef struct chcusr_t{
+ char userid[IDLEN + 1];
+ int uid;
+ int win;
+ int lose;
+ int tie;
+} chcusr_t;
#endif