You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Sometimes it's nice to have comments inside your tree to clarify what some branches do, especially when your trees get bigger and more complex.
Describe the solution you'd like
We could use a name of a node inside the BT hierarchy as a comment.
There are a few implementations I can think of:
add a separate BeehaveComment node which would be completely ignored by the BT logic
make BT ignore nodes not inherited from BeehaveNode, thus you could put a basic Node inside tree hierarchy without causing an error
add some fourth state (like PASS/IGNORE/NONE) to the existing SUCCESS, FAILURE and RUNNING so the nodes in BT would ignore nodes returning this state and continue execution as if they were not there - then you can for example return this state from basic BeehaveNode by default (this could break some compatibility though)
Describe alternatives you've considered
You can put an AlwaysSucceed or AlwaysFail decorator so it just gets skipped over by certain composites, but you have to always keep in mind under what composite you put it. For example, if you change selector to sequence, then you have to change all comment decorators from AlwaysFail to AlwaysSucceed. You also have to put an additional dummy node under said decorator anyway, so this gets bloated and ugly quickly.
Alternatively you can just use a built-in editor_description property, but it isn't so readable and clearly visible in your tree hierarchy.
Additional context
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
Sometimes it's nice to have comments inside your tree to clarify what some branches do, especially when your trees get bigger and more complex.
Describe the solution you'd like
We could use a name of a node inside the BT hierarchy as a comment.
There are a few implementations I can think of:
BeehaveComment
node which would be completely ignored by the BT logicBeehaveNode
, thus you could put a basic Node inside tree hierarchy without causing an errorPASS
/IGNORE
/NONE
) to the existingSUCCESS
,FAILURE
andRUNNING
so the nodes in BT would ignore nodes returning this state and continue execution as if they were not there - then you can for example return this state from basic BeehaveNode by default (this could break some compatibility though)Describe alternatives you've considered
You can put an AlwaysSucceed or AlwaysFail decorator so it just gets skipped over by certain composites, but you have to always keep in mind under what composite you put it. For example, if you change selector to sequence, then you have to change all comment decorators from AlwaysFail to AlwaysSucceed. You also have to put an additional dummy node under said decorator anyway, so this gets bloated and ugly quickly.
Alternatively you can just use a built-in
editor_description
property, but it isn't so readable and clearly visible in your tree hierarchy.Additional context
The text was updated successfully, but these errors were encountered: