Hi 
in patterns2.db i found DD3

------------------------------------------------------
Pattern DD3

OXX
X*.
X..

:8,O

OEE
D*c
Dba

;oplay_attack(*,D) && oplay_attack_either(*,a,D,E)
;&& !oplay_defend_both(*,b,c,D,E)

>test_attack_either_move(D,E)
---------------------------------------------------
mkpat.c:

 {"oplay_defend_both",         2, 1, 3.00, "play_attack_defend2_n(color, 0, 
%d"},
-----------------------------------------------------
helpers.c:

void test_attack_either_move(int move, int color, int worma, int wormb) {
...
  if (trymove(move, color, "test_attack_either_move", worma)) {
...
    else if (!defend_both(worma, wormb))

      add_either_move(move, ATTACK_STRING, worma, ATTACK_STRING, wormb);
 ...
}
----------------------------------------------------


I don't understand 2 things:
- why a test is done in action ?  I expected only setting the either_move 
 (if it should do only this, maybe rename it to add_attack_either_move 
  for better clarity ;)
- why different tests are done in the helper, and the action ?

Alain


_______________________________________________
gnugo-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/gnugo-devel

Reply via email to