The rapid progress in deep reinforcement learning (RL) over the last few years holds the promise of fixing the shortcomings of computer opponents in video games and of unlocking entirely new regions in game design space. However, the exorbitant engineering effort and hardware investments required to train neural networks that master complex real-time strategy games might lead to the impression that the commercial viability of deep RL is still far in the future. To the contrary, I will argue in Part 1 of this essay that these techniques are imminently practical and may see widespread adoption within the next decade. Part 2 presents a case study in which I use deep RL to improve the design of a real-time strategy game. Finally, in Part 3, I speculate about the many ways in which machine learning will impact video games in the years to come.Continue reading
The capabilities of game-playing AIs have grown rapidly over the last few years. This trend has culminated in the defeat of top human players in the complex real-time strategy (RTS) games of DoTA 2  and StarCraft II  in 2019. Alas, the exorbitant engineering and compute resources employed by these projects has made their replication difficult. As a result, the application of deep reinforcement learning methods to RTS games has remained disappointingly rare. In an attempt to remedy this sad state of affairs, this article demonstrates how you can use deep reinforcement learning to train your very own sociopaths for a nontrivial RTS game within hours on a single GPU. We achieve this by employing an array of techniques that includes a novel form of automatic domain randomization, curricula, canonicalization of spatial features, an omniscient value function, and a network architecture designed to encode task-specific invariants.Continue reading
Ever since I began working on CodeCraft, I wanted to implement a multiplayer mode which would allow players anywhere in the world to pit their AIs against each other. With most other parts of CodeCraft taking shape, I now spent some time working on that aspect of the game. In this post I want to talk about some of the design challenges and outline my plans for multiplayer. Continue reading
CodeCraft now has a twitter account which I will use for frequent updates about new features. I think Twitter is a nice fit for this, and I should also be able to integrate the feed into the website which is neat. I will still use this blog whenever I have more substantial content.
Getting this to work was surprisingly easy, mad props to everyone behind Scala.js for creating such an awesome piece of technology.
More than a hundred people clicked through to the CodeCraft tutorial over the last few days, which is a nice start. I don’t have any other statistics though, so I have very little visibility into how many of those are actually using CodeCraft, or don’t know/like Scala/Java, or think the idea or implementation suck, or don’t have the time/patience to perform all of the setup and go thought the tutorial. If you have any thoughts on CodeCraft, do share them, it really helps me figure what I need to be working on!
Today, I am releasing the alpha version of the real-time strategy programming game CodeCraft. (previously called CodingGame, but I want to avoid confusion with codinggame.com). This is the first public release, so there will be various bugs, rough edges and missing features, but all the core functionality is there now. There will be regular releases from now on to incorporate your feedback.
I put up a tutorial and overview of the API on github, so if you want to give it a try go on and head over there. Currently, CodeCraft can be used with both Scala and Java. Happy coding!