Thursday, June 08, 2006

Fun with Perlin

It's been rainy for a week. Pardon the lack of energy.

I'm behind: I only heard about Perlin today.

What do I think? It's an idea. It's flawed as stated, but most ideas start flawed, and Perlin didn't state it - Ernest Adams did. So perhaps this should really be called "Adams' Corollary of Perlin's Law".

Perlin's law is good. Adams' corollary is a bit screwed up. My experiences in Nobilis tell me that there is no quicker way to break immersion than to attach numbers or costs to events. What he is essentially proposing is a "mana" to let you cast "spells" which break the game's reality in various fun ways. That's good for a game, but I don't think it's any kind of fundamental breakthrough.

The other problem, besides numbers, is the fact that you're breaking the foundation of a game's immersion with highly unlikely events. I don't think Perlin was talking about summoning chickens. I think he was talking about stumbling across clues to a kidnapping case. At most, he's talking about turning the corner and finding a chicken market.

There are a couple of other ideas which use the same principle without breaking immersion. For example, "for every action there is an equal and opposite reaction" would be fun. The more the player "spends" on unlikely actions, the more the computer can "spend" on unlikely actions. The player doesn't have to know how much he's spending. Of course, in this system, you still have to have a remarkable world engine to allow for such variability without forcing the player to carefully build whatever he's using.

Another idea is the "reality degredation" system, which is really a foundation to the rule itself. "The cost of an event in an interactive story should be directly proportional to its improbability." Well, obviously, once something happens, it's no longer nearly as improbable. Each time it happens, it gets more probable.

So, if a player does an unlikely action, it becomes cheaper for other players/AI to do equally unlikely actions. If the player wants to keep the game a serious real-world cop drama, he can. Or he can turn it into a melodramatic anime.

Also, world control could be given to a player, rather than an author, and the player could determine what is unlikely and what isn't, allowing for different "genres" of story fueled by one game engine...

But all of this is just silly chatter. These are not fundamental laws. They're just corollaries and fun gameplay dynamics.

The fundamental idea that Perlin is suggesting is that "the cost of an event in an interactive story should be directly proportional to its improbability."

I'm going to kick the tires.

I've written dozens of essays about player control, ranging from automatic adaptation to world set-up to game rules and on and on. To me, "cost of an event" isn't some kind of point value, it's the amount of attention a player needs to spend in order to even recognize that event as possible.

For example, a player is walking through a town. There is buried treasure in the town. The player finding that treasure is very unlikely. The longer the player spends in the town, the more people he talks to, and the more places he searches, the higher that probability becomes until, at some point, he finds the treasure.

Now, "that's a linear narrative! It's not generative!"

It could just as easily be applied to generative systems. For example, the player is passing through a city. The probability is very high that the city holds nothing of importance to him.

But every moment he dallies - every moment he talks to civilians ("Pro tip: talk to all townsfolk!") or breaks into someone's house - increases the chance that there's something important here. A "plot" event rather than simply idle conversation and breaking and entering.

Of course, to the player, this unfolds as: "You overhear the two men - they're talking about a pirate ship in the bay!" (Substitute cliche as you feel appropriate.)

To the engine, this is a progression: there's a lowish probability of providing a plot hook. Once you've provided a hook, there's a lowish probability of providing another plot hook based on the first. The longer that the player hangs out in "hooked" regions, the more times we "roll for hook deployment".

To the high-falutin' theory, this is simply "the cost of an event in an interactive story should be directly proportional to its improbability," where "cost" is defined as "player time/attention".

This has a downside of requiring you to write plots, or write something that can write plots. Of course, the downside to Adams' way is that you have to write something which allows the player to try to do anything with enough ease that players won't feel bogged down. Honestly, I don't know which is harder, but I've tried both and neither is easy.

I have some fun new ideas about those requirements, too, but not for this essay.

This essay is just a fun alternative to "cost" meaning "points".


Patrick Dugan said...

Your pointing to player attention/time suggests to me that the real porportional relationship is between local and global agency. Not to flog a dead horse, but it strikes me plain as day. Let me put it this way, its extremely improbable that a given individual wants to spend their leasure time and money in a system so mammoth and cavernous with global agency. Its a hardcore niche that is way more expensive to develop for than there are potential profits.

You said it yourself once, you don't have to provide a sprawling universe of possibility to keep players happy, if you suggest a form of meaningful choice and put it in front of them, they'll want to explore that constrained space. Its still not easy to design interactive storytelling along these lines, but its certianly easier than what you're proposing, and probably more marketable.

But even if you want to build a huge world that can adapt to user choice and sculpt agency dynamically, say as a massively multiplayer platform or a crucial middleware engine (and I'm down with these endeavors, eventually), you still have to expect that user's attentions are going to focus on global and local agency in porportion, so it makes sense to design the system around this property of game-playing cognition.

Come to think of it, a drama game constrained by design and a system that adapts constraints in the manner you describe are really examples of the same principle at different scales, with the latter being able to compose examples of the prior procedurally.

I'm not going to push "conservation of agency" as a law, since like "credibility", agency is extremely difficulty if not impossible to quantify, but its a much more useful design heuristic.

Craig Perko said...

Well, I'm not proposing a game needs to be big. Quite the opposite, as I hope you realize: I'm a big fan of small games.

But I think your "global vs local" thing is an artificial difference, as should be made clear by the fact that not all games have "global". What about games with a "super-local" - where you try to date a particular girl? Or "super-global" - where you try to run a whole kingdom?

The basic idea is one of emotional investment. You are the sort of person who gets more emotionally invested in personal situations, so your games would likely focus on person-to-person agency and choices.

Sure, that means you have to give up some of the more global play styles, but that's a restriction of budget and player attention, nothing more.

Patrick Dugan said...

Fair enough, but the restrictions of player attention are non-trivial, and I think have to do with the interactive equivilant of "suspension of disbelief" that Adams is getting at.

As you suggest, "local" and "global" aren't absolute, they're only words with fuzzy connotations, hence the difficulty in quantifying agency, which is on par with the difficulty of quantifying credibility. Most games, particularly linear action games, don't have a global aspect, you just complete the level and continue. Personally, I think most FPS games have a deficiency in agency that could be salve'd with a bit of global agency.

But whatever, old douchebags aren't going to help interactive drama along much with abstract dictums (or young douchebags for that matter), the proof is in the programming.

On a tangential note, I'd like to hear what you think of Perlin Noise and if you have any unique applications that come to mind.

Craig Perko said...

Perlin noise is just a statistical technique to generate less offensive random numbers. There are a million places it could be useful, but nothing I would consider groundbreaking.

Anyhow, I've been talking about player attention since the blog's beginning: leveraging player attention is critical and can be taught. It's not some kind of wonky math, it's not some complex theory. It's just that players see what you put in front of them, and choose the bits they like the most.

Turning that into a feedback loop is not exactly rocket science.

Patrick Dugan said...

Clint Hocking put it really well in a GDC presentation he did a few years back called "The Interesting Thing About Bishops." He said that players are drawn to complexity in a game like the eye is drawn to light in a painting. I like that.

Craig Perko said...

Sure, but any progression can provide the complexity. Perlin noise is just one method.