Author: Sune Fischer
Date: 15:14:25 08/23/03
Go up one level in this thread
On August 23, 2003 at 17:58:16, Uri Blass wrote: >On August 23, 2003 at 17:29:11, Sune Fischer wrote: > >>On August 23, 2003 at 17:12:32, Uri Blass wrote: >>> >>>Note that I do not like a piece list of 32 squares because it means that even >>>after having the attack information I cannot get the information if the square >>>is attacked by a rook directly and I need to look at the squares of the >>>attackers to see the type of the piece. >> >>There are max 32 pieces on the board, so you just do >>if (ix_attack_sq[sq] & ix_pc[ROOK]) ... >>that gives you a 32 bit piece list of rooks (black and white) attacking that >>square. >>If you want just white rooks: >>if (ix_attack_sq[sq] & ix_pc[ROOK] & ix_co[WHITE]) .... >>and so on. >> >>Very elegant and compact, the problem is the incremental update which is very >>slow. >> >>>I like more attack information that give me directly the information if a square >>>is attacked by a pawn,knight,bishop,... >> >>Can it get much faste than that? >> >>-S. > >I thought about something similiar to Ed's information > >bit[square]&3=number of white pawns that attack square >(bit[square]&12)>>2= number of black pawns that attack the square Yes you can do that, if you don't need to know where the attacks came from. It won't be a super accurate SEE, for how do you do x-ray attacks using that? -S. >Uri
This page took 0.01 seconds to execute
Last modified: Thu, 15 Apr 21 08:11:13 -0700
Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.