Search Unity

[Released] Deathmatch AI Kit

Discussion in 'Assets and Asset Store' started by opsive, Aug 24, 2016.

  1. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    Make sure you are running the latest version of both Behavior Designer and Third Person Controller. Based on those errors it looks like an old third person version.
     
  2. Dennis59

    Dennis59

    Joined:
    Jan 8, 2013
    Posts:
    66
    Justin, thanks for the suggestion. I verified that the latest versions were used. It turned out to be a conflict between the Item class in the Opsive packages and the Item struct in uMMORPG. Using Opsive.ThirdPersonController.Item instead of Item fixed that. Same basic problem for the error on Constants but with a different package.
     
  3. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    Ah, that makes sense. Any class that is in the global namespace can cause problems - if you could suggest to the uMMORPG dev to place everything in a namespace that would prevent you from needing to modify things for future updates.
     
  4. tauceti38

    tauceti38

    Joined:
    Sep 20, 2013
    Posts:
    15
    Downloaded the AI DeathMatch Spark demo scene but getting these errors...seems like the bots see me but will not attack me. Any ideas?



    NullReferenceException: Object reference not set to an instance of an object
    Opsive.DeathmatchAIKit.AI.Actions.Attack.OnUpdate () (at Assets/Scripts/Deathmatch AI Kit/Scripts/AI/Actions/Attack/Attack.cs:49)
     
  5. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    Are you able to tell me how to reproduce the error from a fresh project? Line 49 of attack points to:

    Code (csharp):
    1.  
    2.             var targetParent = Utility.GetComponentForType<Health>(m_Target.Value, true).transform;
    3.  
    Which will return an error if the target doesn't have the Health component. Any target found should have the Health component unless the Target Layer Mask was changed on the Deathmatch Agent component.
     
  6. tauceti38

    tauceti38

    Joined:
    Sep 20, 2013
    Posts:
    15
    To reproduce the error...I downloaded all the supporting files, in the order you suggested in a fresh copy of Unity. Then we simply played the demo scene titled "Spark".
    In the demo, I am able to explore the map, see other players running around the map, but they cannot shoot me. I however can shoot them.
     
  7. tauceti38

    tauceti38

    Joined:
    Sep 20, 2013
    Posts:
    15
    Is it possible for you to send me a fresh copy of the four assets? Instead of downloading them from the assets store? The downloads from the store seem to be giving me problems and I am not sure what to do?
     
  8. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    Unfortunately we don't have a bundled version. When you download it make sure first install the four assets in this order:
    1. Third Person Controller
    2. Behavior Designer
    3. Behavior Designer - Movement Pack
    4. Behavior Designer - Third Person Controller integration
    And then install the Deathmatch AI Kit. After you complete each step make sure you aren't getting any errors. Once you do that you should be error-free :)
     
  9. CrandellWS

    CrandellWS

    Joined:
    Oct 31, 2015
    Posts:
    178
    I had forgot to install the integration once installed all errors became resolved. thanks.
     
  10. CrandellWS

    CrandellWS

    Joined:
    Oct 31, 2015
    Posts:
    178
    @vis2k it has been suggested but it was unclear if it will be done.
     
  11. CrandellWS

    CrandellWS

    Joined:
    Oct 31, 2015
    Posts:
    178
    How can I best optimize this for Android?

    The system slows when Agents are in the camera view seems the biggest factor in is IK...
    What do you suggest?

    (the mobile controls are done by Control Freak 2 )
     
  12. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    If you are on 2017.2 or later you can disable auto sync transforms with Physics.autoSyncTransforms but beyond that the biggest hit is going to be related to the Animator.Update loop. Unchecking IK for each layer that doesn't use IK will help some, but there just may be too much going on within your scene for mobile to keep up. If you follow these graphic optimization tips it should free up more power to be able to run the animations: https://docs.unity3d.com/Manual/OptimizingGraphicsPerformance.html
     
    CrandellWS likes this.
  13. RWChalmers

    RWChalmers

    Joined:
    May 1, 2015
    Posts:
    2
    I've done all this in order (minus the Deathmatch AI kit) and get 4 errors as soon as I install the BD - 3rd person integration package...

    Assets/Behavior Designer Tactical/Integrations/Third Person Controller/AttackAgentBridge.cs(3,38): error CS0234: The type or namespace name `ThirdPersonController' does not exist in the namespace `BehaviorDesigner.Runtime.Tasks'. Are you missing an assembly reference?

    Assets/Behavior Designer Tactical/Integrations/Third Person Controller/AttackAgentBridge.cs(7,53): error CS0246: The type or namespace name `IAttackAgent' could not be found. Are you missing an assembly reference?

    Assets/Behavior Designer Tactical/Integrations/Third Person Controller/DamagableBridge.cs(6,51): error CS0246: The type or namespace name `IDamageable' could not be found. Are you missing an assembly reference?

    Assets/Behavior Designer Tactical/Integrations/Third Person Controller/AttackAgentBridge.cs(15,17): error CS0246: The type or namespace name `AIAgent' could not be found. Are you missing an assembly reference?


    Unity 2018.1.6f1
     
  14. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    It looks like that is the Tactical Pack integration instead of the regular Behavior Designer integration. The Tactical Pack is not integrated with the Deathmatch AI Kit, but you can get the regular integration from:

    http://www.opsive.com/assets/BehaviorDesigner/samples.php
     
  15. radiantboy

    radiantboy

    Joined:
    Nov 21, 2012
    Posts:
    1,633
    I just tried this again, but for some reason none of the AIs move.. but no errors? Any ideas?
     
  16. radiantboy

    radiantboy

    Joined:
    Nov 21, 2012
    Posts:
    1,633
    I want to try this all fresh but it is not clear what to get from the opsive website (Third Person Controller ?) and I cant find my invoice either, no matter I search for.

    Error im getting:

    Assets/Deathmatch AI Kit/Scripts/AI/Actions/Attack/Attack.cs(5,38): error CS0234: The type or namespace name `ThirdPersonController' does not exist in the namespace `BehaviorDesigner.Runtime.Tasks'. Are you missing an assembly reference?

    EDIT: ok found the invoice and downloaded the third person controller integration, its working now!..
     
    Last edited: Aug 13, 2018
  17. radiantboy

    radiantboy

    Joined:
    Nov 21, 2012
    Posts:
    1,633
    Got this going with ufps once but I cant get it going again, they never attack me, is there any tutorials on using this with ufps?
     
  18. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    The Deathmatch AI Kit doesn't support UFPS right now. It will after we release version 2 of UFPS.
     
  19. radiantboy

    radiantboy

    Joined:
    Nov 21, 2012
    Posts:
    1,633
    Well surely you can get them to target a ufps player? (classic ufps).
     
  20. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    There's more to it than just targeting - the damage system would need to be integrated, as would the item type system. This has all been joined with version 2 and we will be updating deathmatch shortly after in order to support it. I can't wait to see this scene with a first person perspective.
     
  21. radiantboy

    radiantboy

    Joined:
    Nov 21, 2012
    Posts:
    1,633
    Yeah I actually solved most of them issues and it was working perfectly about a year ago, but I cant remember how I did it. Been banging my head against the wall all day trying to get it working again. I dont want full integration as such just a semi smart AI to fight with.
     
  22. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    Version 1.1.2 of the Deathmatch AI Kit is now on the Asset Store. This version adds compatibility with the latest Behavior Designer and Third Person Controller releases.

    Note: When we release version 2 of our character controllers, the Deathmatch AI Kit will temporarily be deprecated on the Asset Store while we update the Deathmatch AI Kit to support version 2 of the character controllers. This will also bring support for UFPS.
     
  23. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    The Deathmatch AI Kit has temporarily been deprecated from the Asset Store. It will return when we update it to work with version 2 of our controllers.
     
  24. Gametyme

    Gametyme

    Joined:
    May 7, 2014
    Posts:
    618
    Will it still support the first version?
     
  25. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    No, after version 2 of the Deathmatch AI Kit is released it will only support version 2 of the character controllers. I may be able to place version 1 on our website so you can download it but it will not be supported anymore.

    Version 2 of the Deathmatch AI Kit will be a free update.
     
  26. Gametyme

    Gametyme

    Joined:
    May 7, 2014
    Posts:
    618
    Any time frame for release?
     
  27. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    I currently don't have an ETA - I'll post about it more when I have a better estimate.
     
  28. radiantboy

    radiantboy

    Joined:
    Nov 21, 2012
    Posts:
    1,633
    anyone know why I cant get this to import "BehaviorTreeAgent" ?

    [Error] 44] Assets\Deathmatch AI Kit\Scripts\AI\DeathmatchAgent.cs(12,36):
    error CS0246The type or namespace name 'BehaviorTreeAgent' could not be found (are you missing a using directive or an assembly reference?)
     
  29. radiantboy

    radiantboy

    Joined:
    Nov 21, 2012
    Posts:
    1,633
    argh, went back to older kit and it compiled, but STILL cant get any dudes to appear and run around, I WISH this was not deprecated :-(

    I only get one player appearing, and the error

    [Error] The behavior ""Behavior"" on GameObject ""Eryx"" contains no root task. This behavior will be disabled.
    ...

    Any ideas anyone??? Just trying to get this working spent well over 300 us on all the packages.
     
  30. radiantboy

    radiantboy

    Joined:
    Nov 21, 2012
    Posts:
    1,633
    Failing fixing this which seems tough, is there any way I can use all the packages I got to get this working, to easily create an AI who will run around in my FPS? Surely must be.
     
  31. kodagames

    kodagames

    Joined:
    Jul 8, 2009
    Posts:
    548
    Hello,

    when this returns to the asset store how much will it be?
     
  32. radiantboy

    radiantboy

    Joined:
    Nov 21, 2012
    Posts:
    1,633
    I think it is long forgotten, build your own based on it is the only option.
     
  33. radiantboy

    radiantboy

    Joined:
    Nov 21, 2012
    Posts:
    1,633
    I see myself struggling one year ago above, I wrote my own from scratch.. gonna try sell soon. If you wanna buy its called RadiAI, has real street life etc, sit down eat, smoke, wander, attack etc
     
    Last edited: Dec 25, 2020
  34. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    It'll be $25. Here's a link to the product page and you can get from the Opsive Store right now. This thread has more info. This update requires version 2 of the controllers
     
    Last edited: Dec 25, 2020
  35. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    CoyoteFringe likes this.
  36. SAMURAI_VFX

    SAMURAI_VFX

    Joined:
    Sep 21, 2020
    Posts:
    1
    I purchased the Deathmatch AI Kit, but the error in the image below is displayed and I cannot use it.

    Version used
    Unity2021.1.9.f1 (Mac OS Catalina)

    Owned assets
    Behavior Designer
    Behavior Designer Formations
    Behavior Designer Movement
    Behavior Designer Tactical
    Ultimate Character Controller
    Deathmatch AI Kit

    I think the following conditions may be a problem.
    Requires Ultimate Character Controller, First Person Controller, or Third Person Controller

    Do I need to purchase a First Person Controller or Third Person Controller in addition to the UltimateCharacterController?
    DeathMatch_Error_0604.png
     
  37. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    With the Ultimate Character Controller you are good to go. Make sure you import the Ultimate Character Controller integration. This page has the steps to import that integration: https://opsive.com/support/documentation/deathmatch-ai-kit/
     
  38. BioBurden

    BioBurden

    Joined:
    May 28, 2018
    Posts:
    115
    Hi, can I request that the demo include an option to disable camera collisions when observing the AI? Many thanks.
     
  39. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    You can set the culling mask of the Observer camera to not have it detect any layers. If you have further questions please post on the Opsive forum so I can track your support request better.
     
  40. BioBurden

    BioBurden

    Joined:
    May 28, 2018
    Posts:
    115
    Sorry, to clarify, this is in reference to the build demo available on the asset page, as I've yet to purchase.
     
    opsive likes this.
  41. o3428320d

    o3428320d

    Joined:
    Apr 5, 2019
    Posts:
    21
    Hello,
    I followed the video tutorial to set up the enemy prefab.
    It works when there is only one enemy, the enemy can shoot the player.
    However, when I duplicate the enemy and try to set them in one team for the aim to shoot the player, the enemies just shoot each others.

    I changed the behavior of the enemies from solo to team type, the enemies are at the same layer (enemy), their enemy layers set as "character" layer which the player is at.
    I did these things above but the enemies still shoot each others. (They also will shoot player when the player is near)

    So what should I do to make enemies work as a team, thanks a lot.
     
  42. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    Hello,

    For support please post on the forum at https://opsive.com/forum. This allows us to track each request better and also has a search to make it easier to find previously asked questions.

    Justin
     
  43. o3428320d

    o3428320d

    Joined:
    Apr 5, 2019
    Posts:
    21
    Hello, I have tried to input the invoice number of Deathmatch AI Kit which bought in Unity Asset Store, but it tells me the invoice number is incorrect....
    I also tried to ignore the "IN" and only input the numbers, it also doesn't work.....
    What should I do?
     
  44. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    You should be able to use your character controller or Behavior Designer invoice number.
     
  45. cangcloud2015

    cangcloud2015

    Joined:
    Apr 9, 2018
    Posts:
    63
    Hello, I think you should add support for the creation of bosses to Deathmatch AI Kit, and add more skills...like invisibility, assassination, area attack skills, etc.
     
  46. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    Bosses are outside the scope but adding those power ups is a good idea :)
     
  47. mishrap_unity

    mishrap_unity

    Joined:
    Apr 23, 2020
    Posts:
    2
    Will Deathmatch AI KIT work easily with Smartphone Based VR Game? Your demo scene (game) works well on Smartphone?
     
    Last edited: Aug 14, 2021
  48. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    How many agents are you trying to get on screen at once? Depending on the device you may need to do some optimizations such as use GPU Instancer. One of the biggest bottlenecks is the Animator so by instancing you can get more on the screen at once.
     
  49. lolaswift

    lolaswift

    Joined:
    Jan 10, 2019
    Posts:
    151
    hi, does this support friendly AIs as player companions against Enemy AIs?
     
  50. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,127
    Yes - this is the team behavior tree where the agents will work with you to target the enemy agents.
     
    lolaswift likes this.