Do the math first: why every upgrade felt like nothing, and why packs shouldn't promise new cards
A playtester got stuck in Osaka: upgrades did almost nothing and the cards ran out. The bots never noticed. The cause was simple math: additive upgrades shrink every level, and promised new cards drain the pool. One Claude Code session rebuilt both to a written formula and added a bot that plays like a first-time player. Part 13.

What we asked“A third playtest, in the player's words: I got stuck in Osaka. Every upgrade has very little impact, and because the player always unlocks new cards, we're running out of cards soon. Do some math. Are you sure we should give the player new cards every pack? That ruins the odds. The prompt then gave the math: why additive upgrades shrink, every level as ×1.10 on income, cost growth so payback stays flat, pure-odds packs with cards released city by city, and a casual bot as the test.”
What happened
- Confirmed the cause with numbers: income was the minimum of four limits, and every line was additive
- Rebuilt the upgrades as about five lines, each ×1.10 on income per level, with the real effect on each button
- Removed the promised new card: every slot rolls the odds, and each city adds its own cards and the next rarity tier
- Added a casual bot and measured every purchase by running two copies of the game, with and without it
After part 12 the bots said every city took 30 to 45 minutes. Then a person played it:
"I got stuck in Osaka. Every upgrade has very little impact, and because the player always unlocks new cards, we're running out of cards soon. Do some math. Are you sure we should give the player new cards every pack? That ruins the odds."
Both problems were plain arithmetic, and both were invisible to a bot that always buys the best option.
Play Osaka
Starts in Tokyo. Open full screen (saves your game).
1. Why every upgrade felt like nothing
Every line said "+10%" or "+15%" a level, but it was added: the knife was worth 1 + 0.1 × level. So the next level is worth 0.1 ÷ (1 + 0.1 × level) of what you have: +6.7% at level 5, +3.3% at level 20, +2% at level 40. Meanwhile each level cost ×1.34 more than the last. Players defend multiplicative upgrades and call additive ones "nothing", and this is why.

On top of that, income was the smallest of four limits: seats and guests, chef speed, ingredient stock and the menu. Only an upgrade to the current bottleneck did anything. The bots' own report showed it: Osaka's income sat around 325K a second from minute 30 to 45.
2. The formula
- Every level is ×1.10 on income, with ×2 milestones at levels 10, 25 and 50. The button shows the real effect, "+10%/s", from the game's own estimate.
- Income is price × plates a second, a product of the lines, not the smallest of them. Each dish still runs out of stock, so the menu still rotates.
- Cost growth. With k lines bought in turn, each costing ×r a level, payback stays flat when r ≈ 1.1k. Four lines multiply, so 1.1⁴ ≈ 1.46, adjusted for each city by how much its cards add (1.47 to 1.53, and 1.71 in Tokyo, where new cards multiply income the most).
- Goals from the math. With a payback of 200 seconds, a purchase comes about every 20 seconds. Each city's goal is set from its income at minute 35, instead of by trial and error.

Did it hold? Over 1,000 upgrades per bot, measured by running two copies of the game for 60 seconds (one with the purchase, one without), the predicted and the measured gain are both a median +10.0% in every city.
3. Packs that keep their odds
Every pack used to promise a new card. That makes rarity meaningless, and it drains a small pool fast: Osaka had 4 local cards. Now every slot rolls the odds, a new card is luck, and a duplicate is a level-up (×1.3 on its fish). To keep the pool from running dry, Tokyo starts with the Common and Uncommon shared cards, and each later city adds its own local fish plus the next rarity tier.
A simulation of 300 runs set the rest. At the old odds, the Legendary and Ultimate cards almost never appeared, so they rose to 1.1% and 0.4%. Players now finish with 88–93% of the cards collected. Later cities give about 6 to 13 new cards each and 20 to 39 level-ups, which carry the numbers:

4. A bot that plays like a person
The old bot always bought the best payback, so it never felt a wall. The new casual bot buys whatever it can afford in screen order, opens a pack whenever it can and takes the first pick. Before this change it didn't get past Tokyo in 90 minutes, in any of 8 runs.
| City | Greedy before | Greedy now | Casual now |
|---|---|---|---|
| Tokyo | 38.6 | 29.2 | 39.3 |
| Osaka | 45.1 | 35.0 | 36.2 |
| Toyama | 38.6 | 39.0 | 38.6 |
| Kanazawa | 29.5 | 39.6 | 35.1 |
| Sapporo | 39.0 | 32.2 | 25.3 |
| Fukuoka | 32.0 | 31.9 | 24.3 |
| Route | 3:46 | 3:22 | 3:22, all 8 runs |
Median minutes to each city's goal, 8 runs each. Osaka no longer goes flat: 2.0M a second at minute 10, 4.3B at minute 30. In a 15-minute browser run in Osaka, playing like a first-time player, it bought something every 29 seconds.
What it cost
One session: 3 hours 34 minutes and $19.58, too long for one prompt; it should have been split.
Still weak: one bot run waits 66 seconds in Osaka's fourth minute (the limit is 60) because Osaka's belt estimate is too high while it fills; Osaka's plate colours are almost mandatory; packs after Tokyo add only 0–12% at once; and the goal bar barely moves until the end, because income grows exponentially and the bar is linear.
Update: a short follow-up
A 30-minute follow-up prompt fixed four of those: the goal bar now fills on a log scale (in Osaka it reads about a third at minute 6 and two thirds at minute 12, where it used to read 0%), Osaka's estimate was scaled to what the belt really earns (the worst wait fell from 66 to 56 seconds), each new dish on the belt starts on the plate colour that earns most for it (a player who never changes colours now finishes Osaka in 28–37 minutes, not 43–61), and the menu board line stays hidden until a dish would earn more on it. The game above is the updated one.
Next: what Cookie Clicker does
We read Cookie Clicker's numbers from its console: most of its purchases add only 1–5%, but they come every 20–30 seconds and are broken by ×2 upgrades and golden cookies. That is the rhythm Neta is still missing.
Do the math for your incremental
- Copy the skill below into
.claude/skills/idle-economy/, or download it. - Write the formula first: ×m a level, cost ×mk for k lines, and the payback you want. Then let the bots confirm it.
- Add a casual bot next to the optimizer, and measure every purchase's real effect.
The skill that made it work
The economy skill from part 4, updated with this part's lessons: multiply instead of add (with the formula for cost growth), every upgrade must visibly move income, and test with a casual bot, not only an optimizer. Copy the rules below, or download it with its references.
- Simulate the real code. The game's rules must run headless (no rendering) with a fixed step and a seeded random generator. Write bots that play that code at high speed: greedy (buys the best payback), cheapest-first and random. Never balance in a separate model of the game.
- Payback time is the main number. Payback = cost ÷ the income it adds per second (not the item's total income). The greedy bot buys the lowest payback. Show payback per purchase in the bot report.
- Get the first five minutes right first. First purchase within about 15–30 s, the first new kind of thing (a card pack, a new dish) within 2 minutes, the first real decision within 5 minutes. In one devlog about 40% of players quit before the first goal, with a median session of 5 minutes.
- No dead time. At the greedy bot's pace, the longest wait with nothing affordable stays under about 60 s in the first 30 minutes and under about 3 minutes after that. Eatventure's tables put every purchase within a small step of the next.
- Cost curves. `cost = base × r^owned` with r between 1.07 and 1.15 (lower r for expensive items, as AdVenture Capitalist does). Each new tier costs about 10× the last, with about 2–4× the payback. Use the bulk-buy formula for ×10 and Max buttons.
- Multiply, don't add. Players defend multiplicative upgrades and call additive ones "nothing". The math: a line worth 1 + s·L gives step s/(1 + s·L) for the next level (+10% a level is +3.3% at level 20) while its cost keeps growing, so payback explodes. Make each level a fixed ×m, and with k lines bought in turn set the cost growth to r ≈ m^k so payback stays flat; with payback P, a purchase comes every (m−1)·P seconds and n purchases give ×m^n, which tells you each stage's goal before any tuning. Milestone pops: ×2 at 25, 50 and 100 owned of something, with a visible celebration, plus a ×2 for everything when all items reach a milestone.
- Plateau, then breakthrough. Every 20–30 minutes income should flatten into a soft wall that a new kind of unlock breaks (a new system, a new shop), not another +5%. That is how Universal Paperclips is built.
- Find dominant strategies. If one bot policy reaches the end more than 1.5× faster than the others, or one item or card is part of the best plan in almost every run, rebalance it.
- Numbers people can read. Exact with separators up to 999,999, then K, M, B, T, Qa, Qi with three significant digits, then scientific; a setting to always use scientific. Keep money in one type behind `format()`. Plain JavaScript numbers are fine below about 1e15 for exact values and 1e308 for floats; only reach for break_infinity.js if the simulator shows you need it.
- A second bottleneck besides coins. With only coins, the best move is always the same. A resource that is used up and refills on its own clock (ingredient stock, energy) makes the player spread out: the best dish runs dry and the second best earns while it refills. Tune it so the top dish covers about 40–60% of sales over 10 minutes, never 100%. A sink should eat something (stock, copies), not only give something.
- Every upgrade must visibly move income. If income is the minimum of several limits (seats, chef speed, stock, guests), every upgrade to a limit that isn't the current bottleneck does nothing, and players feel stuck. Prefer income as a product of multipliers, keep at most one throughput limit, and show each upgrade's real effect on income per second on its button ("+18%/s"). In the bot report, flag any purchase that raised income by less than 5%.
- Test with a casual bot, not only an optimizer. A greedy bot hides walls a person hits. Add a bot that plays like a first-time player (buys whatever it can afford in screen order, opens packs when it can, never plans), and require it to finish each stage within about 1.5x the greedy bot's time.
- Change one thing per pass. Re-run at least 20 seeded bot runs after each change and keep a balance log (what changed, the before and after numbers).
- Report a timeline: when each milestone happens for each bot (median and range), the longest gap, the total time to the current end of content, and a chart if possible.
Save it as .claude/skills/idle-economy/SKILL.md in your project.

