As the program's creator I see many, many things that could be improved, which includes the whole program. Most of the cards are hardcoded in Java. While I love Java, it makes it very difficult for the average player to create new cards.
Currently all of the decks are stored in one central file and although individual decks can be imported or exported, it is hard to download multiple decks. (In the future each deck will be stored separately.)
Static effects like Glorious Anthem could be handled better. Activated abilities that tap have to be hacked in order to work correctly, the same goes for planeswalkers. Abilities like Hypnotic Specter have to be hardcoded and it would be nice if those types of abilities were handled by the combat code.
And I would really like to improve the AI and truthfully I'm just going to have to experiment to see what works. In order to use algorithms like alpha-beta you have copy the whole "game state" of Magic which includes all of the end of turn effects and everything else which is very complicated and error prone.
While MTG Forge's user interface isn't perfect, I don't really consider it as a negative. Yes, I wish it looked more like a videogame but truthfully I would prefer working on more cards than improving the user interface. In the code that I have written for MTG Forge 2.0 I have abstracted the user interface so it would be easier for me or some else to update the user interface in the future.
I almost forgot that MTG Forge doesn't support the new combat rules. Maybe I could update MTG Forge to support the new rules but it would be a very big job that doesn't look interesting. The hardest part is updating the AI because everything has to work together perfectly.
The interface is pretty good (though I got one VERY weird bug when the divider between left part and the central part moved so far right I couldn't find it again).
ReplyDeleteOne thing that I'd suggest to do is some way to display counters in play (that, and maybe P/T numbers).
Displaying all of the cards and relevant information like P/T is very hard and is one of the biggest challenges.
ReplyDeleteI have never played MtG or so, but have a thorough background in AI for strategic games (as well as being a dedicated Eye of Judgment player).
ReplyDeleteSome thoughts though...
* Minimax (even in its probabilistic version) is more or less useless here. It works for chess, where you have perfect information and a small number of possible moves, but even in games such as Go (still deterministic) it is doomed to fail.
* TD learning may sound good. However, it was proven to work for Backgammon. Still a game with random elements, but the number of possible moves are very limited, as is the number of types of units (basically 1) and the number of strategies.
* I would recommend to take a look at the work on using Monte Carlo Simulations instead. They have been successfully applied to a number of complex games lately (e.g. Go and Texas Hold'em). Basically what it is is a partial evaluation of the probable search tree to its full depth. You may then update the model of the player deck as more and more of it is revealed through the game (which will give better and better estimates of the best move to make). Moves are chosen through looking at the outcome of different possible moves (where you simulate a single thread of them to the end of the game). This is repeated until you have a number of possible paths per move and then you pick the move with the most positive outcomes.
Well hopefully sometime this week I'll actually getting version 2 with 10 cards working so I can try out min-max, TD learning, or anything else that I can get my hands on.
ReplyDeleteThe monte-carlo algorithm sounds interesting and other people have suggested it. I won't lie and say that I completely understand it but since it works with poker, it might also work with Magic.
ReplyDelete