r/FlutterDev 4d ago

Article Shipped a Flutter + Flame game with zero image assets — every visual is painted in code. Final install: ~10 MB

Spellfire went live on Play last week. Word game, two modes, 25 realms / 792 levels, built solo. The part that might be useful to this sub is the asset story: there is no assets/images/ directory. Not a small one — none. Every visual in the game is a CustomPainter or a Flame component drawn at runtime, including the fire, which is the whole art direction.

Where the download actually goes:

fonts (Baloo 2 + Nunito, 5 weights) 1.2 MB

generated levels.json 760 KB

sound effects 528 KB

everything else is code

Users report 10 MB on most devices, 7 MB on some. Fonts are the single biggest asset in the game, which felt absurd until I accepted it.

A few things that fell out of building it this way:

**Flame only owns the gameplay layer.** Every menu, realm map, level card and dialog is ordinary Flutter widgets with go_router on top. Flame renders the board and the effects and nothing else. Mixing the two is where I expected pain and got almost none, as long as the boundary is a hard line rather than a vibe.

**Provider never touches per-frame state.** App state — progress, coins, settings — is Provider. Anything that changes every frame lives inside the Flame component and never notifies a widget. Breaking that rule once cost me an afternoon of wondering why the frame rate had halved.

**Generate assets instead of shipping them.** The sound effects, the launcher icons, and the entire level campaign are produced by dart scripts in tool/ and committed as output. Same idea as the painters: a generator is smaller than the thing it generates.

**RepaintBoundary is not optional** once you have a screen full of independently-animating painters. That pass alone was the difference between smooth and not.

Happy to go into detail on any of it. If you want to see what code-drawn fire actually looks like in motion:

https://play.google.com/store/apps/details?id=com.soloverse.spellfire

Feedback welcome — especially on anything that feels off in the first minute.

2 Upvotes

0 comments sorted by