From 8455f22f975f00c901cf8b30ac7f739a230edc1b Mon Sep 17 00:00:00 2001 From: scw Date: Wed, 9 Aug 2006 13:57:01 +0000 Subject: Reverse photo display in chess game to fit the direction of the game (especially chc). git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@3398 63ad8ddf-47c3-0310-b6dd-a9e9d9715204 --- mbbsd/chess.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'mbbsd/chess.c') diff --git a/mbbsd/chess.c b/mbbsd/chess.c index c7277f1d..f243b208 100644 --- a/mbbsd/chess.c +++ b/mbbsd/chess.c @@ -1353,8 +1353,8 @@ ChessPhotoInitial(ChessInfo* info) #define PHOTO(X) (photo + (X) * CHESS_PHOTO_COLUMN) fp = NULL; - if(getuser(info->user1.userid, &xuser)) { - sethomefile(genbuf, info->user1.userid, info->constants->photo_file_name); + if(getuser(info->user2.userid, &xuser)) { + sethomefile(genbuf, info->user2.userid, info->constants->photo_file_name); fp = fopen(genbuf, "r"); } @@ -1406,16 +1406,16 @@ ChessPhotoInitial(ChessInfo* info) fclose(fp); sprintf(PHOTO(6), " %s%2.2s´Ñ" ANSI_RESET, - info->constants->turn_color[(int) info->myturn], - info->constants->turn_str[(int) info->myturn]); + info->constants->turn_color[(int) info->myturn ^ 1], + info->constants->turn_str[(int) info->myturn ^ 1]); strcpy(PHOTO(7), " ¢ä.¢á "); sprintf(PHOTO(8), " %s%2.2s´Ñ" ANSI_RESET, - info->constants->turn_color[info->myturn ^ 1], - info->constants->turn_str[info->myturn ^ 1]); + info->constants->turn_color[info->myturn], + info->constants->turn_str[info->myturn]); fp = NULL; - if(getuser(info->user2.userid, &xuser)) {; - sethomefile(genbuf, info->user2.userid, info->constants->photo_file_name); + if(getuser(info->user1.userid, &xuser)) {; + sethomefile(genbuf, info->user1.userid, info->constants->photo_file_name); fp = fopen(genbuf, "r"); } -- cgit v1.2.3