Skip to content

Commit f35156f

Browse files
authored
Merge pull request #106 from abassibe/hotfix/defend-ourself-better-with-splitopen-three
Try to make AI less stupid when dealing with open split three
2 parents d17b10f + f71a04e commit f35156f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/algorithm/mod.rs

+4
Original file line numberDiff line numberDiff line change
@@ -283,6 +283,10 @@ impl Algorithm {
283283
opponent_captures,
284284
&self.patterns
285285
);
286+
result &= legal_open_cells;
287+
if result.is_any() {
288+
return result;
289+
}
286290
let is_threatened = result.is_any();
287291

288292
// Get the moves that threat `opponent` because those are good move to play.

0 commit comments

Comments
 (0)