Initially I decided that MTG Forge version 2 would NOT be able to play itself, but then I changed my mind. I happened to read an article describing how a program named TD-Gammon learned to play backgammon by playing itself. I found this very, very interesting and you can read it for yourself here.
TD stands for “Temporal Difference” which is an algorithm that actually learns. Many times the AI for games like chess, checkers, and Magic’s Xbox game use an algorithm called “min-max” or “minimax” which looks ahead and tries to figure out the best move. The min-max algorithm doesn’t learn, it is “static”, but the temporal difference algorithm actually learns, which is amazing.
The good news is that some very smart people have put together a nice Java library that implements temporal difference and since these people are so smart they also have libraries that work with other programming languages like C, C++, and Python. The website is here. I don’t understand all of the math behind temporal difference but hopefully I should be able to use it in MTG Forge 2.0. (I currently have 0 cards working for it and my goal is a measly 10 or 20.)
This quote comes to mind and I hope it makes sense, “I see further because I stand on the shoulders of giants” which means that I plan to use other people’s code in order to improve MTG Forge’s AI.