X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=gnushogi%2Feval.c;h=2a339869f751a8b9359a63295df56c4b37e51b78;hb=2afa5512342f9662cb5d8f94ed060dbd69a74c3d;hp=355acf30b26e2aad8ef0757927d8a4f2b4ee9633;hpb=5fbd58dc91d27467d3ccbea2d76ab70a5ff2b3f7;p=gnushogi.git diff --git a/gnushogi/eval.c b/gnushogi/eval.c index 355acf3..2a33986 100644 --- a/gnushogi/eval.c +++ b/gnushogi/eval.c @@ -2,11 +2,14 @@ * FILE: eval.c * * ---------------------------------------------------------------------- - * - * Copyright (c) 2012 Free Software Foundation + * Copyright (c) 1993, 1994, 1995 Matthias Mutz + * Copyright (c) 1999 Michael Vanier and the Free Software Foundation * * GNU SHOGI is based on GNU CHESS * + * Copyright (c) 1988, 1989, 1990 John Stanback + * Copyright (c) 1992 Free Software Foundation + * * This file is part of GNU SHOGI. * * GNU Shogi is free software; you can redistribute it and/or modify it @@ -1291,7 +1294,8 @@ PawnValue(short sq, short side) { if (crow(c1, sq) == 2) /* pawn on 3d rank */ { - if (board[(c1 == black) ? (sq + 27) : (sq - 27)] == pawn) + if (board[(c1 == black) ? + (sq + 3*NO_COLS) : (sq - 3*NO_COLS)] == pawn) { /* opposing pawn has been moved (even column == (sq & 1)) */