mirror of
https://github.com/flame-engine/flame.git
synced 2025-10-30 08:27:36 +08:00
chore: Remove deprecations for v1.9.0 (#2749)
Removes everything that was marked as deprecated and that should be removed for v1.9.0.
This commit is contained in:
@ -23,7 +23,7 @@ class CirclesExample extends FlameGame with HasCollisionDetection, TapDetector {
|
||||
}
|
||||
|
||||
class MyCollidable extends PositionComponent
|
||||
with HasGameRef<CirclesExample>, CollisionCallbacks {
|
||||
with HasGameReference<CirclesExample>, CollisionCallbacks {
|
||||
late Vector2 velocity;
|
||||
final _collisionColor = Colors.amber;
|
||||
final _defaultColor = Colors.cyan;
|
||||
@ -45,7 +45,7 @@ class MyCollidable extends PositionComponent
|
||||
..paint = defaultPaint
|
||||
..renderShape = true;
|
||||
add(hitbox);
|
||||
final center = gameRef.size / 2;
|
||||
final center = game.size / 2;
|
||||
velocity = (center - position)..scaleTo(150);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user