
CryEngine 3 gives us a glimpse at the future of gaming [video] - zacharye
http://www.bgr.com/2012/04/16/cryengine-3-gives-us-a-glimpse-at-the-future-of-gaming-video/
======
nihilocrat
Crytek deserves all the praise they get for their hard work in rendering...

...but...

Why are we conditioned to think that "the future of gaming" is solely a
function of a game's audiovisual quality? I would like to see a "future of
gaming" video that shows off highly-interactive (rather than just very pretty)
gameworlds and characters. NPCs that notice you are trying to put a bucket on
their heads, for example.

~~~
Cushman
Visual quality is an "easy" problem. We know exactly how it ought to work (ray
tracing has been photorealistic for some time now), it's just a matter of
tweaking it to run fast enough on the hardware we have. And we're _really
close_ to pulling it off.

AI is, by contrast, a hard problem. We don't have a very good idea at all of
how to exactly simulate a personality, but it's likely to be orders of
magnitude more complex than the most elaborate physical simulation ever
designed. The most intelligent NPC ever developed was really, _really_ stupid.
The appearance of realistic characters in games at all is an elaborate stage
show. You can spend artist time making the show seem convincing in more
circumstances, but evolving it past that _at all_ is one of the hardest
problems in computer science. We're nowhere near realism.

Now, with that said, in the demo they showed off some of their pathfinding and
destructible environment improvements. There are plenty of gamers who care
just as much (or more) about that stuff.

~~~
gavanwoolery
As someone who has worked intensively both in the fields of rendering and AI,
I can say there are easy and hard problems in both. There is much in the way
of AI that we already know, it's just that your average developer actually
knows very little about AI (not trying to be insulting, it's just been true in
my experience) -- and much more so your average company or publisher does not
care to fund AI beyond enemies that can throw themselves into your gun barrel.
Propositional logic, expert systems, backwards chaining, and neural networks
are very powerful tools that we know a lot about, but most games rarely
implement (perhaps trivially at most). We still tend to hand-design/script
quests, when these fields of AI could provide very powerful emergent gameplay.
What it mostly boils down to (for the sake of interesting gameplay) is proper
knowledge-representation (i.e. abstraction) and reasoning (a prolog-like
reasoning system would be a good start). And of course, path-
finding/locomotion is pretty much a given. Interestingly, it is less about
implementing these and more about designing a game that can use them properly
- almost without doubt you need to create a game world that functions on its
own, where every NPC has its own set of motivations, which is a very different
task from creating a game that is limited to what the player does.

Other than that, there are still plenty of hard problems left in rendering,
especially with regards to effective procedural generation (which arguably
falls more under modeling). Our ray tracing is still far from "realistic" -
take a more complex scene than a table with a wine glass, and we can still
usually discern the difference, especially with complex materials and
subsurface scattering (human skin STILL does not look quite right). As it is,
we are only able to calculate light travel by _points_ (we use the term ray
tracing, but typically every ray does a number of steps, unless every model is
mathematically calculated). Light travel should be determined by complex
_volumes_ \-- which is pretty much impossible to simulate on today's hardware
( O(n^6) magnitude at least - growing by volume, travel distance, number of
objects, volume bounces (dear god), and number of pixels calculated ).

~~~
Cushman
I hope I didn't seem to be implying there weren't hard problems in both
fields-- but I do think there's a bigger gap in the current state of the art
than you claim.

The path to realism in graphics is pretty clear because the real-world
behavior of light is well-understood. There may be equations yet to be
perfected, and challenges in efficiently simulating that behavior, but the
direction is never in question; you can always tell if you've made it look
more realistic or less.

By contrast, AI in games has reached a local maxima; the combination of
pathfinding, scripted cues, an elaborate finite state machine, and a few basic
heuristics is capable of simulating human behavior well enough, and with few
enough glitches, that it presents a realistic universe to the player so long
as they don't exceed the scripted bounds. However, if they do exceed those
bounds, the whole thing appears paper-thin. You can extend the bounds with
additional effort in scripting, but not infinitely, and with diminishing
returns-- and doing so gets you no closer to having real AI which would be
able to make those same decisions on its own.

Striking out and attempting to make an intelligent NPC-directed world from
scratch... I'm not saying it's impossible, but I haven't seen anything, from
AAA titles to indie games to tech demos, to imply it's coming soon.

But maybe that's just because I haven't seen the Minecraft of AI-driven
gameplay yet.

~~~
gavanwoolery
Good points :)

I am actually working on such an AI system, believe it or not (As I am sure
quite a few others are)! I don't doubt my algorithms, because I have already
prototyped them and they work (at least well enough to create some
interesting, if flawed gameplay), but I do doubt that I will ever get a game
out that uses them effectively (making even a simple game is incredibly hard,
and I have a bad habit of creating overly-complex stuff).

Your traditional AAA game does, as you mention, basically use finite state
machines to determine enemy behavior (and incredibly simple ones, at that).

Why is a FSM bad?

Because someone MUST explicitly declare every combination of situation, and
the paths between them.

How does my system work? It uses a combination of AI techniques that have been
around a long time (just never used effectively in games).

1) Rules and queries (like prolog), with backwards chaining and propositional
logic (basically a big, graph-based system). How might this work? Let's pose a
few fake rules and a query. A) apples are red B) oranges are orange. C) apples
and oranges are fruit D) red fruit is good...QUERY: are apples good? Using
backwards chaining, this can easily be deduced.

2) Motivators and deterrents. Every NPC has their own set of motivations, as
well as "bad" things they try to avoid. They attempt to maximize their output
towards attaining their goals, prioritized with various points (i.e. get food:
1 point, stay alive: 10,000 points, etc)....the best outcome can be found with
any traditional AI system (like a minmax tree, A*, or whatever is appropriate
for the given case). This is not just about food or living, but can be
emotional concepts like "seek happiness" or concepts that involve the physical
world "find shelter"...

3) Basic AI for sensory and locomotion purposes (line of site, perception,
planning, gathering knowledge, etc.)

4) Abstraction of communication -- not at the syntactical level, and not at
the grammar level, but in its crudest terms ("higher level language")...I call
it caveman-speak but there has to be a better phrase...i.e. "Me Hungry" or
"Why You Steal" -- using sentence fragments, you can construct a variety of
phrases without giving the computer a hard time interpreting it. On the
surface, you can throw in the syntactical sugar to make it sound less crude to
the user, but on the backend writing a full-blown english parser is not a wise
idea.

5) There is more, but I won't type it out here...

In the simplest terms, think of it like an empty stage in a play. There is no
director (Finite State Machine) but there are characters and props, and the
characters have backstories/motivations/genetic makeup/birthrights that
determine what they will do and how they will react to changes in their
environment. When you have rules, motivators, and a knowledge base, you can
let the AI run wild -- and producing new rules grows with linear complexity,
rather than exponential (as with a FSM).

Alternatively, if you even played the Sims, imagine something like that, but
with more comprehensive AI (NPCs seek to maximize their comfort levels (id)
while acting within their restraints (ego/super ego)).

You can track my progress (or lack thereof) at gavanw.com...unfortunately I
work a fulltime job in addition, so development is occasionally slow.

~~~
Cushman
Sounds like the Minecraft of AI-driven gameplay... I would like to subscribe
to your newsletter :)

~~~
gavanwoolery
That makes 2 subscribers ;)

~~~
scorpioxy
Make that 3.

I've always wondered why game rules have to be so rigid (use a state machine)
and always thought it was the technology but what you described makes sense
and makes use of older technology but in new applications.

I just took one AI course while in college but got hooked ever since.

Question: Can you expand on the motivators and deterrents concept?
Specifically, how do you relate something like "getting food" with the world
objects? Assigning points to specific world objects(apple, cow, chicken...)
seems to get us back to a state-machine like game. Humans have experience
(memory and patterns) to guide them, what would the characters have?

~~~
gavanwoolery
Yes, to answer your question, there are many ways to go about implementing it,
but here is how I do it:

In reality, you have one knowledge base, which is simply a set of facts/rules
about the world. For example...

a) berries are fruit b) red fruit is good (+1 score) c) green fruit is bad (-1
score) d) enemies are dangerous e) eating while in danger is bad (-10 score)
f) eating while full is bad (-2 points)

In a finite state machine, you would have to have several combinations of
state (are berries present? are enemies present? are you full? etc). Say (for
argument's sake) you have 5 possible states (binary). In a FSM, this would
have 32 possible permutations of the states, which all must have corresponding
actions associated with them. In a motivation based system, it simply
evaluates each state individually, and adds up the points. It chooses to
pursue the state that gives the most points. So, here, that would be eating
red fruit while enemies are not present.

The way prolog-like systems work, the computer does not have to have ANY idea
what food or hunger or anything like that is -- it can be completely oblivious
to abstract concepts. All it is doing, in essence, is (searching for and)
matching strings. Those strings are the identifiers used for classes (or
instances) of game world objects, NPCs, etc. So if you gave an NPC a motivator
(kill(enemy) = +10 points, Bob = enemy, get_caught_doing(kill) = -100 points),
it will find the best way to kill Bob while avoiding negative consequences.
This is (obviously) metacode, and the actual implementation would require
better organization and more explicit syntax.

Make sense?

~~~
scorpioxy
Yup, makes sense.

I have written exactly 15 lines of prolog but I'm somewhat aware of how they
work. This is great stuff, but as you said the devil is in the details. Please
consider writing up your experiences and sharing it on HN.

~~~
gavanwoolery
Definitely, will do :) It is also encouraging to see that people are
interested in this.

------
ChuckMcM
From PONG to this.

This is perhaps the most accessible way to appreciate just how much the
increase in computation (both 'general purpose' and 'graphical') can be done
on high end hardware these days.

True story, I was a big fan of Empire (ran on terminals, later became known as
Bright's Empire) and when I went to Intel and worked on their 'high end'
graphics chip (82786, used in exactly one video card from Number 9) we thought
maybe someday you would be able to see the units battling cities rather than
have your A turn a city '*' into an 'O'. Little did I know ...

~~~
johnohara
Empire under VMS through DECUS. You stopped me dead in my tracks Chuck. Fond
memories of a heady time when we kids were tasked with building clusters that
ran and ran and ran.

Thank you.

------
Gring
All that great tech, and the end result is just another game where you shoot
people until they're dead, then repeat with more people. Sad, really.

~~~
ChuckMcM
Perhaps, I don't think we've seen a Crysis powered porno, that would be
popular with the kids :-)

I think though that you've may have conflated cause and effect. This sort of
engine isn't really useful in a poker game. Do you remember the beautifully
rendered ChessMaster games on the Amiga? I remember people talking about a
'waste of the graphics' to render chess pieces like that.

I don't think anyone has done a good Myst replacement, this might be good for
that too. An archeology game? possibly. Remember that the 'engine' and the
'game' are two different things. Perhaps the 'safest' thing to imagine is an
FPS, known audience, known play etc etc. Licensing isn't cheap, so if you're
paying for it you don't want to risk that capital on a hyper realistic 'angry
birds' now do you?

Some other thoughts on uses for an engine that does good visuals:

    
    
      1 Mechanical puzzles - build machines to solve puzzles.
      2 Life/City/Population simulators - more fun to watch.
      3 Sex games - mentioned above.
      4 Sports games - haven't had a decent FP kayaking game
      5 Where's Waldo type
    

I'm sure there are others.

~~~
DanBC
Wait, "Where's Waldo" but in 3d, from first person perspective?

    
    
       6 Paparazzi - Start with a lousy camera, have to take
         photos which are graded for score.  Get better lenses
         and access to better hiding places as level ups.
         (This is like a FPS, but with no guns, and with 
         the enemy on a pre-determined route and with strict           
         time limits for each level)
    
       7 Tree in the Field - you start in a field.
         There's a tree.  You wander around.  You can
         climb the tree.  You can run. As you do certain
         things (start running, for example) a timer 
         starts with a recommendation ("Hey! How fast
         can you run round the field? / Climb the tree?
         / etc".  You find a magnifying glass.  You can
         look at bugs.  You can look at stones (and the
         fossils).  You can look at flowers.  The weather
         changes.  The day turns into night.  You find 
         a box.  When you find the box another prompt 
         pops up "Hey! This looks like a good place to
         keep your fossils!".  There is a rich and 
         diverse eco-system, with hooks into information
         about everything ("This is a 'Cowslip' (*Primula 
         veris*)" - but then more links if wanted.  Right 
         down to high level biology concepts.)  You can 
         race bugs against each other.  You find some
         seeds, and a trowel, and some rickety rackety 
         implements.
    
       7a Tree in the Field DLC - A Toolshed for the
          equipment / A mini greenhouse / etc etc.

~~~
Gring
Wow, absolutely love the Paparazzi concept. Have you got more ideas like
these?

~~~
DanBC
I have millions of ideas. Ideas are nothing - delivery is everything. I am
unable to deliver anything.

~~~
follower
Au contraire, you delivered a reply within 2 hours. :)

Perhaps you are too hard on yourself. (Although given you live in the UK
that's likely a pre-requisite for continued residence...)

------
mcmire
I'm fine with more realistic graphics as long as that's not the whole point of
the game (I'm looking at you, Skyrim). What I really have yet to see is AAA
games put effort into making human behavior realistic (in real time, I mean,
not in a cutscene). Like, would it kill ya to actually make the sound match up
with the mouth once in a while?? This is 2012 and still there are only a
handful of games that get even remotely close (Mass Effect, Battlefield 3 and
then of course L.A. Noire and other mocapped games - I'm sure there are
others, I don't play games but they're all the same to some extent). I think
the thing about graphics game companies don't realize is, the better you make
the graphics, the better you have to make everything around it to match --
character behavior, gameplay mechanics, etc. -- because the differences
between the different parts of games are exaggerated -- you leave out some
detail and the magic disappears. Games are just multi-faceted magic tricks,
same for TV shows. The better you can hide the magic -- that's where the
realism lies. Better graphics is just one part of the puzzle.

------
datasage
Even current gaming engines can be used to produce some very amazing visuals,
but games still have to be able to run on hardware that is 5 years old.

Its not very cost effective to create content at a quality that only a small
number of users are going to be able to see.

~~~
beaumartinez
What makes you think CryEngine can't run on older hardware? As a demo, they're
naturally showing the engine at its best.

Games "last" quite a long time, too—by catering first to the high-end and then
downsampling to be able to run on older hardware you make things "future-
proof". When you release your game on iOS in a decade, it'll still look great
:-)

------
kmfrk
The music made me feel like I was watching a modern Fantasia. Fascinating
stuff - although, as people here say, what matters is what it's used for.

------
rollypolly
The video reminds me of demoscene demos.

~~~
pinchyfingers
I probably wouldn't have even watched that video if I hadn't just finished
watching Moleman 2.

------
vibrunazo
It's funny because it has "future of gaming" and "console" in the same
article.

------
troymc
The top paid game apps in the iTunes app store right now are: Draw Something,
Angry Birds Space, Clear Vision, Angry Birds, Fruit Ninja, TETRIS, Bejeweled,
Skylanders Cloud Patrol, and Cut the Rope.

None of those games would be improved by increasing photorealism.

~~~
Marwy
What is your point? These games are for fucking i(phone|pad), so you can play
them in a train while you're traveling to work. This is entirely different
kind of games.

~~~
troymc
Mobile devices are the future, both in terms of total units in use, and total
dollar spent on software. Therefore, the top paid games on the iTunes app
store are a good indicator of where the true "future of gaming" lies.

