implements simple minimax ai player. still very slow.