Skip to content

golom-protocol/contracts

Repository files navigation

Basic Sample Hardhat Project

This project demonstrates a basic Hardhat use case. It comes with a sample contract, a test for that contract, a sample script that deploys that contract, and an example of a task implementation, which simply lists the available accounts.

Try running some of the following tasks:

npx hardhat accounts
npx hardhat compile
npx hardhat clean
npx hardhat test
npx hardhat node
node scripts/sample-script.js
npx hardhat help

Summary of contracts

Core

GolomTrader.sol

This contract acts as the Nft trade matcher with 3 different functions for the 3 different ordertypes , ordertype 0 for filling ask for NFT , 1 for filling bid of an NFT, 2 for filling bid of any NFT from a particular collection ensuring that the supplied proof demonstrates inclusion of the tokenId in the associated merkle root, if root is 0 then any token can be used to fill the order.After filling RewardDistributor contract is called for saving fees generated by each address and distributing rewards.

Emitter.sol

This contract emits any valid signed order as an indexed event for easy querying. this contract will be deployed on polygon.

Rewards

RewardDistributor.sol

This contract is responsible for storing fees generated by each address for distributing rewards. All fees generated from trading will be stored in this contract. Also responsible for distributing Ethereum fees and golom tokens to vote-escrowed stakers. This contract also mints daily golom token based on https://docs.golom.io/emissions and then distributes to traders and exchanges pro-rate based on fees.

Vote escrow

VoteEscrowDelegation.sol

This contract inherits VoteEscrowCore.sol which is a fork of Andre's solidly project (https://github.com/solidlyexchange/solidly/blob/master/contracts/ve.sol) and implements delegation for upgrading other contracts by voting

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published