Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stubbed out beehave_tree_node #306

Closed
wants to merge 2 commits into from

Conversation

RcubDev
Copy link

@RcubDev RcubDev commented Feb 6, 2024

Description

Stubbed out methods from beehave 2.X's behave node (in beehave 3.X it is renamed to beehave_tree_node). Implemented the methods I could without the blackboard being completely implemented.

Screenshots

configuration warnings working with this update:
image

docs updated with new methods:
image

@RcubDev RcubDev changed the title stubbed out behave_tree_node stubbed out beehave_tree_node Feb 6, 2024
BeehaveTreeNode::TickStatus BeehaveTreeNode::tick(Ref<BeehaveContext> context) {
return BeehaveTreeNode::FAILURE;
return BeehaveTreeNode::SUCCESS;
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed this to success as this is what the 2.X version was doing when I looked. I can swap it back if we want

ClassDB::bind_method(D_METHOD("before_run"), &BeehaveTreeNode::before_run);
ClassDB::bind_method(D_METHOD("after_run"), &BeehaveTreeNode::after_run);
ClassDB::bind_method(D_METHOD("get_class_name"), &BeehaveTreeNode::get_class_name);
ClassDB::bind_method(D_METHOD("can_send_message"), &BeehaveTreeNode::can_send_message);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ClassDB::bind_method(D_METHOD("get_class_name"), &BeehaveTreeNode::get_class_name);
ClassDB::bind_method(D_METHOD("can_send_message"), &BeehaveTreeNode::can_send_message);

Those were needed for the debugger. Let us (for now) not define those methods and deal with that later, as with C++ we can do some fancy tricks to not rely on GDScript hacks.

ClassDB::bind_method(D_METHOD("tick"), &BeehaveTreeNode::tick);
ClassDB::bind_method(D_METHOD("interrupt"), &BeehaveTreeNode::interrupt);
ClassDB::bind_method(D_METHOD("before_run"), &BeehaveTreeNode::before_run);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was thinking about making before_run and after_run signals in V3

@bitbrain
Copy link
Owner

Closing this, as this has been done already.

@bitbrain bitbrain closed this May 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants