Search Unity

NodeCanvas - (Behaviour Trees | State Machines | Dialogue Trees)

Discussion in 'Assets and Asset Store' started by nuverian, Feb 8, 2014.

  1. guybro_thunderboots

    guybro_thunderboots

    Joined:
    Aug 27, 2015
    Posts:
    45
    ```
    decoratedConnection.targetNode.SetStatus(Status.Failure); //TODO: Fix normally. Avoid hackz.
    ```

    This is the troublesome line in Timeout.cs. I don't know what it's there for but removing it resolves the issue.
     
  2. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    @Everyone : Please use the official forums for support and faster responses. Thank you!

    Hey,

    Is it possible for you to please make a post in the official NodeCanvas forums with your feature request?
    This way we can discuss and follow your request better rather than within this monolithic thread :)
    Thank you in advance!

    Hello,

    Good find. Thank you.
    Aparently I omited deleting that line of code when it wasn't necessary anymore :)
    Thank you.
     
  3. MoFaShi

    MoFaShi

    Joined:
    Oct 25, 2015
    Posts:
    43
    I am planning to buy NodeCanvas. but before buying it, I have some questions:
    when will the 3.0 be updated? and will we need to pay for upgrading or it will be a free upgrade for us?
     
  4. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hello,
    Thanks for your interest in NodeCanvas.
    V3 is planned for January. It will be a free upgrade.

    Thanks!
     
  5. MoFaShi

    MoFaShi

    Joined:
    Oct 25, 2015
    Posts:
    43
    the Behaviour Tree Node in FSM has two parameters, one is Success Status Event and other is Failure Status Event.
    I am trying to figure out how these two works, but still don't know how to send these to events to this Node.
    could you give me an example of this?
     
  6. kuusuke

    kuusuke

    Joined:
    Dec 24, 2018
    Posts:
    2
    On the behavior of Probability Selector I wanted to ask for confirmation because there seems to be a bug

    Below are the expected behaviors
    1. The child node selected by Probability Selector returns failure
    2. Execute the child node not selected in 1. (Repeat until the child node returns success or all the child nodes fail)

    However, when the following settings were made, the Probability Selector might return a failure without selecting a child node that was not selected in 1. with 2.
    Weight Left 0.2
    Weight Right 0.8 (Probability Selector fails after failing)

    On OnExecute of Probability Selector, when a child node returns failure Perhaps it is trying to calculate the probability by excluding the weight of the child node of the index included in failedIndeces, but the weight to be excluded here seems to be unexpected
     
  7. kuusuke

    kuusuke

    Joined:
    Dec 24, 2018
    Posts:
    2

    I'm sorry I did not update the version I confirmed it again at 2.9.0 and it was repaired
     
  8. Davood_Kharmanzar

    Davood_Kharmanzar

    Joined:
    Sep 20, 2017
    Posts:
    411
    @nuverian
    hello,
    is it possible to creating Quest - Tutorial system with Node Canvas?
    does exists as example?
    thanks.
     
  9. Ivoryjw

    Ivoryjw

    Joined:
    May 20, 2018
    Posts:
    31
    Hello there. I'm interested in buying the lite version of NodeCanvas.
    Just a quick question, will the light version get updates to support upcoming versions of Unity when they come out or will that only be the full version?
     
  10. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    @Everyone. I've stated this many times in the past, but once again, I no longer monitor these forums. Please join us in the official NodeCanvas Forums, or the official Discord Server for questions and/or support. Thank you!

    @unity_zOvEB4IgVxRirA It can be possible using the FSM, or Dialogue Tree system of NodeCanvas depending on what you are after.

    @Ivoryjw Yes. NodeCanvas Lite version will continue be supported although it may happen less frequently than the full version.
     
  11. yousuffahim8

    yousuffahim8

    Joined:
    Feb 21, 2019
    Posts:
    3
    I am very new to both Node Canvas and Unity. Can anyone tell me that when I make some changes in the behaviour tree, which source file also changes in real time?
     
  12. Nathan-Liu

    Nathan-Liu

    Joined:
    Apr 27, 2017
    Posts:
    8
  13. Kirshor

    Kirshor

    Joined:
    Apr 14, 2015
    Posts:
    24
    Hi @nuverian,

    I tested SwitchBehaviourTree action as below:
    Tree1: Sequence->Print Log 1, SwitchBehaviourTree To Tree2, Print Log2
    Tree2: Sequence->Print Log3

    The result when run is: Print Log1, Print Log3, Print Log2, Print Log3, Print Log3, .....
    Why "Print Log2" still run after call SwitchBehaviourTree Action
    I'm using the lasted version of NodeCanvas in Unity Asset Store.
    Help me, please.
    Thank you very much.
     
  14. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    The website migration to a better place (aka host) has finally finished and the forums are back online. The website should now be blazing faster than it was before (and hence the reason the migration happened in the first place). The documentations got a revamp and search bar, while the forums got a nicer text editor while all the above happened. Finally the website is now also secured (using HTTPS) for golden shiny locks.
    Everything should be in order, but if you find any problems with the websites, please let me know. Thank you!

    @Everyone. I've stated this many times in the past, but once again, I no longer monitor these forums. Please join us in the official NodeCanvas Forums, or the official Discord Server for questions and/or support. Thank you for your understanding!
     
  15. juanitogan

    juanitogan

    Joined:
    Aug 18, 2017
    Posts:
    27
    From your website: "Includes hundreds of premade game-oriented tasks to get you up and running quickly!"

    Um... uh... what?

    I can't find a list of any of these tasks. Not even in the documentation. I'm trying to compare NodeCanvas with Behavior Designer and finding it very difficult to find any good intel on what's in the box with NodeCanvas. Behavior Designer lists their tasks and even has a WebGL demo of their movement tasks to see exactly what you get before you pay for it. I can scrape random YouTube videos to get some idea but it is still hard to determine if you have things like pursue and follow but under a different name. Maybe AI experts don't care about this stuff but I'm new to AI and don't have deep pockets to try every asset until I find the one I want.

    It looks like NodeCanvas is the product I want but it is just really hard to know with so little details to compare.

    ... and shouting at us to go to the trouble of joining yet another forum before we buy is simply rude.

    ... especially when you still link to this one from the store page.
     
    Last edited: Mar 22, 2019
    Weblox likes this.
  16. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hello,

    I am sorry, but that wasn't meant to be "shouting" or anything like that of course. I just wanted to make sure that the statement is visible to everyone, since the reason for that is mostly practical. This monolithic thread is really not suitable for software support or tracking questions. There is no separation, but rather just top to bottom series of posts, hence the reason I ask to please join the official forums, the discord channel, or even contact me directly.

    With that said, I have just added a new section in the documentation listing all the current Action and Condition Tasks included in the package. Please find the list here.

    Thanks!
     
    Last edited: Apr 10, 2019
    Weblox likes this.
  17. Deleted User

    Deleted User

    Guest

    Hi, just to let you know your PolyNav extension imports with errors (looks like a namespace issue but I don't want to get messing around with it, it might just create more issues later on). Obviously these things happen so I understand, its just a bit of a shame because I brought nodecanvas especially for polynav (and visa versa)
     
    nuverian likes this.
  18. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hey,
    The package was updated recently and can now be downloaded from the website.
    Thank you :)
     
  19. amanihs

    amanihs

    Joined:
    Feb 20, 2019
    Posts:
    1
    Hello there,i have a question i have a list of object and they are instantiate randomly , can i add probability to these objects with nodeCanvas. and if this posible how can i do this ? thnx
     
  20. misanthropowitsch

    misanthropowitsch

    Joined:
    Sep 30, 2016
    Posts:
    23
    Hi!

    I´ve searched fo an concrete answer to my question for some time now, but couldn´t quite make it - so Sorry if it has already been answered. I´ll come straight to the point in order to not bloat my post to much.

    1. Is it possible to design 2D Platformer bosses with mechanics like say Megaman?

    2. Is there already existing logic to instantiate projectiles/execute melee attacks?

    3. How is 2D Pathfinding achieved? Do I have to download additional assets like polynav?

    4. Is polynav capable of working in a strict 2D platformer environment or is it built for top down environments? Imagine a 2D left/right patroling enemy

    Looking forward to your answers. I may overlook stuff, but for me it isn´t clear how it´s supposed to work without navmesh and what kind of logic exactly is going to be executed. Would buy instantly though if it fits my case. FSMs are a pain in the ass :D

    Best,
     
  21. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hello,

    Sorry for the late reply (please use the official forums for faster replies if you can).
    Please let me address your questions:

    1) There is nothing stopping you from doing that, although that will require some work of course.

    2) There does exist an instantiattion action, but please note that there is no predefined logic for melee attacks (or any game specific mechanic for that matter), since in each game that is (or can be) totaly different, thus you will need to create the logic for the machanics you want to achieve.

    3 - 4) While NC does include tasks like Seek, Wander, Patrol etc, these tasks utilize Unity's NavMesh navigation system, but nothing 2D specific. You can of course use PolyNav if you want which does has an intergration package with NodeCanvas, but please also note that PolyNav is not meant for platformers (where gravity and jumping is involved for example).

    If you have any further questions or need any clarification on the above, please let me know.
    Thanks!
     
  22. anakein

    anakein

    Joined:
    Mar 10, 2019
    Posts:
    22
    can i to use oculus integration with node canvas for VR?

    thanks
     
  23. Caruos

    Caruos

    Joined:
    Dec 30, 2016
    Posts:
    42
    Hi @nuverian ,

    I know you don't monitor that forum often, but on the NodeCanvas site the "Register" doesn't work, I enter a name/mail/password, and when I click "Sign up" nothing happens. So I can't post messages or download attachments. I tried on Firefox and Microsoft Edge, no difference.

    Anyway, I have the same problem as here. I want to create a NodeCanvas/FlowCanvas bridge, but importing the package just shows "all assets are already in your project". I tried a new project with only the latest versions of NodeCanvas and FlowCanvas, and I get the same error message. Could you please send me the modified package you put in this thread ?
     
  24. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hello,
    There are no direct integration tasks (actions/condition) with the VR system in Unity, but depending on what you want to do, you might be able to utilize the reflection tasks to call functions, or get/set properties with the Unity API regarding VR functionality. You can also of course always write custom tasks to do exactly what you want them to do.

    Thank you.

    Hello and sorry about the trouble with the forums. I've made some changes and it will hopefully work now if you want to please give it a try.
    With that said, I have attached for you here the FlowCanvas/NodeCanvas bridge unitypackage as requested.

    Thank you.
     

    Attached Files:

    Caruos likes this.
  25. Caruos

    Caruos

    Joined:
    Dec 30, 2016
    Posts:
    42
    It works. Thanks a lot ! I would recommend adding this file on the NodeCanvas download page while you're at it ;)
     
  26. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
  27. username132323232

    username132323232

    Joined:
    Dec 9, 2014
    Posts:
    477
    Hi! In FSM, is it possible to set a function that would be executed whenever the FSM exits a particular state?
     
  28. FeboGamedeveloper

    FeboGamedeveloper

    Joined:
    Feb 2, 2014
    Posts:
    47
    Hi I have a problem, I can't create a list as a variable in an FSM ActionTask.
    upload_2019-8-22_7-34-17.png

    for example if I try to add elements to the list in the graph I get this error. unity: "You cannot call GetLast immediately after beginning a group". I'm using unity 2019.2 ed I'm using the fNode Canvas final version.
     
    Last edited: Aug 22, 2019
  29. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hello there,

    I just re-checked this (Unity v2019 and NodeCanvas v2.9.4f as well) and I honestly don't get any issues with your exact same example task added on an FSM Action State. Is there any more information you can please provide? (Operating System, API Compatibility Level even though I think none of those matter). Are you sure you are on the latest version?

    Thank you.
     
  30. AlejandroAvarezMelucci

    AlejandroAvarezMelucci

    Joined:
    Nov 2, 2016
    Posts:
    3
    Hi! I have some issues with DialogueTree.
    In a ActionTask, when I set up to call a function over a script in a GameObject in the scene, the reference is lost after stopping a play session (tested on editor, not on build yet).
    If I hit play again, the reference is "restored", but after closing Unity and reopening it, it's lost forever and I have to reset them manually.

    Is this feature supportedat all? I need to rely on DialogueTree calling those methods on scripts in the scene
     
  31. AlejandroAvarezMelucci

    AlejandroAvarezMelucci

    Joined:
    Nov 2, 2016
    Posts:
    3
    Found it! You have to use the "Bind Graph" option in the DialogueTreeController game object :D
    I wish the DialogueTree documentation were more complete and in-depth though!
     
  32. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hey! I am glad you found it :) I've just updated the Dialogue Tree doc to make sure that this is pointed out.
    Thanks!
     
  33. Nunez-Torrijos

    Nunez-Torrijos

    Joined:
    Mar 3, 2016
    Posts:
    33
    Hi @nuverian

    I don't know if this has been asked before...
    Is it possible to use the Unity's ECS/DOTs architecture with node and flow canvas?
    Unity is currently developing a DOTS-based Visual Scripting system, but it will take at least a year until its mature enough.
    I bought Node and Flow Canvas, Eliot and also Bolt, and I need to decide to which system I'm going to migrate my previous home-brewed solution. I intend to take advantage of the DOTS architecture. Bolt is not planning of supporting it anytime soon (the dev loves OOP), there is little info about this with Eliot, so... I would really appreciate if you could tell me... Is it already possible? If not, is it planned in the near future?

    Thanks a lot!
     
  34. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hello there,
    First of all, thank you for purchasing Node and Flow Canvas! To be totally honest about this, I do not really plan to convert the whole framework into working with the DOTS architecture since that would require a tremendous amount of work (almost a re-write). Like probably most devs, I also love OOP and my mind works with objects. Maybe some intensive parts will make it to DOTS if at all possible, but even that is very questionable at the moment.

    Thanks!
     
  35. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hi everyone.

    A new version of NodeCanvas that now properly supports and looks nice in the new Unity Editor GUI Theme (2019.3.x) has recently gone live on the Asset Store. If you want to check the whole changes of this update as well as the previous ones of course, they can always be found here: https://nodecanvas.paradoxnotion.com/change-log/ :)

    Thanks!
     
  36. TextusGames

    TextusGames

    Joined:
    Dec 8, 2016
    Posts:
    429
    Hello.
    Since you are making local blackboards in 3+ update, I wonder will it ever be possible someday to have as many nested (or parallel) bound subgraphs in bound graph? (preferably of any type, dialog, behaviour, state or flow)

    I feels like I am lacking this ability.
     
  37. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hello there,

    Considering you are referring to bound as in their ability to hold scene object references, the answer is generally yes, but not for v3.0, but within the cycle of v3.x. :)
     
  38. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hello everyone and happy new year!

    NodeCanvas v3.0.0 has just been released and is live on the Unity Asset Store!
    There are so many great new features and improvements! As always the whole changelog can be found here:
    https://nodecanvas.paradoxnotion.com/change-log/

    Cheers!
     
  39. Danirey

    Danirey

    Joined:
    Apr 3, 2013
    Posts:
    548
    Hello all,

    i want to throw a question to you guys. In a FSM if you want to enable/disable scripts attached to the FSM owner, what should work better: eneable/disable each script through the fsm itself, using the actions provided, or calling a function from the fsm to enable or disable all of them by code?

    i don’t know if it will make any difference at all, but some light would be much appreciated.

    best regards!
     
  40. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hey!
    Both should work equally. You can just use the one that you prefer or is easier for you the most. I think that enabling/disabling all behaviours at once though some custom action task from within the fsm is a bit easier if you are making custom action tasks in the first place anyway :)
     
  41. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
  42. Danirey

    Danirey

    Joined:
    Apr 3, 2013
    Posts:
    548
    Hi nuverian,

    Thanks a lot for the info. (I love to see this is still going after so much time)

    Best regards!
     
    nuverian likes this.
  43. TextusGames

    TextusGames

    Joined:
    Dec 8, 2016
    Posts:
    429
    I meant. Will it ever be possible to subgraphs not to be assets but just be saved in that original controller.
    Consider this: I have ten subgraphs in one state machine. Do I really need to create an assets for that graphs? I would prefere not to.
     
  44. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    6,327
    hey everyone, what's the performance like when running some (50) BT agents?
    and how do you like the GUI?
     
  45. Emphy

    Emphy

    Joined:
    Feb 7, 2014
    Posts:
    33
    Hey! Discovering NC now but I find it's got a pretty steep learning curve.

    What I'm trying to do: my DefenderAgent has a parallel task that checks if any enemies entered its trigger.
    If so, it is added to a list of Targets. Then shoots at it.

    upload_2020-11-20_15-3-3.png

    Now, my idea was that when the enemy is dead, it sends either a Signal or Event. I went with Event for now. That's cool, I can check global and the FSM of my DefenderAgent removes the enemy from the Targets list (in the parallel task).

    upload_2020-11-20_15-9-13.png

    I also have some bounds in my scene that if the Defender doesn't kill the enemy the enemy dies on hitting the bounds and well, damages the player or deducts score, whatever. When the bound is hit, it despawns the enemy from the scene with a Pooling manager. In the OnDespawned function of my enemy I want the DefenderAgent to know that the enemy died due to 'external causes'. So I thought I'd do this from code:

    Code (CSharp):
    1. GetComponent<GraphOwner>().SendEvent<GameObject>("EnemyDeath", null, gameObject);
    But that doesn't emit it globally. So question would be: how can I let my DefenderAgent FSM best know the enemy that was in its TargetList is dead and should be removed from the list? Am I totally going about this the wrong way? A global event would already help I guess, but how? Also wanted to try Signals but tbh I can't really find how to send those from the code... if you could help me out, thanks!

    P.S. If you see weird things that I could do much easier, please feel free to advise. The idea is: Defender sees enemies in its trigger, picks the closest and fires on it. I'm debating whether I want to pick a new target after a few seconds to re-evaluate the biggest threat or only after the picked target died but that's for later.

    Thanks!
     
    andreiagmu likes this.
  46. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hello from here as well.

    Just for the completion of this thread and as I replied to you previously, you simply need to use the static method 'Graph.SendGlobalEvent' instead :)

    Cheers!
     
    andreiagmu and Emphy like this.
  47. andreiagmu

    andreiagmu

    Joined:
    Feb 20, 2014
    Posts:
    175
    Hi @nuverian, I may have discovered an error in the NodeCanvas documentation, in the "Creating Custom Object Drawers" page.
    https://nodecanvas.paradoxnotion.com/documentation/?section=creating-custom-object-drawers

    In the MyRangeDrawer class example, the "(float)instance" cast is not working.
    Unity throws the following error: InvalidCastException: Specified cast is not valid.

    I tested this with NodeCanvas v3.1.6, Unity 2020.1.17f1.

    EDIT: The error happens when I apply my custom attribute to a BBParameter<float> variable.
    The documentation implies that cast should also work with BBParameter.
     
    Last edited: Dec 17, 2020
  48. andreiagmu

    andreiagmu

    Joined:
    Feb 20, 2014
    Posts:
    175
    @nuverian Is there any public way to do custom error checking in custom Tasks? (similar to Playmaker's ErrorCheck() override)

    I noticed that in Task.cs, there's the virtual method GetWarningOrError(), that does exactly what I want if I override it. (for example, to display a custom warning in the node, if some task validation fails)
    But that method's access modifier is defined as "internal", so I can't override it from custom Tasks in other assemblies (outside of the ParadoxNotion assembly).

    Shouldn't GetWarningOrError() be defined as virtual protected/public, instead?
    Or is there any other way to do my custom warnings in the node/task GUI?
     
    Last edited: Dec 19, 2020
  49. nuverian

    nuverian

    Joined:
    Oct 3, 2011
    Posts:
    2,087
    Hello there,

    I have answered both your questions in the NodeCanvas forums just now. Please let me know there.
    Thank you! :)
     
    Subliminum and andreiagmu like this.
  50. FeboGamedeveloper

    FeboGamedeveloper

    Joined:
    Feb 2, 2014
    Posts:
    47
    I have a request, is there an event or a callback that warns the task that the FSM has been shut down or restarted?