Carray Battle won the "Technical Effects Award" in NEO's 1st Blockchain Game Development Competition.
Chinese Version: HERE
Gameplay Demo: HERE
53BC, Eurasia, the war between Roman Republic and Parthian Empire come to the decisive period. The powerful Roman encountered the toughest defence and could not make a move near the town of Carrhae. However they had another plot.
The poetry-loving Persians in Carrhae had an obscure custom. The bards would play their new chapter of epos in turns during the ceremonies. The townees and visitors voted the most beautiful one as the tribute to the Gods, which would induce luck, wealth or disaster to different people, cities and countries. Althrough the impacts were predictable, townees insisted to vote the best by their hearts even if the disaster would arrive on themselves.
But this time, Romans attempted to manipulate the ceremony, for the result of the Battle of Carrhae...
This article discribes the the gameplay and technology features of CarrhaeBattle, and acknowledge those who helped this project. For other content please refer to (In Chinese Language and will translate soon):
Carrhae Battle is a blockchain card game to simulate the famous trust dilemma Byzantine General Problem. The players act the generals in the ancient Eurasia, deploy the cards to the trigger or participate in the sieges for the trophies.
The story behind Byzantine General Problem is: Several allied generals could win the siege only if enough forces eventually joined. But due to the unreliable communication, each one of them had to think of the authenticity and the latency of the messages they received before issuing an order. Carrhae Battle uses Asymmentropy to temporary "cloak" the players' real actions on blockchain to simulate this process, so players could only know the coming army's real stand (or just a smokescreen) before the siege start. (Note: simulating BGP is optional when players create a new server. It will downgrade to conventional card siege game if this option is off. More details please see Soft Server).
Carrhae Battle is also the first blockchain game to empower the decentralized voted epos to impact the game world. In every chapter's cycle, the players in each server vote the best next chapter. The hash result of the chapter decides the positive or negative impacts on the cities and players respectively. The bard as the author of the voted chapter would be awarded with the voting tokens and be granted some superpower during this cycle as well. By reading the epos, we'll know which servers have the majority of the art sponsors, the self-sacrificers, or the power chasers. (Note: No topic restriction for the "epos")
1. Engine Layer
With the opportunity of developing the NEO version of Carrhae Battle, we developed and open sourced the project Neunity (MIT), in order to help increase the efficiency of developing large scale NEO smart contracts. The features Neunity realized include：
- [Finished] The Adapter layer to realize NEO smart contract local offline breakpoint debug and test cases, while share the SC logic (class definitions and algorithms) with C# client. Video Tutorial
- [Finished] Flexible class serialization method NuSD.
- [Finished] HTTP-like SC invocation protocol: Neunity Transfer Protocol(NuTP).
- [Finished] URI-like Storage management method NuIO.
Thanks the people for helping Carrhae Battle and Neunity with code and innovative solutions:
- generalkim00 and maxpown3r: The idea of "Asymmentropy" to keep competitive Dapps fair and jam-proof. Asymmentropy can also help bookkeepers to avoid transaction-reversing suspicion in competitive Dapps. [Introduction，Chinese Version (Chapter 2.2)]
- FabioRick and Jason L Perry：How to generate multiple random numbers in one block. Also published the article "Random Number at Runtime"
- gongxiaojing0825 and exclusivesunil ： Neunity Continuous Integration bash script on Mac.
Thank you guys very much.
At the same time, very glad to see Neunity can help other teams to increase their development efficiency during this competition. Including: #140 NEOPixelBattle ,#78 BigRedLottery, #95 CarveLoveonBlockchain, #111 Pirateo, #100 FomoNEO, #55 Devourer, #46 CarryBattle
Neunity is going to integrate NEO-Lux RPC to further simplify the development process.
2. Application Layer
- In order to realize the "information delay" to simulate Byzantine General Problem, we'll employ the Asymmentropy algorthim.（Intro Chapter 2.2)
- Carrhae Battle is a blockchain game with full logic on chain. The players can experience the full game without dependency of centralized server (Not even require the client app). The full onchain logic can ensure the digital asset that players own not only be kept forever, but also be usable forever.
- Carrhae Battle client is developed with Unity, support deployment to iOS, Android, H5 and PC/Mac clients.
- Since information on blockchain are public, the late-mover advantage could be very strong in many cases. We designed the Information Subsidy (Intro Chapter 3.1) to balance it.
- Soft Server (Intro) is designed specifically for blockchain games to reduce the invoking cost when number of players and assets increases.
For more information about the technology part, please read from HERE.
Instant Message Channel: Discord
Thanks generalkim00 and maxpown3r the authors of another game BigRedLottery for the method of Asymmentropy. This is used in both BigRedLottery and Carrhae Battle to generate undisputed inter-block randomness.