Remove under-promotion resign
authorH.G. Muller <h.g.muller@hccnet.nl>
Mon, 11 Feb 2013 21:38:13 +0000 (22:38 +0100)
committerH.G. Muller <h.g.muller@hccnet.nl>
Tue, 12 Feb 2013 09:06:06 +0000 (10:06 +0100)
This was legacy code from micro-Max, and is no longer used, as Fairy-Max
allows the opponent every under-promotion.

fairymax.c

index a78c851..cf62466 100644 (file)
@@ -98,7 +98,6 @@ int MovesLeft;
 int MaxDepth;\r
 int Post;\r
 int Fifty;\r
-int UnderProm;\r
 int GameNr;\r
 int Resign;\r
 int Cambodian;\r
@@ -404,7 +403,7 @@ void InitGame()
   if(w[oo[i]] < 0) k = w[oo[i]];\r
  }\r
  R -= 2*(-k/FAC);\r
- UnderProm = -1; pl[WHITE] = pl[BLACK] = 2*BW; \r
+ pl[WHITE] = pl[BLACK] = 2*BW; \r
  pm = !pl[BLACK+7] && pl[BLACK+9] && pl[WHITE+7] ? 2 : 0; // Unlike white, black has no 'Q', so promote to 9, which he does have.\r
  if(gating) pl[14] = pl[15] = pl[30] = pl[31] = 1, R += 2*(w[9]/FAC + w[10]/FAC);\r
 }\r
@@ -572,12 +571,6 @@ int main(int argc, char **argv)
                         N=0;K=I;\r
                         if (D(Side,-I,I,Q,O,LL|S,3)==I) {\r
                             Side ^= BLACK^WHITE;\r
-                            if(UnderProm>=0 && UnderProm != L)\r
-                            {    printf("tellics I hate under-promotions!\n");\r
-                                 printf("resign { underpromotion } \n");\r
-                                 Computer = EMPTY;\r
-                                 continue;\r
-                            } else UnderProm = -1;\r
                             m = GetTickCount() - Ticks;\r
                             printf("# times @ %u: real=%d cpu=%1.0f\n", m + Ticks, m,\r
                                       (CPUtime() - cpuT)/CLOCKS_PER_SEC);\r