isVisibleInCamera method

  1. @override
bool isVisibleInCamera(
  1. GameComponent c
)
override

Used to check if a component is visible in the camera.

Implementation

@override
bool isVisibleInCamera(GameComponent c) {
  if (!hasLayout) return false;
  if (c.shouldRemove) return false;
  return camera.isComponentOnCamera(c);
}