addInteractable method

void addInteractable(
  1. Interactable interactable, {
  2. bool notify = true,
})

Adds an Interactable to the interactables list.

Implementation

void addInteractable(Interactable interactable, {bool notify = true}) {
  _interactables.add(interactable);
  interactable.addListener(notifyListeners);
  if (notify) {
    notifyListeners();
  }
}