Last active
March 26, 2017 13:25
-
-
Save deque-blog/c18ad68017c197e4358eb9482499514c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn- eval-next-score-of | |
"Perform a last minimax step on the next scores following the turn | |
* Allows to see one level deeper for simple scoring strategies | |
* While being fast (the transition does not need to be followed)" | |
[ai {:keys [scores] :as turn} players] | |
(minimax/minimax-step ai turn | |
(fn [_ transition] | |
(let [scores (scores/update-scores scores transition)] | |
(apply + (map #(get scores %) players))) | |
))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment