BC.GAMEOfficial siteOfficial
Go to bc.gamebc.game

Provably Fair

Every BC Originals result can be checked with the server seed, the client seed and the nonce. Pick a game to see how its result is calculated.

Baccarat Multiplayer

Validate

Is The Game Fair?

Every round has a pre-generated SHA256 hash. The hashes form a chain and are released in reverse order, each corresponding to one round of the game. The SHA256 of a round's hash equals the hash of the previous round, so the results cannot be changed once the chain is published.

The cards of a round are calculated from its hash and a salt. The salt is the hash of Bitcoin block 790,100 (0000000000000000000301e2801a9a9598bfb114e574a91a887f2132f33047e6), which had not been mined when the chain was published.

How Are the Results Calculated?

  1. seed = HMAC_SHA256 with the round's hash (decoded from hexadecimal into bytes) as the message and the salt as the key.
  2. Shuffle the 52 cards by the seed (first shuffle), then shuffle the result again by the SHA256 of the seed (second shuffle).
  3. The first six cards are used: Player gets the 1st and 3rd cards, Banker gets the 2nd and 4th cards, and the 5th and 6th cards are used when a third card is drawn.
function seedGenerator(hash, salt) {
  const hmac = CryptoJS.HmacSHA256(CryptoJS.enc.Hex.parse(hash), salt);
  return hmac.toString(CryptoJS.enc.Hex);
}
function createNums(allNums, hash) {
  const nums = [];
  let h = CryptoJS.SHA256(hash).toString(CryptoJS.enc.Hex);
  allNums.forEach((c) => {
 nums.push({ num: c, hash: h });
 h = h.substring(1) + h.charAt(0);
  });
  nums.sort(function (o1, o2) {
 if (o1.hash < o2.hash) {
 return -1;
 } else if (o1.hash === o2.hash) {
 return 0;
 } else {
 return 1;
 }
  });
  return nums;
}