1.9.0
Description
Abstract
Enable reset behavior plugin of entity.
Background
Previously, no means was provided to reset the behavior plugin, and the state had to be saved and respawned.
This pull request provides functionality to allow plugins to be replaced more easily.
Details
Enable reset behavior plugin of entity.
You can use this feature by function below.
void API::resetBehaviorPlugin(const std::string & name, const std::string & behavior_plugin_name)
First argument is the name of the entity you want to reset behavior plugin.
Second argument is the name of the behavior plugin you want to set.
Internally, the following operations are performed
- Save entity state and parameters.
- Despawn and respawn target entity.
- Reset acceleration/twist/behavior parameters to the target entity.
References
Destructive Changes
N/A
Known Limitations
API::resetBehaviorPlugin
function cannot be called on non-spawned EntityAPI::resetBehaviorPlugin
function cannot be called for entities other than vehicle/pedestrian because behavior plugin does not exist for entities other than vehicle/pedestrian.