Cardano Plutus Tutorial #3: Game Project | Smart Contracts DApp and Haskell Explanation

In this video we will take everything we have learned and understand how to make our own guessing game DApp on the Plutus Playground.

In this project we will create a game where one user will lock up their lovelace with a password on the blockchain and another user has to guess it to redeem the it.

Some of the key concepts we will be looking at are:
1) Creating Datum and Reedemer classes to store data on the Cardano Blockchain
2) Receiving inputs from the user by setting up our Contract
3) Implementing and sending transactions with the user’s input

Along the way, we will be doing additional light explaination on some of the Haskell syntax that shows up in more detail.

For other similar video’s, check out our Cardano Plutls Playground Tutorial playlist:
https://www.youtube.com/playlist?list=PL53JxaGwWUqAE59_XRxhwDuN1QrBgbIav

00:00 – Intro
00:45 – Running the Game project in the simulator
02:22 – Setting up our Template Haskell code with Plutux TX
03:34 – Creating the Game object and defining the Datum and Redeemer type
06:19 – Creating the Validator script to release the funds
07:49 – Setting up code for the simulator
09:08 – Defining the Contract’s Schema to receive user input
11:33 – Defining the endpoints to receive user input
12:37 – Implementing the Lock endpoint
16:01 – Implementing the Guess endpoint
17:57 – Conclusion

Donate Ada: addr1qxws6z9qxkycclpxxpnkq202wxrlc7ke29zmpydj40a2z8aq4jx95m2pnvdrwrsrl5m30j0vce0w7k5zt0aeqzcsurwqulm5hc

(Visited 255 times, 1 visits today)

You might be interested in

LEAVE YOUR COMMENT

Your email address will not be published. Required fields are marked *

eos
EOS (EOS) 0,763086 2,05%
aave
Aave (AAVE) 86,26 3,43%
the-graph
The Graph (GRT) 0,252394 2,03%
kusama
Kusama (KSM) 28,21 3,39%
waves
Waves (WAVES) 2,27 3,35%
dash
Dash (DASH) 28,05 0,35%
bitcoin
Bitcoin (BTC) 59.759,16 1,51%
ethereum
Ethereum (ETH) 3.089,01 5,93%
cardano
Cardano (ADA) 0,441403 2,67%
tether
Tether (USDT) 0,934303 0,12%
xrp
XRP (XRP) 0,487634 0,54%
solana
Solana (SOL) 133,96 4,79%
polkadot
Polkadot (DOT) 6,44 2,27%
usd-coin
USDC (USDC) 0,934288 0,01%
dogecoin
Dogecoin (DOGE) 0,140003 2,32%
uniswap
Uniswap (UNI) 7,50 3,96%
terra-luna
Terra Luna Classic (LUNC) 0,000101 3,10%
litecoin
Litecoin (LTC) 78,87 3,20%
chainlink
Chainlink (LINK) 13,35 0,82%
bitcoin-cash
Bitcoin Cash (BCH) 451,35 1,26%
algorand
Algorand (ALGO) 0,186451 0,27%
matic-network
Polygon (MATIC) 0,694856 6,34%
stellar
Stellar (XLM) 0,107710 1,59%
cosmos
Cosmos Hub (ATOM) 7,90 2,03%
filecoin
Filecoin (FIL) 5,60 2,47%
tron
TRON (TRX) 0,112440 1,14%
ethereum-classic
Ethereum Classic (ETC) 26,83 5,97%
dai
Dai (DAI) 0,934077 0,00%
tezos
Tezos (XTZ) 0,949300 0,69%
monero
Monero (XMR) 115,78 4,03%