[英]C# Algorithmic Game Theory API
I recently came accross Gambit - http://www.gambit-project.org/doc/index.html - a C++ algorithmic game theory API. 我最近来到了Gambit - http://www.gambit-project.org/doc/index.html--一个C ++算法游戏理论API。
Is anyone aware of a .NET Game Theory Library? 有人知道.NET游戏理论库吗?
I don't know of any existing library. 我不知道任何现有的图书馆。
The minimax algorithm is pretty easy to implement if you are doing a 2 player game. 如果你正在进行2人游戏,那么minimax算法很容易实现。 The following pseudocode is plagiarised from the wiki page :
以下伪代码是从Wiki页面中抄袭的:
function integer minimax(node, depth)
if node is a terminal node or depth <= 0:
return the heuristic value of node
α = -∞
for child in node: # evaluation is identical for both players
α = max(α, -minimax(child, depth-1))
return α
If you are doing more than 2 players, then there is Sturtevant and Korf's MaxN algorithm . 如果你做的超过2个玩家,那么就有Sturtevant和Korf的MaxN算法 。
I've implemented these before, and they are pretty easy. 我之前已经实现了这些,它们非常简单。 It should be very straightforward in .Net.
它应该在.Net中非常简单。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.