Switch back to absolute royalty when value = -1
[fairymax.git] / fairymax.c
index 0c1fc81..0eaaf2d 100644 (file)
@@ -373,6 +373,8 @@ InitGame()
  K=BW;W(K--)\r
  {b[K]=oo[K+16]+16;b[K+112]=oo[K];b[K+16]=18;b[K+96]=1; /* initial board setup*/\r
   pl[oo[K+16]+16]++;pl[oo[K]]++;pl[18]++;pl[1]++;\r
+  if(w[oo[K+16]+16] == -1)pl[oo[K+16]+16]=1;\r
+  if(w[oo[K]] == -1)pl[oo[K]]=1;\r
   L=8;W(L--)b[16*L+K+257]=(K-BW/2)*(K-BW/2)+(L-3.5)*(L-3.5); /* center-pts table   */\r
  }                                                   /*(in unused half b[])*/\r
  Side = WHITE; Q=0; O=S;\r
@@ -813,6 +815,7 @@ int main(int argc, char **argv)
                                             break;\r
                                         }\r
                                         pl[BLACK+WHITE-color]++;pl[p+color]++;\r
+                                        if(w[p+color] == -1)pl[p+color]=1; // fake we have one if value = -1, to thwart extinction condition\r
                                         continue;\r
                                 }\r
                         }\r