Ticket #164: def_both.diff

File def_both.diff, 29.7 kB (added by draqo, 20 months ago)
  • engine/combination.c

    diff -N -r -u -X .ignore gnugo-copy/engine/combination.c gnugo/engine/combination.c
    old new  
    22 * This is GNU Go, a Go program. Contact gnugo@gnu.org, or see       * 
    33 * http://www.gnu.org/software/gnugo/ for more information.          * 
    44 *                                                                   * 
    5  * Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005 and 2006      * 
     5 * Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 and 2007 * 
    66 * by the Free Software Foundation.                                  * 
    77 *                                                                   * 
    88 * This program is free software; you can redistribute it and/or     * 
     
    144144                remove_attack_threat_move(ii, a_threatened_groups[l]); 
    145145              } 
    146146            } 
    147             else if (!defend_both(a_threatened_groups[k], 
    148                                   a_threatened_groups[l])) { 
     147            else if (defend_both(a_threatened_groups[k], 
     148                                 a_threatened_groups[l]) != WIN) { 
    149149              TRACE("Double threat at %1m, either %1m or %1m attacked.\n", 
    150150                    ii, a_threatened_groups[k], a_threatened_groups[l]); 
    151151              add_either_move(ii, ATTACK_STRING, a_threatened_groups[k], 
  • engine/reading.c

    diff -N -r -u -X .ignore gnugo-copy/engine/reading.c gnugo/engine/reading.c
    old new  
    638638  int a_savepos; 
    639639  int b_savepos; 
    640640  int acode = 0; 
    641   int dcode = 0; 
     641  int dcode_a; 
     642  int dcode_b; 
    642643   
    643644  int color = board[astr]; 
    644645  ASSERT1(IS_STONE(color) , astr); 
     
    653654    bstr = t; 
    654655  } 
    655656 
    656   attack_and_defend(astr, &acode, NULL, &dcode, &a_savepos); 
    657   if (acode != 0) { 
     657  attack_and_defend(astr, &acode, NULL, &dcode_a, &a_savepos); 
     658  if (acode != LOSE) { 
    658659    a_threatened = 1; 
    659     if (dcode != WIN) 
    660       return 0; /* (astr) already lost */ 
     660    if (dcode_a == LOSE) 
     661      return LOSE; /* (astr) already lost */ 
    661662  } 
     663  else 
     664    dcode_a = WIN; 
    662665   
    663   attack_and_defend(bstr, &acode, NULL, &dcode, &b_savepos); 
    664   if (acode != 0) { 
     666  attack_and_defend(bstr, &acode, NULL, &dcode_b, &b_savepos); 
     667  if (acode != LOSE) { 
    665668    b_threatened = 1; 
    666     if (dcode != WIN) 
    667       return 0; /* (bstr) already lost */ 
     669    if (dcode_b == LOSE) 
     670      return LOSE; /* (bstr) already lost */ 
    668671  } 
     672  else 
     673    dcode_b = WIN; 
    669674 
    670675  /* Neither string can be attacked or only one of them, in which case 
    671676   * we have time to save it. 
    672677   */ 
    673678  if (!a_threatened || !b_threatened) 
    674     return WIN; 
     679    return gg_min(dcode_a, dcode_b); 
    675680   
    676681  /* If both strings are threatened we assume that one will become lost, 
    677682   * unless find_defense() happened to return the same defense point for 
     
    682687   */ 
    683688 
    684689  if (a_savepos == b_savepos) 
    685     return WIN; /* Both strings can be attacked but also defended  
    686                  * by one move. */ 
     690    return gg_min(dcode_a, dcode_b); /* Both strings can be attacked but 
     691                                        also defended by one move. */ 
    687692 
    688693  /* We also try each of the returned defense points and see whether 
    689694   * the other string can still be attacked. This still gives a 
  • engine/utils.c

    diff -N -r -u -X .ignore gnugo-copy/engine/utils.c gnugo/engine/utils.c
    old new  
    13841384        && trymove(move, color, "double_atari", NO_MOVE)) { 
    13851385      if (countlib(move) > 1 
    13861386          && (BOARD(m, n+dn) == EMPTY || BOARD(m+dm, n) == EMPTY  
    1387               || !defend_both(POS(m, n+dn), POS(m+dm, n)))) { 
     1387              || defend_both(POS(m, n+dn), POS(m+dm, n)) != WIN)) { 
    13881388        popgo(); 
    13891389        if (value) { 
    13901390          if (worm[POS(m, n+dn)].effective_size 
  • patterns/aa_attackpats.db

    diff -N -r -u -X .ignore gnugo-copy/patterns/aa_attackpats.db gnugo/patterns/aa_attackpats.db
    old new  
    434434?*? 
    435435BAC 
    436436 
    437 ; lib(A) == 1 && lib(B) + lib(C) <= 6 && !oplay_defend_both(*,B,C) 
     437; lib(A) == 1 && lib(B) + lib(C) <= 6 && oplay_defend_both(*,B,C)!=WIN 
    438438 
    439439 
    440440Pattern A25 
  • patterns/barriers.db

    diff -N -r -u -X .ignore gnugo-copy/patterns/barriers.db gnugo/patterns/barriers.db
    old new  
    215215Oc 
    216216ba 
    217217 
    218 ;!safe_omove(a) || oplay_defend_both(a,b,c) 
     218;!safe_omove(a) || oplay_defend_both(a,b,c)==WIN 
    219219 
    220220 
    221221Pattern Barrier12 
     
    406406Oab. 
    407407.dcO 
    408408 
    409 ;oplay_attack_either(a,b,c,d,b,d) || oplay_defend_both(a,b,c,d,a,c) 
     409;oplay_attack_either(a,b,c,d,b,d) || oplay_defend_both(a,b,c,d,a,c)==WIN 
    410410 
    411411 
    412412Pattern Barrier24 
     
    656656OcXe 
    657657.bad 
    658658 
    659 ;oplay_defend_both(a,b,c,d,a,e) 
     659;oplay_defend_both(a,b,c,d,a,e)==WIN 
    660660 
    661661 
    662662Pattern Barrier42 
     
    669669cD? 
    670670baO 
    671671 
    672 ;oplay_attack_either(a,b,b,D) || oplay_defend_both(a,b,a,c) 
     672;oplay_attack_either(a,b,b,D) || oplay_defend_both(a,b,a,c)==WIN 
    673673 
    674674 
    675675Pattern Barrier43 
     
    696696..,o 
    697697---- 
    698698 
    699 ;oplay_attack_either(a,b,c,d,d,b) && !oplay_defend_both(a,c,b,c,E) 
     699;oplay_attack_either(a,b,c,d,d,b) && oplay_defend_both(a,c,b,c,E)!=WIN 
    700700 
    701701 
    702702Pattern Barrier45 
     
    11981198bfE 
    11991199aDc 
    12001200 
    1201 ;!oplay_defend_both(a,b,c,D,E) 
     1201;oplay_defend_both(a,b,c,D,E)!=WIN 
    12021202>return (!xplay_attack(b,f)); 
    12031203 
    12041204 
     
    14861486fAb 
    14871487 
    14881488;lib(A)==2 && !oplay_attack(b,b) 
    1489 >return (!xplay_attack(c,d) && xplay_defend_both(e,d,f)); 
     1489>return (!xplay_attack(c,d) && xplay_defend_both(e,d,f)==WIN); 
    14901490 
    14911491 
    14921492Pattern Intrusion21 
     
    18941894 
    18951895;safe_omove(a) 
    18961896;&& (o_somewhere(e) || oplay_attack(a,e,e)) 
    1897 ;&& !oplay_defend_both(a,b,c,b,D) 
     1897;&& oplay_defend_both(a,b,c,b,D)!=WIN 
    18981898>return (!xplay_attack(a,f) && (o_somewhere(e) || (!xplay_attack(e,f)))); 
    18991899 
    19001900 
     
    19131913 
    19141914;safe_omove(a) 
    19151915;&& (o_somewhere(b) || oplay_attack(a,b,b)) 
    1916 ;&& !oplay_defend_both(a,c,d,e,F,G) 
     1916;&& oplay_defend_both(a,c,d,e,F,G)!=WIN 
    19171917>return (!xplay_attack(a,h)); 
    19181918 
    19191919 
     
    22632263cDO 
    22642264 
    22652265;oplay_attack(c,b,D) 
    2266 >return !safe_xmove(a) && !oplay_defend_both(c,b,a,b,D); 
     2266>return !safe_xmove(a) && oplay_defend_both(c,b,a,b,D)!=WIN; 
    22672267 
    22682268 
    22692269Pattern Intrusion63 
     
    24682468ebaO 
    24692469---- 
    24702470 
    2471 ;!oplay_defend_both(a,b,c,b,D) 
     2471;oplay_defend_both(a,b,c,b,D)!=WIN 
    24722472 
    24732473>non_xterritory(b); 
    24742474>non_xterritory(c); 
     
    25062506bac 
    25072507--- 
    25082508 
    2509 ;safe_omove(a) && !oplay_defend_both(a,b,c,?,d,b,E) 
     2509;safe_omove(a) && oplay_defend_both(a,b,c,?,d,b,E)!=WIN 
    25102510 
    25112511>non_xterritory(d); 
    25122512 
     
    26752675|Xd 
    26762676|bX 
    26772677 
    2678 ;!oplay_defend_both(a,b,?,c,a,d) 
     2678;oplay_defend_both(a,b,?,c,a,d)!=WIN 
    26792679 
    26802680>non_oterritory(a); 
    26812681>non_oterritory(c); 
     
    26922692|ba 
    26932693|Xc 
    26942694 
    2695 ;!xplay_defend_both(a,b,c) 
     2695;xplay_defend_both(a,b,c)!=WIN 
    26962696 
    26972697>non_oterritory(a); 
    26982698 
     
    27092709bacO 
    27102710---- 
    27112711 
    2712 ;!oplay_defend_both(a,b,c,?,d,b,E) 
     2712;oplay_defend_both(a,b,c,?,d,b,E)!=WIN 
    27132713 
    27142714>non_xterritory(a); 
    27152715>non_xterritory(b); 
     
    27282728dcaeO 
    27292729----- 
    27302730 
    2731 ;!oplay_defend_both(a,b,c,d,e,?,f,d,b) 
     2731;oplay_defend_both(a,b,c,d,e,?,f,d,b)!=WIN 
    27322732 
    27332733>non_xterritory(a); 
    27342734>non_xterritory(b); 
     
    30963096.cX 
    30973097.ab 
    30983098 
    3099 ;!xplay_defend_both(a,b,c) 
     3099;xplay_defend_both(a,b,c)!=WIN 
    31003100 
    31013101>non_oterritory(a); 
    31023102 
     
    31153115.DO 
    31163116.bC 
    31173117 
    3118 ;!oplay_defend_both(a,?,b,C,D) 
     3118;oplay_defend_both(a,?,b,C,D)!=WIN 
    31193119 
    31203120>non_xterritory(b); 
    31213121 
     
    31723172bX 
    31733173ac 
    31743174 
    3175 ;!xplay_defend_both(a,b,c) && !adjacent_to_defendable_stone_in_atari(b) 
     3175;xplay_defend_both(a,b,c)!=WIN && !adjacent_to_defendable_stone_in_atari(b) 
    31763176;&& !adjacent_to_defendable_stone_in_atari(c) 
    31773177 
    31783178>non_oterritory(a); 
     
    32863286Oab 
    32873287?Xc 
    32883288 
    3289 ;!oplay_defend_both(a,b,a,c) 
     3289;oplay_defend_both(a,b,a,c)!=WIN 
    32903290 
    32913291>non_oterritory(b); 
    32923292>non_oterritory(d); 
     
    33443344bXa 
    33453345cdX 
    33463346 
    3347 ;!safe_omove(a) && !oplay_defend_both(b,a,?,c,b,d) 
     3347;!safe_omove(a) && oplay_defend_both(b,a,?,c,b,d)!=WIN 
    33483348 
    33493349>non_oterritory(c); 
    33503350 
     
    34033403... 
    34043404--- 
    34053405 
    3406 ;oplay_defend_both(a,b,c,D,b) && oplay_attack(a,b,a) 
     3406;oplay_defend_both(a,b,c,D,b)==WIN && oplay_attack(a,b,a) 
    34073407 
    34083408>non_oterritory(e); 
    34093409 
  • patterns/endgame.db

    diff -N -r -u -X .ignore gnugo-copy/patterns/endgame.db gnugo/patterns/endgame.db
    old new  
    547547X* 
    548548-- 
    549549 
    550 ;eye(*) && proper_eye(a) && oplay_defend_both(*,a,*,b) 
     550;eye(*) && proper_eye(a) && oplay_defend_both(*,a,*,b)==WIN 
    551551 
    552552 
    553553Pattern EE303 
  • patterns/helpers.c

    diff -N -r -u -X .ignore gnugo-copy/patterns/helpers.c gnugo/patterns/helpers.c
    old new  
    579579      if (TRYMOVE(cpos, other)) { 
    580580        if (board[bpos] == EMPTY 
    581581            || board[epos] == EMPTY 
    582             || !defend_both(bpos, epos)) 
     582            || defend_both(bpos, epos) != WIN) 
    583583          result = 1; 
    584584        popgo(); 
    585585      } 
     
    639639        if (TRYMOVE(cpos, color)) { 
    640640          if (board[bpos] == EMPTY 
    641641              || board[epos] == EMPTY 
    642               || !defend_both(bpos, epos)) 
     642              || defend_both(bpos, epos) != WIN) 
    643643            result = 1; 
    644644          popgo(); 
    645645        } 
     
    663663  ASSERT1(board[worma] == OTHER_COLOR(color) 
    664664          && board[wormb] == OTHER_COLOR(color), move); 
    665665 
    666   if (!defend_both(worma, wormb)) { 
     666  if (defend_both(worma, wormb) != WIN) { 
    667667    if (0) 
    668668      gprintf("%1m: Reject attack_either_move for %1m, %1m (can't defend both)\n", 
    669669              move, worma, wormb); 
     
    677677          gprintf("%1m: Rej. attack_either_move for %1m & %1m (regular attack)\n", 
    678678                  move, worma, wormb); 
    679679      } 
    680       else if (!defend_both(worma, wormb)) 
     680      else if (defend_both(worma, wormb) != WIN) 
    681681        add_either_move(move, ATTACK_STRING, find_origin(worma), 
    682682                        ATTACK_STRING, find_origin(wormb)); 
    683683      else { 
  • patterns/owl_attackpats.db

    diff -N -r -u -X .ignore gnugo-copy/patterns/owl_attackpats.db gnugo/patterns/owl_attackpats.db
    old new  
    733733.... 
    734734---- 
    735735 
    736 ;!xplay_defend_both(*,b,c,a,b) 
     736;xplay_defend_both(*,b,c,a,b)!=WIN 
    737737 
    738738 
    739739Pattern A218 
     
    881881...x 
    882882---- 
    883883 
    884 ;xplay_attack(*,a,C) || !xplay_defend_both(*,a,b,a,C) 
     884;xplay_attack(*,a,C) || xplay_defend_both(*,a,b,a,C)!=WIN 
    885885 
    886886 
    887887Pattern A227 
     
    12801280Y*.. 
    12811281?..? 
    12821282 
    1283 ; oplay_defend_both(*,a,*,b) && !oplay_attack(*,a,b) 
     1283; oplay_defend_both(*,a,*,b)==WIN && !oplay_attack(*,a,b) 
    12841284 
    12851285 
    12861286Pattern A401a 
     
    12981298Y*.. 
    12991299?..? 
    13001300 
    1301 ; oplay_defend_both(*,a,*,b) 
     1301; oplay_defend_both(*,a,*,b)==WIN 
    13021302 
    13031303 
    13041304Pattern A402 
     
    13321332Aad 
    13331333OYX 
    13341334 
    1335 ; oplay_defend_both(*,a,b,c,A,b) && oplay_defend_both(*,b,a,d,*,A) 
     1335; oplay_defend_both(*,a,b,c,A,b)==WIN && oplay_defend_both(*,b,a,d,*,A)==WIN 
    13361336 
    13371337 
    13381338Pattern A403b 
     
    13511351OYX 
    13521352 
    13531353; owl_escape_value(e)>0 
    1354 ; && oplay_defend_both(*,a,b,c,A,b) && oplay_defend_both(*,b,a,d,*,A) 
     1354; && oplay_defend_both(*,a,b,c,A,b)==WIN && oplay_defend_both(*,b,a,d,*,A)==WIN 
    13551355 
    13561356 
    13571357Pattern A404 
     
    16461646.*Y 
    16471647Abc 
    16481648 
    1649 ;owl_escape_value(A)>0 && oplay_defend_both(*,b,*,c) 
     1649;owl_escape_value(A)>0 && oplay_defend_both(*,b,*,c)==WIN 
    16501650 
    16511651 
    16521652Pattern A416 
     
    17051705.*A 
    17061706 
    17071707;(owl_escape_value(A)>0) 
    1708 ; && oplay_defend_both(*,c,*,d) 
     1708; && oplay_defend_both(*,c,*,d)==WIN 
    17091709 
    17101710 
    17111711Pattern A419b 
     
    17201720.*Y 
    17211721 
    17221722;(owl_escape_value(A)>0) 
    1723 ; && oplay_defend_both(*,c,*,d) 
     1723; && oplay_defend_both(*,c,*,d)==WIN 
    17241724 
    17251725 
    17261726Pattern A420 
     
    17381738bd*. 
    17391739xexx 
    17401740 
    1741 ;owl_escape_value(e)>0 && !xplay_defend_both(*,a,b,c,d) 
     1741;owl_escape_value(e)>0 && xplay_defend_both(*,a,b,c,d)!=WIN 
    17421742 
    17431743 
    17441744Pattern A421 
     
    24762476XA* 
    24772477--- 
    24782478 
    2479 ; oplay_defend_both(*,A,b,*) 
     2479; oplay_defend_both(*,A,b,*)==WIN 
    24802480 
    24812481 
    24822482Pattern A619 
     
    29062906 
    29072907;lib(A) == 3 && !obvious_false_xeye(d) 
    29082908;&& oplay_defend(*,b,c,*) && oplay_defend(*,e,c,*) 
    2909 ;&& oplay_defend_both(*,c,b,d,e,b,e) 
     2909;&& oplay_defend_both(*,c,b,d,e,b,e)==WIN 
    29102910 
    29112911 
    29122912######################################################### 
     
    36963696X*? 
    36973697 
    36983698; owl_escape_value(b)>0 
    3699 ; && oplay_defend_both(*,A,b,c,b) 
    3700 ; && oplay_defend_both(*,A,b,b,*) 
     3699; && oplay_defend_both(*,A,b,c,b)==WIN 
     3700; && oplay_defend_both(*,A,b,b,*)==WIN 
    37013701 
    37023702 
    37033703Pattern A1014 
     
    37273727AfgB 
    37283728 
    37293729; (owl_escape_value(A) > 0 || owl_escape_value(B) > 0) 
    3730 ; && oplay_defend_both(*,g,f,e,f,*) 
     3730; && oplay_defend_both(*,g,f,e,f,*)==WIN 
    37313731 
    37323732 
    37333733Pattern A1015a 
     
    37413741AfgB 
    37423742 
    37433743; (owl_escape_value(A) > 0 || owl_escape_value(B) > 0) 
    3744 ; && oplay_defend_both(*,g,f,e,f,*) 
     3744; && oplay_defend_both(*,g,f,e,f,*)==WIN 
    37453745 
    37463746 
    37473747Pattern A1016 
     
    37603760 
    37613761; (owl_escape_value(A) > 0 || owl_escape_value(B) > 0) 
    37623762; && ((x_somewhere(d) && xplay_attack_either(*,c,c,e)) 
    3763 ;     || (!x_somewhere(d) && !xplay_defend_both(*,c,d,c,e))) 
     3763;     || (!x_somewhere(d) && xplay_defend_both(*,c,d,c,e)!=WIN)) 
    37643764 
    37653765 
    37663766Pattern A1016a 
     
    37793779 
    37803780; (owl_escape_value(A) > 0 || owl_escape_value(B) > 0) 
    37813781; && ((x_somewhere(d) && xplay_attack_either(*,c,c,e)) 
    3782 ;     || (!x_somewhere(d) && !xplay_defend_both(*,c,d,c,e))) 
     3782;     || (!x_somewhere(d) && xplay_defend_both(*,c,d,c,e)!=WIN)) 
    37833783 
    37843784 
    37853785Pattern A1017 
     
    40124012?Y? 
    40134013 
    40144014; vital_chain(A) && vital_chain(B) 
    4015 ; && !xplay_defend_both(*,A,B) 
     4015; && xplay_defend_both(*,A,B)!=WIN 
    40164016 
    40174017 
    40184018Pattern A1102 
     
    40274027c*O 
    40284028?Y? 
    40294029 
    4030 ;!xplay_defend_both(*,a,b,a,c) 
     4030;xplay_defend_both(*,a,b,a,c)!=WIN 
    40314031 
    40324032 
    40334033Pattern A1104 
     
    41024102Yb? 
    41034103 
    41044104; vital_chain(a) && vital_chain(b) 
    4105 ; && !xplay_defend_both(*,a,b) 
     4105; && xplay_defend_both(*,a,b)!=WIN 
    41064106 
    41074107 
    41084108Pattern A1107b 
     
    41224122Yc 
    41234123 
    41244124;lib(c)>2 && vital_chain(b) && vital_chain(c) 
    4125 ;&& oplay_attack(*,a,a) && !xplay_defend_both(a,b,c) 
     4125;&& oplay_attack(*,a,a) && xplay_defend_both(a,b,c)!=WIN 
    41264126 
    41274127# nn Removal candidate (3.3.13) 
    41284128#   Success rate in regressions : 0.9 % (23/2562) 
     
    41424142Yc 
    41434143 
    41444144;lib(c)>2 && vital_chain(b) && vital_chain(c) 
    4145 ;&& oplay_attack(*,a,a) && !xplay_defend_both(a,b,c) 
     4145;&& oplay_attack(*,a,a) && xplay_defend_both(a,b,c)!=WIN 
    41464146 
    41474147 
    41484148Pattern A1108 
     
    42824282*bX 
    42834283xCx 
    42844284 
    4285 ;owl_escape_value(C)>0 && owl_goal_dragon(D) && !xplay_defend_both(*,a,b) 
     4285;owl_escape_value(C)>0 && owl_goal_dragon(D) && xplay_defend_both(*,a,b)!=WIN 
    42864286 
    42874287 
    42884288Pattern A1117 
     
    42964296X*b 
    42974297?aY 
    42984298 
    4299 ;!xplay_defend_both(*,a,b) 
     4299;xplay_defend_both(*,a,b)!=WIN 
    43004300 
    43014301 
    43024302Pattern A1117a 
     
    43104310Y*b 
    43114311?aX 
    43124312 
    4313 ;!xplay_defend_both(*,a,b) 
     4313;xplay_defend_both(*,a,b)!=WIN 
    43144314 
    43154315 
    43164316Pattern A1118 
     
    44544454 
    44554455;(owl_escape_value(c) > 0 
    44564456; || owl_escape_value(b) > 0) 
    4457 ;&& oplay_defend_both(*,d,A,*) 
     4457;&& oplay_defend_both(*,d,A,*)==WIN 
    44584458 
    44594459 
    44604460Pattern A1124a 
     
    44764476;(owl_escape_value(d) > 0 
    44774477; || owl_escape_value(b) > 0 
    44784478; || owl_escape_value(c) > 0) 
    4479 ;&& !oplay_defend_both(e,*,A,e) 
     4479;&& oplay_defend_both(e,*,A,e)!=WIN 
    44804480 
    44814481 
    44824482Pattern A1124b 
     
    49874987?a? 
    49884988B*C 
    49894989 
    4990 ;attack(a) && !oplay_attack(*,a) && !oplay_defend_both(*,B,C) 
     4990;attack(a) && !oplay_attack(*,a) && oplay_defend_both(*,B,C)!=WIN 
    49914991 
    49924992 
    49934993######################################################### 
  • patterns/owl_defendpats.db

    diff -N -r -u -X .ignore gnugo-copy/patterns/owl_defendpats.db gnugo/patterns/owl_defendpats.db
    old new  
    42524252A* 
    42534253OB 
    42544254 
    4255 ;vital_chain(A) && vital_chain(B) && !ko(*) && !oplay_defend_both(*,A,B) 
     4255;vital_chain(A) && vital_chain(B) && !ko(*) && oplay_defend_both(*,A,B)!=WIN 
    42564256 
    42574257 
    42584258Pattern D1100b 
     
    42664266A* 
    42674267OB 
    42684268 
    4269 ;vital_chain(A)>1 && vital_chain(B)>1 && !oplay_defend_both(*,A,B) 
     4269;vital_chain(A)>1 && vital_chain(B)>1 && oplay_defend_both(*,A,B)!=WIN 
    42704270 
    42714271 
    42724272Pattern D1101 
     
    44024402eOODf 
    44034403..... 
    44044404 
    4405 ; !oplay_defend_both(*,f,a,B,C) && oplay_attack(*,D) && !safe_xmove(e) 
     4405; oplay_defend_both(*,f,a,B,C)!=WIN && oplay_attack(*,D) && !safe_xmove(e) 
    44064406 
    44074407 
    44084408Pattern D1108b 
     
    44194419.aaXX 
    44204420..... 
    44214421 
    4422 ;owl_goal_dragon(a) && !oplay_defend_both(*,B,C) 
     4422;owl_goal_dragon(a) && oplay_defend_both(*,B,C)!=WIN 
    44234423 
    44244424 
    44254425Pattern D1109 
     
    47324732OAc 
    47334733B*? 
    47344734 
    4735 ;lib(A)==2 && owl_escape_value(c)>0 && !oplay_defend_both(*,A,B) 
     4735;lib(A)==2 && owl_escape_value(c)>0 && oplay_defend_both(*,A,B)!=WIN 
    47364736 
    47374737 
    47384738Pattern D1125 
     
    49574957aO 
    49584958Ob 
    49594959 
    4960 ; (owl_escape_value(*) > 0) && !oplay_defend_both(*,a,b) 
     4960; (owl_escape_value(*) > 0) && oplay_defend_both(*,a,b)!=WIN 
    49614961 
    49624962 
    49634963Pattern D1140 
     
    51215121*.O 
    51225122Boo 
    51235123 
    5124 ; lib(A)==2 && !oplay_defend_both(*,A,B) 
     5124; lib(A)==2 && oplay_defend_both(*,A,B)!=WIN 
    51255125 
    51265126 
    51275127Pattern D1202 
     
    58355835dab. 
    58365836ofoo 
    58375837 
    5838 ;owl_escape_value(f)>0 && !oplay_defend_both(*,a,b,c,d,a,E) 
     5838;owl_escape_value(f)>0 && oplay_defend_both(*,a,b,c,d,a,E)!=WIN 
    58395839 
    58405840 
    58415841Pattern D1331