Jump to content

$4,000 Top Tier Habanero Multiplier Battle!


BCGame_Ewa

Recommended Posts

Link to comment
Share on other sites

Link to comment
Share on other sites

https://bc.game/#/sd/10XTZBT5TTHYQB

image.png.599f448e8ce14a89f4da8980bee821d5.png

https://bc.game/#/sd/10XTZQ5JUOLMVN

image.png.b04c0d2902d91d7a72a367caa87e98e3.png

https://bc.game/#/sd/10XU0B6NTOETXV

image.png.9bb39e8e590ee176be392f852dbaf21f.png

https://bc.game/#/sd/10XU7DA0TX7EHF

image.png.03bf7cf3d23460709a02b296e8fa4874.png

https://bc.game/#/sd/10XU7JMUJFGCGJ

image.png.dd49e0666bc6cb96467aeed299e03e30.png

https://bc.game/#/sd/10XU889SQGK93N

image.png.45ac47175f89a4cb48fb0db61c84d840.png

https://bc.game/#/sd/10XU8Y3W51O3RN

image.png.07ba5abbee7a76e64b12137f9a4039a0.png

  • Mighty Medusa                                                                                                                                                                       

 

Edited by JuanLazyTV
Link to comment
Share on other sites

Link to comment
Share on other sites

Good okay 

On ۱۴۰۱/۶/۱۲ at 20:56, JackSonova said:

[EDIT: I realize I may have misunderstood you, so below may be more complicated than desired. If when you say you can only verify game in bc.game modal  you mean that it does not let you input a server seed/client seed/nonce independent of the game, (because I know that when you click verify results, it does not let you input those fields) then you can actually find the same form with input fields that do allow you to change the seed/nonce/etc. here: https://bc.game/mines_help/validate ]

_______

Yes, you can take the code provided by BC.Game on the provably fair modal popup that appears when you click on the help icon on the game page. Just copy and paste this code into a Node.js instance. Then you can enter your variables and run to generate the numbers.

For Example, you can use Runkit, Codepen,io, etc. to do it all from a browser. As an example and reference,  you can see how I did it here.:  https://runkit.com/nucleare/bc-games-mines-provably-fair-verifier

For ease of reference, this is the code below with some minor modifications so that you only have to replace the seeds/client seed/nonce to produce a result.

I'm working on a more user-friendly version with visual sbut at the moment this is just a barebones, copy n paste of the BC.Games provided function script for mines.

const crypto = require("crypto");

function getResult(hash) {
  const allNums = [
    7, 2, 19, 25, 1, 13, 5, 24, 14, 6, 15, 9, 22, 16, 3, 17, 18, 20, 8, 21, 4,
    12, 10, 23, 11,
  ];
  let seed = hash;
  let finalNums = createNums(allNums, seed);
  seed = crypto.createHash("SHA256").update(seed).digest("hex");
  finalNums = createNums(finalNums, seed);
  return finalNums.map((m) => m.num.num);
}

function createNums(allNums, hash) {
  let nums = [];
  let h = crypto.createHash("SHA256").update(hash).digest("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;
}

function main (serverSeed, clientSeed, nonce) {
  let resultArr = [clientSeed, nonce];
  let hmacSha256Result = crypto.createHmac("sha256", serverSeed).update(resultArr.join(":")).digest("hex")
  let resultList = getResult(hmacSha256Result);


  



همچنین، می‌توانید آن را در یک فایل متنی کپی کنید و به عنوان فایل js ذخیره کنید تا اجرا شود.

 

Link to comment
Share on other sites

Link to comment
Share on other sites

  • Moderator
Link to comment
Share on other sites

Link to comment
Share on other sites

Link to comment
Share on other sites

Link to comment
Share on other sites

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...