X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=gnushogi%2Fattacks.c;h=7d2237d81af82aceb5d3773ff9764a63932e2187;hb=68c554411d120d163045f77a80ad9009f7a73841;hp=e70f358dbac08f1d018359d43cbdfb08ecfd9916;hpb=8ae7e7d1b257ef36d8a9fd1cd88807954ef10764;p=gnushogi.git diff --git a/gnushogi/attacks.c b/gnushogi/attacks.c index e70f358..7d2237d 100644 --- a/gnushogi/attacks.c +++ b/gnushogi/attacks.c @@ -4,6 +4,7 @@ * ---------------------------------------------------------------------- * Copyright (c) 1993, 1994, 1995 Matthias Mutz * Copyright (c) 1999 Michael Vanier and the Free Software Foundation + * Copyright (c) 2008, 2013, 2014 Yann Dirson and the Free Software Foundation * * GNU SHOGI is based on GNU CHESS * @@ -14,8 +15,8 @@ * * GNU Shogi is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the - * Free Software Foundation; either version 1, or (at your option) any - * later version. + * Free Software Foundation; either version 3 of the License, + * or (at your option) any later version. * * GNU Shogi is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or @@ -23,8 +24,8 @@ * for more details. * * You should have received a copy of the GNU General Public License along - * with GNU Shogi; see the file COPYING. If not, write to the Free - * Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. + * with GNU Shogi; see the file COPYING. If not, see + * . * ---------------------------------------------------------------------- * */ @@ -118,6 +119,7 @@ SqAttacked(short square, short side, short *blockable) } while (u != square); +#ifndef MINISHOGI /* try a knight capture (using xside's knight moves) */ ptyp = ptype[side ^ 1][knight]; @@ -141,6 +143,7 @@ SqAttacked(short square, short side, short *blockable) #endif } while (u != square); +#endif /* MINISHOGI */ *blockable = true; @@ -216,6 +219,7 @@ SqAttacked(short square, short side, short *blockable) } while (u != square); +#ifndef MINISHOGI /* try a lance capture (using xside's lance moves) */ ptyp = ptype[side ^ 1][lance]; @@ -248,6 +252,7 @@ SqAttacked(short square, short side, short *blockable) } } while (u != square); +#endif /* MINISHOGI */ return false; }