11 ms·
Emergent Behavior in Skyrim's Fox AI
- H8crilA 5y agoWouldn't it only cause the fox to stop at treasure areas rather than run towards such areas? Still, overall it looks like the fox leads you to stuff, but I'm just trying to understand.
- 01acheru 5y ago“The fox isn't trying to get 100 meters away - it's trying to get 100 triangles away.” When escaping, if they get nearby a “dense” zone, their behavior makes them run towards it since there are more triangles to hop to and it makes them “feel like” they are farther away from you, instead they will keep running around in the same “dense” area. Well… maybe I could’ve explained it better but yeah, it’s more or less like this.
- beaconstudios 5y agoYeah the cost for denser triangles is lower, so it'll run 50 meters for 100 triangles in a camp rather than run 200 meters in open field.
- BlueTemplar 5y agoI don't think that's it - the fox just randomly picks any point X triangles away, so it has a biais towards densely triangled areas.
- xarope 5y agoPersonally, if I was being chased by someone/something, the last thing I would do is run across an open field. Instead, I'd seek a more complex environment. TIL, I'm a fox in skyrim... /j
- 01acheru 5y agoYou made me think that young children do something like that too. When running away/playing they try to maximize the cost/effort of running away, not actual distance. Like: zigzagging, passing under chairs or tables, climbing on something just to immediately climbing off. The problem is they usually maximize their effort, not yours in following them. Nice, thanks :)
- skohan 5y agoWhat’s interesting to me is that this result shares something with the relativistic theory of gravity: That is, that gravity is a side-effect of the fact that time moves more slowly closer to centers of mass, which causes the velocity vector of an object moving in space to turn in the direction of the time-speed gradient in space.
- javajosh 5y agoThere is a quantity that nature likes to minimize, which makes it so. See https://en.wikipedia.org/wiki/Stationary-action_principle https://en.wikipedia.org/wiki/Stationary-action_principle
- eternalban 5y agoThanks. That led to a minor reading on a very colorful character: https://21sci-tech.com/Articles%202004/Spring2004/Maupertuis.pdf https://21sci-tech.com/Articles%202004/Spring2004/Maupertuis...
- desmosxxx 5y agoThis is misleading / incomplete. Curviture in the time dimension is not enough to explain gravity. Gravity is caused by curviture in spacetime (4D). It's definitely not intuitive to think about the time dimension (and so makes for a good youtube video), but this "theory" you're talking about isn't anything that wasn't already known when GR was first introduce. I'm not sure if you just meant GR and "accounts for some of gravity", but it's a common mistake I've seen people make after some youtube videos on the subject. See https://physics.stackexchange.com/questions/609217/how-much-of-gravity-is-caused-by-time-dilation https://physics.stackexchange.com/questions/609217/how-much-...
- eurasiantiger 5y agoAren’t there formulations which do away with space-time by treating it as an emergent feature?
- 5y ago
- RL_Quine 5y agoThat's a really hard to read article which is summarizing a couple of tweets.
- bjterry 5y agoHere's the original tweet, for those interested. The content is essentially identical either way: https://twitter.com/JoelBurgess/status/1428008041887281157 https://twitter.com/JoelBurgess/status/1428008041887281157
- drzaiusapelord 5y agoThanks for the original link! I find it so hard to read text with animated gifs right below them. I literally had to scroll the gifs off the screen to read the test. Its just too distracting and there's no stop animation option on twitter. Its just incredible how this world is made for people who have high levels of on-demand focus and there's no care for us who don't have that skill or neurotypicality.
- argvargc 5y agoWell... 13 tweets, but they're a good read nonetheless.
- lucb1e 5y agoIndeed. The TL;DR of the whole thing seems to be: Spooked foxes aim to be 100 "triangles" away from the player on a pathfinding mesh. Where are they likely to run into the 100th triangle? In a place with a lot of pathing points, so it'll often lead you to a camp or something interesting. ^fits in one tweet and no cookie wall minigame required
- drzaiusapelord 5y agoWhich is funny because we have so much story telling and myth that suggests the same thing. Our hero lost somewhere follows a wild animal which brings him to food or water or treasure or shelter. In real life, animals might also be seeking out that 100th triangle. In low density areas like fields they are super exposed to predators and the elements so if chased or watched, they'll go to places with complexity and resources. I think this is a very amusing and interesting parallel between the virtual worlds we build and the real one nature built.
- VectorLock 5y agoEmergent gameplay as they describe it, "the bubbling cauldron of overlapping systems", is really what makes Bethesda games so successful.
- beaconstudios 5y agoSkyrim isn't very emergent though - morrowind is moreso, but for emergent gameplay you want to look at dwarf fortress, SS13 or many roguelikes. If anything, Bethesda have been simplifying their games through the years.
- Agentlien 5y agoIn what regard is Morrowind more emergent than Skyrim? It definitely felt magical when it was new, but I think that's just a feeling. Skyrim has Radiant AI and things like NPCs taking over establishments when the owner dies. A number of dynamic behaviors which help things feel a bit more alive. I can't remember Morrowind having any kind of dynamic behavior or emergent gameplay. Unless you count being able to lock yourself out of quests by killing important characters (including as part of other quest lines!) which is something I do miss.
- neartheplain 5y agoIn what regard is Skyrim's gameplay emergent, aside from the OP link's fox example? As I understand it, Radiant AI is a framework for fixed and relatively simple finite state machines, with states like "use the anvil at the blacksmith's shop during working hours" or "drink in the tavern at 9 PM." Don't get me wrong, it's leaps and bounds beyond the NPC AI found in earlier games, but it's far from the emergent craziness you'll see in a sandbox game like Rimworld or Dwarf Fortress. Dynamic behaviors like the one you mentioned are still all essentially scripted interactions. Dialogue, the core interaction between the player and most NPCs, is still 100% scripted conversation trees. The most interesting emergent events I remember from Skyrim (or Oblivion) were funny glitches like this one: https://www.youtube.com/watch?v=QvuW2Jl5ZyY https://www.youtube.com/watch?v=QvuW2Jl5ZyY I'd also like to hear the GP commentor's reply re: emergent gameplay in Morrowind. I haven't played that game as much as the others, and don't have enough in-game experience to comment.
- jsd1982 5y agoIt's not really emergent behavior, just merely an unintended consequence of tons of compromises in implementation.
- kortex 5y agoEmergent just means a more complex behavior (foxes tending to flee towards interactivity-dense areas) resulting from a simpler rule (while fox.spooked, maintain 100 triangles of distance away). Flocking is an emergent behavior that is basically minimizing a loss function of "maintain x distance". If you implemented boid AI (birds) in skyrim and used triangle count as your metric, you'd be able to spot points of interest by the sudden increase in density of flocks. But players might extrapolate to the idea that "birds flock denser in cities". But no one programmed that behavior. It just emerged.
- technothrasher 5y ago> Emergent just means a more complex behavior [...] resulting from a simpler rule Emergence is more a behavior that results from the relationship between two parts of a system. The fox fleeing behavior leads you to interesting things only when coupled with the way the triangles are laid out. The two parts of the world model together bring out the emergent behavior.
- deleted 5y ago[deleted]
- exdsq 5y agoAn unintended consequence that adds a feature is an emergent behavior isn’t it?
- chestertn 5y agoNo, that is a serendipity. Emergent behavior is when the sum is more than its parts.
- deleted 5y ago
- onion2k 5y agoDwarf Fortress is good for this sort of thing.. Especially the famous case of the poisoned cats https://www.eurogamer.net/articles/2017-04-13-why-dwarf-fortress-started-killing-cats https://www.eurogamer.net/articles/2017-04-13-why-dwarf-fort...
- beaconstudios 5y agoThe difference being that DF is specifically designed for emergent behaviour because it's probably the most system-driven game in existence - this fox AI feature is totally accidental. I really love emergent gameplay and I only say this because I was rather let down by skyrim's lack of emergence compared to morrowind.
- rhn_mk1 5y agoWhat are the examples of emergence in Morrowind?
- beaconstudios 5y agoThe best examples are related to the magic and alchemy systems: you can break the game in many different ways, the classic one being to use fortify intelligence potions to boost your alchemy skill and then make new fortify intelligence potions until you have effectively infinite skill and extremely valuable potions. You can also use levitation and chameleon spells to access areas or items early. It's not a /very/ emergent game but it has more to offer than skyrim. The speedrun completes in something like 10 minutes using a variety of exploits.
- pjm331 5y agoI may be wrong on this but I also feel like Skyrim lacked the kinds of magical items Morrowind had that basically required you to think up clever magical hacks to make them useful eg Boots of Blinding Speed
- 5y ago
- vmception 5y agoI wonder if we can trick an animal to guide us in the physical world using this density concept I guess its kind of what seafarers did with birds But I’m thinking more about altering an environment to make animal non player characters assist humans
- WJW 5y agoWell training animals to do basic tasks is literally thousands of years old, but using this density concept probably won't fly since the real life "grid" is pretty much infinitely dense. (yes yes the Planck length is technically a limit, but that is not a concern for anything alive)
- criticaltinker 5y agoPrevious HN discussion regarding the original tweet: Why wild foxes led you to treasure in Skyrim https://news.ycombinator.com/item?id=28230305 https://news.ycombinator.com/item?id=28230305 4 Months ago | 221 comments Transcribed text of tweets (for convenience): https://news.ycombinator.com/item?id=28230677 https://news.ycombinator.com/item?id=28230677
- pdimitar 5y agoLeaky abstraction in a nutshell! Really fun little tidbit, loved it.
- LambdaTrain 5y agoJust want to make sure if I correctly understand what it means by "triangle": For navigation, the developer triangularize the skyrim world, and these divided triangles are not the same size - for example, a 100-sq feet field is covered by one triangle, while a 100-sq feet point of interest is more complicated and covered by more triangles. The original design intention is that the number of triangles encodes the sense of distance, but maximizing the #triangles actually leads to interesting places.
- FeepingCreature 5y agoRight. Another way to think about it is if you reproject the Skyrim map so that each navmesh tri is equally big, a surprisingly large area would be taken up by points of interest, and foxes target a random point in a radius around the current point in that reprojected map.
- alephxyz 5y agoAnother way to think of it is that foxes travel in more or less straight lines in the curved navmesh-POI space (/s)
- omegalulw 5y agoYou don't even need the /s I think. They travel towards a far away point from the player but near treasure areas, because of their high navmesh density, all path lead in one direction.
- prox 5y agoYeah, you can open the skyrim map in the Creation Kit and see the navmesh. You could even remake the navmesh as you see fit in a mod.
- junon 5y agoYeah they made the decision to judge total distance in the fox's pathfinding by number of triangles, not by actual world distance.
- 5y ago
- egypturnash 5y agoThis was a beautiful and magical thing to discover. Here I am, bumbling around this new open-world game, not really caring too much about the main quest, when a white fox crosses my path. I decide to follow it and it leads me up a mountain to an ancient, mysterious shrine. With a quest in it. It was completely unintended but so rewarding, and I really hope that the next one keeps it. Because getting rewarded for acting like someone in a fairy tale is exactly what these games are for.
- zitterbewegung 5y agoYea the fox AI is accessing basically a mesh or a graph and then the algorithm with the heuristic finds a local minima (or is it a maxima )?
- ethbr0 5y agoI think the true gem of this story is that it explains the inconsistent outcome/reason for this behavior, and hence the enduring community debate. I.e. a fox can be leading you to a high-triangle-density area (aka treasure), or it can simply be leading you away if no treasure is about And so players no doubt observed both of these outcomes... and hence the debate! And thus the nuances of the behavior somehow make it more magical than "fox always leads to treasure" simplicity.
- cortesoft 5y agoThis is always the case when you have probabilities in games... there will always be patterns in an individual's series of random numbers, and people will construct a narrative to explain it.
- casperc 5y agoIt reminds me of Onyxia in WoW, where the leading theory for a long time was that you needed Damage over time spells (DoTs) on her to prevent her from doing her damaging fire breaths, which would wipe the entire raid group. Turns out it was just random (confirmed by a developer long after), but it is interesting the meaning that can and will be assigned to random events. Probably the same mechanism that causes myths and eventually religion to form in real life.
- sdrothrock 5y agoInterestingly enough, foxes are connected to shrines in Japanese folklore. I've heard some people claim Ghost of Tsushima uses foxes to lead to shrines in a homage to this behavior in Skyrim, but it's really just an older cultural connection and a nice bit of kismet. :)
- Agentlien 5y agoWhen I first started playing Ghost of Tsushima I just thought it was a reference to Inari foxes guarding shrines in Japanese folklore. But since learning about the fox treasures in Skyrim (I had completely missed those theories when I first played it) I have been wondering if it's more. I haven't heard of foxes leading you to their shrine before, only guarding it and acting as messengers to the divine. So this American game with foxes leading you to inari shrines feels to me like a nod to Skyrim nicely incorporating this Japanese folklore.
- lowbloodsugar 5y agoI did not know this bit of internet lore. I'm assuming the Ghost of Tsushima developers did, because those foxes explicitly lead you to treasure.
- joshschreuder 5y agoI’m pretty sure the GoT foxes are based off Japanese inari myth rather than this, but it is a fun coincidence! > Legends tell of such celestial foxes providing wisdom or service to good and pious humans as they act as mediums between the celestial and human worlds.
- ricardobeat 5y agoThis article has little content and is basically getting clicks out of embedding the original thread. Better just link to that: https://twitter.com/JoelBurgess/status/1428008041887281157 https://twitter.com/JoelBurgess/status/1428008041887281157
- deleted 5y ago[deleted]
- deleted 5y ago[deleted]
- windex 5y agoI wonder if the real world has remnant bits of magic like this.
- keyle 5y agoThe title is elusive; that doesn't make it an emergent behavior, with the term AI, implying some sort of intelligence. The fox is programmed to run away from the player, very simple state machine. It happens to navigate the navmesh like the player and eventually will end up leading places the player didn't think of going containing secrets. It's not emerging intelligence as much as it is murphy's law.
- 01acheru 5y agoI think they are using AI in gaming terms, not literally AI. I hear NPC behavior in games being called AI since… more or less ever. Your second paragraph is not totally correct though and that’s actually what the article is about. It explains how “run away” is implemented and why this implementation leads foxes to interesting places more often than you would expect by simply running around. BTW what do you mean by “navigate the navmesh like the player”? The player is unaware of the navmesh, am I reading your comment wrong?
- tsimionescu 5y agoGames have conserved (or re-invented, not sure) the older notions of AI, where even algorithms like A* were discovered by and considered part of the AI "movement".
- ehnto 5y agoVideo game AI is a decades old context and has lots of it's own nomenclature for things. Emergent behavior in the context of video game AI is just when the behavior or states of various characters/objects interact in such a way that new, unprogrammed things occur. I would say this falls into that category, albeit loosely. Another example of emergent behavior in game AI would be if you had a police NPC and a regular NPC, and the police NPC will chase any character entity if they have stolen goods on them. As the player, you could place a stolen good on a regular NPC and the police would chase them. The developers didn't anticipate that behavior, it just emerged from the interactions between various states and abilities that they did program.
- sangnoir 5y agoNitpick: I think the correct homonym in this case is "illusive" (same root as illusion). Elusive shares root with elude.
- leto_ii 5y agoI don't really see any emergence [1] here. At most this could be some sort of inadvertent gradient descent like algorithm. ]1] https://en.m.wikipedia.org/wiki/Emergence https://en.m.wikipedia.org/wiki/Emergence
- lanternfish 5y agoThe emergence here is somewhat loose, but the two 'systems' interacting are the 'fox pathfinding system' and 'terrain meshing system'. Neither of these systems explicitly point the player towards high value locations, but together they tend to. The fox points towards high mesh density locations, and the meshing system correlates those high mesh density locations with high value. Now, this is borderline in my book as the fox pathfinding system isn't meant to point towards high mesh density locations, that's really more of a happy bug.
- junon 5y agoThe linked Twitter thread has all of the information the article has and more. Do yourself a favor and just click the Twitter link they have and get on with it.
- discardedrefuse 5y agohttps://twitter.com/JoelBurgess/status/1428008041887281157 https://twitter.com/JoelBurgess/status/1428008041887281157
- windmark 5y agoAnd in even better format with a thread reader, https://threadreaderapp.com/thread/1428008041887281157.html https://threadreaderapp.com/thread/1428008041887281157.html
- jwmoz 5y agoI recently downloaded skyrim and played for the first time, yes I'm quite late to it, but considering the hype of the game I was massively disappointed. The combat and manoeuvring was truly awful. People will say, ah yes but the story, the lore! But if I wanted that I'd read a book. After playing for a while I decided to try red dead 2 and can say that that game is so, so much better than skyrim imho.
- pverghese 5y agoSkyrim was released in 2011. It was groundbreaking when it was released. A lot has changed in 10 years.
- tsimionescu 5y agoI have never heard anyone particularly praise Skyrim's story, and rarely even the lore. What I think people usually like about it is the mix - magical world, graphics, decently weighty combat, big monsters, people to talk to or murder or steal from etc. It doesn't excel at any one of these, but there is also nothing else outside the series offering the same combination. Perhaps RDR2 does improve on every aspect, but the massive difference in setting will still mean that both have a place - especially for this type of exploration game.
- Xplune13 5y agoYou're comparing 2 games which were a generation of console apart and a lot of things happen between those 7-8 years. > People will say, ah yes but the story, the lore! But if I wanted that I'd read a book. That story and lore in the video game are exactly the reason I play video games i.e. video game can easily transport you into a world which you can see/hear/play-in instead of only imagining it in your mind. Books can never come anywhere close to that because of obvious restrictions of the medium and that was the reason, many (including me) were instantly captivated by the world of Skyrim. They successfully created a world full of atmosphere and lore along with the freedom of exploration and managed to do it excellently even compared to most of the games released now (and the thing is I also played Skyrim late in 2019, yet it is probably my 2nd or 3rd favorite game of all time). It's unfortunate that you didn't like it, so have fun with RDR2 (which is an excellent game with arguably the best storyline and characters in any video game till date).
- aaron695 5y agoTheir explanation is wrong. This discussion was had last time. Unless the fox understands the idea of distance the triangles can't be dense. If it understands distance the idea falls apart. One explanation might be, if the fox stops and looks around after 100 triangles or some sort of signal. When it looks around, it's more likely to be in a treasure zone. But the fox will not go toward high density triangles, because it doesn't understand density.
- vzaliva 5y agoThe title is misleading. It is not the same as the original page title, so basically user @kjeetgill is scamming us. I find this behaviour unethical and offencive. Please do not upvote.