ZK MultiPlayer Card Game
Play, Shuffle, Win – All While Keeping Your Hand Secure with zkShuffle and Privacy powered by Manta Blockchain
Created on 12th August 2024
•
ZK MultiPlayer Card Game
Play, Shuffle, Win – All While Keeping Your Hand Secure with zkShuffle and Privacy powered by Manta Blockchain
The problem ZK MultiPlayer Card Game solves
The zkShuffle Card Game is a decentralized, multiplayer card game built on blockchain technology. Utilizing the zkShuffle SDK by Manta Network, this game ensures complete privacy for player hands, allowing for a secure and anonymous gaming experience. The game features advanced functionalities, including multiplayer lobbies, multiple decks, in-game tokens, AI opponents, player statistics, and live streaming.
Features
- Privacy-Preserving Gameplay: With zkShuffle by Manta Network, players' hands remain private throughout the game.
- Multiplayer Lobbies: Create or join lobbies and challenge other players in real-time.
- Multiple Deck Choices: Choose from a variety of decks to keep the game interesting.
- In-Game Tokens: Earn tokens as you play, which can be used for various in-game activities or traded.
- AI Opponents: Challenge AI-driven opponents if you prefer single-player modes.
- Player Statistics: Track your performance with detailed statistics on wins, losses, and more.
- Live Streaming: Watch live games and learn from other players' strategies.
How the DApp Works
-
Lobby Creation and Joining: Players can either create a new lobby or join an existing one. Each lobby supports a set number of players.
-
Deck Selection: Once the lobby is full, players select their preferred decks. The
cardConfig()function ensures that all players have the correct deck configuration. -
Game Start: The
startGame()function shuffles the deck and deals the cards, ensuring that each player's hand remains private through zkShuffle. -
Gameplay: Players take turns playing cards by invoking the
playCard(uint8 cardIndex)function. The played card is revealed to all, but the rest of the player's hand remains private. -
Game End: The game ends when all rounds are completed or a player reaches the win condition. The
endGame()function then distributes rewards, including in-game tokens.
Challenges I ran into
Privacy with zkShuffle by Manta Network
The core privacy feature of the game is powered by zkShuffle, an SDK developed by Manta Network. zkShuffle uses zero-knowledge proofs (zk-SNARKs) to shuffle and encrypt the deck of cards in such a way that no player, including the one initiating the shuffle, can determine the order of cards.
How Privacy is Maintained:
- Zero-Knowledge Proofs: zkShuffle ensures that the shuffle and distribution of cards are done in a manner that preserves player anonymity.
- Encryption: Each player's hand is encrypted, and only the respective player can decrypt their cards. This is verified by the
encryptVerifierin theShuffleGameInfostruct. - Verifiable Randomness: The shuffle process is both random and verifiable, ensuring fairness without revealing any player's hand.
By combining blockchain technology with zkShuffle, this game guarantees that your strategies and cards remain secure and private, making it a truly decentralized and trustless experience.
Tracks Applied (1)
Web3 Innovation Track
Manta Network
Technologies used
Cheer Project
Cheering for a project means supporting a project you like with as little as 0.0025 ETH. Right now, you can Cheer using ETH on Arbitrum, Optimism and Base.

