Inspiration

Forget defusing bombs, try splitting a snack perfectly in half while your sibling breathes down your neck. ​One millimeter off? Total war. ​This game takes the everyday childhood trauma of "fair shares" and turns it into a high-stakes, sweat-inducing precision challenge. Because in this kitchen, geometry isn't just math, it's survival.

What it does

Everyone on the subreddit gets the same fruit, snack or vegetable each day. Could be an orange, a bent carrot, a Kitkat, a lumpy potato, a big head of broccoli. You get one cut, and one cut only.

You can pick it up and spin it around first to scope out its shape (produce is never perfectly symmetrical, which is the whole point). Then you line up the knife and slice. The two halves fall onto a pair of kitchen scales, and your score is basically "how close were the two weights?" Nail a near-perfect split and you'll see something like 99.4%.

After you play you find out where you landed for the day; the percent of players you beat, a little bar chart of everyone's scores with yours highlighted, and your current streak. There's also a share button that copies a spoiler-free result you can paste into the comments to call out the rest of the sub.

The math behind the score is nothing fancy - just the lighter half over the heavier half:

balance = (min(weightA, weightB) / max(weightA, weightB)) × 100

How we built it

It's a Devvit Web app, TypeScript on both the client and the server so they can share the produce definitions and scoring code.

The 3D is all three.js. The part I sank the most time into is the slicer: given the knife's plane, it clips the produce mesh into two pieces, builds a fresh flat face where the cut happened, and works out the actual volume of each half. That volume is what turns into grams on the scales, so it had to be right.

The fruit itself is mostly generated in code. I use layered noise to push the surface around into believable bumps and give it a slight bend, then a few small shaders (injected into three's standard material) to add blotches, freckles, and the tell-tale patterns; watermelon stripes, the little seed ring in a kiwi, the chambers in a tomato. No texture files for those. For the hero items I also load real .glb models and run them through the same slicer.

On the backend it's a small Hono server with Redis doing the heavy lifting: the daily leaderboard, making sure you only get one go per day, the score histogram, and everyone's streak stats.

Challenges we ran into

Cutting a 3D mesh in real time and getting a clean face back was the hard part, and I rewrote it more than once. Real fruit is bumpy, so the cut can't assume a nice flat circle.

The sneakier problem was fairness. Since the shape decides the weights, everyone has to see the exact same fruit; if my potato is even slightly different from yours, the same cut scores differently and the leaderboard is meaningless. So every lump and wobble is generated from a fixed seed. Zero randomness in the geometry.

I also spent a very confused evening on a bug where the whole fruit only drew about a sixth of itself and floated there like a little umbrella. Turned out to be a three.js thing with material groups on indexed geometry. Swapping the uncut fruit to a single material fixed it instantly, after way too long staring at it.

Smaller stuff that still ate time: keeping the halves sitting on the scale pans instead of clipping through them, letting you rotate the fruit without it sinking into the table, and shrinking the broccoli model from a ridiculous 47 MB down to about 3 so it'd actually load fast on a phone.

Accomplishments that we're proud of

You can cut a 3D vegetable inside a Reddit post, on your phone, and get a real weight back. The procedural fruit ended up looking way better than I expected for having basically no image assets. And the full daily loop is there: play, see how you stack up, keep a streak, share it.

What we learned

A lot about Devvit and building inside its limits (serverless, Redis, one-shot-per-day logic). A lot about the geometry side too; clipping planes, capping a cut, computing volumes. And mostly, how much "the same for everyone" matters the second a game turns into a shared daily competition.

What's next for Fair Slice

  • Lean into the community side: a daily comment thread, score flair, shout-outs for the day's best cut.
  • Let people submit their own produce to feature.
  • Weekly themed fruit, plus badges and "perfect cut" milestones.
  • Sound - the knife thunk and the clink of the scales are badly missing.

Built With

Share this project:

Updates

Submission history