Make gameRef late (#742)

This commit is contained in:
Luan Nico
2021-04-03 19:47:37 -04:00
committed by GitHub
parent 971fc09add
commit bc3820c0fa
12 changed files with 41 additions and 16 deletions

View File

@ -1,7 +1,7 @@
import 'package:flame/components.dart';
import 'package:flame/game.dart';
class Square extends PositionComponent with HasGameRef<Composability> {
class Square extends PositionComponent {
Square(Vector2 position, Vector2 size, {double angle = 0}) {
this.position.setFrom(position);
this.size.setFrom(size);