Live data from Hacker News

The Low-Tech AI of Elden Ring

nega.tv

71–80 of 101 posts

Re: The Low-Tech AI of Elden Ring

#71

And for Dark Souls AI: https://www.youtube.com/watch?v=PrHKzKQdZxY&t=1366s

The video is actually describing the exact same thing as the blog post. The approach of FROMSOFT to NPC AI hasn't really changed much at all between Dark Souls and Elden Ring. (One of the most impressive things about their studio imo is the way they don't change much between titles, and yet all the games have a quite unique feel)

What the video refers to as a "Combat Wheel" is, in my opinion, much more easily explained as a weighted random selection. It really just takes a list of functions and randomly chooses one to call with dynamic weights. (But I appreciate that I differ significantly from AI academia on this point, because I also think the term "utility ai" is a really silly term for... dynamically weighting options before selection)

Likewise the start of that video talks a lot about the "Goals", in reference to complex planners like GOAP (which is the approach famously used in FEAR) and HTNs, but there is no planner here. It's just a basic pushdown automata.

Anyway, the reason I wrote this post in the first place is mostly because I watched that video and it felt a bit off, and investigated the code myself.

Re: The Low-Tech AI of Elden Ring

#72

The article keeps on mentioning about the performance issues of the decision tree that somehow this approach avoids, but it doesn't seem to actually put any real detais about the why here. Especially considering that: 1. Many scripting languages you'd find in games are implemented by evaluating the syntax tree directly (IIRC WitcherScript in Witcher 2 and 3 is implemented like that) 2. A behavior tree can be "compile…

Yeah you're totally correct that ultimately the specific implementation details are what matters for performance. You could easily take either system and make it terribly slow, or more than fast enough. That's why I was somewhat deliberately vague about performance claims, it's really just a vibe-based thing.

Basically in my experience when you actually build a behavior tree as a tree, you get a pretty significant node count once you try to do anything remotely complex, just due to the way that behavior trees implement both control flow and actions as a (usually) static tree. In large AAA games this can really quickly turn into a situation where you have tens of thousands of nodes in a single behavior tree, which you then need to deal with somewhat efficiently. This affects not only the runtime, but the editor tooling as well, since these are often authored as visual noodle graphs.

You could totally lower the tree to some kind of bytecode, or optimized representation, but something I like about the approach here is that you kinda just don't need to do that. It's naturally resistant to the kind of node explosion you get with static trees because the decision logic is contained within nodes as Lua script (or C++ code), rather than built into the tree structure itself.

It's not a strongly justified position, I just think these kinds of structural decisions have an oversized impact on the amount and kind of optimization work you need to do down the line.

(Author here, if it wasn't clear)

Re: The Low-Tech AI of Elden Ring

#73

What do you mean by "low-tech AI"? This isn't AI...It's a behavior tree. Calling every decision-making system "AI" is like calling a flowchart a neural network. What you're describing is a behavior tree: predefined logic, predefined responses, no learning, no inference, no model. Stop calling everything AI, guys.

It's called AI because it drives the behavior of the NPCs, hence the name "artificial intelligence". I couldn't think of a better fitting term, especially if you know it is in the context of games. Everyone who actually plays games knows what AI in gaming means and that it doesn't need to involve LLMs or neural networks.

The thing about artificial intelligence is that it doesn't necessarily have to look or behave like biological intelligence. It could very well be a very alien and foreign form of intelligence.

Re: The Low-Tech AI of Elden Ring

#74
post #40
post #7

As a game dev, the fact "AI" as a keyword became totally unusable is quite annoying.

I try to say "LLM" as much as possible, but I'm aware that it's unlikely to work. Partly for technical accuracy, partly to manage the average person's expectations when they hear "AI", partly to avoid contributing to a big dumb-money "everything is AI" bubble, etc.

We probably should call LLMs "Alchemy" at least until the big AI companies remove the disclaimer that "AI can make mistakes".

Re: The Low-Tech AI of Elden Ring

#75
post #5

Perhaps this explains why Fromsoft npc quests are easily the most inscrutable in all of gaming. Like, okay Hyetta, have another “grape”, aka eyeball, oh now you’ve moved to the bridge in Liurnia, cool. I’ve exhausted your dialogue but you’re stuck. Oh I have to reload the area and exhaust it again to advance your quest. Okay, cool. Now you’re in a random church and you want a “fingerprint grape”. What? It’s all part…

When I finally started using the internet to figure out what I'm supposed to do next on some of the quests, I couldn't believe how many of the answers were "Talk to the NPC three times in a row to exhaust their dialogue". Like, are you shitting me? Why? After a while, I would do this to every NPC, every time. But, yeah, it's a bad design.

It's... interesting design, in that there's a puzzle or chance element I suppose. Especially Elden Ring encourages exploration, because there's almost always a reward for wandering and exploring in terms of items / abilities.

The NPC / quest thing means that, unless you go online, you will need multiple playthroughs and exploration to get every quest done, OR you need to engage in a community - the quests and lore are often all discussed, disseminated, notes compared, theories crafted, etc in the community after the release of a new game.

Whether that's good or bad design I'll leave up to opinion, but it's interesting.

(personally I don't have the time to do multiple 100+ hour playthroughs so I followed guides online)

Re: The Low-Tech AI of Elden Ring

#76
post #67
post #63

Earlier quoted context omitted.

It has gotten worse. Shadow of the Erdtree requires you to kill a boss (Mohg) hidden within a SECRET AREA (Mohgwyn Palace) hidden within ANOTHER secret area (Consecrated Snowfield). And the Consecrated Snowfield is only accessible if you find two parts of a hidden medallion, the first in a castle later in the game than the lift it operates. The second is hidden in a jar underneath a mountain. But you can't just smash…

All the speedrunners just kill the guy in the jar to get the medallion: you don't have to talk to him. Also, all you have to do in the Snowfield is to take a teleporter: that's not very secret, is it?

It's not secret, but it's not exactly easy; you can find one part of the medallion just by exploring (iirc its description says what it's for), but not sure if the second half is that straightforward.

And even then, while an item may say "use it here", if it's been dozens of hours since you got it you may just straight up forget about it.

That said, I think that the target audience for the DLC was always people who thoroughly played through the game.

Same with the other games' DLC; for Bloodborne's you need to be yoinked by an invisible enemy while in posession of an item; while it's very possible people were accidentally yoinked on their first playthrough, they will forever know that the item is a trap and will avoid getting yoinked.

(unless the item in question explicitly said "get yoinked to go to DLC", I forgot)

Re: The Low-Tech AI of Elden Ring

#77

Earlier quoted context omitted.

Especially in Elden Ring, it also contributes to the ludonarrative cohesion. Hyetta's quest (no spoilers!) isn't meant to be completed by everyone, her story is a foil to Melina's "default" questline that is mandatory for beating the game. Other characters (eg. Boc, Sellen, Selivus, Thops) also have quests that are easy to start but deliberately obfuscated towards the end. The JRPG logic is annoying, but From uses it…

They're victims of success. Lautrec was so infamous some people (read: me) are too scared to play the game without a guide now. "What if I missed some NPC and I can't level up anymore?!"

That's what I had; I was going through Elden Ring thinking "I will just play the game straight / naive the first time, no guides". Got close to the city and thought "...this feels like a point of no return / the end, better check if I missed anything important!". 100 hours later (or whatever) and I found out it's more like the halfway point.

Re: The Low-Tech AI of Elden Ring

#78

Earlier quoted context omitted.

How big are these trees that performance starts to matter?

Usually one would start with "is there a measurable performance bottleneck here?" :-P. TBH i haven't played Elden Ring but from what i've seen there are so few "active" NPCs around that i highly doubt there'd be any performance issue coming from this.

Yeah I doubt it, in terms of scale you get at most dozens of enemies, and I can't imagine their behaviour is at all expensive compared to everything else. Every "mode" (idle, attack 1/2/3, etc) is relatively slow as well.

Re: The Low-Tech AI of Elden Ring

#79

Earlier quoted context omitted.

The same thing happened with crypto (cryptography) after Bitcoin blew up, though it was just an abbreviation so it wasn't as bad. There's no ambiguity when speaking, but when searching Rust-related things I get a lot of Rust game stuff. "Rust crates" or "Rust drops" correspond to in-game things so the fandom wiki will pop up. Occasionally I'll even get rust-removal webpages.

Crypto is not short for cryptography though in that context, it's cryptocurrency?

Different meanings in closely related contexts is exactly the point of OP and GP.

If you search for 'rust crypto', you get results for Rust cryptographic packages as well as Rust in the cryptocurrency space (as it's become very popular with that audience)

Same with googling 'game dev AI', as I've been doing to learn about behaviour trees/FSM, you get inundated by articles of people with a Claude subscription and a dream.

Re: The Low-Tech AI of Elden Ring

#80
post #6
post #3

Low tech AI? Its sounds like standard game AI. I would really like to hear what the author would deem high tech game AI.

My favorite high tech AI was Crysis. Might have been an update after it was originally released. The enemies will aggressively attack but then get quiet after you've taken cover. Eventually you'll realize some of them are flanking you while others keep suppressing fire on you to stop you from moving. You can hear them yelling to one another. Very cool touches.

Far Cry 2 had a similarly sophisticated system, if not more sophisticated.

Not only would they call out to each other, they would attempt to carry off wounded allies and call out to each other in native language (set in africa, so I understood it).

They also adjusted their techniques based on the reputation level of the player.

Post reply on HN