The issue with a lot of procedurally-generated content is that overall things become same-y. Lots of breadth, little depth. When you have a set number of variable sliders, you don't have to see all the possible worlds to get a sense of how many sliders there are and what their ranges are. The problem only gets worse when moving away from planet/landscape generation (dumb matter) and getting into simulations of history or society.
I'd be really interested in learning about any work in the "interestingness" of procedural content. Is it possible to quantify that sort of emergent complexity that happens in life, or in a work or story with artistic direction that takes on a life of its own? Can a system make a billion compelling and unique stories without solving the issue of Strong AI and just making a superintelligent DM?
I've been working on combating this problem for a few years now. I'm working on a game called Spire (http://hitboxteam.tumblr.com/), which is a mix of Quake and Roguelikes. Every procedural dungeon creator I've seen so far seems to just use pre-made rooms or chunks of rooms, and shuffles them around. It never feels like you're in a new world each time, it just feels like you're in the same world jumbled up.
For the past few years, I've been working on an alternate system, which is to use a goal-oriented design based around the player experience. Each element in the world is placed purposefully, instead of randomly.
I do this by emulating the traditional level design process. I think about every action and intention that goes in creating a level manually, and reduce it to rules for my system. The goal is that the end result feels crafted to guide the player through an experience, rather than to rely on the player to create a experience for themselves.
Examples of the generation behavior:
- Lights are placed in areas to guide the players attention towards the primary path, or treasures and dangers.
- Geometric features are generated based on spatial aesthetic rules (eg. a pleasing amount of symmetry and repetition), as well as gameplay rules (eg. jump distances based on player capabilities, corridor widths based on desired feeling of claustrophobia and combat difficulty).
- Unique color palette for each seed.
- Parameters of room construction have emotional analogues (high density -> claustrophobia; harsh angles -> tension; high symmetry -> order; sweeping vistas -> a moment to take a break; gradually lowering elevation -> an unsettling descent).
- The curve of emotional parameters over time have varying mathematical relationships to other parameters' curves, so every seed feels like there is a unique consistency to it.
Yup, there's a lot of inspiration from that, except the big difference is that this system isn't dynamic. In L4D, the flow would change based on your performance. We want our system to be fully set up from the start, since we're designing it to also be a competitive speedrunning game and need reproducible challenges for everyone.
> It never feels like you're in a new world each time, it just feels like you're in the same world jumbled up.
This was always the feeling I got from games like Daggerfall / Arena Scrolls, which procedurally generate dungeons. Sure, it's technically a different dungeon each time, but in reality it's just the same set of blocks in a different order. Even the mob spawning was based on the block type, so there were few surprises by the end.
Genuine procedurally generated architecture sounds like an awesome challenge - good luck!
The "emotional analogues" sound actually very interesting. I wonder how well that will hold up in practice - it seems like if it were possible to generate a compelling story from variables we'd be able to do it by now - we would be able to consistently put out compelling stories in book form at the very least. Its frequently not the structure or even the overall plot that's the point, but the little details that matter. I've heard it said of movies that the point is not what happens, but how it happens (probably a paraphrase of Roger Ebert). It feels like we're a very long way off from having any machine generate that.
It's certainly an experimental method, so I'm not quite sure how it'll turn out (but it's getting there). I agree about the details - although of course it's important to have a proper structure to the world and narrative, as it gives context to the details. My aim to build a thematic structure, and then to bring it alive through the details. Things like light placement, color, room shape, prop placement, and the overall mood of each section should all work to build an interesting world.
We even have generators that make tiny little stories out of the props - a campfire might have candles and tomes next to it (signs of a ritual), or maybe utensils and dishes (signs of a traveler's meal). Not to mention, the actual gameplay of movement and combat is intended to be its own world of intricacy (the other guys are working on that).
I'm not aiming to explicitly generate narratives of characters and dialogue and words. Rather, the system generates the feeling of narratives. Rising action, conflicts, an interesting flow of emotions, pacing the intensity, etc. The player can fill in the details themselves, as they (not their character) are the protagonist, exploring the world and going on a journey of discovery and mastery.
My thinking is that what it lacks in human touch, it makes up for in mystery. Knowing that it's a unique world that no human has ever set foot upon before is genuinely exciting, and gives a real desire to explore. It's like that feeling you got the first time you played Minecraft, and found some amazing outdoor environments and knew your eyes were the first to see it - but then as you played over and over you saw the patterns and it lost the magic. My goal is to capture the first feeling, and to hide the second effect with not patterns but processes, generating things based on a thematic goal in mind.
Good video games cover the little details through gameplay.
The secret seems to be a mix of a meaningful possibility of failure with 'fair' gameplay. Basicly, I did something stupid, so something happened, which I responded to by doing X which worked or almost worked but failed.
Think dangerous enemies with vary low HP. Or useful but not nessisary NPC's that can die.
Even though I am an advocate of procedural generation, I concur that this is a problem with procedural generation. Even though one algorithm can create millions of permutations, they are all based on the same algorithm (for example, you can vary the size and distance of Worley noise in many ways, but in the end it looks like variations on the same type of noise). For each really new thing you want to produce, you basically have to create a new algorithm to produce it. You can often combine algorithms (say, combining simplex noise with worley noise to produce rocky terrain), but there are only so many interesting ways you can do this, and so many ways you can do it that won't break your game. You can't go wild adjusting the parameters, because 99 percent of the results will look like junk, so you often have to restrict yourself to meaningful subsets of the parameters. Really, it gets pretty close to manual generation at some point, because there is so much human input. Even if you were creating creatures, simply varying the amount of limbs would only produce so many interesting results. Then you have to code separate algorithms to generate eyes, horns, claws, skins, fur, etc -- and then make sure that every generated permutation looks ok.
Edit: to add an additional distinction, I am referring to the generation of visual content here. You can do much more in an emergent (AI-driven, state-based, or chaotic) system and produce surprising results, although you still fall into the dilemma of making sure that all resulting permutations look/function correctly.
If the procedural system were only used as inputs for the initial state and the world were based on a chaotic model then the the starting game state (after some iterations of the world model) could be wildly different for very similar sets of input states.
As you mention, the challenge then becomes to define this sort of chaotic system in such a way that the resulting worlds are not 'nonsense'. Nonsense states could be culled using some fitness functions... sounds like fun :-)
Yes, in my mind there are at least two levels of procedural generation:
1) Generating the layout of the world, placement of entities, and other world states (such as available quests or plot devices).
2) The generation of the actual content itself (NPCs, items, terrain, flora, fauna, etc).
Here, I'm mostly referring to the second type. :)
As far as the first type, there is a LOT more you can do with chaotic systems because they are often AI-driven, and AI-driven things can (potentially) have emergent results (although even an AI-less system, like Conway's game of life, can produce many interesting results).
> Even if you were creating creatures, simply varying the amount of limbs would only produce so many interesting results.
That's exactly what I was thinking when I saw the gazelles, the diplodocus, and that oversized rhinoceros plowing through the purple forest. This is meant to be a one of infinite worlds to explore, and it's just Earth with a few tweaks.
There is nothing same-y about a game where you can't hit a bogeyman with a hammer because he's too fast, but you can kick his ass with cranberry leaves because they're lighter and let you hit faster.
Or, how about the elephants roosting in trees? Or the vampirism that can take over a fortress? Of the possible were-versions of most creatures, with infections, meaning were-swallows, were-frogs, and plague-like invasions of were-spiders?
Dwarf Fortress is built to generate stories, not just monsters and treasure. Every dwarf has likes and dislikes, friendships, pets, belongings, all driven by a fairly simple AI that just takes these preferences into account when deciding whether or not the dwarf is drunk enough to actually do some work, or whether it's so depressed it wants to sit in its room and cry.
I love Dwarf Fortress, and there are some real treasures in the legends of many worlds. But even with all the possibilities, things still get redundant.
Yes, the elephants have taken to their emergent treenests, and that's beautiful. But that's a single bug (feature) that makes us say 'wow' once, after which we've seen it. The possibilities of were-spiders and were-alpacas and reanimated spleens and rains of dwarf blood are just more evidence of those sliders he mentioned. Urist likes tigermen for their stripes, and you can care about it, but Tosid likes cows for their mooing and Tovist prefers to consume purring maggot cheese and at a certain point we've seen it all.
That doesn't mean that Dwarf Fortress is flawed. It's easily the most involved story generator out there, and I'm really glad to live at a time when I get to read about it. But it's still not immune to the issues that the grandparent post raised.
I think the deeper you make it, the less dull it becomes. For example, I realize all the personalities are created by a relatively repetitive grammar, but all the same I think that it adds flavor to the game with all the little quirks.
You could say the same about movies, or literature. There are many repetitive plot choices, tropes, and cliches that are repeated, but little nuances and tweaks here and there make it interesting. In the Sims, if you think about it there's very little variation in the "sliders", pick a job, have nonsensical conversations, woohoo, and then lock everyone in a room and burn them alive, but the game draws you in because there is enough detail that the human mind can draw a narrative. You've seen the landscapes in Minecraft before, but that makes it no less fun to try and dig to the bottom to find the big caves and pits.
So yes, this game will be really dull if they do sort of a breadth first procedural generation. But if they succeed in adding features that make every interaction deep, I think it could be very absorbing. Sure, maybe it's just another variation of CrocodilePerson, but this particular one has a monogomous mate and 4 children, has scars from a fight with a WereRabbit, grew up without a father and sometimes thinks about it, is well known for his tracking abilities, ect.. I think that kind of depth really adds to the experience.
Procedural generation isn't a magic substitute for creativity, it's a tool that requires lots of time and skill. Toady has put the work into it, and it shows.
Dwarf fortress is amazing, the algorithms it must use must be pretty interesting, it would be interesting to piece it out and open source it.
Dwarf fortress also benefits from completely simplified UI. Meaning it can go really deep without worrying about how the rocks are generated. Does magnetite look like pyrite?
It already looks like the scope of No Man's Land has gotten out of hand, maybe it will offer some of the joys of dwarf fortress, but not if it's purely visual.
The author open sourced his last game, Liberal Crime Squad, and its... The work of a madman. IIRC it was one ~40kloc C++ file full of globals and switch statements 6+ levels deep.
I'm sure someone's cleaned it up some now, but it made me wonder if that (unpredictable spaghetti code) is what's required for truly dynamic behavior, the kind that you see in DF and (to a lesser extent) LCS.
This. There's a reason Toady won't open source Dwarf Fortress, and I think it is mainly because he is embarrassed. Toady has a masters in math, not CS.
Yes, Dwarf Fortress is a great example of what can be achieved. To provide some level of distinction, as in my other comment (which I will repeat here for convenience), there are at least two types of generation: generating the world layout and its rules, quests, plot devices, etc, and generating the actual visual content itself.
A totally different type of procedurally-generated content: The physical card game, Dominion.
It is a deck-building game, where players play cards to generate cash to buy cards that go into the deck that they are playing out of (which cycles endlessly). There are 6 boring and fundamental cards that are present in every game, and 10 'kingdom' cards which do interesting and clever things. The 10 kingdom cards that are present in any given game are randomly selected from a set of 25 (around 170 in the expansions), without constraint.
The variations are extreme. Some games have fast drawing and high power curves, some are slow slogs. Some games progress linearly, others build slowly and then explode, and some have stair-shaped power curves because there just aren't any cards at certain price-points. Some games have ways of attack other players. Some games have alternate victory conditions. Some games have multiple paths to victory, other are won by fine-grained control over normally-minor details. In short, the variation is immense and novel experiences have continued, even years after I first started playing.
Can we extrapolate from this? I think so. The two conclusions I would draw are: qualitative variation, and combinatorial traits. Differences in game worlds that are the most interesting may not fit into a slider, and binary or enumerated traits should be considered. Also, the interaction between random variables is what allows for a combinatorial explosion of situations. Stemming from that, it must be the case that multiple variables are meaningful.
I wouldn't say that's procedural content, I would say that it's emergent, or even less impressively, combinatorial.
I would probably call it emergent, in that the designers likely could not test the entire state space of all strategies.
What's impressive, in light of that, is that the game ends up balanced, or at least not fundamentally broken.
To your point though, is that the "content" (cards) introduces mechanics. Most procedural gameplay content doesn't necessarily introduce mechanics. That's why it's easy to feel "boring".
Dominion is balanced largely through the fact that it's symmetrical. No matter how good or bad the kingdom cards, both players are interacting with them in the same way, so, barring things like writing cards that give additional advantage to the first player, it's hard to unbalance it.
If you played "a game like Dominion, except each player had their own independent set of Kingdom cards," it would be big-time not balanced. Like, kingdom sets aren't balanced against each other.
Or perhaps you meant that it's balanced like "a given card tends to be about as good as a given other card." But that's just... not very true. In any Kingdom, there are typically a few must-buys and a few must-not-buys, and there are cards that are almost never good buys and cards that are almost always good buys.
Source: played a few thousand games of Dominion on isotropic back when that was a thing.
Disclaimer: Haven't played Dominion since Hinterlands, so this may not still be accurate.
Oh, you can definitely break the game with the wrong combination of cards in the same game. When we were starting to play, I did just that... I could essentially cycle through my entire deck on a single turn. But here you can always choose which cards to include or exclude, so the overall game is mostly not breakable unless you choose to or luck into it.
While I don't know how readily Dominion conforms to the definition of "procedurally generated", it's interesting to consider how its lessons can be applied to creating unique experiences in repeatedly-played video games. The game is always built on the same foundation of rules (expansions notwithstanding) and every game has the same goal. The difference in each game is the selection of actions available to each player, and the thrill is in attempting to compose a more effective sequence of actions than any other player.
To make this interesting, you need both a very wide pool of potential actions, and the mechanics of each action need to be designed such that feedback loops arise naturally.
Dominion gets off easy here, as the "medium" through which different cards interact is the very simple system of resources: actions, gold, and buys. You can create an enormous selection of cards just by having any given card grant some unique combination of these three resources, and then attempt to balance the card by dialing up or down its cost. It's all very abstract, and that eases the burden on the designers.
But how do you do such a thing in a video game, where actions are usually not abstract, but specific (and as a result, limited in number)? What medium of interaction do you exploit to create the game-breaking feedback loops that are the delight of a Dominion player? Better still, how do you make it so that the interactions between actions are subtle enough that game-breaking strategies are non-obvious, making them a joy to discover?
Off the top of my head, you could start with a game that already has a huge number of actions and create a replayable game mode where you limit the number of available actions. Let's use MMOs as a concrete example. You could just take World of Warcraft, assemble four five-man parties, and then present each party with the same randomly-reduced selection of the game's classes, where each class is limited to only one or two of the three talent trees, the class' usable abilities are pared down, and the talents within each talent tree have been shuffled randomly. Each group then races to assemble a functioning party and see who can down the most bosses in a non-randomized dungeon. And instead of instancing each party, you could just pseudo-instance them: for instance, downing a boss makes that boss unavailable to kill for any other group, rewarding groups who made hasty party selections (but punishing them if their hasty selections slowed their ability to deal with the trash mobs leading up to the boss).
I dunno, I suppose it could be fun with enough effort.
Games are played and any amount of variation that isn't reflected in the game play is quickly filtered out. It isn't a problem of better sliders or more sliders or more realistic ranges of results, it's about the variation in gameplay they produce. The variation in game play is all down to the rules of the system and how the generated world influences that.
That's often a problem with what's sometimes called "constructive" PCG, i.e. manually writing an algorithm that generates variations of content. It's somewhat hard to craft an algorithm that produces a ton of variations that don't look trivially like variations, at least without a lot of careful tweaking.
> I'd be really interested in learning about any work in the "interestingness" of procedural content.
Some of the AI research on PCG goes in that direction. Instead of writing a constructive algorithm, you instead try to specify what content you want in some formal way, and then use a solver to generate content meeting the description (a genetic algorithm, constraint solver, etc.). I.e. start from the goal rather than from the algorithm. It is still difficult to quantify "interesting content" though! Instead it usually needs to be something more specific, like "a level with the following properties: A, B, C". As a shameless plug, two colleagues and I are working on a book that surveys the current research: http://www.pcgbook.com
> Instead of writing a constructive algorithm, you instead try to specify what content you want in some formal way, and then use a solver to generate content meeting the description (a genetic algorithm, constraint solver, etc.)
This is basically the difference between imperative programming and logical programming. Each has advantageous domains (basically which ever way is easier to implement).
> The issue with a lot of procedurally-generated content is that overall things become same-y
Yes. It's easy for a developer to say "trillions of possible combinations" or "every x is unique with a high degree of certainty" but those statements mean very little without seeing the end product.
Creating vast numbers of combinations is completely trivial. E.g. http://jsfiddle.net/JpZ7s/3/ which has ~10 million possible combinations but most are garbage and they're all very samey.
> I'd be really interested in learning about any work in the "interestingness" of procedural content.
Given that selecting "interesting" content from a pool of procedurally generated content is essentially a curation problem, I imagine any such method might also be applied to select potentially interesting content from a pool of human-generated content. As publishing in all media grows easier and easier, curation is going to increase in importance and difficulty.
The No Man's Sky approach to curation is interesting. Bots that roam around and create animated gifs of the universe so the developers can get an at-a-glance cross-section of the universe.
I'd be interested as well in any recent academic research in this. The best I've seen in the wild is Dwarf Fortress, which focuses on building interesting terrain, a rich global history, and interesting local power structures and NPC behavior. I think the ultimate vision for the game is pretty ambitious, and it is slowly getting there, step by step, over the course of years.
Are there "a billion compelling and unique stories" to be told? Perhaps the reason procedural content falls down is because it's so much easier to exhaustively explore than real life. In other words, the novelty of real-world stories is an illusion borne from ignorance/inexperience.
There's a possibility for hybrid approaches, where interesting content is generated procedurally from a corpus of real-world content. For example, lichess generates chess puzzles by [procedurally analyzing real-world games](http://en.lichess.org/blog/U4sjakQAAEAAhH9d/how-training-puz...).
Imagine a tactical warfare game that drew from actual military upsets. I think this would avoid the same-yness problem.
I think of lot of the solution to this problem is going to be make the random creation conditioned on user-provided examples of interesting content. You already see a lot of this happening in the most recent SIGGRAPH papers, such as http://people.cs.umass.edu/~kalo/papers/ShapeSynthesis/
Also there is an absence of beauty in the generative/algorithmic-art scene. Much neato, interesting and colorful - which equates to weak.
It's HARD to make beauty happen algorithmically. Nigh impossible. Frankenstein hard. Also, the intersection between people who code and people who possess a sharp aesthetic sense is minescule.
I'd agree that a lot of coders lack a good sense for design and art (hence the term "programmer art" :D). I'm not a great programmer or artist, but I'm a competent programmer and an "average" artist (at best). This is only because I put so much time into learning art as a kid, and then later doing a lot of design work (mostly related to web design). Additionally I began 3D modeling when I was 13 and most games were still 2D. Anyhow, I think that learning at least a little of both goes a long way in terms of the resulting abilities.
Nonetheless, many of the old demo-scene pieces, which are entirely algorithmic, are occasionally beautiful, I'd argue. (A lot of the newer demos just look like music visualizers though...for dubstep songs :/ )
Ya, I dig alot of that demo scene stuff too. I sniff a natural beauty there somewhere. A natural beauty, a smart shape game, or something. It's what I'm trying to get at with my own work (http://fleen.org). Sorta got a handle. Frankly done with the whole subject presently.
This is true, but I don't think it's a huge obstacle for this game or others like it. Sure, it'll get boring after a while, but what game doesn't? It will likely remain interesting enough to enable dozens of hours of play, if not hundreds, which is more than anyone could ask. Minecraft and Starbound are both procedurally generated, and I got lots of enjoyment out of both before eventually getting bored.
The article mentions of evolution of creatures, which probably involves genetic algorithms. I suspect if you would procedurally generate planets and move the clock forward with genetic algorithms a few million years, both landscape and life would look pretty natural.
But since even our best RNG algorithms eventually converge, the resulting systems would start converging as well. So the issue of same-yness is an inherent issue of CS.
A grammar that generates every possible squence of symbols is boring. What makes it interesting is contraints, that only some subset of all possibilities is generatable. Even the Chomsky hierarchy relates to characterists of the subset defined.
So, you don't need more elements, but more constraints. e.g. a novel is a sequence of a small number of symbols...
This would make each section of a game have a certain style or character. For gameplay elements, figuring out the constraint could be part of the puzzle.
Generating interesting constraints then would be the difficulty...
A long time ago (so forgive me if I can't provide the reference), I read a paper about exploring a parameter space with a focus on "novelty".
The basic idea was that there were two different machine learning algorithms competing against each other. One was searching for configurations in the parameter space (I forget what type of learning algorithm the first one was), and the other was an unsupervised learning algorithm (a Kohonen self-organizing map (SOM), IIRC) which tried to model/predict the output of the model with the parameters chosen by the first one.
So there was a parameter space being explored by some search/learning algorithm. These parameters, when fed into a model (I forget what kind, I think it was a procedural graphics formulas of some kind) produce an output image. This image (not the parameters) is then fed into the SOM (which is doing online learning, so it's training and classifying at the same time), which slowly adapts to what sorts of images it sees, creating a sort of internal model.
The parameter-configurations found by the first algorithm were then scored against how well the SOM could fit/represent the output image of those parameters (IIRC, in the SOM algorithm you can calculate a score for how well it's doing).
So if the first algorithm would find something novel, something unexpected, the SOM would have more trouble fitting that output with its internal model.
From what I remember, it worked relatively well. The output images definitely had more "variety" in them than purely randomly chosen parameter values.
I'm not at all sure how to apply these ideas to planet/ecosystem-generation, though.
Apologies for the super-vague description, but it must have been at least 10 years since I read that paper :)
--
BTW another completely different approach to this problem might be found by using constraint solvers. Check out this site: http://www.gamesbyangelina.org/2013/06/the-saturday-paper-go... (if you're interested in procedural content generation, there's a lot of cool articles there, bringing together scientific research and game development).
I'm not entirely sure why, but from most examples I've seen, generally when you add constraints to a random generator, it tends to produce more variety. Variety is really all about restricting the randomness, anyway. White noise all looks the same, but it's the most random from an entropy point-of-view.
I'd be really interested in learning about any work in the "interestingness" of procedural content. Is it possible to quantify that sort of emergent complexity that happens in life, or in a work or story with artistic direction that takes on a life of its own? Can a system make a billion compelling and unique stories without solving the issue of Strong AI and just making a superintelligent DM?