Add watercolour artwork for all campaign discoveries

This commit is contained in:
Hadrian Burkhardt
2026-10-31 18:25:02 +01:00
parent e163cbb832
commit 36fbbce6ef
32 changed files with 348 additions and 25 deletions
+17 -2
View File
@@ -586,7 +586,7 @@ class _NotebookState extends State<Notebook> with WidgetsBindingObserver {
);
case 3:
body.addAll([
const Sketch('match'),
discoveryArt(g.book.levels.first, height: 155),
writing(
g.recovered(0)
? 'A pattern restored · a memory kept'
@@ -1026,6 +1026,21 @@ class _NotebookState extends State<Notebook> with WidgetsBindingObserver {
}
}
Widget discoveryArt(CampaignLevel level, {double height = 190}) {
if (level.illustrationAsset case final asset?) {
return Image.asset(
asset,
height: height,
width: double.infinity,
fit: BoxFit.contain,
semanticLabel: 'Watercolour illustration: ${level.object}',
errorBuilder: (_, _, _) =>
PixelPicture(level.picture, label: level.object, height: height),
);
}
return PixelPicture(level.picture, label: level.object, height: height);
}
Widget reveal() {
final i = g.campaignIndex, l = g.book.levels[i];
return Leaf(
@@ -1041,7 +1056,7 @@ class _NotebookState extends State<Notebook> with WidgetsBindingObserver {
color: muted,
),
writing(l.object, size: 35),
PixelPicture(l.picture, label: l.object),
discoveryArt(l),
writing(l.after, size: 25),
gap(),
writing(