Inspiration
I wanted to create a project that would allow me to use Chainlink's VRF
What it does
My project simulates the game of black jack. There is a player and a dealer. The winner either hits 21, has the higher score, or doesn't hit above 21.
How we built it
I used foundry for the smart contract framework and I implemented Chainlink's VRF and Automation.
Challenges we ran into
- Figuring out how to generate 52 cards of a deck with properties of rank, suit, card value.
- Then generating 52 random cards.
- Getting the frontend to properly display the correct data to match the backend (didn't finish yet). ## Accomplishments that we're proud of
- Being able to generate 52 cards in a deck that represented each card in a deck.
- Being able to implement the functionalities on the smart contract end. ## What we learned
- I learned how to use different data structures such as structs, arrays, and mappings to create data by combining them.
- I also learned how to use VRF and Automation.
- I also learned how to ask better questions so that helps me better understand the problems that I encouter. ## What's next for Blackjack I would like to finish the frontend so that it works properly and then write test scripts for the functions.
Built With
- foundry
Log in or sign up for Devpost to join the conversation.