Files
flame/lib/game/simple_game.dart
2020-04-20 21:11:54 +02:00

13 lines
445 B
Dart

import 'package:flame/components/component.dart';
import 'base_game.dart';
/// This is a helper implementation of a [BaseGame] designed to allow to easily create a game with a single component.
///
/// This is useful to add sprites, animations and other Flame components "directly" to your non-game Flutter widget tree, when combined with [EmbeddedGameWidget].
class SimpleGame extends BaseGame {
SimpleGame(Component c) {
add(c);
}
}