onRemove method
Called right before the component is removed from the game.
Implementation
@override
void onRemove() {
_controller?.onRemove(this);
if (_controller?.components.isEmpty == true) {
_controller = null;
}
super.onRemove();
}