Sunday, July 11, 2021

AI and Game Editors

 For my Masters thesis I am working on a study with Dr. Yong Gao at UBC Okanagan on using Artificial Intelligence to aid in the creation of game levels. This will have you playing a simple platforming game and creating levels for that game using our editor. If you think this sounds interesting you can find more information on (redirects to the study site) between July 11th and July 31st.

Now that I have plugged my study, and humbly request that you share the link with your friends, I will spend a bit of time explaining what I am researching and how I got to the point I am currently at. I was originally looking at machine learning techniques and applying it to procedural content generation, which is known as PCGML (Procedural Content Generation via Machine Learning). Procedural content generation is the technique used to create new assets through computer algorithms and has been seen in the genre known as rogue-likes but it's also been used in creation of textures from art packages as well as music and sound effects amongst other things.

The idea I had when I first started this research was that if you trained a neural network with good levels then you may be able to get the AI to produce similar looking levels from what it has learned about what good levels are like. There have been several different types of neural networks used to create levels with the ones I developed being LSTMs and autoencoders. The one thing I noticed while experimenting with these was that they do produce interesting game levels but they tend to be still obviously computer generated. My thoughts were that it would be interesting if you could have a human and the AI working together.

Now knowing I was probably not the first person to come to this conclusion, I started looking into this idea and found that there were several editors known as mixed initiative Co-creative editors used for predominantly strategy and dungeon romps but a few other genres were present. The two main forms of editors where ones where the AI would make suggestions as the user edited and ones where the user in the AI took turns editing. I preferred the idea of suggestions so the editor I developed was set up so that as the user made changes to the map the AI would use it's techniques to make suggestions for how to improve the map well procedurally generating areas of the map that the user hasn't had yet to edit. One thing I did notice about most of these generators their editors is that the ones that did use machine learning approaches tended to use evolutionary genetic algorithms. This led to the basic idea for this study which was to see how using deep learning techniques compared to using genetic algorithms for editing and if one of the two techniques produced better overall results.

The game that I was focusing my research on was it very popular platform in game held by a very litigious company so knowing that that I would be having people edit levels for the game would potentially have IP issues. I looked into a clone of this game and found the open source SuperTux game. Unfortunately it was not as easy to compile and get running as I would have liked and had way too many features in there that my editor would not be able to support so I decided to clone the clone creating a simplified version of Super Tux which I called LiteTux. Well this is not the greatest game I have created and is probably a little bit too simplified I think that with a little bit more Polish (such as finishing the animation which I simply did not have time to complete) it would be pretty good game in fact may end becoming a much better game as once the study is completed I plan on not only releasing the game but the editor as open source with the hope that my research on mixed initiative editing will be useful to other people and by other people I mean general programmers not just academia.

Even if the study ends up the flaming disaster I fear it may become due to lack of enough participants finishing the study, I am going to continue to work on both the LiteTux game and the editor even if it is on my own I may apply some of the techniques that I've learned towards other genres. One of the things I am thinking about is my old Mr. Holman game and using at least some of the utilities in the editor to make creating levels for that game more enjoyable. Mr. Holman is on my list of projects that I do want to complete so don't be surprised if next year you see a new version of Mr. Holman with the interactive editor that makes suggestions for you and lets you share levels with your friends.

I hope you enjoyed this brief overview of my research and will support the study or at least tell other people that you think may be interested in the study about it. I will keep you updated on what's happening in future posts but no matter what the results the study the game and editor will live on in one form or another.


No comments:

Post a Comment