Limboにおけるプロバブリーフェアの仕組み
CloudbetでのLimboの遊び方と、各倍率がプロバブリーフェアであることを確認する方法をご紹介します。
Limboの遊び方
Limboはスピーディでシンプルな倍率ゲームです。各ラウンドが始まる前に、目標倍率——狙いたい勝利の大きさ——を設定します。ベットを確定すると結果倍率が生成されます。それが目標値以上であれば、目標倍率分の配当を獲得できます。目標値を下回った場合はそのラウンドで負けとなります。
設定する目標倍率が高いほど、当たったときの勝利額は大きくなりますが、その分結果が目標値に到達する可能性は低くなります。ベットのたびに、目標値はお好きなだけ低くも高くも設定できます。
Cloudbet Originals Limbo
CloudbetオリジナルのLimboは、99%のRTP、最大x1,000,000の倍率を備え、$0.01から$20,000までのベットに対応しています。
Limboの乱数は、ほかのすべてのCloudbet Originalsと同じ検証可能な方法で生成されます——サーバーシード、クライアントシード、ノンスがどのようにラウンドシグネチャーへ結合され、そこからSHAKE256によって乱数列が生成されるかについては、Cloudbetのプロバブリーフェアシステムをご覧ください。このページでは、Limbo特有の部分——その乱数がどのように、あなたが競う倍率になるのか——を解説します。
倍率の計算方法
Limboは、SHAKE256によって生成される32ビットの乱数から始まります。この乱数は一様分布しており、0から2³²-1までのあらゆる値が等しい確率で出現します。
しかし、私たちが必要とするのはこの分布そのままの形ではありません。倍率は、巨大な値よりも小さな値の方がはるかに頻繁に出る必要があります——1.01倍が出る確率は、100,000倍が出る確率よりもずっと高くなければなりません。そこで、この乱数は次のように段階的に形を変えられます。
- リジェクションサンプリングが使われますが、軽い形にとどまります——後で1を加算するため、取り得る最大の数値だけが引かれることを避けるためです。
- その数値に1が加算されます(これにより0になることがなくなり、手順4の割り算で問題が生じません)。
- 取り得る最大値で割ることで、0から1の間の小数にスケールダウンされます。
- 0.99(Limboのペイアウト率)をその小数で割ります——この手順によって、一様な分布が、小さな倍率の方が大きな倍率よりも指数関数的に頻繁に出る分布へと変換されます。
- 結果は小数点以下2桁に切り捨てられます。
- 最後に、Limboの有効な範囲に「クリップ」されます。1未満の値はすべて1になり(最小ベットは1.01倍であるため、1未満の結果はすべて単なる負けとなります)、1,000,000を超える値はすべて1,000,000になります(Limboの最大配当)。

生成された倍率は、いったん確定すると固定され非公開になります——ベットを確定した後に変更することはできません。倍率に到達する前にキャッシュアウトするかどうかが、そのラウンドの結果を決めます。
ご自身のLimboの結果を検証する
以下のコードはCloudbetのLimbo実装に忠実なものです。サーバーシード、クライアントシード、ノンスを入力してご自身の結果を再現してください。補足:Cloudbetでゲームのサーバーシードを公開するには、別のサーバーシードの使用を開始する必要があります。
依存関係:
npm install js-sha3
コード:
// If you are running this yourself, then you can input your own data here
// You can then compare:
// 1) Cloudbet's provided Commitment to the Commitment outputted here. This proves that the Server Seed was not altered during gameplay.
// 2) Cloudbet's provided game outcome to the game outcome outputted here. This proves that your game's outcome was determined solely by the pre-game seeds and was not altered afterwards.
let myServerSeed = 'your_server_seed'; // ✍️YOUR_INPUT✍️: Enter your (unhashed) Server Seed here
let myClientSeed = 'your_client_seed'; // ✍️YOUR_INPUT✍️: Enter your Client Seed here
let myNonce = 0; // ✍️YOUR_INPUT✍️: Enter your Nonce here
const usingCustomData = false; // Change this to true if you are using your own data
// Load libraries
const crypto = require('crypto');
const { sha3_256, shake256 } = require('js-sha3');
// Step 1: Generate a Server Seed and Commitment
// And generate a Client Seed - either by player input or by the player's browser
function generateServerSeed() {
let seed = crypto.randomBytes(32).toString('hex');
if (usingCustomData) { seed = myServerSeed; }
const commitment = sha3_256(seed);
return { 'serverSeed': seed, 'commitment': commitment };
}
function getClientSeed() {
let seed = crypto.randomBytes(32).toString('hex');
if (usingCustomData) { seed = myClientSeed; }
return seed;
}
// Step 2: Create a Round Signature with SHA3 using a Server Seed, Client Seed and Nonce
function createRoundSignature(serverSeed, clientSeed, nonce) {
return sha3_256(`${serverSeed}:${clientSeed}:${nonce}`);
}
// Step 3: Create a SHAKE256 stream generator from a Round Signature.
// To simplify this example program, this function doesn't create a stream, but instead a sequence of custom length.
function* createRandomNumberSequence(numbersToGenerate, roundSignature) {
const numOfBytes = 4 * numbersToGenerate; // 4 bytes (32 bits) per random number we generate
const byteStream = shake256.create(8 * numOfBytes); // shake takes bits as input
byteStream.update(roundSignature); // Use the Round Signature to seed the generator
const buf = Buffer.from(byteStream.digest()); // The Buffer class lets us package every 4 bytes into one 32-bit integer
for (let i = 0; i < numbersToGenerate; i++) {
yield buf.readUInt32BE(i * 4); // Read buf in 4-byte steps
}
throw new Error("No more numbers in the random number sequence! Fix: make 'numbersToGenerate' larger.");
}
// Step 4: Draw from the random number sequence to calculate the game result
function getGameResult(rng) {
let randomInt32 = rng.next().value; // 'randomInt32' ranges from 0 and 4294967295
while (randomInt32 == 0xFFFFFFFF) { randomInt32 = rng.next().value; } // This can basically be ignored
const fraction = (randomInt32 + 1) / 0xFFFFFFFF; // 'fraction' ranges from 0 to 1
const inverse = 0.99 / fraction; // 'inverse' ranges from 0 to (basically) infinity
let crashPoint = Math.floor(inverse * 100) / 100; // Cut off everything past the second decimal place
// We force the crashpoint to range from 1 to 1,000,000
if (crashPoint < 1.0) {
crashPoint = 1.0;
}
if (crashPoint > 1000000) {
crashPoint = 1000000;
}
return crashPoint;
}
// Example usage
(function main() {
let nonce = 1;
if (usingCustomData) { nonce = myNonce; }
const { serverSeed, commitment } = generateServerSeed();
const clientSeed = getClientSeed();
const roundSignature = createRoundSignature(serverSeed, clientSeed, nonce);
const numbersToGenerate = 1 * 2; // We need 1 random number, but there is an improbable case we'll need two
const rng = createRandomNumberSequence(numbersToGenerate, roundSignature);
const value = getGameResult(rng);
console.log('📝 Commitment (shown before the game):', commitment);
console.log('🔒 Server Seed (revealed after the game):', serverSeed);
console.log('🎲 Client Seed:', clientSeed);
console.log('🔢 Nonce:', nonce);
console.log('🔁 Round Signature (can be verified after the game):', roundSignature);
console.log('⛓️💥 Break Point:', value);
})();
