BehaviourGroup¶
- class mobrob_behcon.behaviours.behaviourgroup.BehaviourGroup(name)[source]¶
The class BehaviourGroup
Attributes
name
Name of behaviourgroup
resolver
resolver
percept_space
percept_space
Methods
__init__
(name)constructor
Activate this behaviourgroup, so set all behaviours in this behaviourgroup as active so that resolver can trigger them
add
(behaviour, priority)function to add an behaviour to behaviourgroup
deactivate the behaviour group
set_error
(code)Set error state of this behaviourgroup.
set_percept_space
(percept_space)Set the reference to percept_space
set_resolver
(resolver)Set the reference to resolver
set_success
(code)Set success state of this behaviourgroup.
Details
- activate_exclusive()[source]¶
Activate this behaviourgroup, so set all behaviours in this behaviourgroup as active so that resolver can trigger them
- add(behaviour, priority)[source]¶
function to add an behaviour to behaviourgroup
- Parameters
behaviour (inherited class of Behaviour) – reference to behaviour
priority (int) – priority of behaviour in this behaviourgroup [0-100]
- set_error(code)[source]¶
Set error state of this behaviourgroup. With the error code some more information about the error can be given.
- Parameters
code (int, optional) – error code, defaults to 0
- set_percept_space(percept_space)[source]¶
Set the reference to percept_space
- Parameters
percept_space (PerceptualSpace) – relevant percept_space object