back to article Doom and Super Mario could be a lot tougher now AI is building levels

AI researchers do love their games and two papers have shown that they can use general adversarial networks (GANs) to make old favorites a lot more interesting. In two separate papers, AI researchers built general adversarial networks to construct new video game levels for Super Mario Bros, a popular platform game controlling …

  1. Anonymous Coward
    Anonymous Coward

    Bubble Bobble had AI, the more sweets you got the harder it became. I speak as someone that spent many a 10p coin trying to beat it (I did it in the end btw, tib street arcade Manchester circa 1988)

    1. Friendly Neighbourhood Coder Dan

      Selfie or it never happened!

      1. asdf

        Funny don't remember why we didn't take selfies with polaroids. Probably the flash in your face.

        1. Terry 6 Silver badge

          Polaroids were expensive. You used them sparingly. And you had to have the camere with you. Digital photos are free and we carry the camera in our phones.

          1. asdf

            That's right and now I remember the cameras were fairly heavy and bulky compared to say an iPhone as well. Awkward to take a selfie for sure. Most things in the late 1970s to even late 1980s were heavier, as plastic and lighter wasn't used for everything like today.

            1. Charles 9

              It was entirely possible to take a selfie then. You just did it "the old-fashioned way" using a mirror. Thing was, the cameras were pretty bulky unless you used something like a 110 film so it took up a lot of the picture space. And the shutter timer was pretty much reserved for 35mm cameras which at the time (until around the 90's) were at least semi-professional equipment.

    2. Charles 9

      Compile's Zanac for the NES/FamiCom had adaptable difficulty as well IIRC (all there in the manual). The more aggressively you shot, the trickier the enemy patterns became. Not AI, of course, just an algorithmic adjustment to enemy generation.

  2. Anonymous Coward
    Anonymous Coward

    "Imagine the frustration of playing a game where the difficulty can constantly change"

    AKA Life

    1. ecofeco Silver badge

      Re: "Imagine the frustration of playing a game where the difficulty can constantly change"

      Oh hell. Beat me to it.

    2. Pascal Monett Silver badge

      Re: "Imagine the frustration of playing a game where the difficulty can constantly change"

      I have no problem with that, nor has anyone that played or still plays Left 4 Dead 2, I'd wager.

      Great game, good balance between ammo and enemies, and big rush when the next wave arrives a the most inopportune moment.

    3. Voland's right hand Silver badge

      Re: "Imagine the frustration of playing a game where the difficulty can constantly change"

      Nethack comes to mind. It is entertaining to observe modern games trying to match 30+ years old ideas and technology.

  3. Mephistro
    Meh

    Is this good or bad?

    Generating levels is an expensive task in man hours, but it also allows game makers to gain strong insights in how to improve games or how to create new and better ones. Everything including the programming tools, the game 'philosophy', game mechanics and playability benefits from to the experience gained by creating game levels.

    I fear that using AI to perform this task will in the long term lower the quality of new games, independently of how good the AI-created levels are.

    1. ArrZarr Silver badge
      Boffin

      Re: Is this good or bad?

      The term in the industry is "procedural generation" and has been around for quite a few years. Notably in Minecraft and then being extended to other open world games like Terraria. This peaked with No Man's Sky (I believe) and everybody knows how well that turned out.

      An example of procedural generation used well is the Binding of Isaac where the rooms and items are human constructed but the overall layout of the floor is procedurally generated. The rest of the roguelike

      As with all things, elements are good - increased replayability for roguelikes is a prime example but an overreliance tends to make everything incredibly bland - refer to the No Man's Sky example above.

      1. Mephistro

        Re: Is this good or bad?

        The term in the industry is "procedural generation and has been around for quite a few years."

        Hmmm... yes and no. Procedural generation usually works well for simple-ish games, like platformers and bi-dimensional games, as in "The Binding of Isaac" (a game to which I've been irrevocably addicted for several years). Even for these examples, the procedure has to be developed by a human who decides on the rules for the procedural generation, i.e. the programmers create the heuristics, which implies lots of thinking and effort if they want to make a good game.

        Now, an AI creating the levels is a different beast altogether, in the sense that once the neural network has been created, it's very difficult to know what it's doing or why it's doing it, and hence it's almost impossible to tweak, debug or improve.

        Frankly, I don't know for sure whether NMS's levels were generated using AI -as the company marketing department stated often- or are just procedurally generated, but I totally agree with you that the results were bland and boring. Ditto about Mass Effect: Andromeda and other similar games like Star Citizen.

    2. deive

      Re: Is this good or bad?

      Like with all things machine learning, it is neither good nor bad, but how you use it.

      Can imagine it generating a load of different levels then an actual level designer can pick the best and tweak for example - saving lots of time on the boring parts whilst getting properly designed levels. Or for replacing procedurally generated levels.

      1. DiViDeD

        Re: an actual level designer can pick the best and tweak

        .. except that, in the current "that'll do" culture of corporate fame design, it's more likely the AI will generate a load of levels, some beancounter will say "well, that was cheap, we can make 10 new games a week this way." and it'll be shipped out to sit on a shelf with a million other bland and unimaginative derivatives.

    3. asdf

      Re: Is this good or bad?

      Well if the computer makes it as hard as that as a few of the end levels in Super Mario 3 (thinking it was the airships) I would just use the in game item to skip them too.

  4. GrumpyOldBloke

    Queue the lawsuits from Nintendo.

    1. Charles 9

      As I recall, Nintendo isn't too harsh on custom level hacks. Heck, they enable it with Super Mario Maker.

      What I'd be curious to see is this kind of system given one of those crazy level hacks as a base (the ones that can only be passed by knowing quirks of the game engine).

  5. Chozo
    Devil

    Challenge Accepted

    Bring it on my silicon friend, gonna whoop your ass so bad you'll wish you were still a Tamagotchi!

  6. pAnoNymous

    Random Levels?

    Seems like computer games have had random levels for a long time but if it helps better train our eventual overloads it's worth it I guess.

  7. Lee D Silver badge

    Look...

    AI doesn't exist.

    It can't even PLAY Mario, let alone design a level (go look up MarI/O - it trains on one level and then can only complete that level, maybe, if nothing changes at all. Further training on more levels means it becomes crap in general).

    AI is currently just "brute force and heuristics". We don't have anything capable of playing these games, except literally "try every combination quickly and choose the one that gives the biggest score". That's not AI. And it doesn't work well (e.g. getting stuck in loops, being untrainable for a general level rather than specific ones, etc.). And that's the easy bit (or we'd all be level designers... have you seen the messes that the Mario level creator game makes when people are let loose on it?).

    We all know this, because we all know that the computer players are either hand-fed WAY more information than is available to the human (i.e. exact co-ordinates and angles that will head-shot you), and/or they are pathetically easy to "distract", "confuse" or just plain lure into obvious traps (which is why in a game one hero wades through thousands of AI opponents).

    AI - even in modern computer games with studios pumping millions into their development - can just about work out how to play a nice game against humans given every advantage in the world (in terms of processing, latency, data available, pre-fab calculations rather than training themselves etc.). They are either "too perfect" because they are literally instructed to always get the perfect shot, or useless/unconvincing because they have to be instructed to pretend they don't know how to take the perfect shot (e.g. "take the perfect shot, add a random failure element to simulate a human").

    And almost all AI is just human-controlled heuristics. Because genetic algorithms, deep learning, etc. always end up in a single good result for a small dataset and then fail miserably as the dataset scales or they fall out of their training comfort zone.

    1. deive
      Thumb Up

      The problem is everyone calling it A.I. this is not A.I. it is machine learning. M.L. is required for an A.I. but it is only a small part of what would be required before we get anywhere near an A.I.

    2. Peter2 Silver badge

      For first person shooters, yes. For strategy games it gets a bit more interesting.

      I've written strategy game AI's on an existing game from around 2000ish. The game originally expected a few hundred megahertz processor and recommended a couple of hundred megabytes of memory. This did limit what the original design team could acheive without grinding the computer to a halt.

      Typically in strategy games the AI cheats massively as a crutch. Over a fairly long time at a low level along with a bunch of testers we slowly tuned the AI to recognise the fighting and strategic value of specific units and buildings and eliminated the various ways in which it cheated. The end result was (somewhat unexpectedly) that the AI was a lot more challanging, happily avoiding masses of defensive buildings and armies and striking at either undefended things, or striking at things that it could destroy using the forces available to it. And break and run should that change.

      The overall performance was incredibly scary to play against and it could take out the best human players at that game because it never made mistakes and would be controlling multiple operations similtaniously where a human player could only manage one and it's keep nipping away, never making a mistake until the human ended up bled dry by a thousand cuts.

      It also passed a turing test, renamed from "Computer: Hard" to "[clan]RandomName" people happily beleived that they were playing humans in multiplayer games even with a toal lack of chat from it.

      Yet... it was as intelligent as an excel macro. It just split the map up into cells and followed carefully programmed parameters for what units were worth plus basically a bit of code saying "if $AiUnitAttackForcePower > $HumanUnitAttackForcePower within $AttackRange in this cell or next 2 surronding cells then attack else retreat" Hence, overwhealming force marched in, and the moment the AI spotted them it'd be on the way out while scouting elseware to find another weak spot to kill.

      Properly speaking, I think that it was more an algorithm than an intelligence.

      From what I can see, we are no closer to true artifical intelligence than we were in the 1980's. Sure, we can produce a huge stack of code that can perform specific tasks better than a human, but is that intelligence or just more complex algorithms driven by more processing resources being available.

      And at what point does a complex algorithm become an intelligence, if at all?

      1. Lee D Silver badge

        Was the AI subject to the same interface as the human?

        Did the AI discover the value of units or was it explicitly told?

        Did the AI discover the statistic involved or did it know that it could reach X squares at a time, and do 56 damage at that range?

        It's EASY to make an AI that wins. It's EASY to make a bad AI. It's very hard to make an AI that wins enough to be fun, without "cheating" (as you describe) or outperforming the player in every single respect. An AI should LITERALLY have the same mouse-input as a player can give, through the same programming interface as the player's mouse. That's it. That's all they get. I'll let you "read" statistics directly rather than interpret the screen but any AI has inherent advantages that allow it to submit 200 orders across the map where a player can barely click on a menu, or scroll to the region that's alerting.

        What you describe are heuristics. Rule-based. You have told it where, when, what, how many, and under what conditions to do something. A human told it what to do, what the rules of the game are and PRECISELY whether or not that shot would kill the unit involved. It didn't learn (machine learning), infer (intelligence) or discover for itself.

        1. Peter2 Silver badge

          The AI didn't have the same interface, however it only had the same information as the player. It knew the number of hitpoints that it's units had, and basically just did a sum of the total of those in it's group and the enemy hitpoints in a given set of grids to decide if it was engaging or not. The same information was available to the human player.

          This is not a good way of doing things as it makes the implicit assumption that the firepower of a unit is equal to it's hitpoints, which wasn't actually correct. It was however "good enough" The AI frankly sucked at tactical engagement, but won at a strategic level by only engaging when it made sense to do so and always getting that right.

          What you describe are heuristics. Rule-based. You have told it where, when, what, how many, and under what conditions to do something.

          Strictly rule based, but those rules were in fact not a tenth as complex as your describing. Yet it still won disturbingly often.

          It didn't know what the rules of the game were, if it could kill the units or anything else (it wasn't capable of one shotting anything) Frankly it just dumped a mass of units into an cell arbitarily drawn by the AI and left them there until the either it's total pool of hitpoints was less than the oppositions, in which case it moved it's units out, or if the opposition ran out of hitpoints in that cell. It was in short depressingly stupid, but it still worked.

          It certainly didn't learn, infer or discover anything and I agree it wasn't intelligent. But most AI's only fuction within the constraints of their programming; are they really intelligent if they are just following an algorithm?

      2. davidp231

        "Typically in strategy games the AI cheats massively as a crutch"

        Prime example is a skirmish on the original C&C Red Alert - you've barely built your barracks and trained some fodder before you have an army of tanks and troops on your MCV's doorstep. No matter how quick you try and build.

        1. Peter2 Silver badge

          Typically, AI designers cheat by:-

          1) Shorter build times

          2) Allowing the AI to ignore the tech tree and build things without regard to the prerequisites

          3) Giving the AI discounts on purchase prices.

          4) Letting the AI see everything

          I think the C&C RA AI does 1, 3 & 4. It's simpler than doing anything more comprehensive, but to be fair remember the AI is the last thing developed for a game and is probably thrown together in a few weeks. We started a decade down the line with the benefit of knowing how best to play the game in terms of strategies and then spent literially years on and off fine tuning our scripts for the AI. (and mostly off, given it was done an hour here and there when people could be assed in spare time in an evening)

  8. Terry 6 Silver badge

    Is this to make the games more frustrating?

    I'm not a gamer. Because I could never be bothered to get past one of those stages where you have to keep trying random things until something gets you through, (Usually early on in the game). So do gamers actually enjoy that kind of frustration?

    Is that what I'm missing?

  9. Dan 55 Silver badge

    Not one mention of MarI/O AI?

    Link here.

    And procedurally generated levels have been in games for ages. Nobody remember The Sentinel?

    1. Pascal Monett Silver badge

      Re: the Sentinel

      I still have the CD. Great game.

      Shame it became incompatible with successive Windows versions. Never tried it on Win7. Maybe I shall.

      1. WallMeerkat

        Re: the Sentinel

        Was it not a DOS game? If so, should run on Dosbox?

      2. The Mighty Biff

        Re: the Sentinel

        The CD?? I have the 5.25 inch floppy somewhere. It was an awesome game :)

  10. BinkyTheMagicPaperclip Silver badge

    You could use AI design but it wouldn't be the same game

    There are some games that work well with 'random' design (in reality constraints are always applied). Part of the fun of roguelikes is running into extremely fortuitous or horrific situations (If I remember correctly it's technically possible to encounter about the fifth hardest monster on the second level of Nethack, but the probability is rather low).

    However, the reason most platformers work is because they're predictable. People can develop strategies to pass them, run speed running contests, and play test them until they're perfect.

    It's easy to make difficult games, but hard to tweak the balance between hard enough to be a challenge, but easy enough not to frustrate. Games already bend the rules to ensure they are fun, their main point (there's more than one game where the chance to be hit when at 1% health is much lower than at 20% health.. Just squeaking through to the end of a level is fun)

  11. juice

    Garbage in, garbage out

    I have to ask: how does the "discriminator" decide what counts as a good level? It's not exactly a "true/false" question, and the most important factor - "fun" - is the hardest to quantify.

    Most likely, you'll just end up with levels which score highly by the computer but is completely unfun to play...

  12. Anonymous Noel Coward
    Boffin

    "What's it doing?"

    "It's Learning."

  13. Anonymous Coward
    Anonymous Coward

    Sounds interesting but...

    If it makes an impossible level it will be very frustrating.

    One of the reasons kids liked Mario etc is that they could muscle memory the levels and show off to friends, this would not be possible unless only the base level is procedurally generated for the developer and maintained as a finished article on deployment.

    Games with lots of scripted storyline could also simply become differently challenging to design particularly if fixed elements are required.

    Why not extend the design to the equipment/guns/clothes etc?

    </END_THOUGHT_DOWNLOAD>

  14. Anonymous Coward
    Trollface

    MY AI should enjoy the challenge

    it goes at it while I'm asleep

  15. The Indomitable Gall

    Hmmm... while I like the concept, I'm a little bit unsure about how the data is encoded. My understanding is that classic Mario games were all designed as repeated "chunks" of tiles, hence patterns of blocks that recur throughout the game.

    This is non-trivial -- part of the learning curve of Mario is the fact that you become more fluent/competent in these patterns as you play, and then adapt your strategy based on the different obstacles before and after.

    A machine learning algorithm based on the individual tiles may spot the repeating patterns and implement them incidentally, but not necessarily... in which case the levels would not be "Mario" levels.

    If you're looking at generating levels at the tile level, pretty much any platformer of a similar vintage would be more appropriate, as most other games had fully hand-crafted levels. But then again, 2D Mario games were always huge because of how quickly the levels could be generated, and other platformers don't provide the same size of training set as Mario.

  16. Anonymous Coward
    Anonymous Coward

    I have two favorite games

    One is a flight simulator with medium realistic settings, easy landings, daylight, no bad weather etc.

    The other one is an old first person shooting game with special keys for making me invulnerable and giving unlimited ammo. I play them whenever I feel like in a need to have some fun.

    Now, you brilliant AI boffins, tell me what your AI wizards can do to my games.

    I want to have fun playing games but not the game to have fun at my expense.

  17. Anonymous Coward
    Anonymous Coward

    Try SuperTux instead of Super Mario

    It comes with a level editor so you can use your Natural Intelligence.

  18. King Jack
    Thumb Down

    I'd not buy

    I used to play games (single player) because it was a challenge that you could learn to beat. If it was too easy you chose a harder setting. You knew it was still beatable. That was the challenge. If the game kept adapting to your game play (like some chess games) you would lose all the time and that is not fun. Losing to a real person can be fun (if they are in the room) as you can interact. Losing to a machine would just mean that I'll play once then move on to something more fun. Or just leave the game on the shelf. Save the fancy brain work to making a good campaign and leave AI for piloting airplanes.

    1. Charles 9

      Re: I'd not buy

      "That was the challenge. If the game kept adapting to your game play (like some chess games) you would lose all the time and that is not fun."

      Not necessarily. Hardcore gamers who would find your kind of hard too easy might enjoy something like this, as now they adapt their play to outwit the generator. That's why people still play games like the Left 4 Dead duology (which has adaptable difficulty, if you'll recall).

  19. DanieleLoiacono

    Hi, I am one of the author of the paper on DOOM level generator. If you want to find out more on the project, we released a playable level (https://github.com/DanieleLoiacono/DoomGAN) and here is a video about the work: https://www.youtube.com/watch?v=K32FZ-tjQP4

POST COMMENT House rules

Not a member of The Register? Create a new account here.

  • Enter your comment

  • Add an icon

Anonymous cowards cannot choose their icon

Other stories you might like