|
|
@ -19,6 +19,7 @@ class AndroidBumper extends BodyComponent with InitialPosition {
|
|
|
|
required double minorRadius,
|
|
|
|
required double minorRadius,
|
|
|
|
required String litAssetPath,
|
|
|
|
required String litAssetPath,
|
|
|
|
required String dimmedAssetPath,
|
|
|
|
required String dimmedAssetPath,
|
|
|
|
|
|
|
|
required Vector2 spritePosition,
|
|
|
|
Iterable<Component>? children,
|
|
|
|
Iterable<Component>? children,
|
|
|
|
required this.bloc,
|
|
|
|
required this.bloc,
|
|
|
|
}) : _majorRadius = majorRadius,
|
|
|
|
}) : _majorRadius = majorRadius,
|
|
|
@ -32,6 +33,7 @@ class AndroidBumper extends BodyComponent with InitialPosition {
|
|
|
|
_AndroidBumperSpriteGroupComponent(
|
|
|
|
_AndroidBumperSpriteGroupComponent(
|
|
|
|
dimmedAssetPath: dimmedAssetPath,
|
|
|
|
dimmedAssetPath: dimmedAssetPath,
|
|
|
|
litAssetPath: litAssetPath,
|
|
|
|
litAssetPath: litAssetPath,
|
|
|
|
|
|
|
|
position: spritePosition,
|
|
|
|
state: bloc.state,
|
|
|
|
state: bloc.state,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
...?children,
|
|
|
|
...?children,
|
|
|
@ -46,6 +48,7 @@ class AndroidBumper extends BodyComponent with InitialPosition {
|
|
|
|
minorRadius: 2.97,
|
|
|
|
minorRadius: 2.97,
|
|
|
|
litAssetPath: Assets.images.androidBumper.a.lit.keyName,
|
|
|
|
litAssetPath: Assets.images.androidBumper.a.lit.keyName,
|
|
|
|
dimmedAssetPath: Assets.images.androidBumper.a.dimmed.keyName,
|
|
|
|
dimmedAssetPath: Assets.images.androidBumper.a.dimmed.keyName,
|
|
|
|
|
|
|
|
spritePosition: Vector2(0, -0.1),
|
|
|
|
bloc: AndroidBumperCubit(),
|
|
|
|
bloc: AndroidBumperCubit(),
|
|
|
|
children: children,
|
|
|
|
children: children,
|
|
|
|
);
|
|
|
|
);
|
|
|
@ -58,6 +61,7 @@ class AndroidBumper extends BodyComponent with InitialPosition {
|
|
|
|
minorRadius: 2.79,
|
|
|
|
minorRadius: 2.79,
|
|
|
|
litAssetPath: Assets.images.androidBumper.b.lit.keyName,
|
|
|
|
litAssetPath: Assets.images.androidBumper.b.lit.keyName,
|
|
|
|
dimmedAssetPath: Assets.images.androidBumper.b.dimmed.keyName,
|
|
|
|
dimmedAssetPath: Assets.images.androidBumper.b.dimmed.keyName,
|
|
|
|
|
|
|
|
spritePosition: Vector2(0, -0.1),
|
|
|
|
bloc: AndroidBumperCubit(),
|
|
|
|
bloc: AndroidBumperCubit(),
|
|
|
|
children: children,
|
|
|
|
children: children,
|
|
|
|
);
|
|
|
|
);
|
|
|
@ -70,6 +74,7 @@ class AndroidBumper extends BodyComponent with InitialPosition {
|
|
|
|
minorRadius: 2.97,
|
|
|
|
minorRadius: 2.97,
|
|
|
|
litAssetPath: Assets.images.androidBumper.cow.lit.keyName,
|
|
|
|
litAssetPath: Assets.images.androidBumper.cow.lit.keyName,
|
|
|
|
dimmedAssetPath: Assets.images.androidBumper.cow.dimmed.keyName,
|
|
|
|
dimmedAssetPath: Assets.images.androidBumper.cow.dimmed.keyName,
|
|
|
|
|
|
|
|
spritePosition: Vector2(0, -0.4),
|
|
|
|
bloc: AndroidBumperCubit(),
|
|
|
|
bloc: AndroidBumperCubit(),
|
|
|
|
children: children,
|
|
|
|
children: children,
|
|
|
|
);
|
|
|
|
);
|
|
|
@ -125,12 +130,13 @@ class _AndroidBumperSpriteGroupComponent
|
|
|
|
_AndroidBumperSpriteGroupComponent({
|
|
|
|
_AndroidBumperSpriteGroupComponent({
|
|
|
|
required String litAssetPath,
|
|
|
|
required String litAssetPath,
|
|
|
|
required String dimmedAssetPath,
|
|
|
|
required String dimmedAssetPath,
|
|
|
|
|
|
|
|
required Vector2 position,
|
|
|
|
required AndroidBumperState state,
|
|
|
|
required AndroidBumperState state,
|
|
|
|
}) : _litAssetPath = litAssetPath,
|
|
|
|
}) : _litAssetPath = litAssetPath,
|
|
|
|
_dimmedAssetPath = dimmedAssetPath,
|
|
|
|
_dimmedAssetPath = dimmedAssetPath,
|
|
|
|
super(
|
|
|
|
super(
|
|
|
|
anchor: Anchor.center,
|
|
|
|
anchor: Anchor.center,
|
|
|
|
position: Vector2(0, -0.1),
|
|
|
|
position: position,
|
|
|
|
current: state,
|
|
|
|
current: state,
|
|
|
|
);
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
|
|