Inspiration
"Guayabita" is a traditional Colombian game in which 2 or more people play with a die. The game is very simple: players pool a certain amount of money, and it is determined who starts. Each player has one chance to roll the die. If you roll a 1, you lose; if you roll a 6, you win. Rolling a 2, 3, 4, or 5 changes the turn. We have decided to bring this dynamic to web 3, and that's where Guayabita Web3 is born! Our demo for this hackathon is modest but robust! As a player, you will play against the house. The mechanics are very simple: you can place your bet, and the house will automatically generate a random offer, which may be lower or higher than your bet. If you roll a 1 on the die, you will lose immediately; if you roll a 6, you will win the amount that the house has bet. To make it more interesting, if you roll a 2, 3, 4, or 5, you won't lose or win, but the house will adjust its bet until you either win or lose. Guayabita Web3 has a crucial focus on a purposeful mission. Beyond implementing various Chainlink services and technologies, it strives to make a positive impact on the planet. The strategy involves utilizing the $GU token as the game's transactional mechanism, with each transaction generating a tribute for environmental causes. The second aspect involves a forward-looking approach to the ecosystem, anticipating increased interoperability through tools like CCIP. Guayabita is not just a game; it's a purposeful bet on contributing to the planet's well-being through gaming and chance.
What it does
Guayabita is the web3 adaptation of the traditional Colombian game also called Guayabita (just to clarify, 'guayabita' or 'guayaba' refers to a local fruit). It operates with the previously mentioned mechanics but includes additional implementations. We use Chainlink's VRF (Verifiable Random Function) to generate our seed randomly, which in turn generates the random numbers for our game. This is done only once to enhance gameplay and reduce requests, making it more cost-effective to play.
Another crucial factor is the implementation of Chainlink's CCIP (Cross-Chain Interoperability Protocol). In this case, the player places their bets on the Polygon network, while the house operates on the Avalanche network. Every time the player wins or loses, tokens move across both networks. This implementation is a first step towards a future vision where PvP (Player vs. Player) development occurs, allowing any player from any network integrated by CCIP to feasibly participate. This facilitates interoperability and opens the door for a more inclusive gaming experience.
Something very important is the focus of Guayabita Web3. While we aim to implement various Chainlink services as well as other technologies or frameworks, purposeless endeavors lack meaning. That's why Guayabita Web3 is an alternative with a purpose—to help the planet. You might wonder, 'How does it do that?' Simple, the answer has two parts. The first is through its token. In the future, to play Guayabita Web3, you will need to acquire the $GU token, which will be the transactional mechanism for the game. For every withdrawal or purchase within the token structure, we will generate a tribute that will be allocated to support charitable causes related to environmental protection.
The second part is a bet on the ecosystem's vision. We understand that tools like CCIP and many others will increasingly streamline interoperability processes, inevitably leading to widespread adoption. We believe that initiatives like Guayabita can easily be embraced due to their strong presence in betting systems. So, Guayabita is a gamble to contribute to the planet through gaming and luck!
How we built it
The project focuses on creating a blockchain-based dice game using Python as the programming language. In order to ensure fairness and transparency in the game, we have implemented the VRF (Verifiable Random Function) system from Chainlink. This system provides a random seed that directly influences the dice roll results, ensuring a fair gaming environment free from manipulations.
Furthermore, to enhance interoperability between the test networks of Polygon and Avalanche, we have integrated the CCIP (Cross-Chain Interoperability Protocol) protocol. CCIP plays a crucial role in efficiently and securely sharing data, specifically the game results, between these two blockchain networks. This implementation not only improves the user experience when operating across multiple networks but also lays the groundwork for potential future developments, such as expansion to other networks or integration with applications and smart contracts in decentralized environments. In summary, the use of VRF and CCIP reflects our commitment to the integrity of the game and the creation of a transparent and collaborative gaming ecosystem.
Challenges we ran into
The connection from Python to smart contracts has limited documentation compared to other languages
Also, another challenge is the response times, both from the VRF and the CCIP, for transactions.
Accomplishments that we're proud of
Successful Web3 Adaptation: Accomplishing the successful transition of the traditional Colombian game Guayabita into a Web3 format.
Implementation of Chainlink Services: Successfully integrating various Chainlink services into the game, such as the VRF system for generating random numbers.
Innovative Environmental Contribution: Creating a unique and purposeful contribution to environmental causes by allocating tributes from game transactions.
Cross-Chain Interoperability with CCIP: Successfully implementing the Cross-Chain Interoperability Protocol (CCIP) to enable communication between the testnets of Polygon and Avalanche.
Overcoming Documentation Challenges: Navigating and overcoming challenges related to limited documentation, demonstrating adaptability and problem-solving capabilities.
What we learned
Using Chainlink services and employing Pygame for the development of indie games is a viable option for aspiring game developers who want to create innovative and engaging experiences. Chainlink is a decentralized oracle network that allows smart contracts to access real-world data and events, such as weather, sports scores, or market prices. Pygame is a cross-platform library that simplifies the creation of 2D games using Python. By combining these two technologies, one can create games that are dynamic, interactive, and responsive to external factors. For example, one could create a game that changes its difficulty or rewards based on the current price of Bitcoin, or a game that incorporates real-time weather data into its gameplay mechanics. These are just some of the possibilities that Chainlink and Pygame offer for indie game development.
What's next for Guayabita Web3
For Guayabita Web3, many things are coming up, including deployment on the mainnet, PvP game mode, the launch of the $GU token, and analysis of foundations interested in adopting these technologies and joining the initiative.
Built With
- adobe
- adobe-illustrator
- ccip
- premiere-pro
- pygame
- python
- remix
- solidity
- vrf
- web3.py

Log in or sign up for Devpost to join the conversation.