Search Unity

  1. We're looking for feedback on Unity Starter Kits! Let us know what you’d like.
    Dismiss Notice
  2. Unity 2017.2 beta is now available for download.
    Dismiss Notice
  3. Unity 2017.1 is now released.
    Dismiss Notice
  4. Introducing the Unity Essentials Packs! Find out more.
    Dismiss Notice
  5. Check out all the fixes for 5.6 on the patch releases page.
    Dismiss Notice
  6. Help us improve the editor usability and artist workflows. Join our discussion to provide your feedback.
    Dismiss Notice

[RELEASED] Emerald - AI (Dynamic Wildlife, Breeding, Predators & Prey, Herds, NPCs & more!)

Discussion in 'Assets and Asset Store' started by BHS, Jun 26, 2015.

?

Which (in development) feature would you like to see the most implemented with Emerald Animal AI

Poll closed Oct 1, 2015.
  1. Predator and Prey system support (allows animals to hunt and flee from each other)

    12 vote(s)
    17.4%
  2. Pack/Herd Support (allows for animals to stay together and hunt or graze)

    5 vote(s)
    7.2%
  3. Mating Support (allows animal to reproduce Minecraft style to help keep populations balanced)

    5 vote(s)
    7.2%
  4. Combat Support (will include a working example system of fightable and huntable animals)

    10 vote(s)
    14.5%
  5. All of the above (they are all equally as awesome and they all need to be implemented)

    37 vote(s)
    53.6%
  1. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    Emerald AI - Dynamic Huntable Animals, Wildlife Animals, Farm Animals, NPC, Enemies, breedable animals (similar to Minecraft), and more!
    [​IMG]

    Emerald AI 2.0 (In Development)
    For more information regarding the huge Emerald 2.0 update, see the post here:
    https://forum.unity3d.com/threads/r...y-herds-npcs-more.336521/page-22#post-3181083



    Emerald AI 1.3 (Released)
    Mecanim support, custom function and 3rd party systems support (such as RFPS and UFPS), tons of new features, and many improvements with Emerald AI version 1.3! For more information regarding our newest update, see the link here: https://forum.unity3d.com/threads/r...y-herds-npcs-more.336521/page-15#post-2841047

    What's Emerald AI?
    Emerald AI is an easy to use, all in one, AI system that creates dynamically wandering animals, predator and prey, enemies, NPCs, and more. With the behavior system, you choose if the AI is a Cowardly, Passive, Hostile, or Defensive. With Emerald's easy to use Editor, it only takes about a minute to setup custom models. All AI using Emerald will have dynamically generated waypoints. These waypoints allow the AI to dynamically roam, hunt, form herd and packs, graze all within their appropriate Radii. Emerald offers 150+ customizable options allowing you to create the perfect AI to suit your game's needs.

    Version updates to the system will always be free, for those who have already purchased Emerald, but the price may increase with each new update that makes the system more advanced. So, it's best to get it early.


    The Uses
    Create living, breathing worlds by adding dynamic wildlife/NPC/Enemies with Emerald AI. The AI will roam around the worlds you create fleeing from your players as the get near, hunt other AI (Even if it's an NPC hunting an animal AI), or form dynamic herds and packs. If your player stumbles upon a predator, they will be attacked and your player may have to choose to fight or flee for their life.

    Whether it's huntable animals, wandering farm animals, background wildlife, or even enemy AI, Emerald AI can pretty much find a place in any game.

    Emerald AI supports both UFPS and RFPS character controller systems. Tutorials can be found on our Emerald AI Wiki Site.

    Buy
    Emerald AI has been accepted and is now live on the Asset Store.

    You can get it here: https://www.assetstore.unity3d.com/en/#!/content/40199

    Demo Videos
    This video demonstrates multiple AI fights using Emerald AI and RFPS. The AI are spawned using our newest system, Crux.


    This video demonstrates 1 Troll vs 3 Skeletons (each with customized stats using Emerald) to show the combat improvements made with Emerald 1.3 (submitted). Emerald AI can be used for animals, NPCs, creatures, and more. All AI dynamically fight, flee, or hunt according to customized tags.


    This video demonstrates fighting an AI created with Emerald AI using the RFPS system. Implementation is fairly simple and will be covered on the Emerald AI Wiki Site.

    Screenshots
    Character models by: Protofactor, INC
    [​IMG]
    [​IMG]
    [​IMG]
    [​IMG]
    [​IMG]
    Big thanks to Adventure Forge and their deer model (Assets Not Included).
    [​IMG]

    Emerald AI's Breeding Feature Explained

    Breeding Demonstration

    This video demonstrates Emerald 1.2's new breeding system. Most of what you see if fully customizable via the Editor. Times for breeding (5 seconds) and newborns growing to adult size (15 seconds) is set to fast for demonstration purposes. We used a style similar to Minecraft for this demonstration.

    Farm animals are put into breeding mode when the right requirements are met. This can be done in anyway and is completely customizable. Emerald will handle the rest.

    We are working on making this fully dynamic that will allow wild roaming animals to breed. This will of course be within the cap limits set within the Population System.

    Feel free to ask questions or make suggestions. We will be further tweaking and improving the system.




    Breeding Demonstration 2

    This video demonstrates the Breeding Odds that Emerald 1.2 will use. Emerald will support 4 animals that can be bred on a probability chart of Common 50%, Uncommon 30%, Rare 15%, and Super Rare 5%. Animals must be "breed compatible". This is done by having the same Breed Type. The times set in the video are set to 5 seconds for baby to adult and 5 second breed cooldown for demonstration purposes. This could be anything desirable from minutes to hours.

    These odds can be tweaked based on each animal. So, for example, if you have a rare animal born, that rare animal can be more likely to have an animal of its color, type, rarity, etc. You will be able to label 4 animals as either Common, Uncommon, Rare, or Super Rare. You will then assign the prefabs for each rarity and Emerald will handle the rest.

    This same system can be used in the wild for creating dynamic animals. These animals will also use the Breeding Odds system that can really add to games feeling dynamic.

    Breeding doesn't have to be based off rarity or it can be disabled entirely.

    The chart below shows an example of the odds system Emerald 1.2 will be using. The colors of these animals, and the rarity, are the same ones used in the video above. Feel free to ask questions or make suggestions. Feedback is always appreciated.

    Note: Colors are only used to help distinguish the differences between the rarities. These can be anything desirable from crossbreeds to the same type of animal.

    [​IMG]


    Features
    There are too many features to list everything. Emerald is capable of so much and can pretty much find a place in any game. Here are some of its features that are worth noting.

    System
    • Supports both Unity Free and Unity Pro
    • Support for more than just Animals. Emerald AI can be used for NPCs, Enemies, Creatures, and more.
    • For users who want only animals or only NPCs, we have designed Emerald with this in mind. NPC and Animals are separated using the Editor. The code from these 2 categories don't even run unless one or the other is selected. So, if your AI was set to Animal, none of the code for the NPC would be running in the script.
    • Emerald has amazing performance by utilizing Unity's LOD system. This is done by deactivating Emerald and its components when not in view. This allows Emerald to have 1,000's of AI within 1 scene at a time. AI are then activated when within view when they become unculled. This process is seamless and fast. We tested this with 1,000+ AI/Animals spread across 13 square miles and maintained 60+ frames per second.
    • Dynamic Herds and Packs. This is done dynamically by randomly generating an alpha on start. There is a 1 in 5 chance that an AI will be an alpha. If an AI that is not an alpha comes within range of an alpha, that is also the same Name Type (that is set within the Editor), and it isn't ready in a herd, it will become apart of that alpha's herd. AI within a herd will follow the alpha (in herd mode) to its generated waypoints. This can be used from animals, to enemies, to hordes of zombies.
    • AI use slope detection and rotate according to the current terrain slope. This allows there to be no hovering on steep slopes as well as resulting in much more realistic looking AI. This option can be enabled or disabled if desired. This feature is only enabled if an AI is active.
    • Behavior Types categorized as (Cowardly [will flee from appropriate tags] Passive [usable by farm animals or NPCs, allows AI to continuously wander around an area], Hostile [will attack anything with the appropriate tag on site] Defensive [will attack enemies on sight (with the tag enemy) but only attack a player, or others, if they are hit first.])
    • Predators will attack/chase Prey. This is according to Prey Size (Predators can only attack Prey that are less than or equal to in size)
    • After an AI has given up on its chase. It will return back to its starting position and continue to wander within its Wander Range. This keeps AI from going where they're not supposed to.
    • Frozen system that allows AI/animals to freeze for a randomly generated amount of time, when a predator or player comes within range. This randomly generated amount is based off of a min and max set within the editor. This is regenerated each time an AI/animal has exited its predator encounter. This allows it to seem a lot more natural with each freeze time always being different.
    • Max Herd Capacity for each AI Name Category. This is to help AI/animal herds from getting too big and dominating your artificial ecosystem.
    • Alpha replacement. If an alpha AI dies, and it is leading a herd, it will generate a new alpha within its herd to become the new alpha.
    • Turn Animation Support - We have also added support for turning animation, as requested. This feature is completely optional. Turning animations will play when an AI needs to take a turn that's sharper than ~60°. This also applies when an AI is attacking and chasing its opponent. This allows for greatly improved realism.
    • Smart Waypoint Generation for fleeing animals - Fleeing Animals and NPCs won't get stuck or generate waypoints they can't access. AI will continuously generate waypoints away from the target that is chasing them. AI will also no longer get stuck. Emerald can detect when an AI sets a waypoint that's inaccessible or will get them stuck and regenerate a new one. This also goes for wandering AI.

    Example Systems (These do not have to be used. They are simply a starting point for users who need them. Emerald can easily be integrated with custom systems, character controllers, camera systems, loot systems, and more.)
    • Custom character controller that allows collisions with AI, running, stamina system (that will only allow the player to run as long as they have stamina), and footstep sounds system. Speed, jump height, sounds, and more are all customizable.
    • A customizable player weapon damage system is included with Emerald. This system has customizable timers, distances, and delays to perfectly match any custom animations customers may have. It also uses RayCast so all attacks are properly registered which then spawns a customizable blood effect right on the hit point of attack.
    • AI receive damage by calling the Damage function. This makes it easy to implement custom forms of damage from bullets, arrows, or anything else.
    • A Player Health system is also included. We have built a custom Editor to make it easier than ever to customize the settings. These settings include customizable health, health regeneration, attack sounds, UI, and more.
    • An animal Breeding system allows users to feed animals, of similar type, to breed and spawn babies of customizable rarities (common, uncommon, rare, and super rare).
    • We include a Loot System with our system.
    • Easily integration with UFPS, Unity's FPSController, and other systems. Our wiki site covers these tutorials.

    Example Scenes
    • Animal Breeding Example – Demonstrates breedable animals, similar to MineCraft. Animals have 4 rarity types, Common, Uncommon, Rare, and Super Rare. A system is included that allows interaction with animals.
    • Defensive AI Example - Demonstrates defensive AI that will attack enemies on sight (with the tag enemy) but only attack a player, or others, if they are hit first.
    • Enemy/Hostile AI Example - Demonstrates enemy/hostile AI that will attack anything on sight with the tag Ally, Player, or prey.
    • Fleeing Example – Demonstrates fleeing AI that will run away from the player when they get near.
    • Loot Example - Demonstrates a loot system that randomly generates loot when an enemy is killed. It is then added to the player's inventory UI that is visible on screen.
    • Prey and Predator Example - Demonstrates a predator AI chasing and killing its prey.
    • AI Health Bar Example - Demonstrates displaying an AI's current health and name (UI included).

    Combat System
    • Attack sound support to play sounds when AI attack. There are no limits to how many that can be used.
    • Randomized Attack Animations (Choose from up to 6 animation clips for your AI to attack with.)
    • Customizable Attack Time that controls when an AI will give up on a chase
    • Support for Run Attack animations for those models that have it (this is an optional feature)
    • Hit animation support, if desired (this will play a hit animation when an AI is hit by a player or other AI)

    Animal Breeding
    • Emerald is the only AI system that has a built in animal breeding system
    • Emerald will support 4 possible babies that can be bred based on the customizable probability system in the Editor. By default the odds are Common 60%, Uncommon 25%, Rare 10%, and Super Rare 5%. Animals must be "breed compatible". This is done by having the same Breed Type.
    • Customizable Breed Seconds controls how long it takes for the animal to have its baby.
    • Customizable Cool Down Seconds controls how long until the animal can breed again.
    • Customiable Baby Seconds controls how long a baby will stay a baby until it's fully grown.
    • This, and so much more, is possible with Emerald AI's Breeding System.

    Code
    • Well documented code with custom wiki site with tutorials, code references, documentation, example scripts, and more for you to get the most out of Emerald.
    • Easy calling of functions like Damage(damageAmount) to damage an AI or ReturnBackToStartingPoint() for the AI to return back to its starting position. These make it easier for adding custom scripts or systems. All code and functions are covered in our Emerald Wiki Site.

    Customization
    • Easily create an AI with one button and Emerald does the rest.
    • Dynamic Waypoint Generation (Every waypoint is different every time)
    • Dynamic Grazing/Roaming (AI/Animal will graze/roam in by a waypoint for a randomly generated time based off the minimum and maximum seconds set within the Editor)
    • Option for up to 3 randomly chosen graze/idle animations which the AI will use.
    • Intelligent Fleeing (AI will flee away from the Flee Tag to avoid danger. This makes it great for huntable animals/wildlife)
    • Works with Untiy's NavMesh system (no need for other plugins or 3rd party assets)
    • Adjustable Flee Trigger Radius (AI/animals will flee if their radius is met with the Flee Trigger Tag set via the Editor)
    • Adjustable Wander Range (AI will only wander within the given radius)
    • Adjustable Flee Range (AI/animals will flee within the given amount, but keep generating waypoints if they need to escape danger)
    • Visual in-scene Ranges for all Ranges above (Useful for speeding up development and level designing)
    • Adjustable Extra Flee Seconds. This allows the AI to stay in Flee Mode, even if out of their Flee Radius, form anywhere from 0 to 10 extra seconds allow for more realistic results when an AI/animal is fleeing away from a player.
    • Easy to use but powerful Editor
    • Option to enable or disable visible Path Lines that show an AI's current path (Useful for speeding up development and level designing)
    • Option to enable or disable visible Waypoints that show an AI's current waypoint (Useful for speeding up development and level designing)
    • Customizable colors for all visual in-scene ranges
    • Animation Options makes it easy to customize and add your model's animations via name as well as animation speeds (Perfect for matching movement speeds)
    • Movement Options makes it easy to adjust Turn Speed, Walk Speed, Run Speed
    • Option to enable or disable Dust Particle Effect for when AI is fleeing
    • An entire Wiki site for Emerald AI containing tons of tutorials, documentation, code references, and more.

    Support
    • We do our best to offer the highest quality support possible. We are available via email and usually respond with questions within a few hours of receiving them, during business hours.
    • We appreciate our customers and consider them apart of the Emerald Community. We help out the community by offering our help with customized Emerald scripts. If we have spare time, we will help you implement what's needed. We write custom scripts for our customers all the time. We then add these to the Emerald AI Wiki for others to use.
    • Our Emerald AI Wiki site offers tons of tutorials, script references, example scripts, and more to help you get the most out of Emerald.
    • Detailed Emerald AI Documentation covering every component allowing and setting up for a low learning curve. This allows users to get Emerald implemented in their games and projects as fast as possible.
    • 3rd Party support for top character controller systems such as RFPS and UFPS. Tutorials can be found here: Emerald AI Tutorials


    The Editor
    Emerald features an easy to use Editor with tons of customizable options. You can adjust radiuses, speeds, behavior, animations, and more.

    bandicam 2015-06-26 16-16-04-422.png bandicam 2015-06-26 16-16-21-507.png
     
    Last edited: Aug 15, 2017 at 3:35 AM
  2. b4c5p4c3

    b4c5p4c3

    Joined:
    Jan 4, 2013
    Posts:
    524
    I'm subscribing. Seems interesting
     
  3. rosor

    rosor

    Joined:
    Nov 15, 2009
    Posts:
    2,888
    looks cool. wondering if you would add some wild predators as well that can attack the player? wolves and bears in the forest, mountains areas, lions, cheetah, hyenas in the savannah etc... I guess it might be a little bit more annoying than just animal fleeing though... anyways, Looking forward to checking out the demo scene.
     
  4. HeadTrip

    HeadTrip

    Joined:
    Apr 1, 2013
    Posts:
    418
    Wow looks very cool! Looking forward to it.
     
  5. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    We plan on adding more Behavior Types as the system progresses. Adding predators as a behavior type sounds like it could be interesting.

    Maybe we could add an Environment Type too that would some how influence the AI. We will see what we can do.


    Thanks.
     
    rosor likes this.
  6. rosor

    rosor

    Joined:
    Nov 15, 2009
    Posts:
    2,888
    another stuff that came on top of my head after reading your post wold be to have the predator AI also want to attack the fleeing one... that would be ridiculously awesome! :)
     
  7. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    Looks good. I second a predator type.
     
  8. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    That also crossed our minds. Great idea.

    We will see what we can do. This will progress over a series of updates, but I'm sure we can make it happen.


    Thanks.

    We will make it happen.
     
    Teila likes this.
  9. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    Great! I am building an awesome swamp at the moment and need something for my alligators to do. lol Can't wait to try it.
     
  10. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    A suggestion, allow to make more than one layer cause animals to flee. That way, the animals will also flee from NPCs and other animals if you tag them properly. It would be nice to have several drop down options. Also, the ability for the animal to be aggressive and not flee would be nice.
     
    rosor likes this.
  11. rosor

    rosor

    Joined:
    Nov 15, 2009
    Posts:
    2,888
    What been said above. :)
     
  12. siblingrivalry

    siblingrivalry

    Joined:
    Nov 25, 2014
    Posts:
    384
    I have been watching a few documentaries and its funny how often when the predator is chasing down its prey, if the prey is getting away from a big cat, after a big enough distance the cat will often give up knowing that it cannot succeed and just wait till next time.

    predator memory has similar function in game. Not sure how you would do it but; if the prey is X distance away and travelling at speed greater than the predator, then predator gives up the chase.
     
  13. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    A game I used to play did that....lol. Lucky for me, since I was not a combat person, when I was attacked by monsters or NPCs, I learned to run REALLY fast. I played the game for 3 years and only died twice, both times I didn't run fast enough I guess. :)

    The NPC or monster would chase me for a bit and then give up and turn around. I knew that if I ran away, I had a chance to survive. I liked that a lot. :)
     
    siblingrivalry likes this.
  14. Shawn67

    Shawn67

    Joined:
    Jan 2, 2014
    Posts:
    1,833
    You just need to have your NPCs have an agro radius and if whatever they are fighting runs out and is outside that agro radius for so long, have them return to their home point. So if the NPC is a touch slower than whatever is fleeing from it, the fleeing NPC will eventually outrun it and leave the agro radius of its pursuer. BurgZerg did something similar in their tutorial videos with player/npc combat. Worked quite well.
     
    siblingrivalry and Teila like this.
  15. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    Thanks everyone for the suggestions!

    We have refined everything that's been said and have made a nice list of things to add for the next update. While making this list, we also came up with more features. We will post an update list when we are further along with development and nearer to submitting the new update.

    A main thing we will implement is a Prey and Predator based system. This will allow users to create their own type of ecosystem. Predators will be able to chase Prey and Prey will be able to flee from Predators. We will also implement some type of customizable distance/time based system for a Predator giving up on a Prey.. This, as well as the other features we have planned, should allow for some very interesting game mechanics. There's nothing more immersive than a living breathing artificial environment.

    Please keep the suggestions coming and will be sure to take them into consideration.
     
    Last edited: Jun 29, 2015
  16. rosor

    rosor

    Joined:
    Nov 15, 2009
    Posts:
    2,888
    Is it available yet? didn't notice any links to the Asset Store. Can you place a link on the first post? Or maybe I'm missing something.

    thanks
     
  17. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    Emerald version 1.0 has been submitted, but we are still waiting for it to be approved. We will post it here when it is accepted.

    We are currently working on a new version for implementing a Predator and Prey based system, as well as many other features.
     
    hopeful and rosor like this.
  18. rosor

    rosor

    Joined:
    Nov 15, 2009
    Posts:
    2,888
  19. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    Emerald should be accepted very soon. Until then, we have made a simple video demonstration.

    This video demonstrates both Farm and Wild animals created with Emerald. All actions of the animals you see are dynamic. There is no preset waypoints. Wild animals will flee if a player enters their Flee Radius. They will then react dynamically to flee from the player so every time it's different. Farm animals will wander within their Wander Radius and dynamically graze.

    We have a lot of new features that we're going to add for the next update. This includes a Predator and Prey system. It should allow users to create their own ecosystem. Stay posted as we will post our progress and here for our next version of Emerald.

     
    John-G, AdamGoodrich and Sliceandkill like this.
  20. Sliceandkill

    Sliceandkill

    Joined:
    Dec 2, 2014
    Posts:
    89
    You can make something factions based. Like large predator, medium predator, small predator, large, medium and small prey. Large predators attack everything including player, medium predators attacks only medium and small prey, maybe even small predators and so on. Another faction can be friendly with everything (for domestic animals).
     
  21. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    Fabulous! I like it.

    Looking forward to the updates.

    I wonder though if you could put in a freeze behavior as well since often deer and rabbits freeze when someone approaches them...then they run.
     
  22. Shawn67

    Shawn67

    Joined:
    Jan 2, 2014
    Posts:
    1,833
    What kind of cost do we need to be budgeting for? :p
     
  23. AdamGoodrich

    AdamGoodrich

    Joined:
    Feb 12, 2013
    Posts:
    2,798
    I would be tempted to add some sort of needs driven thing to the animals so that they generate interesting behaviour regardless of your proximity or not.
     
    BHS and christoph_r like this.
  24. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    Thanks for the suggestion. We already had plans to implement a Predator and Prey animal type system and a category by size is perfect.


    Great idea, we can totally add this.

    It could be something that can be enabled or disabled. If enabled, you will set a minimum and maximum amount of freezing time, generating a random number between these two values, before the animal flees. If the player leaves the flee radius it could just go back to grazing.


    The starting price will be $19.99. After the update, the price will increase.


    Great idea, we will see what we can implement.
     
    Last edited: Jul 2, 2015
  25. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    Great! I can't wait. :) I love the fact that you can modify and change things to suit your game.
     
    BHS likes this.
  26. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    Yes, of course. Our goal is to create a versatile system that can find a place in, mostly, any game.
     
    Teila likes this.
  27. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    We were able to add a quick feature to Emerald before we resubmitted it. This new feature is called Extra Flee Seconds. This allows the AI to stay in Flee Mode, even if out of their Flee Radius, form anywhere from 0 to 10 extra seconds allow for more realistic results when an animal is fleeing away from a player.
     
    Last edited: Jul 2, 2015
  28. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    Fantastic! I really need this.

    I am assuming since most animals come with legacy animations that it will still work with those as well? I realize I never asked that.
     
  29. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    Yes, it supports Legacy Animations.
     
  30. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    Emerald Animal AI has been accepted and is now live on the Asset Store!

    You can get it here: https://www.assetstore.unity3d.com/en/#!/content/40199

    We appreciate all the suggestions and feedback. You can expect a lot of awesome features coming with the next update.
     
  31. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    Also, I am assuming the grazing animation can be any idle animation. Unfortunately, I will have to buy all new animals since most of my domestic animals and deer have very few animations. lol

    Unless Roser is going to update them so we can use them in your asset. ;)
     
  32. rosor

    rosor

    Joined:
    Nov 15, 2009
    Posts:
    2,888
    I assume you meant:"rosor".
    What kind of animations are you lacking? currently pretty busy with the Fantasy Bosses Pack Volume 1 and some contract work. If the animations you need might be something a lot of other developers might want, I guess it would be possible to make an update. don't hold your breath though, as there would be 24 animals to update... well maybe less if it's just the grounded animals...
    Maybe it's better to post your request on the animals dedicated thread rather than derailing this one with some side requests. Sorry @BHS, didn't mean to hijack your thread.

    Now on topic: Congrats for the release! and great job! :)
     
  33. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    Rosor, sorry about the mistaken spelling, but I was kidding since I saw you on the list. It really wasn't a request, more a comment.

    I will make a request on your thread. :)
     
  34. Shawn67

    Shawn67

    Joined:
    Jan 2, 2014
    Posts:
    1,833
    This sounds cool! Is there an option to randomize this? That way it isn't always the same time, every time? Maybe a bool where if we check to have it randomized, it will disable entry of selection of seconds but if unchecked, we can define a set amount?
     
  35. HeadTrip

    HeadTrip

    Joined:
    Apr 1, 2013
    Posts:
    418
    edit: saw your responses above...vote for predators and "attractor" tag or object assign for animals to be attracted to. thanks

    "Is there a planned follow or attract, the opposite of flee? i would love to have things follow me, or an object i toss or assign...throw food... thanks"
     
  36. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    Yes, any idle animation can be used in place of a graze animation.


    No worries and thanks.


    It isn't randomized, but we can certainly add it with the next update. We will also add a quick tutorial of how to do so to our Emerald Wiki site for those who want that feature early.


    Yes, we already have the base Predator and Prey system working with the version we are developing now. It's pretty cool.

    We can add some kind of command type features in the near feature. Right now we are focused on getting the Predator and Prey system finished and submitted.
     
    Last edited: Jul 3, 2015
    Shawn67 likes this.
  37. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    Oh good. I really want the fox to chase my chickens. :)
     
  38. Shawn67

    Shawn67

    Joined:
    Jan 2, 2014
    Posts:
    1,833
    Awesome! Any chance there are or you plan to have any herding/flocking type mechanics? It looks like some of the functionality here might conflict with HerdSim or other herding/flocking type scripts. Would be nice to have all of that AI functionality in a single asset... :)
     
  39. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    Yes, the Predator and Prey system is pretty cool and entertaining so far.

    Right now, we have Predators chasing Prey based off their size, if within their Hunt Radius. So we have wolfs set Large Predators who will hunt Deer Large Prey. We will were thinking of adding some type of odds/desire factor. This instance would be, what if a wolf is chasing a rabbit (small prey) and they see a deer in the distance. Are they going to continue chasing the rabbit, which might be easy food, or go after the deer because it's more food. We want some type of system to work this out so it's something we're considering of adding to the system.


    I think this is a good idea and it's something we will work in.

    Right now, we're considering some type of pack system is well. This would be for animals like wolfs, who tent to hunt in packs. They can then find prey together and more efficiently kill them. We need some type of cap though to prevent them from killing everything in a level. This would most likely be a cap of 4 to 6 per pack and only a certain amount of kills within a certain amount of time.
     
    Teila likes this.
  40. Shawn67

    Shawn67

    Joined:
    Jan 2, 2014
    Posts:
    1,833
    Please make the pack/herd sizes configurable and not hard capped in the code. I think the cap is a good idea, but also like the idea of a pack of predators growing in the zone and having events triggered calling for player help to eradicate the threat. Not sure of API functionality you are building into the system, but maybe this could be something that could be controlled via API.. If the predator population is low, more grazers populate the area but at a certain point a high quantity of grazer herds would attract packs of predators. Once the predators are in the zone, they begin discovering farms. Local magistrate posts bounties for predator hides.. As predator population dwindles, grazer population grows.. Rinse and repeat.. For this idea, I'd need the ability for the scenario that you described as not wanting to happen, to actually happen... heheh

    Edited to add: Kills per time frame configurable as well, please... :)
     
  41. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    Not only that, Shawn, but if you want to use the pack for a herd of sheep then you would definitely want more than 6 sheep. I recommend giving us a slider and letting us take the risk of depleting our rabbits. :)

    We can always set spawners to spawn more rabbits if need be, they do populate rather fast.
     
  42. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    Yes, everything will be configurable.

    Our goal is to have the most versatile system as possible. All herd/pack caps will be adjustable as sliders, as well as kills per time frame.

    The population idea is great. We will see what we can do.

    One way to help with population levels is to possibly allow for some type of mating system that could be similar to Minecraft's mating system. If population levels of a particular animal type are low than this feature could be enabled. It could be done where their animal type, which could be a String, would have to match an animal that's within their radius.


    Yes, this all should allow for interesting gameplay/scenarios.
     
  43. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    Now that would be amazing!! :) I love it. My son and and I (he happens to my college student programmer and my son) and were just discussing this and thinking about how mating could be coded. If you do it for us, it will save us a lot of time. :) My son might be disappointed but I have plenty of jobs for him.
     
  44. Shawn67

    Shawn67

    Joined:
    Jan 2, 2014
    Posts:
    1,833
    That would ROCK! My thoughts for the scenario I described above were to use this system in conjunction with the dynamic quest generator that @TonyLi is currently developing. If Emerald were to keep track of animal populations like you described and Tony's quest system could hook in via API to look at the numbers and determine the magistrate has an issue with a growing wolf population, it would generate a quest for wolf hide bounties.. Or something like that. Purely speculation since Tony is still developing that system, but that is what I'm hoping for... That and maybe even some similar conservation type quests to help promote growth of the species the wolves are depleting...
     
    twobob and Teila like this.
  45. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    6,793
    Good idea! The quest system provides hooks for external knowledge sources. I've made a note to look into Emerald AI. If it can report the population size in an area, you'll be able to access that information in procedurally-generated quests.
     
    twobob, BHS, Teila and 1 other person like this.
  46. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    All this looks so good but I do have one big request. Some of my animals have turn animations and I would love to use them but we need more than the 6 animation slots available. Any chance you could allow us to add our own animation slots? Maybe a way to specify the number of animations and increase slots available like in other Unity assets I have used. That way we can put it more animations for other things as well.

    BTW, my son informed me that it would have to be coded that the animal detects the turn to use the turn animation. Not sure if that is something that can be added..but figured I would ask anyway. lol

    Thanks.
     
  47. Shawn67

    Shawn67

    Joined:
    Jan 2, 2014
    Posts:
    1,833
    Any chance for a setting that would have the fleeing animal wander back to its home area after not being scared for a set amount of time?

    Edited to add: Is it possible to add criteria to ensure animals don't wander into the ocean or into altitudes they wouldn't be? Also would love to see avoidance area triggers that could be placed around high population areas where whiled animals would probably never wander.

    Also seems to be some issues with NavMesh.. Seems instead of avoiding steep areas, animals get stuck and are unable to move up or down. Shouldn't they be moving around these areas? Was talking with another dev team and they are having similar issues.
     
    Last edited: Jul 3, 2015
  48. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    2,857
    While trying to test the system as much as we can, we have designed a simple tool to procedurally spawn an array of animals throughout a terrain. It will spawn them based on your terrains height and a specified X and Y amounts.

    This lead to some interesting and natural feeling gameplay. One of our test terrains is 13 square miles. We spawned a total of 120 animals (30 rabbits, 30 foxes, 30 deer, and 30 wolfs.) During one test, I walked through the 13 sq mile terrain for about 15 minutes and saw 4 or 5 rabbits, 0 deer, 2 foxes, and 2 wolfs. What was interesting about this was that the deer have the highest Flee Radius which makes them more illusive. One of the wolfs I saw was chasing something. However, the forest was too dense to see what it was chasing. This all was created in one generation that took about 10 seconds to setup and about 2 seconds to generate rather than hand placing each animal, which I imagine would take hours and wouldn't have had as realistic results. With this spawn generation system, maybe we can further adapt this to allow for some type of herd/pack generation as well.

    If this is something you guys would want included, just let us know.


    Support for turning animations is something we will look into to see if we can add. We will also add support for more animations slots.


    Great idea. We will be sure to create some system that tracks populations and many other factors/numbers.


    Awesome, sounds great. We will be sure to add support for tracking population and tracking populations in certain areas.


    On start, the AI store their starting position. We will add an option for whether or not to travel back to their starting areas if they have traveled too far away from their spawn position.

    That's strange, the AI shouldn't try to walk where the angle is too steep. We didn't notice any animals getting stuck in our tests. We will look into this to see if we can recreate the issue. If we find it, I'm sure we can find a solution.

    We can also do some type of angle detection using some type of raycast or terrain steepness detection, that can be adjusted via the Editor. If the steepness is greater than the max steepness the animal can walk up, it will generate a new waypoint.
     
    hopeful and Shawn67 like this.
  49. Teila

    Teila

    Joined:
    Jan 13, 2013
    Posts:
    5,758
    We had some animals getting stuck too, usually when there was a hill between them and another flat area on the other side.

    Will the flee feature be added to the asset, so the deer and rabbits freeze before fleeing? I remember mentioning this but can't recall seeing it on your later lists. I fear that without it, our archers will have very little chance of catching the little buggers. :)

    Looking great, by the way. We are having fun playing with that and along side Herdsim, it is a great addition.

    One thing to warn people, make sure the animals are legacy. More and more newer animal assets are using mechanim and they do not always tell you this before you buy. :)
     
    hopeful likes this.
  50. Shawn67

    Shawn67

    Joined:
    Jan 2, 2014
    Posts:
    1,833
    DEFINITELY!!!! Maybe you could also have this contain a spawn button in the editor. That way if a dev would like to just pre-spawn and then tweak placements, they can do it instead of individually placing each animal. Then for the devs that just want to let it pop all the animals at runtime, they would have that option as well.

    Woohoo!!! Thanks, to both of you! I can't wait to see what kind of cool stuff I'll be able to do with a combination of both assets! :)

    Awesome! Could we add minimum and maximum terrain height as well? That way mammals don't flee into the ocean where they roam underwater? :p And the higher altitudes can be reserved for mountain goats and other animals more adapt for the higher elevations... :)

    On a side note, I totally love the way this is coming together and the prospects of what can be done with it. Is there a chance that other behavior types will be added for birds and fish to turn this into a complete animal AI system for any type of animal?