Skip to content

Bokeverse is a decentralized 2D open-world RPG with turn-based battles. It is set in a fantasy world, allowing players to explore, fight monsters and possess NFT characters and collectibles registered to their wallet address. We also have a trading marketplace for NFTs and a QR code generation system to easily access and purchase these NFTs.

License

Notifications You must be signed in to change notification settings

Yukino2002/Bokeverse

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Contributors Forks Stargazers Issues MIT License

Logo

Bokeverse

Explore the decentralized world of Bokeverse!
View Demo · Report Bug · Request Feature

Table of Contents

About The Project

Town Square

The game is a decentralized 2D open-world RPG with turn-based battles. It is set in a fantasy world, allowing players to explore, fight monsters and possess NFT characters and collectibles registered to their wallet address. We have also included a trading marketplace for NFTs and a QR code generation system to easily access and purchase these NFTs.

Marketplace Fantom Mainnet Contract

Game Fantom Mainnet Contract

Youtube Demo

(back to top)

Game Mechanics

The game is made using Unity. As a game engine, Unity is able to provide many of the most important built-in features that make a game work. That means things like physics, animations, 3D/2D rendering, collision detection etc. We can create different game objects and add components to provide them with functionality, and make them interact with each other. These components can be in-built components provided by Unity, or custom scripts that we write ourselves in C#.

Technologies Used

  • Unity Engine

    • We used version 2021.3.16f1 of the Unity Engine to create the game.
    • Utilized DoTween animation package for Unity.
  • Thirdweb

    • We used the Thirdweb web3 development framework to integrate web3 into our game and website.
  • Next.js

    • We used the powerful Next.js framework to create our website.

(back to top)

Getting Started

Before getting a local copy up, you must ensure that you have the necessary software required.

Prerequisites

  • Unity
    https://unity3d.com/get-unity/download
  • Node.js
      https://nodejs.org/en/download/

Installation

  1. Clone the repo
    git clone https://github.com/Yukino2002/Bokeverse.git

Running the game

  1. Open the project Bokemon in Unity (Editor version is 2021.3.16f1)
  2. Open the scene "SampleScene.unity" in /Bokemon/Assets/Scenes/SampleScene.unity
  3. Open your Build settings, select WebGL as the target platform.
  4. Open Player settings > Resolution and Presentation and under WebGLTemplate choose Thirdweb.
  5. Save and click Build and Run to test out your game in a browser.

Deploying the smart contract

  1. Navigate to the folder contract
cd contract
  1. Deploy the contract using thirdweb ContractKit
npx thirdweb deploy .
  1. Confirm the 2 transactions on unitys dashboard

Deploying the website

  1. Navigate to the folder website
cd website
  1. Install the required dependencies
npm i
  1. Run the server
npm run dev

Minting Bokemons(NFTs) to your account

You can get a starting Bokemon(Walruse) from the game. If you want another Bokemon you can use the scripts

  1. Navigate to the folder website
cd website
  1. Navigate to src\scripts\deployThirdWebNFT.js and in
var result = await contract.call("mint", "0xB7E99669e9eDdD2975511FBF059d01969f43D409", uri, 1);

replace 0xB7E99669e9eDdD2975511FBF059d01969f43D409 with your own contract address

  1. Run createBokemon script
npm run createBokemon

Creating a QR Code to Scan

  1. Navigate to the folder website
cd website
  1. Run generate script
npm run createBokemon
  1. QR code is generated in the src\scripts\QRCodeResults Folder
  2. Scan the QR code and obtain a Shiny Girason!!!!

(back to top)

Usage

Demo Links

The links to the working demos(in case of any error, kindly reload, the game will run smoothly) and articles of the project are as follows:

Prerequisites

  • MetaMask, Coinbase or any other wallet that supports the Ethereum network.
  • Some mainnet FTM to pay for gas fees.

Playing the Game

  • On start, the user sees the start menu, where they must connect a wallet to play. The wallet options are MetaMask, Coinbase Wallet, etc.

Start Menu

  • With a connected wallet, players can explore, battle Bokemons, etc. They must first have a Bokemon linked to their wallet. Otherwise, they can't access the wild grass where Bokemons appear. A message appears, telling the player to talk to the white-haired NPC for a starter Bokemon.

Getting Bokemon

  • The player visits the white-haired NPC. If they lack a Bokemon and their party size is 0, they'll sign a transaction for a Bokemon NFT. The NFT is made using the player's wallet as seed and sent to the wallet. Wait briefly for transaction completion. If transaction fails or rejected, try again.

Transaction Execution

  • Receive Walruse, the popular Ice-type Bokemon! Explore the wild grass and battle other Bokemons. On the battle screen, you can attack, flee, or switch Bokemons. Use the right attack for the right Bokemon as some are more effective against certain types. Use 'Z' to choose and 'X' to return.

The Battle Screen

  • After winning, experience points are earned and a write operation updates the Bokemon data. If the transaction is rejected, the Bokemon won't level up. If accepted, you'll see a message to wait for the transaction to complete.

  • If all party Bokemons are defeated, the battle ends and you'll be asked to heal them. Go to the sleeping healing tree to heal your Bokemons.

Heal Bokemons

Navigating the Website

  • You can purchase bokemons from the marketplace and increase your party size, and find rare bokemons!

Marketplace

  • You can also redeem bokemons from QR codes.

Redeem

You're all set to go! You can now battle other Bokemons, explore the map, and have fun! If you want more Bokemons, you can visit the Bokeverse marketplace and buy a Bokemon NFT or redeeem through external QR codes.

(back to top)

Roadmap

  • Improving the graphics and overall visual appearance of the game

  • Adding more NFT bokemons and collectibles for players to possess

  • Adding more quest lines, battles, and exploration elements to the game

  • Introducing new gameplay elements such as PvP arenas, boss battles, and more.

  • Add physical trading cards for redeeming in-game bokemons from the website. Sample design below:

(back to top)

Contributing

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

(back to top)

License

Distributed under the MIT License. See LICENSE.txt for more information.

(back to top)

Acknowledgements

(back to top)

Contact

Pratik Jallan - LinkedIn - pratikjalan11@gmail.com

Asim Jawahir - LinkedIn - asimjawahir123@gmail.com

(back to top)

About

Bokeverse is a decentralized 2D open-world RPG with turn-based battles. It is set in a fantasy world, allowing players to explore, fight monsters and possess NFT characters and collectibles registered to their wallet address. We also have a trading marketplace for NFTs and a QR code generation system to easily access and purchase these NFTs.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published