Please describe your proposed solution
As we are developing cPoker, a decentralized poker game on cardano, we are in the right spot to create and share a practical, non-trivial example of working smart contract for interactive exchange of value with multiple participants. See the video at the bottom of this section to get an idea of the cPoker application.
With this proposal we intend to fund the open development of smart contracts for implementing a peer-to-peer protocol for escrow and payout with poker rules. We'll provide it openly so many real-world dApps can benefit from it.
The smart contract is designed to be robust in real-world conditions, and it will include the following elements:
- Establish a Table token for each active table, stored in the smart contract (source code)
- Enable key contract transactions on that Table for players to join the table and exit the table
- Minimize fee overhead for the Table contract
- Ensure all funds paid in by table players are also paid back out to the players (peer-to-peer game)
- Implement designed elements to guard against player misbehaviors such as game abandonment, ensuring incentive alignment
- Enable cash-out transaction for post-game settlement with player-consensus mechanism
- Enforce the presence of the DRED network-operator contract to cover costs of the communication-channel providers (the DRED contract will require its own fee tokens)
You can get an idea of the architecture from this diagram
Beyond the technical elements, we will share progress with the community:
- Present our progress on a twice-monthly basis in the ODIN Build group in an open session for community developers to have this learning opportunity about real-world contract development and real-time on-chain value exchange with Cardano.
In the video below, you can understand the team's overall effort for building a real-time interactive dApp. From this video, you can get an idea of how the protocol will be used in the real-world application.
<https://www.youtube.com/watch?v=ERWI-xHvXE0>Note: The scope of this proposal is the development of the smart contracts for the dApp.
- The development of the dApp and the development of the side-channel are not in scope for this proposal.