Skip to content

Commit

Permalink
Don't touch paint in tile_layer
Browse files Browse the repository at this point in the history
  • Loading branch information
spydon committed Jul 29, 2023
1 parent 8f0c7ec commit 256e56d
Showing 1 changed file with 3 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ import 'package:meta/meta.dart';
/// {@endtemplate}
@internal
abstract class FlameTileLayer extends RenderableLayer<TileLayer> {
late final _layerPaint = Paint();
late final _layerPaint = Paint()
..color = Color.fromRGBO(255, 255, 255, opacity);
final TiledAtlas tiledAtlas;
late List<List<MutableRSTransform?>> transforms;
final animations = <TileAnimation>[];
Expand All @@ -50,11 +51,7 @@ abstract class FlameTileLayer extends RenderableLayer<TileLayer> {
required this.animationFrames,
required this.ignoreFlip,
super.filterQuality,
}) {
_layerPaint
..color = Color.fromRGBO(255, 255, 255, opacity)
..filterQuality = filterQuality;
}
});

/// {@macro flame_tile_layer}
static FlameTileLayer load({
Expand Down

0 comments on commit 256e56d

Please sign in to comment.