Etherplay : A Provably Fair Skill Game Platform Using Ethereum

We did not made the headlines yet and we thought it is time to explain what Etherplay is all about. This blog post will hopefully give you a general idea of what it is. If you have any questions, do not hesitate to leave comments.

What is Etherplay?

Before everything else, Etherplay is a game platform. It aims at providing fun games for players all over the world. Our team has always had a passion for games. We love playing them and more importantly we love making them. This is our opportunity to do it for the long term and for the enjoyment of everybody.

Coming from the casual “free to play” game industry it was a bit disappointing to see so many cool game ideas turn into half baked game with the promise of infinite upgrades. As a game designer you needed to design a playable game with holes in it so that paying players could get a more complete game. But this often resulted in games that could never be made whole. Of course not every games suffered from it and there are success stories but the general rules influenced them in one way or another. We wanted a different path.

Our first childhood video games we played were games from the arcade machines at our local fair and this is the model that inspired us. We wanted to bring back that magic to a global scale where the highscore list becomes worldwide and top players get rewarded.

In a similar way that arcade machines require you to put your money for every play, Etherplay require the player to pay a small fee to play a game session. The difference is that the fee get added to a jackpot that is shared among the players with the top scores.

Competitions are organized automatically and run for a limited time. At the end of each competition the players with the top score get a share of the jackpot. To allow us to improve and make new games, we take a percentage of that jackpot. For now it is 25% (a standard for skill game platform) and we will never go bigger that this.

Ethereum

One thing that set Etherplay apart from other similar game platform is that we are using an awesome new technology called Ethereum.

At the beginning we were planning to use traditional technology and currencies. But after discovering Ethereum, it was clear that using that technology will bring us and our players many advantages.

Ethereum for those we do not know is both a technology where the name come from and a social community based around that technology. It is a set of computer that cooperate to ensure honest execution of a set of rules. Some describe it as an attempt to build a world’s computer.

For Etherplay it allows us to build a transparent and verifiable system. You can be sure that players are all treated equals and if we at Etherplay were trying to bend the rules, this would be visible to the whole world. More on that later.

Of course, Ethereum also introduces friction. Most of the world is still at odd with public/private key system and the idea of Ethereum is still far from widespread. We are thus relying on the brave crypto users to pave the way for the other future players.

How does it work?

Etherplay requires the use of an ethereum client like metamask or mist. The client allows the player to interact with the Ethereum blockchain which require signing and broadcasting transaction to the available ethereum nodes on the internet. Each of these transactions takes time as they need to be “mined” by special nodes that get rewarded by “mining” transactions into so called “blocks”. Part of the reward the “miners” get is the mandatory transaction fee that is part of every transaction.

Etherplay requires at max 2 ethereum transactions per play. The first and mandatory transaction is for starting a new game. The player pays the gas required for Ethereum plus a fee that will be added to the total jackpot. The seed and time of play are recorded on the ethereum blockchain and used later to verify the player game session.

The second transaction that happen at the end of the game is only necessary to save the score if the score is better than the player’s previous score and worthy enough to be among the top. Only a gas cost will be necessary here. This transaction needs to be executed right away after finishing the game because we do not allow players to submit their score too long after the end of the game to avoid the possibility of cheating.

Since transaction takes time to be confirmed it is possible that when it get mined, it is too late. In that case the game session becomes invalid. We decided to let the player play right away anyway and cancel the session if that happens. The alternative was to make the players wait until the transaction get mined before starting to play but this is can be too long to wait. We are thinking to offer the choice in a latter version of our platform if the rate of failed start is too high.

Why Ethereum?

We discovered Ethereum in March and it blew our mind so much that anything we thought had to relate to Ethereum :) It turned out that for our use case ( a skill game platform) it was the perfect match.

Reduced Complexity And Risk

Ethereum reduce complexity by a great extent making our system safe and secure. By using it, we do not need to manage user accounts, nor their money. All of it is managed by the smart contract and consensus network that Ethereum provides. Of course, Ethereum brings its own challenge but being able to deal with player’s money without the risk of screwing up is a real boon. Players can feel confident about their security. With Ethereum there is no need for Etherplay to even have players’ accounts in its system.

This has allowed us to have a very simple backend. Our backend has 2 part, the user facing one is built in go using Google App Engine and serves the web pages and game. The other is the verifier built in javascript running on Node.js that probe the ethereum blockchain regularly to verify players’ submissions by replaying their game. It talks to the other part to update the verified scores. All of this is less than 3000 lines of code.

The community

The Ethereum community is really great and helped us boostrap our platform. We got lots of good feedback from our 2 successful beta. For the last one we provided a reward in real ether. This has given information on the soundness of our system and smart contract. We are confident that we are ready for release. Thanks to all who participated! We hope that our mainnet release will meet with even more enthusiasm.

Micro transactions and Automatism

Ethereum blockchain with its relatively low gas cost (we would love it to be even smaller :) allow our players to play games for a very small fee. This is an improvement over other skill game platform which use traditional currencies as they require players to pay a bigger sum upfront that is then stored on their server. With Etherplay we do not need to make our players put more money than needed to play our games.

Ethereum also allows Etherplay to pays the players automatically. This is a significant advantage over other skill game platform where players are required to have a minimum amount to withdraw to cover the cost of traditional currencies transaction.

Provably Fair

Ethereum allows Etherplay platform to be transparent and verifiable. Every transactions is verifiable and traceable on the ethereum network. Since our system records all the data, it is possible to verify if the correct players got the reward.

When the player start the game, the time and the seed get recorded on the blockchain. Upon finishing with a highscore the player submit the proof (consisting of player’s inputs) and create a transaction to ethereum with the proof’s hash alongside the score and duration of the game. If the time taken to submit does not exceed by much the time taken to play the game, that transaction will be accepted and the proof hash alongside the score will be saved on the blockchain.

At the end of the competition, our verifier sort the player’s submission based on their score and verify them one by one. If the score or duration do not match the score is rejected and the next submission is considered. At the end of the process, we get the list of the winners and submit a special “rewardWinners” transaction with that list as input. These winners get the reward based on the jackpot and the parameters set at the beginning of the competition. This is also when we got our part of the jackpot (we cannot get it before).

While Etherplay could give a list of its own accounts to the “rewardWinners” transaction in order to get all the ether it would be visible to everybody since every submission can be replayed and inspected. As such our system can be proven to be valid at each competition. This is a unique feature of our skill game platform.

Conclusion

We hope that this blog post has given you a general idea of what Etherplay is. We also hope it got you interested in playing. Stay tuned, we plan to release our platform on the mainnet next week on http://etherplay.io ! Here is a pick at what is coming :

Thanks for reading,

The Etherplay team