mirror of
https://github.com/flame-engine/flame.git
synced 2025-11-01 10:38:17 +08:00
Fixing lint
This commit is contained in:
@ -58,8 +58,11 @@ class MyGame extends BaseGame {
|
|||||||
Vector2 cellSize;
|
Vector2 cellSize;
|
||||||
Vector2 halfCellSize;
|
Vector2 halfCellSize;
|
||||||
|
|
||||||
MyGame({Vector2 screenSize}) {
|
@override
|
||||||
size = screenSize;
|
Future<void> onLoad() async {
|
||||||
|
await images.load('zap.png');
|
||||||
|
await images.load('boom3.png');
|
||||||
|
|
||||||
cellSize = size / gridSize;
|
cellSize = size / gridSize;
|
||||||
halfCellSize = cellSize * .5;
|
halfCellSize = cellSize * .5;
|
||||||
|
|
||||||
@ -67,12 +70,6 @@ class MyGame extends BaseGame {
|
|||||||
Timer.periodic(sceneDuration, (_) => spawnParticles());
|
Timer.periodic(sceneDuration, (_) => spawnParticles());
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
|
||||||
Future<void> onLoad() async {
|
|
||||||
await images.load('zap.png');
|
|
||||||
await images.load('boom3.png');
|
|
||||||
}
|
|
||||||
|
|
||||||
/// Showcases various different uses of [Particle]
|
/// Showcases various different uses of [Particle]
|
||||||
/// and its derivatives
|
/// and its derivatives
|
||||||
void spawnParticles() {
|
void spawnParticles() {
|
||||||
|
|||||||
@ -3,7 +3,6 @@ import 'dart:math';
|
|||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flame/game.dart';
|
import 'package:flame/game.dart';
|
||||||
import 'package:flame/sprite_batch.dart';
|
import 'package:flame/sprite_batch.dart';
|
||||||
import 'package:flame/extensions/vector2.dart';
|
|
||||||
import 'package:flame/components/sprite_batch_component.dart';
|
import 'package:flame/components/sprite_batch_component.dart';
|
||||||
|
|
||||||
void main() async {
|
void main() async {
|
||||||
|
|||||||
@ -6,7 +6,6 @@ import 'package:flame/components/text_component.dart';
|
|||||||
import 'package:flame/game.dart';
|
import 'package:flame/game.dart';
|
||||||
import 'package:flame/palette.dart';
|
import 'package:flame/palette.dart';
|
||||||
import 'package:flame/text_config.dart';
|
import 'package:flame/text_config.dart';
|
||||||
import 'package:flame/extensions/vector2.dart';
|
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
void main() {
|
void main() {
|
||||||
|
|||||||
Reference in New Issue
Block a user