Whitepaper
How the network runs — the two specimens, the five-step loop, what the tolls pay for, and the contracts underneath.
1 · What this is
Neuron Mining is a staking game on BNB Smart Chain, dressed as a simulated fly brain. Flies are cultured, staked in the Nectary, and produce NECTAR. Swatters are cultured, staked in the Grid, and take a cut of every claim.
Neither specimen is decoration. One produces, the other skims, and the two are in direct conflict by design. Both come out of the same mint and share one staking entry point, addManyToBarnAndPack — which side a token lands on is decided at mint, not by the holder.
2 · The specimens
One culture, two outcomes. Roughly nine in ten come out a Fly.
| Fly | Swatter | |
|---|---|---|
| Share of cultures | ~90% | ~10% |
| Where it goes | Nectary | The Grid |
| What it does | Produces NECTAR | Takes a cut of every claim |
| Key parameter | DAILY_CHEESE_RATE() | CHEESE_CLAIM_TAX_PERCENTAGE() and cheesePerAlpha() |
| Shown in this front end | 1,600 NECTAR / day per Fly | 20% of every Nectary claim |
| Alpha | — | α5–8, capped by MAX_ALPHA() |
| Exit lock | MINIMUM_TO_EXIT() | MINIMUM_TO_EXIT() |
The figures in the fifth row are what this front end displays today. The authority for each is the contract getter named beside it — read them from the deployment before quoting a number.
3 · The economy
One culture costs 10 USD and every cent of it goes into the pool. This is what the pool promises back.
| Price | 10 USD, paid into the pool |
| Specimen split | ~90% Fly / ~10% Swatter |
| Supply | 50,000 — 45,000 Flies, 5,000 Swatters |
| Emission | fixed per NFT, released linearly. It does not chase the price. |
| Payback target | 5 days for a Fly |
| Fly budget | 8,000 NECTAR over 5 days, 1,600 a day |
| Swatter budget | 14,400 NECTAR over 5 days, 2,880 a day — 1.8× a Fly, which is the 20% tax expressed as a budget |
| Farm emission | 432,000,000 NECTAR, 43% of a 1,000,000,000 supply |
| Implied break-even | $0.00156 per NECTAR |
Break-even is a price, not a promise
A Fly's budget is fixed in NECTAR, so the payback period floats with the market. At the numbers above, the 6,400 NECTAR a Fly actually keeps over 5 days is worth 10 USD when NECTAR trades at $0.00156. Above that price the Fly is ahead; below it, it is not. A payback quoted in days without the price is half a fact.
What the pool takes in, and what it owes
Every culture brings in 10 USD. Per culture the pool owes 0.9 Flies × 12.5 USD of gross output = 11.25 USD — 9 to the Flies as their 5-day payback, and 2.25 to the Swatters as their 20%.
So the pool collects exactly the principal it promises back, and pays out 1.25 USD more per culture than it takes in: a 20% Swat Tax means the pool owes 1/0.8 = 1.25× what it collects. That 1.25 USD has to come from somewhere other than the mint, which is what §6 is about. Read plainly, a pool funded only by cultures returns exactly the money that came in — the average player is at zero before any leakage, and every payout is money a later player put in. What makes it worth playing is the price of NECTAR, and what keeps the pool liquid is new cultures.
The exit lock
MINIMUM_TO_EXIT() counts from the moment a token is staked, not from the end of its budget. With a 5-day budget and a 2-day lock, a Fly can be pulled out on day two having produced 40% of what it was owed — the rest is simply never emitted. Leaving early is allowed; it is not free.
The cap has to fit the budget
MAXIMUM_GLOBAL_CHEESE() is a hard ceiling on everything the farm emits. Set it below 50,000 cultures × 1.08 × the Fly budget — 432,000,000 NECTAR at the numbers above — and the farm runs dry mid-flight. In the contract this front end was derived from, every token staked after the ceiling is reached earns nothing at all, so the cap has to be sized against the budget rather than discovered by it.
4 · The loop
- Push the curve — Buy or hold NECTAR through FLAP. The curve fills toward 100%.
- Culture —
mint(amount, stake). The specimen is decided here, not chosen. - Stake —
addManyToBarnAndPack(account, tokenIds). Flies and Swatters share one entry point. - Claim —
claimManyFromBarnAndPack(tokenIds, unstake). The Swat Tax comes off here.
5 · The signal
The signal meter is a readout of the FLAP curve, not a gate. Nothing is locked behind it — culturing, staking and claiming work from the first block, whether the signal sits at 0% or 100%.
This front end reads the curve from flap-adapter.js. It starts at 37%, and each demo purchase moves it 8 points.
This front end reads FLAP through exactly one file, flap-adapter.js. It exposes the curve state, the progress and the buy link, and nothing in the UI binds the Portal directly. Toll revenue is routed FLAP 3/3 → BrainTreasury.
6 · Tolls are not the Swat Tax
Two different cuts run through this game. Conflating them is the easiest mistake to make here.
Swat Tax 20%
Taken when a Nectary claim settles, off what the Flies produced. This is what the Swatters are paid from.
Market tolls
FLAP market fees routed to BrainTreasury. They pay for three player-facing things: Grid Charge, Nectary Boost and Culture Rebate.
Portal setting: deflationBps=500 + mktBps=9500. The tax lands in BrainTreasury, and the lucky spike is what it currently pays for.
The 3/3, and the lucky spike
The 3/3 is the trading tax on NECTAR itself, set when the token launches. It lands in BrainTreasury. Right now the treasury has exactly one outgoing: one culture in twenty spikes, and it pays 10 USD of the pool currency — currently BNB — straight to whoever opened it.
Priced out, a 5% hit rate at 10 USD is 0.50 USD of expected value per culture, or 25,000 USD across the full 50,000. It needs roughly 833 USD of daily trading volume per 100 cultures a day to fund. The odds, the amount and the currency all live in js/config.js — change the pool currency there and the copy follows it.
7 · Contract surface
The two contracts this front end is written against. The fiction renamed the cast; the contracts kept their names.
CatMouse — the NFT
| Function | What it does |
|---|---|
mint(amount, stake) | Cultures amount tokens, paying MINT_PRICE() each. stake sends them straight into the Nectary or the Grid in the same call. |
tokenTraits(tokenId) | Specimen and the full trait tuple for a token. The species flag is what splits the Nectary from the Grid. |
minted() | How many have been cultured so far, against MAX_TOKENS(). |
setEntropy(bytes32) | Sets the entropy seed the reveal is drawn from. |
setPaused(bool) | Halts culturing and transfers on the NFT. |
withdraw() | Owner sweep of the contract balance. |
CheeseBarn — the staking pool
| Function | What it does |
|---|---|
addManyToBarnAndPack(account, tokenIds) | The single staking entry for both specimens — the pool sorts by species on the way in. |
claimManyFromBarnAndPack(tokenIds, unstake) | Claims NECTAR for the given tokens. unstake also pulls them back out. |
DAILY_CHEESE_RATE() | NECTAR produced per Fly per day. |
CHEESE_CLAIM_TAX_PERCENTAGE() | The percentage taken at claim — the Swat Tax. |
MAXIMUM_GLOBAL_CHEESE() | Ceiling on total NECTAR emitted over the pool's life. |
cheesePerAlpha() | How much a Swatter's alpha is worth when the cut is split. |
MINIMUM_TO_EXIT() | How long a token must stay staked before it can leave. |
rescue(tokenIds) | Hands back tokens that got stuck in the pool. |
Swatter staking settles on an owner drawn by seed — see randomCatOwner(seed). The pool emits TokenStaked, MouseClaimed and CatClaimed.
The rest of the surface is read-only: isMouse(tokenId), totalMiceStaked(), totalAlphaStaked(), totalCheeseEarned(), lastClaimTimestamp(), unaccountedRewards(), PAID_TOKENS(), paused(), owner().
8 · Randomness, pause, rescue
Specimen and traits are assigned from an entropy source the owner controls, and either contract can be stopped.
setEntropy(bytes32)anddemoEntropy()— the seed traits are drawn from, and a demo mode for it.setVrfCoordinator(coordinator, useVrfOnly)— move to a VRF coordinator, optionally VRF-only.setPaused(bool)— either contract can be halted.rescue(tokenIds)andsetRescueEnabled(bool)— the pool can hand back tokens stuck inside it.
Tax taken while no Swatter is staked is not lost. It accrues in unaccountedRewards() and is handed to the Grid once Swatters arrive — so the earliest Swatters earn more than the later ones.
These are owner-side controls. Read them before assuming how a reveal or a halt will behave.
9 · The front end, and what is wired today
This build is a complete front end pointed at contracts that are not configured inside it.
The lane
The hub carries one playable thing: a drop lands on the flight lane, you send the Fly for it, and a Swatter patrolling the same lane will take it first if it can. It is scored for the visit only — fetched, swatted, best streak — and it deliberately touches neither NECTAR nor stored state. It is the loop, run by hand.
Two languages
Every player-visible string lives in js/i18n.js and the markup carries only the key, so English and Chinese cannot drift apart. Chinese sets in ZCOOL QingKe HuangYou for the display type, and the document declares its own language so a screen reader does not read Chinese with an English voice.
The demo runs the real arithmetic
With no addresses set, staked Flies accrue at the configured rate, a Nectary claim splits that gross 80/20 between the Fly and the tax pot, and the Swatters draw the pot by alpha. That is the contract's arithmetic, running on a number in your browser instead of on chain.
- Addresses come from the
cma_catMouseandcma_cheeseBarnlocal storage keys, and default to empty inconfig.js. - With no addresses set, the curve state, the progress and your holdings are demo state living in this browser only.
- Nothing is written on-chain.
flap-adapter.jsis a local model, not a Portal binding. - Set both addresses to point this same UI at a real deployment.
- The model itself — price, odds, prize, pool currency — lives in
js/config.js. Change it there, not in the pages.
Fill in the two addresses — in config.js, or under the cma_catMouse and cma_cheeseBarn local storage keys — to point it at a deployment. Until then, treat every number on screen as a demo, not a balance.