Skip to content

NPBehave 2.0 Changes - Wishlist #25

@meniku

Description

@meniku

Looking at how things work in NPBehave two years after I wrote it, I realise it has some flaws in the aborting/Stops Rules, that cannot be resolved without major changes to the API. That’s why I aim for a new major version.

If you also have suggestions, feel free to comment on this ticket.

My Suggestions:

Base C# Library

As I currently don’t work in Unity, but in Monogame, I would like to split the NPBehave in a base C# library and have separate git-projects for each of the specific engines: Unity, Monogame etc.

Stops Rules

IMO one of the biggest flaws NPBehave has, is the Stops Rules and the aborting of nodes.

  1. Aborted nodes can influence the way the Behaviour Tree continues processing by returning Succeed or Failed. This is a property of NPBehave that I like over UE4, where aborting a node results in the whole branch to be aborted. You can get UE4s way by a combination of IMMEDIATE_RESTART and returning the right result in the aborted node, however the way it works right now is not very obvious. I would like to get rid of any IMMEDIATE_RESTART versions of the Stops Rules, and give the control over what “aborting” actually means completely to the aborted node. In case a node gets aborted, the node could control the flow by finish with: Succeed, Failed or Aborted (the latter is a replacement for IMMEDIATE_RETART but will always guarantee that the aborting decorator is restarted)
  2. I would like to introduce an “Aborting” state inside nodes. Nodes that are requested to be aborted shouldn’t be forced to immediately finish their work, but allowed to block the flow until they are finished cleaning up ( sometimes you want to wait for some animation for example ). This could be quite problematic in NPBehave, so I will have to see if I can actually make it happen.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions