Skip to content

Commit

Permalink
perfect: Fix Perfect AI cannot win quickly
Browse files Browse the repository at this point in the history
Change-Id: I2e730a63942ef0c5c7bca50259d539ecdee6ce44
  • Loading branch information
calcitem committed Dec 26, 2023
1 parent 2bca07d commit 1cb22ae
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/perfect/perfect_wrappers.h
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ struct gui_eval_elem2
else if (key1 < 0)
return key2 == o.key2 ? 0 : (key2 < o.key2 ? -1 : 1);
else if (key1 > 0)
return key2 == o.key2 ? 0 : (key2 < o.key2 ? -1 : 1);
return key2 == o.key2 ? 0 : (key2 > o.key2 ? -1 : 1);
else
return 0;
} else {
Expand All @@ -195,6 +195,7 @@ struct gui_eval_elem2
else if (a1.key1 < 0)
return a1.key2 == a2.key2 ? 0 : (a1.key2 < a2.key2 ? -1 : 1);
else if (a1.key1 > 0)
// TODO: Right?
return a2.key2 == a1.key2 ? 0 : (a2.key2 < a1.key2 ? -1 : 1);
else
return 0;
Expand Down

0 comments on commit 1cb22ae

Please sign in to comment.