Author: Robert Hyatt
Date: 13:42:13 12/05/03
Go up one level in this thread
On December 05, 2003 at 14:18:27, Georg v. Zimmermann wrote: >Hi, > >just had a little idea and was wondering whether anyone of you is doing that. >When in check there are obviously two ways to generate moves, either flip >through all pieces and see whether they can capture attacker/ move in between, >or flip through the in-between squares and see whether pieces can move there. >Now usually b) will be faster. But in some positions when the attacker is far >aways from the king and few pieces are left, a) will be faster. I wonder if >someone has 2 versions and uses a) or b) depending on the board situation ? It >is an insignificant gain in an insignificant function, I know. But still ... > >Georg I have a specific move generator for use when one side is in check and has to move. It generates only legal moves, but it doesn't try generating them all and eliminating them if they are illegal. It uses specific rules to capture if there is only one checker, or move if there is more than one, plus interposing and the like. GenerateCheckEvasions() is the source in movegen.c, if you want to look. The comments are pretty informative on what I am doing there...
This page took 0 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.