Search Unity

[RELEASED] Emerald AI 3.2 (New Sound Detection) - The Ultimate Universal AAA Quality AI Solution

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

  1. Darrkbeast

    Darrkbeast

    Joined:
    Mar 26, 2013
    Posts:
    125
    Hi, I did have to change one thing in your OpsiveBridge.script to get to work. Line 22 I changed to originator.gameObject.transform);

    it was this.gameObject which made my ai target itself since the script is on it. At first I didn't notice as I let the ai target me first which made me default target, but if you attack it first it was attacking itself, quite funny but not what I needed.
     
  2. magique

    magique

    Joined:
    May 2, 2014
    Posts:
    4,030
    Very strange. I just turned on the debug statement on mine and it correctly reports that my player was the source of the attack and it indeed damages the AI and it dies. Are you sure you have the OpsiveBridge on the AI component?
     
  3. tredpro

    tredpro

    Joined:
    Nov 18, 2013
    Posts:
    515

    If you can share everything when you have it ready, I personally use forge so I could see if i can get it working with that. Same with crux and unistorm too
     
  4. Darrkbeast

    Darrkbeast

    Joined:
    Mar 26, 2013
    Posts:
    125
    Yeah its on them. I had the debug on to for the AI controller and it was showing itself, when I changed it showed the Player. It was when I had the ai set to line of sight and hit it from behind. If the ai saw me it was fine.
     
  5. Mlackey

    Mlackey

    Joined:
    Dec 5, 2014
    Posts:
    41
    Started a fresh project to test Emerald AI 2.2, the documentation for Ootii integration is not supportive for 2.2 (threw errors for me on the version 2.1 and not even applicable for 2.2).

    Will we see an update for the integration of Emerald AI 2.2 with Ootii?
     
  6. AndyNeoman

    AndyNeoman

    Joined:
    Sep 28, 2014
    Posts:
    938
    Excellent, thanks @BHS. One quick question. I have a trigger collider on my player that is quite large. Can I omit it from emeralds use of colliders because the animals are attacking at a long range because of it?

    I'm also getting a lot of errors after importing 2.2 DO I need to do anything different to setup?

    Assets/Emerald AI 2.0/Scripts/System/Emerald_AI.cs(747,4): error CS0246: The type or namespace name `EmeraldHealthBar' could not be found. Are you missing an assembly reference?

    Assets/Emerald AI 2.0/Scripts/System/Emerald_AI.cs(747,4): error CS0246: The type or namespace name `EmeraldHealthBar' could not be found. Are you missing an assembly reference?


    Assets/Emerald AI 2.0/Scripts/System/Emerald_AI.cs(831,22): error CS0246: The type or namespace name `CombatTextAnimator' could not be found. Are you missing `EmeraldAI.Utility' using directive?
     
    Last edited: Feb 22, 2019
  7. combatsheep

    combatsheep

    Joined:
    Jan 30, 2015
    Posts:
    133
    Thank you, BHS!
    I'll try it later.

    By the way, I am looking forward to try v 2.2.
    Do I need to remove the all of v2.0 from current project before updating to v2.2?
     
  8. gearedgeek

    gearedgeek

    Joined:
    Jun 19, 2015
    Posts:
    236
    @BHS I'm getting this error now with Emerald 2.2 and Core GameKit. I'm using Core GameKit to spawn the enemies into the level so these errors are from the inactive prefabs of the enemies. The health bars are working.

    Code (csharp):
    1.  
    2. NullReferenceException: Object reference not set to an instance of an object
    3. EmeraldAI.Utility.EmeraldAIHealthBar.OnDisable () (at Assets/Emerald AI/Scripts/UI/EmeraldAIHealthBar.cs:79)
    4. UnityEngine.GameObject:SetActive()
    5. DarkTonic.CoreGameKit.SpawnUtility:SetActive(GameObject, Boolean) (at Assets/Plugins/DarkTonic/CoreGameKit/Scripts/Utility/SpawnUtility.cs:137)
    6. DarkTonic.CoreGameKit.PoolBoss:InstantiateForPool(Transform, Int32) (at Assets/Plugins/DarkTonic/CoreGameKit/Scripts/PoolBoss/PoolBoss.cs:283)
    7. DarkTonic.CoreGameKit.PoolBoss:CreatePoolItemClones(PoolBossItem, Boolean) (at Assets/Plugins/DarkTonic/CoreGameKit/Scripts/PoolBoss/PoolBoss.cs:400)
    8. DarkTonic.CoreGameKit.PoolBoss:ContinueInit() (at Assets/Plugins/DarkTonic/CoreGameKit/Scripts/PoolBoss/PoolBoss.cs:227)
    9. DarkTonic.CoreGameKit.PoolBoss:Initialize() (at Assets/Plugins/DarkTonic/CoreGameKit/Scripts/PoolBoss/PoolBoss.cs:198)
    10. DarkTonic.CoreGameKit.PoolBoss:Awake() (at Assets/Plugins/DarkTonic/CoreGameKit/Scripts/PoolBoss/PoolBoss.cs:136)
    11.  
     
  9. magique

    magique

    Joined:
    May 2, 2014
    Posts:
    4,030
    I wonder if it has to do with line of sight. I'll have to test that.

    [EDIT]
    I tried line of sight and it definitely is a bit different. I can still attack and kill the AI and it even says that the player was the source, but the AI won't fight back. Changing to originator fixes that. Good catch. I'll update the docs and upload later today.

    [EDIT 2]
    Updated docs.


    https://opsive.com/forum/index.php?attachments/opsive_v2_emeraldai_intgration-pdf.891/
     
    Last edited: Feb 22, 2019
  10. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,764
    I will work on getting some of the Integration Tutorials updated today. I'm not entirely sure how integration would work with another AI system, such as Invector's AI asset as they are both completely different. However, I can look into it after everything has been updated to version 2.2.


    Yes, I will be doing a tutorial to cover this after all the documentation has been updated, but I can give you a brief explanation on how it was accomplished.

    To update the AI's current its destination or "work area", you would call the function below. This will allow the AI to travel to this new destination and dynamically wander. This could be altered for each time of day using your time system.
    Code (CSharp):
    1. YourEmeraldComponent.EmeraldEventsManagerComponent.SetDynamicWanderPosition(Transform Destination)
    You can also change its Wander Type to be static if you would like them to stay stationary.
    Code (CSharp):
    1. YourEmeraldComponent.EmeraldEventsManagerComponent.ChangeWanderType(EmeraldAISystem.WanderType NewWanderType)
    2. YourEmeraldComponent.EmeraldEventsManagerComponent.SetDestination(Transform Destination)

    This allows you to override the idle animation to play that is played to ensure it is the AI's work animation.
    Code (CSharp):
    1. YourEmeraldComponent.EmeraldEventsManagerComponent.OverrideIdleAnimation(int IdleIndex)
    For the picking berries part, the AI had a series of objects that were enabled and disabled using EnableItem and Disabletem Animation Events. These items were attached to the AI object as children. The items need to be assigned through your AI's Items List. This can be found under AI's Settings>Items.
    Code (CSharp):
    1. YourEmeraldComponent.EmeraldEventsManagerComponent.EnableItem(int ItemID)
    2. YourEmeraldComponent.EmeraldEventsManagerComponent.Disabletem(int ItemID)

    I'll look into this once I've updated all of the documentation.


    Those are examples of what can be created. A list of all assets used can be found in the video's description.


    I'm still working on updating the integration tutorials and will have them updated within the next couple of days.


    Exclude the Layer of the object that the AI are getting instead of your player.

    It sounds like you may have updated Emerald AI without removing the previous version, is this correct? It seems like the UI scripts are not using the new EmeraldAI namespace. You need to completely remove Emerald AI from your project before updating.


    Thanks for the error report. I'll look into this.
     
  11. Mlackey

    Mlackey

    Joined:
    Dec 5, 2014
    Posts:
    41
    When I upgraded, it threw an error. It seems certain classes have been removed and reworked into a single class. It does appear that you will need to remove Version 2.0 for Version 2.2 as I had errors when upgrading from it.
     
    combatsheep likes this.
  12. SickaGames1

    SickaGames1

    Joined:
    Jan 15, 2018
    Posts:
    1,270
    @BHS uRPG is pretty slick system and I think Emerald could make it even better!
     
    Last edited: Feb 22, 2019
  13. Matro

    Matro

    Joined:
    Mar 15, 2013
    Posts:
    38
    Do you have to remove the previous version to upgrade to 2.2?
     
  14. magique

    magique

    Joined:
    May 2, 2014
    Posts:
    4,030
    Yes, you do. It's a complete re-write. The classes are all different.
     
    AndyNeoman likes this.
  15. Matro

    Matro

    Joined:
    Mar 15, 2013
    Posts:
    38
    Thanks will do can't wait to get the new system working. I do have another question, I have a stationary npc a chicken in a henhouse that does not use a navmesh and it just falls through the collider to the ground.
     
  16. magique

    magique

    Joined:
    May 2, 2014
    Posts:
    4,030
    Falls through the henhouse collider? If so, check your Layer settings for the Henhouse and the chicken and then check the Physics settings to see if those layers are checked to collide with each other.
     
  17. AndyNeoman

    AndyNeoman

    Joined:
    Sep 28, 2014
    Posts:
    938
    This will probably explain my errors thanks.
     
  18. IsntCo

    IsntCo

    Joined:
    Apr 12, 2014
    Posts:
    146
    Look forward to getting this!

    I also second adding a 'switch to Melee from Ranged if the player is close'

    Does the integration for Ootii need updating?
    (Edit: Looks like another user above said Ootii is broken with version 2.2?)

    Also, I could just be missing it, but I don't see any examples in /Scenes specifically of new features from 2.2. Is that coming, or am I mistaken? Based on the documentation, it looks like a lot of the example scenes were removed (Pet, Combat Text, Fleeing, Health Bar, etc.) - unless it was all merged into other samples?
     
    Last edited: Feb 22, 2019
  19. Matro

    Matro

    Joined:
    Mar 15, 2013
    Posts:
    38
    Getting the following error when I run the game only one npc.

    NullReferenceException
    UnityEngine.AnimationClip.get_events () (at C:/buildslave/unity/build/artifacts/generated/bindings_old/common/Animation/AnimationsBindings.gen.cs:154)
    EmeraldAI.Utility.EmeraldAIInitializer.CheckAnimationEvents () (at Assets/Emerald AI/Scripts/Components/EmeraldAIInitializer.cs:734)
    EmeraldAI.Utility.EmeraldAIInitializer.Initialize () (at Assets/Emerald AI/Scripts/Components/EmeraldAIInitializer.cs:29)
    EmeraldAI.EmeraldAISystem.Awake () (at Assets/Emerald AI/Scripts/System/EmeraldAISystem.cs:776)
     
  20. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,764
    Any surface that your AI will be on need to have NavMesh. If the henhouse’s entrance is too small for NavMesh to be properly baked, you can create dummy objects to be baked and disable them when the baking is finished.


    Yes, I’m currently working on updating the integration tutorials. It will be a couple of days before they’re all updated.

    I will be adding more demo scene with the next update.


    This error is happening because you missed an empty animation slot somewhere on your AI. You need to have an animation applied to every slot that’s enabled.
     
  21. Matro

    Matro

    Joined:
    Mar 15, 2013
    Posts:
    38
    Yep found it, thanks
     
  22. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,764
    For whoever is needing help, I’ve created a tutorial video for setting up an AI.



    If you’re needing help with creating attack Animation Events, there’s a tutorial here:


    I’ve also created an Emerald AI Tutorial Playlist that will have all of the Emerald AI Tutorial videos that I will be making. This can be found here: https://www.youtube.com/playlist?list=PLlyiPBj7FznY7q4bdDQgGYgUByYpeCe07
     
  23. SickaGames1

    SickaGames1

    Joined:
    Jan 15, 2018
    Posts:
    1,270
    @BHS i have been selling you on the uRPG forum about a possible integration!
     
  24. Matro

    Matro

    Joined:
    Mar 15, 2013
    Posts:
    38
    Wow Root Motion no need to use Navmesh, thank you. I am not a big fan of navmesh.
     
  25. SuperSal

    SuperSal

    Joined:
    Jan 23, 2018
    Posts:
    5
    @BHS Hey..one more thing is possible with Emerald AI that upon getting seen by the enemy the game will be over?
     
  26. Matro

    Matro

    Joined:
    Mar 15, 2013
    Posts:
    38
    Ok so I know Emerald needs a navmesh and agent and I am using root motion and getting the following error.

    "CalculatePolygonPath" can only be called on an active agent that has been placed on a NavMesh.
    UnityEngine.AI.NavMeshAgent:CalculatePath(Vector3, NavMeshPath)
    EmeraldAI.Utility.EmeraldAIInitializer:SetupNavMeshAgent() (at Assets/Emerald AI/Scripts/Components/EmeraldAIInitializer.cs:322)
    EmeraldAI.Utility.EmeraldAIInitializer:Initialize() (at Assets/Emerald AI/Scripts/Components/EmeraldAIInitializer.cs:20)
    EmeraldAI.EmeraldAISystem:Awake() (at Assets/Emerald AI/Scripts/System/EmeraldAISystem.cs:776)
     
  27. BHS

    BHS

    Joined:
    Dec 21, 2009
    Posts:
    4,764
    Thanks! I’ll reach out to the developer to see if we can get things integrated.


    You could use an On Start Combat Event to trigger some custom code, such as a game over.


    This error typically only happens when there’s no NavMesh or the AI is placed too high or too low from the NavMesh.
     
  28. SickaGames1

    SickaGames1

    Joined:
    Jan 15, 2018
    Posts:
    1,270
    @TonyLi might be a good resource as well.
     
  29. Mad_Mark

    Mad_Mark

    Joined:
    Oct 30, 2014
    Posts:
    484
    OK. I have installed Emerald22 into a clean project, and brought in all of my 200 characters, including the Emerald20 prefabs. Each of the characters need EmeraldAI on them. I have deleted the old scripts from the root objects. They still contain the Rigidbody, Navmesh,, AudioSource,,Animator (with reference to Emerald2 Controller) and collider box. I need to generate new animator controllers obviously as they are way different.

    Is there a faster way to do this rather than one at a time? They all share the same animations (well, groups of ten do) and audio clips. Is there a way to setup one and copy/paste the script on to a group of models? Will doing so cause any issues?

    If I have to create unique controllers for each one, and add all the audio clips, and then test each one, I will be another two weeks just setting them up. If there are shortcuts, I could be done by Wednesday!

    Mark
     
  30. Mad_Mark

    Mad_Mark

    Joined:
    Oct 30, 2014
    Posts:
    484
    My prefabs now have no EmeraldAI script or other components on them. I copy the prefab into the scene, and when I try to add the Emerald AI using the Setup Manager, I get this error:
    ArgumentException: UnpackPrefabInstance must be called with a Prefab instance.
    UnityEditor.PrefabUtility.UnpackPrefabInstance (UnityEngine.GameObject instanceRoot, UnityEditor.PrefabUnpackMode unpackMode, UnityEditor.InteractionMode action) (at C:/buildslave/unity/build/Editor/Mono/Prefabs/PrefabUtility.cs:1526)
    EmeraldAI.Utility.EmeraldAISetupManager.OnGUI () (at Assets/Emerald AI/Scripts/Editor/EmeraldAISetupManager.cs:155)
    System.Reflection.MonoMethod.Invoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at <d7ac571ca2d04b2f981d0d886fa067cf>:0)
    Rethrow as TargetInvocationException: Exception has been thrown by the target of an invocation.
    System.Reflection.MonoMethod.Invoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at <d7ac571ca2d04b2f981d0d886fa067cf>:0)
    System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) (at <d7ac571ca2d04b2f981d0d886fa067cf>:0)
    UnityEditor.HostView.Invoke (System.String methodName, System.Object obj) (at C:/buildslave/unity/build/Editor/Mono/HostView.cs:342)
    UnityEditor.HostView.Invoke (System.String methodName) (at C:/buildslave/unity/build/Editor/Mono/HostView.cs:336)
    UnityEditor.HostView.InvokeOnGUI (UnityEngine.Rect onGUIPosition, UnityEngine.Rect viewRect) (at C:/buildslave/unity/build/Editor/Mono/HostView.cs:310)
    UnityEditor.DockArea.DrawView (UnityEngine.Rect viewRect, UnityEngine.Rect dockAreaRect, System.Boolean customBorder, System.Boolean floatingWindow, System.Boolean isBottomTab) (at C:/buildslave/unity/build/Editor/Mono/GUI/DockArea.cs:361)
    UnityEditor.DockArea.OldOnGUI () (at C:/buildslave/unity/build/Editor/Mono/GUI/DockArea.cs:320)
    UnityEngine.Experimental.UIElements.IMGUIContainer.DoOnGUI (UnityEngine.Event evt, UnityEngine.Matrix4x4 worldTransform, UnityEngine.Rect clippingRect, System.Boolean isComputingLayout) (at C:/buildslave/unity/build/Modules/UIElements/IMGUIContainer.cs:266)
    UnityEngine.Experimental.UIElements.IMGUIContainer.HandleIMGUIEvent (UnityEngine.Event e, UnityEngine.Matrix4x4 worldTransform, UnityEngine.Rect clippingRect) (at C:/buildslave/unity/build/Modules/UIElements/IMGUIContainer.cs:438)
    UnityEngine.Experimental.UIElements.IMGUIContainer.HandleIMGUIEvent (UnityEngine.Event e) (at C:/buildslave/unity/build/Modules/UIElements/IMGUIContainer.cs:421)
    UnityEngine.Experimental.UIElements.IMGUIContainer.HandleEvent (UnityEngine.Experimental.UIElements.EventBase evt) (at C:/buildslave/unity/build/Modules/UIElements/IMGUIContainer.cs:401)
    UnityEngine.Experimental.UIElements.EventDispatcher.ProcessEvent (UnityEngine.Experimental.UIElements.EventBase evt, UnityEngine.Experimental.UIElements.IPanel panel) (at C:/buildslave/unity/build/Modules/UIElements/EventDispatcher.cs:511)
    UnityEngine.Experimental.UIElements.EventDispatcher.Dispatch (UnityEngine.Experimental.UIElements.EventBase evt, UnityEngine.Experimental.UIElements.IPanel panel, UnityEngine.Experimental.UIElements.DispatchMode dispatchMode) (at C:/buildslave/unity/build/Modules/UIElements/EventDispatcher.cs:307)
    UnityEngine.Experimental.UIElements.BaseVisualElementPanel.SendEvent (UnityEngine.Experimental.UIElements.EventBase e, UnityEngine.Experimental.UIElements.DispatchMode dispatchMode) (at C:/buildslave/unity/build/Modules/UIElements/Panel.cs:176)
    UnityEngine.Experimental.UIElements.UIElementsUtility.DoDispatch (UnityEngine.Experimental.UIElements.BaseVisualElementPanel panel) (at C:/buildslave/unity/build/Modules/UIElements/UIElementsUtility.cs:245)
    UnityEngine.Experimental.UIElements.UIElementsUtility.ProcessEvent (System.Int32 instanceID, System.IntPtr nativeEventPtr) (at C:/buildslave/unity/build/Modules/UIElements/UIElementsUtility.cs:68)
    UnityEngine.GUIUtility.ProcessEvent (System.Int32 instanceID, System.IntPtr nativeEventPtr) (at C:/buildslave/unity/build/Modules/IMGUI/GUIUtility.cs:179)

    Something to do with the new prefab system?
    Mark
     
  31. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,702
    @BHS - If you decide to look into uRPG integration, feel free to PM me. I had to get familiar with the code base to add Dialogue System integration to uRPG.

    I'm also working on updating the Dialogue System's Emerald AI integration, which I hope to get into the next Dialogue System update. (And same for Quest Machine.)
     
    SammmZ, Mark_01 and uberwiggett like this.
  32. Matro

    Matro

    Joined:
    Mar 15, 2013
    Posts:
    38
    Ahh that seems about right as I was trying to place the AI too high above the nav mesh, thanks again.
     
  33. marco-maceratesi

    marco-maceratesi

    Joined:
    Sep 20, 2013
    Posts:
    13
    @BHS -
    Hello,
    first of all congratulation on your amazing update!
    I think there is also to document the settings of the animator component, I try to explain why:
    I have encountered a problem with the default settings of the Emerald AI Wizard sets to the Animator component (see photo below).

    upload_2019-2-24_9-41-40.png

    The problem lies in the new type of motion (Root motion):
    In the Unity editor everything works perfectly, but when I compile the project and run it the speed of my characters (NPC) are very slow (as if they slipped on the surface of the ground).
    After trying to change the speed of the Navmesh agent nothing has changed, but after modifying the Update Mode parameter of the animator component from "Normal" to "Animate Physics" the problem seems to have disappeared.

    upload_2019-2-24_9-25-32.png

    Now the question is whether this is the correct solution...

    Sorry for my bad English
    :)
     

    Attached Files:

  34. RonnyDance

    RonnyDance

    Joined:
    Aug 17, 2015
    Posts:
    557
    @BHS
    Wrote you a PM regarding possible questions and features of Combat Hit / Hit Effect feature.
     
  35. Shadow-X6

    Shadow-X6

    Joined:
    Apr 29, 2016
    Posts:
    108
  36. uberwiggett

    uberwiggett

    Joined:
    Jun 26, 2015
    Posts:
    105
    This is 100% why I love to support both developer's assets. Emerald AI 2.0, UniStorm 3, Dialogue for unity, Love/hate and Quest machine all integrated for me to create a living breathing world of NPCs. If I ever get around to starting that project :p
     
    BHS, AndyNeoman and SickaGames1 like this.
  37. SuperSal

    SuperSal

    Joined:
    Jan 23, 2018
    Posts:
    5
    @BHS One more thing, can you provide me a visual guide to create buttons to companions to stop or follow? Cheers

    Edit: Can I apply sounds to enemy with Emerald AI? Like when they idle, attacking, patrolling etc
     
    Last edited: Feb 24, 2019
  38. Pauloxande

    Pauloxande

    Joined:
    Feb 8, 2014
    Posts:
    110
    The new update make the integration stop the enemy actions, don1t attack anymore
    Do you now how to fix this
     
  39. Mad_Mark

    Mad_Mark

    Joined:
    Oct 30, 2014
    Posts:
    484
    Just a hunch, as I had a problem with idle animations not being set. Check your animator controller and double click on the attack state. It should open up a state machine that has 3 attack states. Click on one and the inspector should list what attack animation is set there. If it is none, drag and drop your desired anim in each one. Doesn't fix the setup wizard issue, but should get you up and running I hope.

    Mark
     
    Pauloxande likes this.
  40. SuperSal

    SuperSal

    Joined:
    Jan 23, 2018
    Posts:
    5
    @BHS Also..if I create long grass and my player is hidden in it, will the patrolling enemy be able to detect our character?
     
  41. huntersteeger

    huntersteeger

    Joined:
    Dec 27, 2017
    Posts:
    19
    2.2 is awesome! I've played around with it a lot now I'm wondering does RFPSP integration still works on 2.2
     
  42. pccross

    pccross

    Joined:
    Jun 20, 2015
    Posts:
    106
    So, I had a enemy AI character working reasonably well in my game with version 2.0.
    I switched to new 2.2 version today (completely removing previous version), and seeing some odd behavior. This is a VR game just for context.
    So on initial enemy AI attack of my FPS VR character, the enemy comes within correct range and initiates attack on player. However, if player moves sufficiently far away from enemy, the enemy doesn't appear to recognize player movement, but continues with original attack (initiating damage with axe, etc) from a very far distance.
    If the player bends over (lowering their head), the enemy AI seems to recognize new player position and moves correctly closer to initiate attack.
    Anyone seeing this type of behavior?
     
  43. Mad_Mark

    Mad_Mark

    Joined:
    Oct 30, 2014
    Posts:
    484
    I sure could use some advice regarding applying EmeraldAI 2_2 to prefabs. Is there a reference being made outside of the editor to the animator controller?

    1) If I copy the naked prefab into the scene and run it through the setup manager, it turns the prefab grey and it no longer appears to have a connection to the original prefab. Is that intended?

    2) If I setup a bouncer, copy the new grey prefab over the old one, it is fine. When I copy the EmeraldAI System script from bouncer1 onto bouncer2, he is stuck in idle1, and I get null reference errors. Even after setting the head transform.

    3) If I duplicate the animator controller and assign it to bouncer2's animator, nothing changes.

    WTF? Do I _REALLY_ need to run each and every character through the setup wizard from a raw imported FBX? C'mon...

    There has got to be a better workflow!!
    Mark
     
  44. Mad_Mark

    Mad_Mark

    Joined:
    Oct 30, 2014
    Posts:
    484
    @BHS If a character already has an animator controller on it, why does Emerald not identify it, and read in the-animations? -=[FEATURE REQUEST]=-
     
  45. Oderus_Urungus

    Oderus_Urungus

    Joined:
    Jun 8, 2017
    Posts:
    96
    View attachment 379066

    Just updated to version 2.2 and I am having these errors thrown concerning RFPS. I deleted version 2.0 before downloading 2.2, and deleted all of my prefabs that were using 2.0. Screenshot (283).png
     
  46. julianr

    julianr

    Joined:
    Jun 5, 2014
    Posts:
    1,212
    Open up an Emerald AI 2.2 script and see if the namespace name has changed. Then change it on your RFPS references that are causing issues.
     
  47. Oderus_Urungus

    Oderus_Urungus

    Joined:
    Jun 8, 2017
    Posts:
    96
    Didn't work.
     
  48. Oderus_Urungus

    Oderus_Urungus

    Joined:
    Jun 8, 2017
    Posts:
    96
    The namespace is now EmeraldAI, instead of Emerald_AI.

    I changed the lines in RFPS, but it did not work.
     
  49. RonnyDance

    RonnyDance

    Joined:
    Aug 17, 2015
    Posts:
    557
    As I understood you will have to add Emarald AI for the first time on a prefab with the wizard. After that you can simply duplicate or copy the Ai or this prefab (creature) from one scene to another or simply duplicate it in your scene. The changes are taking place per scene level and not on general prefab level. So you can't just take the whole prefab which is stored in a creature folder in your projekt and copy it to diffrent scene with Emeraild AI in it. Anyway good question and BHS should clarify the right approach for it.

    How should this work automatically? Your Animators come with different Animations which can all have different names and transitions. Beside that you could have an animator with 10 attack animations, 5 idle animations etc. but EmeraldAI only supports 3 attack animations and so on. How should Emerald AI know which animations to take and how?

    I don't see such a feature in the future because it's not trivial and every Animation Controller can be totally different using different names, animations, transitions etc. Perhaps a small importer in a wizard step which ask you "Hey I found 5 possible attack animations which one should I take?" and you can add them through checkboxes. But I don't see a way to make this work completely automatically.

    Cheers
    Ronny
     
    Last edited: Feb 25, 2019
    TeagansDad likes this.
  50. AndyNeoman

    AndyNeoman

    Joined:
    Sep 28, 2014
    Posts:
    938
    Any links for the docs regarding adding sound? I presume it is similar to adding animation events for damage but docs are awaiting update.