@@ -166,21 +166,19 @@ PYBIND11_MODULE(btpy_cpp, m)
166
166
167
167
// Register the C++ type hierarchy so that we can refer to Python subclasses
168
168
// by their superclass ptr types in generic C++ code.
169
- py::class_<TreeNode>(m, " _TreeNode" );
169
+ py::class_<TreeNode>(m, " _TreeNode" )
170
+ .def (" get_input" , &Py_getInput)
171
+ .def (" set_output" , &Py_setOutput);
170
172
py::class_<ActionNodeBase, TreeNode>(m, " _ActionNodeBase" );
171
173
py::class_<SyncActionNode, ActionNodeBase>(m, " _SyncActionNode" );
172
174
py::class_<StatefulActionNode, ActionNodeBase>(m, " _StatefulActionNode" );
173
175
174
176
py::class_<Py_SyncActionNode, SyncActionNode>(m, " SyncActionNode" )
175
177
.def (py::init<const std::string&, const NodeConfig&>())
176
- .def (" get_input" , &Py_getInput)
177
- .def (" set_output" , &Py_setOutput)
178
178
.def (" tick" , &Py_SyncActionNode::tick);
179
179
180
180
py::class_<Py_StatefulActionNode, StatefulActionNode>(m, " StatefulActionNode" )
181
181
.def (py::init<const std::string&, const NodeConfig&>())
182
- .def (" get_input" , &Py_getInput)
183
- .def (" set_output" , &Py_setOutput)
184
182
.def (" on_start" , &Py_StatefulActionNode::onStart)
185
183
.def (" on_running" , &Py_StatefulActionNode::onRunning)
186
184
.def (" on_halted" , &Py_StatefulActionNode::onHalted);
0 commit comments