mirror of
https://github.com/johrpan/christmas_cats.git
synced 2025-10-28 03:07:25 +01:00
The items can be bought directly from the running game in the future. The player can get free coins from the main and pause menu.
40 lines
993 B
Dart
40 lines
993 B
Dart
import 'package:flutter/material.dart';
|
|
import 'package:sprintf/sprintf.dart';
|
|
|
|
import '../localizations.dart';
|
|
import '../widgets/get_coins.dart';
|
|
import '../widgets/menu.dart';
|
|
import '../widgets/menu_entry.dart';
|
|
|
|
class PauseScreen extends StatelessWidget {
|
|
final int score;
|
|
|
|
PauseScreen({
|
|
this.score,
|
|
});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
final localizations = ChristmasCatsLocalizations.of(context);
|
|
|
|
return Scaffold(
|
|
resizeToAvoidBottomInset: false,
|
|
backgroundColor: Color(0xccffffff),
|
|
body: Menu(
|
|
title: localizations.paused,
|
|
subtitle: sprintf(localizations.score, [score]),
|
|
children: <Widget>[
|
|
MenuEntry(
|
|
text: localizations.unpause,
|
|
onTap: () => Navigator.pop(context, true),
|
|
),
|
|
GetCoins(),
|
|
MenuEntry(
|
|
text: localizations.exit,
|
|
onTap: () => Navigator.pop(context, false),
|
|
),
|
|
],
|
|
),
|
|
);
|
|
}
|
|
}
|