https://medium.com/@pinknetwork/our-unique-bankroll-management-fun-for-players-safe-for-investors-75d668c39370Little over one week ago, we announced our entry into the #BuildOnWax contest held by WAX io. We set ourselves a big goal: To build a decentralized bankroll service from scratch, running on the WAX blockchain, offering developers around the world the opportunity to build their own gambling services quicker and without any risks.
We are very happy with the progress our team made, and now that the contest has reached the halfway mark, we want to give you an update as to what we did so far, and what you can expect in the coming days.
The first thing we did was to publish the beta documentation for our REST/ Websocket API. Usability has been one of the main focuses of our project from the beginning. By offering an extensive gateway to the WAX blockchain, developers are able to build frontend-only sites without any of the drawbacks traditionally faced without a backend server. In the next days, we will make the beta version of our API accessible to the public.
We also developed a completely new way of managing our bankroll. Because our bankroll contract is capable of accepting bets of multiple players and on multiple outcomes, all based on the same random result, traditional bankroll management models could not be applied. Between wanting to offer our end users the best experience possible, and keeping the risk low for bankroll investors, it is important to find a good balance. We are excited to share more details on both how and why our method works soon.
The biggest single task was (and still is) developing the smart contracts.
Therefore, we are very proud to announce that we have deployed them on the WAX mainnet and published the 100% open source code on Github. The main functionality is split in two separate contracts. The bankroll contract, which offers our powerful functionality for placing custom bets, and the gambling contract, which allows for simplified access, including placing bets in a single transaction. We have made the decision to split this functionality in a bid to increase security of the bankroll funds.
Although we are confident that all bugs will be found and fixed before we officially launch, it would be negligent not to take additional precautions. By only keeping the critical functions in the contract holding the bankroll, and moving helper functions into a separate contract, we reduce the risk of having hidden bugs in the bankroll contract. And on top of out own efforts to secure the contract, we are also looking to get a professional smart contract audit done in the near future.
Our plan is to use the WAX RNG Oracle as soon as it will become available on the mainnet. However, as it will still take a couple more weeks until that happens, we had to create our own randomness oracle. We purposely built it in a very similar way to what the “real” WAX oracle will look like, so that when it does come out, we can switch over easily. The randomness generation starts with an account sending a signing_value. This value is then hashed immediately on-chain. Our off-chain oracle then notices this action and signs the generated hash with a preset private key, and sends the signature back to the oracle contract. There, its’ validity is verified, and it is hashed one last time to generate the random value.
Note: Our RNG oracle is provably fair. However, because we are in possession of the private key used to sign the seeds, we could theoretically precalculate the results. This isn’t ideal, and you should be aware of that. Until the official RNG oracle is deployed, you should only use our oracle for trying out the system.
It has to be said that the smart contract development isn’t finished yet. During the next week, we will extensively test the contract for vulnerabilities, and we will update it when needed.
All in all, there certainly is a lot still left to do until the final evaluation of the #BuildOnWax contest next week, but we are confident that we will manage to reach our goals, and we already are very proud of what we have created so far. All the groundwork is done, and now we can focus on polishing the various parts of our project, as well as putting out more content for you to learn about what we’re doing.
In the next days, we will be covering
- Our unique bankroll management - Fun for players, Safe for investors
- A technical look at the pink.network bankroll contract
- Guide: Getting started with the pink.network API
Are you interested in keeping up to date with our project? Follow us on Twitter and you won’t miss any news. Are you interested in using our bankroll contract/ API to build your own awesome site? Check out our documentation, and feel free to contact us. We will be glad to assist you!