CreatureCounter constructor
CreatureCounter({
- required TickerProvider vsync,
- required List<
Color> initialColors, - required int initialCounter,
- BlendMode blend = BlendMode.hardLight,
Implementation
CreatureCounter(
{required TickerProvider vsync,
required List<Color> initialColors,
required int initialCounter,
BlendMode blend = BlendMode.hardLight}) {
_counter = initialCounter;
_colors = initialColors;
_blend = blend;
_controller = AnimationController(
vsync: vsync,
upperBound: 2,
duration: const Duration(seconds: 10),
)..repeat();
_addPointController = AnimationController(
vsync: vsync,
duration: const Duration(milliseconds: 500),
);
_addPointAnimation =
_addPointController.drive(CurveTween(curve: Curves.ease));
}