From daa2b6f8ef739193ee8f339914f8b24671b8c965 Mon Sep 17 00:00:00 2001 From: Luan Nico Date: Fri, 1 Jan 2021 12:58:18 -0500 Subject: [PATCH] Bump versions and fix lint issues (v0.x) (#599) --- .github/workflows/test.yml | 2 +- CHANGELOG.md | 4 ++++ doc/README.md | 2 +- doc/examples/animation_widget/pubspec.yaml | 1 + doc/examples/animations/pubspec.yaml | 1 + doc/examples/aseprite/pubspec.yaml | 1 + doc/examples/audiopool/pubspec.yaml | 2 ++ doc/examples/box2d/contact_callbacks/pubspec.yaml | 3 ++- doc/examples/box2d/simple/pubspec.yaml | 3 ++- doc/examples/debug/pubspec.yaml | 3 ++- doc/examples/effects/combined_effects/pubspec.yaml | 3 ++- doc/examples/effects/infinite_effects/pubspec.yaml | 3 ++- doc/examples/effects/sequence_effect/pubspec.yaml | 3 ++- doc/examples/effects/simple/pubspec.yaml | 3 ++- doc/examples/gestures/pubspec.yaml | 3 ++- doc/examples/go_desktop/pubspec.yaml | 3 ++- doc/examples/isometric/pubspec.yaml | 1 + doc/examples/joystick/pubspec.yaml | 3 ++- doc/examples/keyboard/pubspec.yaml | 3 ++- doc/examples/layers/pubspec.yaml | 5 ++--- doc/examples/nine_tile_box/pubspec.yaml | 3 ++- doc/examples/parallax/pubspec.yaml | 3 ++- doc/examples/particles/pubspec.yaml | 3 ++- doc/examples/render_flip/pubspec.yaml | 3 ++- doc/examples/sound/pubspec.yaml | 2 ++ doc/examples/sprite_batch/pubspec.yaml | 3 ++- doc/examples/sprites/pubspec.yaml | 3 ++- doc/examples/spritesheet/pubspec.yaml | 3 ++- doc/examples/text/pubspec.yaml | 1 + doc/examples/timer/pubspec.yaml | 3 ++- doc/examples/widgets/pubspec.yaml | 3 ++- doc/examples/with_widgets_overlay/pubspec.yaml | 3 ++- example/pubspec.yaml | 1 + lib/animation.dart | 4 ++-- pubspec.yaml | 8 ++++---- 35 files changed, 66 insertions(+), 32 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index c683378b6c4..68c887b0a6c 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -13,7 +13,7 @@ jobs: java-version: '12.x' - uses: subosito/flutter-action@v1 with: - channel: 'beta' + channel: 'stable' - run: flutter --version - run: flutter pub get - run: ./scripts/lint.sh diff --git a/CHANGELOG.md b/CHANGELOG.md index 0c987d7dd35..874d212a491 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ ## [next] +## 0.29.0 +- Update audioplayers to latest version (now `assets` will not be added to prefixes automatically) +- Fix lint issues with 0.28.0 + ## 0.28.0 - Fix spriteAsWidget deprecation message - Add `lineHeight` property to `TextConfig` diff --git a/doc/README.md b/doc/README.md index 88c330a0774..b47f4ed113d 100644 --- a/doc/README.md +++ b/doc/README.md @@ -18,7 +18,7 @@ Put the pub package as your dependency by dropping the following in your `pubspe ```yaml dependencies: - flame: ^0.28.0 + flame: ^0.29.0 ``` And start using it! diff --git a/doc/examples/animation_widget/pubspec.yaml b/doc/examples/animation_widget/pubspec.yaml index cc60be88071..0dfe1861aa6 100644 --- a/doc/examples/animation_widget/pubspec.yaml +++ b/doc/examples/animation_widget/pubspec.yaml @@ -2,6 +2,7 @@ name: animation_widget description: A sample Flame project to showcase the animationAsWidget method. version: 0.1.0 +publish_to: none environment: sdk: ">=2.0.0-dev.68.0 <3.0.0" diff --git a/doc/examples/animations/pubspec.yaml b/doc/examples/animations/pubspec.yaml index 563ff937621..faa4343882a 100644 --- a/doc/examples/animations/pubspec.yaml +++ b/doc/examples/animations/pubspec.yaml @@ -2,6 +2,7 @@ name: animations description: Flame sample game showcasing animations features version: 1.0.0+1 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/aseprite/pubspec.yaml b/doc/examples/aseprite/pubspec.yaml index 356f34ca44f..1b906cec13e 100644 --- a/doc/examples/aseprite/pubspec.yaml +++ b/doc/examples/aseprite/pubspec.yaml @@ -2,6 +2,7 @@ name: aseprite description: Flame sample for using Aseprite animations version: 1.0.0+1 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/audiopool/pubspec.yaml b/doc/examples/audiopool/pubspec.yaml index c74f1629731..6c7c6e199e5 100644 --- a/doc/examples/audiopool/pubspec.yaml +++ b/doc/examples/audiopool/pubspec.yaml @@ -1,6 +1,8 @@ name: audiopool description: Flame example application showcasing the audiopool class + version: 0.1.0 +publish_to: none environment: sdk: ">=2.0.0-dev.68.0 <3.0.0" diff --git a/doc/examples/box2d/contact_callbacks/pubspec.yaml b/doc/examples/box2d/contact_callbacks/pubspec.yaml index 4929f45d15a..850f2a3e975 100644 --- a/doc/examples/box2d/contact_callbacks/pubspec.yaml +++ b/doc/examples/box2d/contact_callbacks/pubspec.yaml @@ -1,7 +1,8 @@ name: box2d_contact_callbacks description: Flame sample game showcasing the structure for box2d games -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/box2d/simple/pubspec.yaml b/doc/examples/box2d/simple/pubspec.yaml index c7a024d86a1..64b9555edc5 100644 --- a/doc/examples/box2d/simple/pubspec.yaml +++ b/doc/examples/box2d/simple/pubspec.yaml @@ -1,7 +1,8 @@ name: box2d description: Flame sample game showcasing the structure for box2d games -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/debug/pubspec.yaml b/doc/examples/debug/pubspec.yaml index 6dea24adf59..bafa4228f96 100644 --- a/doc/examples/debug/pubspec.yaml +++ b/doc/examples/debug/pubspec.yaml @@ -1,7 +1,8 @@ name: debug description: Flame sample for using debug features -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/effects/combined_effects/pubspec.yaml b/doc/examples/effects/combined_effects/pubspec.yaml index 55d48e57f35..811eed1d500 100644 --- a/doc/examples/effects/combined_effects/pubspec.yaml +++ b/doc/examples/effects/combined_effects/pubspec.yaml @@ -1,7 +1,8 @@ name: combined_effects description: Flame sample game showcasing combined effects -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/effects/infinite_effects/pubspec.yaml b/doc/examples/effects/infinite_effects/pubspec.yaml index 59cc1f3bb89..324c0de7816 100644 --- a/doc/examples/effects/infinite_effects/pubspec.yaml +++ b/doc/examples/effects/infinite_effects/pubspec.yaml @@ -1,7 +1,8 @@ name: infinite_effects description: Flame sample game showcasing infinite effects -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/effects/sequence_effect/pubspec.yaml b/doc/examples/effects/sequence_effect/pubspec.yaml index 6d5931ecff7..e23bb99aeea 100644 --- a/doc/examples/effects/sequence_effect/pubspec.yaml +++ b/doc/examples/effects/sequence_effect/pubspec.yaml @@ -1,7 +1,8 @@ name: sequence_effect description: Flame sample game showcasing the sequence effect -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/effects/simple/pubspec.yaml b/doc/examples/effects/simple/pubspec.yaml index 69b27db7733..c2b91dcd827 100644 --- a/doc/examples/effects/simple/pubspec.yaml +++ b/doc/examples/effects/simple/pubspec.yaml @@ -1,7 +1,8 @@ name: effects description: A Flame game showcasing the use of the effects api -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/gestures/pubspec.yaml b/doc/examples/gestures/pubspec.yaml index 5a74dc9123b..3843b18c19a 100644 --- a/doc/examples/gestures/pubspec.yaml +++ b/doc/examples/gestures/pubspec.yaml @@ -1,7 +1,8 @@ name: gestures description: A flame game showcasing the use of gestures callbacks -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/go_desktop/pubspec.yaml b/doc/examples/go_desktop/pubspec.yaml index ea333628745..a91b06dd845 100644 --- a/doc/examples/go_desktop/pubspec.yaml +++ b/doc/examples/go_desktop/pubspec.yaml @@ -1,7 +1,8 @@ name: go_desktop description: Flame sample game on using the go flutter desktop framework -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/isometric/pubspec.yaml b/doc/examples/isometric/pubspec.yaml index 5b6e39e4df0..51b5745d9c4 100644 --- a/doc/examples/isometric/pubspec.yaml +++ b/doc/examples/isometric/pubspec.yaml @@ -2,6 +2,7 @@ name: isometric description: Example of isometric tilemap using Flame version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/joystick/pubspec.yaml b/doc/examples/joystick/pubspec.yaml index 16396061579..6d2fb0dcdb5 100644 --- a/doc/examples/joystick/pubspec.yaml +++ b/doc/examples/joystick/pubspec.yaml @@ -1,7 +1,8 @@ name: joystick description: A flame game showcasing the use of joystick -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/keyboard/pubspec.yaml b/doc/examples/keyboard/pubspec.yaml index 2daeceacfa6..2198fa4a39b 100644 --- a/doc/examples/keyboard/pubspec.yaml +++ b/doc/examples/keyboard/pubspec.yaml @@ -1,7 +1,8 @@ name: keyboard description: Simple Flame project showcasing how to use the Keyboard events -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/layers/pubspec.yaml b/doc/examples/layers/pubspec.yaml index d1a64a83c68..4d537833d2a 100644 --- a/doc/examples/layers/pubspec.yaml +++ b/doc/examples/layers/pubspec.yaml @@ -1,9 +1,8 @@ name: layers description: Simple project to showcase the layer feature of Flame -publish_to: 'none' # Remove this line if you wish to publish to pub.dev - -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.7.0 <3.0.0" diff --git a/doc/examples/nine_tile_box/pubspec.yaml b/doc/examples/nine_tile_box/pubspec.yaml index cb8f5a8f19c..1bf3e1b488f 100644 --- a/doc/examples/nine_tile_box/pubspec.yaml +++ b/doc/examples/nine_tile_box/pubspec.yaml @@ -1,7 +1,8 @@ name: nine_tile_box description: Flame sample for using the nine_tile_box feature -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/parallax/pubspec.yaml b/doc/examples/parallax/pubspec.yaml index 97338cc98fd..11ed5e8a16f 100644 --- a/doc/examples/parallax/pubspec.yaml +++ b/doc/examples/parallax/pubspec.yaml @@ -1,7 +1,8 @@ name: parallax description: Flame sample game showcasing the parallax features -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/particles/pubspec.yaml b/doc/examples/particles/pubspec.yaml index 2856e4544de..8a44fd58862 100644 --- a/doc/examples/particles/pubspec.yaml +++ b/doc/examples/particles/pubspec.yaml @@ -1,7 +1,8 @@ name: particles description: Flame sample game showcasing particle effects -version: 1.0.0 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/render_flip/pubspec.yaml b/doc/examples/render_flip/pubspec.yaml index a2e63c764d9..6b0e7c2a8d2 100644 --- a/doc/examples/render_flip/pubspec.yaml +++ b/doc/examples/render_flip/pubspec.yaml @@ -1,7 +1,8 @@ name: render_flip description: Flame sample game showcasing animations features -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/sound/pubspec.yaml b/doc/examples/sound/pubspec.yaml index e8483718748..e8515494cf4 100644 --- a/doc/examples/sound/pubspec.yaml +++ b/doc/examples/sound/pubspec.yaml @@ -1,6 +1,8 @@ name: sound description: Flame example application showcasing the audio features + version: 0.1.0 +publish_to: none environment: sdk: ">=2.0.0-dev.68.0 <3.0.0" diff --git a/doc/examples/sprite_batch/pubspec.yaml b/doc/examples/sprite_batch/pubspec.yaml index eab9766ead2..099e63af4d9 100644 --- a/doc/examples/sprite_batch/pubspec.yaml +++ b/doc/examples/sprite_batch/pubspec.yaml @@ -1,7 +1,8 @@ name: sprite_batch description: Showcasing SpriteBatch features -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/sprites/pubspec.yaml b/doc/examples/sprites/pubspec.yaml index 757cce95586..53644d5f761 100644 --- a/doc/examples/sprites/pubspec.yaml +++ b/doc/examples/sprites/pubspec.yaml @@ -1,7 +1,8 @@ name: sprites description: Flame sample game showcasing rendering 500 sprites -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/spritesheet/pubspec.yaml b/doc/examples/spritesheet/pubspec.yaml index dec48fabf19..e1427577ec0 100644 --- a/doc/examples/spritesheet/pubspec.yaml +++ b/doc/examples/spritesheet/pubspec.yaml @@ -1,7 +1,8 @@ name: spritesheet description: Flame sample game showcasing spritesheet features -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/text/pubspec.yaml b/doc/examples/text/pubspec.yaml index de4ff0969c5..5bf27fc1eee 100644 --- a/doc/examples/text/pubspec.yaml +++ b/doc/examples/text/pubspec.yaml @@ -2,6 +2,7 @@ name: text description: A sample Flame project that renders texts. version: 0.1.0 +publish_to: none environment: sdk: ">=2.0.0-dev.68.0 <3.0.0" diff --git a/doc/examples/timer/pubspec.yaml b/doc/examples/timer/pubspec.yaml index 18a7824e704..84fd62572ca 100644 --- a/doc/examples/timer/pubspec.yaml +++ b/doc/examples/timer/pubspec.yaml @@ -1,7 +1,8 @@ name: timer description: Example app using Timer class -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.0.0-dev.68.0 <3.0.0" diff --git a/doc/examples/widgets/pubspec.yaml b/doc/examples/widgets/pubspec.yaml index 9c9856cc4cf..13c1ab31eeb 100644 --- a/doc/examples/widgets/pubspec.yaml +++ b/doc/examples/widgets/pubspec.yaml @@ -1,7 +1,8 @@ name: widgets description: A Flutter project showcasing Flame's widgets. -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.1.0 <3.0.0" diff --git a/doc/examples/with_widgets_overlay/pubspec.yaml b/doc/examples/with_widgets_overlay/pubspec.yaml index f465b6781b7..6beea48d6af 100644 --- a/doc/examples/with_widgets_overlay/pubspec.yaml +++ b/doc/examples/with_widgets_overlay/pubspec.yaml @@ -1,7 +1,8 @@ name: with_widgets_overlay description: A Flame game showcasing how to use the WithWidgetsOverlay feature -version: 1.0.0+1 +version: 0.1.0 +publish_to: none environment: sdk: ">=2.0.0-dev.68.0 <3.0.0" diff --git a/example/pubspec.yaml b/example/pubspec.yaml index 457e90c663b..5658515d64c 100644 --- a/example/pubspec.yaml +++ b/example/pubspec.yaml @@ -2,6 +2,7 @@ name: position_component description: A new Flutter project. version: 0.1.0 +publish_to: none environment: sdk: ">=2.0.0 <3.0.0" diff --git a/lib/animation.dart b/lib/animation.dart index 463e1e1135c..e7bdfa6ec4a 100644 --- a/lib/animation.dart +++ b/lib/animation.dart @@ -83,7 +83,7 @@ class Animation { this.loop = true, }) : assert(amountPerRow == null || amount >= amountPerRow) { amountPerRow ??= amount; - frames = List(amount); + frames = List.filled(amount, null); for (var i = 0; i < amount; i++) { final Sprite sprite = Sprite( imagePath, @@ -109,7 +109,7 @@ class Animation { this.loop = true, }) : assert(amountPerRow == null || amount >= amountPerRow) { amountPerRow ??= amount; - frames = List(amount); + frames = List.filled(amount, null); for (var i = 0; i < amount; i++) { final Sprite sprite = Sprite( imagePath, diff --git a/pubspec.yaml b/pubspec.yaml index d639fab949a..9ed618abdf9 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,14 +1,14 @@ name: flame description: A minimalist Flutter game engine, provides a nice set of somewhat independent modules you can choose from. -version: 0.28.0 +version: 0.29.0 homepage: https://github.com/flame-engine/flame dependencies: flutter: sdk: flutter - audioplayers: ^0.15.1 - ordered_set: ^2.0.0 - path_provider: ^1.6.0 + audioplayers: ^0.17.1 + ordered_set: ^2.0.1 + path_provider: ^1.6.24 box2d_flame: ^0.4.6 synchronized: ^2.1.0 convert: ^2.0.1