Обучение

Обучение · 02

Пока эта страница доступна только на английском.

Your Seed and Mine

Most casino games ask you to take them on faith. Tower asks you to take it on math.

Every floor of every climb, which stones hide a slip and which one carries a bonus, is decided by two seeds and a counter, run through a keyed hash. One seed is BitKong's. One is yours. Neither side can steer the result alone, and afterwards you can check that nobody did.

This is what provably fair means.

Two seeds and a counter

Server seed. A long random string from BitKong's side. You never see it before you climb. You see its hash instead: a SHA-256 fingerprint that locks BitKong to that exact seed without giving it away. When you retire the seed, the seed itself is revealed, and you can hash it yourself to confirm it matches the fingerprint you were shown at the start.

Client seed. Yours. It starts out random, and you can change it whenever you like. BitKong cannot know it in advance, so BitKong cannot work out a climb against you before you make it.

Nonce. A counter. It goes up by one with every climb on the same pair of seeds, so no two climbs share an outcome.

How a floor is decided

Each floor gets its own hash:

HMAC-SHA-256( key: server seed, message: client seed | nonce | floor )

The server seed is the key. The message is your client seed, the nonce and the floor number, counting from zero, joined by |. The result is 32 bytes.

Those bytes shuffle the floor's stones, a Fisher–Yates shuffle drawing one byte at a time, and that decides where the slips are. On floors that can carry a bonus, the next bytes decide whether one lands and on which safe stone.

Notice what is not in the hash: the stone you pick. Every floor of the climb is fixed before your first step, by inputs that were locked in before you began. Your choice changes where you step. It never changes what is there.

Checking a climb

Once the server seed is revealed, you have everything you need:

  1. Hash the revealed server seed with SHA-256. It must match the fingerprint you were shown before you climbed.
  2. Take your client seed and the nonce of the climb you want to check.
  3. For each floor, compute the HMAC above and shuffle the stones the same way.
  4. The tower you rebuild must be the tower you climbed: every slip and every bonus in the same place.

If it is not, BitKong cheated. It will not be.

Where to check

A verifier opens on bitkong.com with the tower. Paste your seeds, choose a climb, and watch it rebuild floor by floor. The functions behind it are open. Read them if you want.

Why this matters

Most casino games have to be trusted. Most could be rigged in ways you would never notice. A provably fair game is a different shape entirely: every climber can audit every climb.

The tower is fair. Fairness is not the same as kindness. The math is the math.