onRemove method

  1. @override
void onRemove()
override

Called when the game is about to be removed from the Flutter widget tree, but before it is actually removed.

Implementation

@override
void onRemove() {
  super.onRemove();
  Component.staticGameInstance = null;
}