# Contract design **Published by:** [ChanceDAO](https://paragraph.com/@chancedao/) **Published on:** 2022-03-25 **URL:** https://paragraph.com/@chancedao/contract-design ## Content Chance DAO's gameplay has already been introduced, and this article will briefly describe the gameplay from a contractual perspective. Chance contract covered all rules of play.Draft Diagram of Chance DAO contractDraft Diagram of Chance DAO contractChance DAO contract📝The chance contract contains four core contracts: 1️⃣Chance 2️⃣ChanceDrop 3️⃣Chance Invite 4️⃣VRFv2Consumer 🧐Details of the rules can be found with How to Play🔴Chance contractBased on ERC721 Chance contract be in charge of Minting and withdrawing the winning amount or rebate amount through this contract🟡ChanceDrop contractResponsible for picking a winner at random, the random numbers are generated by oracles.The winning rule is a 90% probability of being elected in the current round of minted NFTs, 10% probability of being elected in the history round of minted NFTs.🔵ChanceInvite contractThis is an invitation promotion contract.You can set your own unique invitation code, When the invitee mints NFT within 30 days, there will be a 10% minting price awards to you.When you successfully invite 10 people, you can withdraw all your rebate rewards from Chance contract.🟢VRFv2Consumer contractA contract that request true random numbers, you can check the details to see how it works: VRFv2Consumer contract. 👇Smart contract code has been uploaded to Github, please check it out! https://github.com/ChanceDAO ## Publication Information - [ChanceDAO](https://paragraph.com/@chancedao/): Publication homepage - [All Posts](https://paragraph.com/@chancedao/): More posts from this publication - [RSS Feed](https://api.paragraph.com/blogs/rss/@chancedao): Subscribe to updates - [Twitter](https://twitter.com/chance_dao): Follow on Twitter