Skip to content

A dapp to gamify urban mobility with bicycle rides, public goods and web3 tools

Notifications You must be signed in to change notification settings

zenbitETH/Bright-Forest

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 

Repository files navigation

Bright-Forest

Developed at HackFS 2022

About

Bright forest is based on Dark Forest game dynamic to move game units between two places located by coordinates. In DF this works to move resources between planets, while BF will use it to move "Energy and Chips" between IRL places minted as NFTs on Punk Cities.

Bright Forest uses ZKsnarks to prove that players' IRL location matches with the origin and destination coordinates and validate that the ride is completed. When a ride is completed the player gets energy units from the Bright Forest contract as a reward for the distance traveled on the ride.

Contracts

Built with:

-React -SnarksJS
-Google API
-IPFS
-Polygon
-Punk Cities Places
-Tailwind CSS

Dev Environment

Working with Polygon Mumbai testnet contracts (further update to deploy your own contracts)

  1. Make .env.sample
touch .env.sample

add environment variable

REACT_APP_MAPS_API_KEY
  1. Install dependencies
cd client
npm install
  1. Start developmment
cd client
npm start
  1. 📱 Open http://localhost:3000 to see the app

Contracts

Deployment address (Polygon Mumbai)

BrightForest:

0xAb359104d87180B0d2506cBc6AC75BCba553dc3c

Verifier:

0x4C7F5fbBd452b004Db659C9379d483EF2A5e2427

Verified code can found here. To view decoded Inputs and contract calls use Decode Input Data button provided at the bottom of the transaction.

About

A dapp to gamify urban mobility with bicycle rides, public goods and web3 tools

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published