diff --git a/lib/super.dart b/lib/super.dart index 965ecd8..1f91ef3 100644 --- a/lib/super.dart +++ b/lib/super.dart @@ -72,6 +72,19 @@ class _SuperGameState extends State { turn: turn, cellOnTapCallback: (int i) { if (!_checkValidChoice(data[subGame], i)) { + showDialog( + context: context, + builder: (context) => AlertDialog( + content: + Text("${data[subGame][i].name.toUpperCase()}" + " already claimed " + "[${i % 3}, ${(i / 3).floor()}]"), + actions: [ + ElevatedButton( + onPressed: () => Navigator.pop(context), + child: const Text("Close")) + ], + )); return; }