MKMoose Posted Saturday at 05:42 PM Report Posted Saturday at 05:42 PM (edited) Motivation Animal behavior in Vintage Story is largely unimmersive and unintuitive, because animals respond in gamified and highly simplified ways. Most animals exhibit survival strategies which could realistically be easily considered pathological, i.e. caused by disease or injury. Goals Improve animal behavior to be more engaging when hunting. Make animal behavior more believable and realistic. Give the player fair warning before an animal attacks. Reduce early-game frustration with overly aggressive wildlife. Improve the behavior of domesticated animals to be less erratic. Stay reasonably close to the vanilla experience. Primary behavioral patterns In science it's not uncommon to distinguish many different kinds of distinct behavioral responses that animals exhibit when approached or threatened. I'm going to simplify the system into three generalized patterns which, with some variation within each group, can cover every single animal in the game and provide plenty of gameplay depth. The borders between categories are naturally fluid and some animals may exhibit behaviors typical of more than one group (especially since behavior can vary due to various factors), but this is intended more as general guideline than rigid categorization. Evasive animals, prey and small game. Relevant animals include smaller species like foxes, raccoons, hares, as well as several larger herbivores like deer, sheep and goats. The primary response for these animals is flight - fast escape, preferably to pre-selected advantageous terrain, like high ground in the case of goats or trees in the case of raccoons. Some animals like raccoons often employ threat display - hissing, bluffing, fur standing up, and many animals like deer, sheep or again raccoons, especially if cornered or immobilized in some way, may engage in more defensive combat - ramming, kicking and thrashing, clawing and biting. It is important to remember that for these animals even more so than others, combat is about survival - if they engage in it at all, they generally only do it opportunistically to protect themselves and their young or to create an escape opportunity. They are not aggressive and their first response is almost always retreat. Those are also the animals which a hunter will often focus on for meat and pelts. Defensive and territorial animals, large game. This category includes boars, bears, moose and similar large animals. Due to their size, they can be unexpectedly dangerous even if they don't seem immediately threatening. Typical response often involves territorial defense and threat display - repeated approach and retreat, vocal warnings, guarding boundaries. Under some circumstances like guarding their territory or food, protecting offspring, or getting surprised at close distance, they may resort to managed but decisive aggression to neutralize a perceived threat, though they still remain defensive above all else - deliberately seeking out a target or pursuing a threat is rare. Some species like black bears may be more avoidant and prefer to disengage as quickly as possible. Simply avoiding approaching too close and leaving the area once warned is generally sufficient to avoid danger. This category, from a gameplay perspective, should include animals balanced as "hunting challenges" - large game that will fiercely fight back when hunted, but may provide relatively lucrative rewards in the form of heavy hides, fat and large bones. Predators. In the current state of the game, this only includes wolves and hyenas. Predators are generally much less aggressive than many people seem to think, and their behavior is driven by well-developed risk assessment abilities. Wolves and hyenas often move in packs or small groups, though many other predators hunt individually. Their typical response when threatened is keeping distance, careful observation, tracking and similar behaviors. If they encounter larger animals or groups, then the decision-making process is simple: high risk => retreat. If they deem that the target is worth the risk - primarily when a pack of predators locates lone prey - they will circle the target and close in, then attack. In part to protect lone players from somewhat unfair attacks, larger packs of predators should arguably only target large enough groups of targets. They don't just outright attack anything that comes into their vicinity, and instead they choose their prey carefully. Implementation details Animal awareness. Each animal should have certain distances (much as they do currently, though it's pretty shallow as of now) at which they enter specific behavioral states. Ideally, this would be done not with strict distances, but based on some simulated aspects of hearing, sight and maybe even smell. Some delays, lingering states and other details would make them more believable. Keep in mind that distances may vary greatly between different animals, and the examples I'm giving are very rough and generally much lower than realistic for the sake of gameplay. The primary states which should be generally shared by almost all animals are: calm (no threat in vicinity, resting, eating, drinking), alert (~20-50 m or closer, prey animals will raise their head and start scanning for threats, while territorial or predatory animals may move to investigate the potential threat or target), cautious (~10-20 m, all relevant animals may engage in defensive threat display at this distance, prey animals will freeze or retreat depending on species, while other animals will either retreat cautiously or turn towards the threat depending on intention), threatened (~2-10 m, prey animals flee quickly, defensive and territorial animals may attack, predators retreat unless confident), attacked (after getting hit, behavior is more erratic and unpredictable, for most species the primary reaction is flight, especially if hit at range and not from up-close, while defensive behaviour similar to when threatened is less common, though more aggressive if present). Animal speed. Flight (escape) and pursuit speed should generally be higher than the player's sprinting speed, unless injured. I believe that hunting should be about strategy, element of surprise, careful shot placement, and fast action, not about pumping half a dozen arrows into a single target. The best way to do this is to make sure that prey animals escape quickly when hunted carelessly, while larger animals should be avoidable if warnings are respected, but extraordinarily dangerous when aggressive (it's genuinely kind of pathetic that a Seraph can outrun a bear in many contexts, even a brown or polar bear with effective use of terrain). Defensive attacks. When threatened or attacked, many animals will attempt a quick and decisive attack, and then disengage and retreat if unsuccessful - largely the same as the current "attack and pursue", except switched back to "flee" after the first attack, whether successful or not. If the threat pursues the animal in turn, they may opportunistically attack again. Exceptions may include boars as well as brown or polar bears, especially when protecting their offspring, but even those should often relent after a short sprint - if they don't manage to catch the threat within that time, they should retreat back to roughly where they started (especially if the initial reason for the aggression was protecting their young). Predator attacks. When travelling through the wilderness, predators shouldn't generally be a jumpscare, or at least it should be the presence of the predator or vocal warning that jumpscares the player, not immediately taking damage. Animals like wolves practically never attack right the moment they notice a target. The default wolf encounter should be noticing them some two dozen blocks away, looking at the player and following them. In many cases, they would disengage naturally. In some cases, if the risk is not too high, they would circle the target, close in gradually (often with vocal warnings) and then attack suddenly. Domesticated animals. The "threatened" radius in which animals initiate flight or attack should be very quickly reduced to zero for domesticated animals, and the thresholds for other states should also be relaxed fairly quickly. The key here is gradation (important everywhere, but here especially) - it's only natural for a domesticated animal to be hesitant and careful around humans if it's not habituated, but the current behavior of either being completely oblivious or full-speed sprinting away with nothing in-between is exceptionally unimmersive and annoying. Additional factors affecting behavior. The most relevant factor is likely having offspring to protect, and the mating season also causes increased aggression in many species. These could be implemented in various, simple or complex ways, but the most important detail is that when an animal is protecting their young, they should actually protect them, not forget about their existence once out of range. Animals that don't generally fit these categories Animals like aurochs, elephants or horses, as herd animals, would ideally need more complex herd behavior to be simulated or at least approximated. They are in many regards similar to other larger animals like moose or boars, but herd dynamics shape their behaviors is very distinct ways. Some predators, though we don't have them currently in the game, may silently ambush the target. A big cat or two could really spice up the tropics. Additional notes AI improvements are borderline necessary to really bring a rework like this to a more complete state. The least that should be eventually done is: prevent animals from constantly falling down pits or into water, introduce more variation to animals' direction of movement, instead of having them always move either directly towards or directly away from the target or threat. Injuries, bleeding and similar effects would allow to make hunting (and being hunted) much more dynamic, engaging and realistic in a whole range of ways, mainly by greatly reducing the number of hits required to bring down a target but increasing their threat level and adding on additional complexity of tracking injured animals. Animal yields would have to be increased if animals are made more difficult to kill. Arguably, animal yields should be adjusted regardless by implementing simple butchering. It would require more effort per animal while retaining a similar level of effort for the same yields, changing very little about balance while greatly increasing mechanical depth and reducing the need to kill dozens or hundreds of animals over a single playthrough. Edited yesterday at 07:24 AM by MKMoose Minor corrections. 7 3
Jellyamp Posted Saturday at 07:48 PM Report Posted Saturday at 07:48 PM This is really well put together! The only thing I would add onto it would be more consideration for how animals interact with each other. Specifically, the behavior of certain prey animals would be different depending on if they are encountering a player or another smaller prey animal that they are hunting (for those that do hunt other animals). This isn't a super necessary addition as it might not add a lot of gameplay value but I think it would add to the immersion of the world. It would also probably require new types of animals like small rodents to be introduced. Since these animals would likely be of very little value to the player, it might make sense to have them only spawn in around larger prey animals to allow for those animals to engage in hunting behaviors (which the player could then take advantage of). If the player isn't nearby, then spawning them in wouldn't make sense as their purpose from a gameplay perspective would only be for adding immersion and a unique complication to the player's hunt of the larger prey animals. This would also help cut down on the amount of extra computation that would need to happen for an entirely new set of animals in the game. Also, it would just be fun to have small cats that the player could "domesticate" and keep in and around their homes to occasionally catch small rodents (domesticating cats might not be the right term but the general idea is that having large food stores would also bring with it rodent populations which could be managed by the player accepting the presence of a cat in and around their homes). 3
LadyWYT Posted yesterday at 02:23 AM Report Posted yesterday at 02:23 AM I'm probably going to have to come back to this later, as I'm not really sure I'm going to cover what I really want to in proper detail. Overall, I like the suggestion, and I'm pretty sure this is already what the devs would like to do someday. However, I'm also not expecting 100% realistic behavior either, as there are limits to what can be simulated and a 1:1 of real life doesn't always make for the best of gameplay. 8 hours ago, MKMoose said: threat display - hissing, bluffing, fur standing up I think these in particular aren't necessarily hard to simulate, but hard to implement as fun, challenging gameplay. The main hurdle when it comes to creature behavior and survival challenges in general is that...videogames aren't real, and are very predictable. Mistakes in real life can have severe consequences, so people will tend to be more cautious in how they approach things, since there's not exactly console commands or reset buttons if something goes really wrong. In a videogame though, poking a bear to see what happens will, at worst, cause the player a bit of frustration and lost time(maybe a broken keyboard if the situation is bad enough). Hence where I think the threat display fails, and needs some additional planning if it's going to work well in the game. If the creature is small enough, the threatening display might entertain the player if they choose to watch, but it's not going to make them think twice about attacking said creature when they know they can easily overpower it without consequence. I think the same applies to large creatures as well, to some extent; if the creature always gives a lot of warning before attacking, then the player will pretty much always be able to avoid dangerous creatures with ease, and won't think twice about picking a fight if they're confident in their skill. 8 hours ago, MKMoose said: flight - fast escape, preferably to pre-selected advantageous terrain Creatures already do this to some extent, especially if severely wounded. I also don't think a lot of them run fast enough or react quickly enough, but eh...details. The main issue I see with making creatures good at noticing the player and running away is then it's harder for the player to really enjoy watching the local wildlife. For some, like deer, it does make sense, but I don't think it should be a given for every creature. 8 hours ago, MKMoose said: AI improvements are borderline necessary to really bring a rework like this to a more complete state. The least that should be eventually done is: prevent animals from constantly falling down pits or into water, introduce more variation to animals' direction of movement, instead of having them always move either directly towards or directly away from the target or threat. Injuries, bleeding and similar effects would allow to make hunting (and being hunted) much more dynamic, engaging and realistic in a whole range of ways, mainly by greatly reducing the number of hits required to bring down a target but increasing their threat level and adding on additional complexity of tracking injured animals. Animal yields would have to be increased if animals are made more difficult to kill. Arguably, animal yields should be adjusted regardless by implementing simple butchering. It would require more effort per animal while retaining a similar level of effort for the same yields, changing very little about balance while greatly increasing mechanical depth and reducing the need to kill dozens or hundreds of animals over a single playthrough. Cutting to the chase, I think overall the animal behavior issue isn't something that can really be solved until the status effect system is implemented. As it stands now, animals just aren't going to be very scary unless they can hit hard and chase the player down/get the drop on the player somehow. The recent changes to the raccoons are pretty fun(and funny), but I'm still not going to think twice about collecting their hides whenever I want. Even the bears don't really feel that threatening anymore since I can literally just run backwards and stab them to death with a flint spear or falx. Half the time they're just sitting there letting me get free hits, and the other half the time they swing at me but somehow miss despite the fact that I'm right in front of their face. At the very least, I'd like to see bears get their reach back, since while I think it's fair to allow the player to outrun the bear if they react fast enough, they shouldn't be able to just run around and stab the bear to death. Bears should be dangerous, and it seems more appropriate for the player to build a pit trap or get some armor before trying to tackle one head-on, if they aren't going to rely on ranged combat that is. As for wolves, I'd like to see them prefer to avoid the player if by themselves, or call other wolves nearby for backup before attacking as a pack. They are, after all, pack animals, and working together as a proper pack would make them a lot more threatening, as well as help them stand out from other aggressive wildlife. The howl could even be a bit different than the standard howl, so the player knows when they're actively being hunted versus when the wolves are just socializing. When the status effect system is added...there's a lot I'd like to see, but one thing I really want to see: skunks. They don't need to attack the player at all, not that they'd be terribly dangerous if they did. The main concern for the player? Getting sprayed. This would be a perfect time to implement a "threat display" warning, that the player really should listen to, since getting sprayed by a skunk isn't at all fun and that smell is going to stick around for a while. I'm not sure what kind of effect getting sprayed would have, but surely smelling that bad can't be good for conducting business with NPCs, and probably isn't useful for hunting since everything in the forest is gonna smell the stink coming. It may also make the player more noticeable to monsters, though given monsters already smell bad I could also see it having the opposite effect. 4
MKMoose Posted yesterday at 09:56 AM Author Report Posted yesterday at 09:56 AM (edited) 10 hours ago, LadyWYT said: I think these in particular aren't necessarily hard to simulate, but hard to implement as fun, challenging gameplay. The main hurdle when it comes to creature behavior and survival challenges in general is that...videogames aren't real, and are very predictable. Mistakes in real life can have severe consequences, so people will tend to be more cautious in how they approach things, since there's not exactly console commands or reset buttons if something goes really wrong. In a videogame though, poking a bear to see what happens will, at worst, cause the player a bit of frustration and lost time(maybe a broken keyboard if the situation is bad enough). Hence where I think the threat display fails, and needs some additional planning if it's going to work well in the game. If the creature is small enough, the threatening display might entertain the player if they choose to watch, but it's not going to make them think twice about attacking said creature when they know they can easily overpower it without consequence. I think the same applies to large creatures as well, to some extent; if the creature always gives a lot of warning before attacking, then the player will pretty much always be able to avoid dangerous creatures with ease, and won't think twice about picking a fight if they're confident in their skill. The purpose of defensive threat display is less to warn the player not to attack, and more to warn the player before the animal attacks. But if the player attacks the animal or just approaches too quickly, then they will still be met with a fast and dangerous response, especially from animals like boars, moose or bears. Even a raccoon or a deer might sometimes defend themselves with an opportune attack first before fleeing if you manage to run straight into it (though especially deer would practically always run away before you can do that). Being able to avoid dangerous creatures is, in large part, exactly the point, though they will easily still give you a scare or outright attack if you don't make distance quickly enough after initially getting too close. With the exception of wolves and hyenas in certain regards, I would argue that animals should be easy to avoid, but more dangerous when not respected. Even if the player is confident in their skill, they would still be easily put in their place once they get too cocky and disregard one warning too many or forget to keep their guard up. As things stand, the best way to cross a forest is just to keep running since animals are for the most part just too slow, and I think it would be much better if instead it was preferable to move more carefully to avoid disturbing the wildlife. And at the same time, moving slowly should be greatly rewarded when hunting with the ability to get much closer to the target for a better chance at an accurate hit with arrows or spears. Wolves, hyenas, and to some extent brown and polar bears, are exceptions from the above, because they can function as more active predators and would be much more tricky to avoid completely unless the player simply doesn't even approach their territory. 10 hours ago, LadyWYT said: Cutting to the chase, I think overall the animal behavior issue isn't something that can really be solved until the status effect system is implemented. Fair enough, I do certainly agree that there's a lot of things that would require a bunch of new mechanics to be introduced. That said, there's good reason I've put injuries and bleeding in "additional notes". I think that even just very basic gradation of reactions to the player (simply one extra state between calm and scared/aggressive), ideally with vocal warnings where appropriate and some adjustments to animal stats, could do wonders for the animals' behavior in practially all contexts - exploring, hunting and husbandry - all while almost exclusively using already existing mechanics. Edited yesterday at 12:54 PM by MKMoose 3
Emeal Posted yesterday at 11:24 AM Report Posted yesterday at 11:24 AM I think a System like this is great, but idk how much processing Anego can allow here. Lets think about what each Animal would need a: Values: Perception Range: Range at which is checks for BushRustle or can generate a line of sight from. Threat%: A value that changes over the course of interactions with other Mobs. HasHerd: A value that determines if Creature is part of a herd or not. HasDen: A value that determines if Creature has a Den. Status: Alert: Adds a bonus to Perception Range, commonly triggers by BushRustle. Flee: Triggers pathfinding away from Threat determined by Line of Sight OR last known BushRustle direction and follows normal threat avoidance. HasLineofSight: Creature will now look in this direction and set Threat% based on distance. Systems we would need: BushRustle sends signal to Mobs. Generation of Line of Sight for Mobs. Herd generation mechanic for Mobs of the same species. Brrr yeah this is certainly alot of consider, I think I know why they have not dont this yet. 3
LadyWYT Posted 23 hours ago Report Posted 23 hours ago I think the main thing about the threat displays is that while I would like to see them, I don't want to see them become something the player can use to avoid an encounter 100% of the time. By that I mean I still want to be able to stumble across a bear in the bushes every once in a while, and then needing to deal with that. That doesn't necessarily mean that the bear has to attack me when that happens, or that I have to run away, just that it leaves the door open for some more variety in animal-player interaction other than "You're fine until an animal does X, then you should leave before you get attacked". Maybe this kind of thing could be handled by animal "personalities", where some are more skittish and likely to run while others of the same type might be more aggressive and prone to attacking the player. In regards to livestock animals specifically, perhaps they could become semi-tame when fed, but the player will need to remove negative traits like aggression or skittishness over a few generations of breeding to get special traits for domestic livestock(docile, higher yields of certain products, alarm calls when a threat is nearby). 4
williams_482 Posted 21 hours ago Report Posted 21 hours ago 14 hours ago, LadyWYT said: When the status effect system is added...there's a lot I'd like to see, but one thing I really want to see: skunks. They don't need to attack the player at all, not that they'd be terribly dangerous if they did. The main concern for the player? Getting sprayed. This would be a perfect time to implement a "threat display" warning, that the player really should listen to, since getting sprayed by a skunk isn't at all fun and that smell is going to stick around for a while. I'm not sure what kind of effect getting sprayed would have, but surely smelling that bad can't be good for conducting business with NPCs, and probably isn't useful for hunting since everything in the forest is gonna smell the stink coming. It may also make the player more noticeable to monsters, though given monsters already smell bad I could also see it having the opposite effect. Getting sprayed could give blurred vision and put a gross brownish yellow green tint on everything, with the effect's severity and duration proportionate to how direct a hit you got. I love the idea that NPCs avoiding and refusing to trade with a skunk-sprayed player, which could be a longer duration effect and more difficult to avoid than the blurred vision, but that alone isn't enough. Being sprayed by a skunk at close range hurts more than just your social life. 2
Recommended Posts