How to Set Up NFT Boost in Staking Pools
After adding a staking pool, pool managers can enhance user engagement by enabling an NFT boost. This feature provides users with additional rewards if they hold specific NFTs in their wallet. The setup process applies uniformly to all types of staking pools, including Liquidity Pools, Dynamic Pools, and Compounding Pools.
Supported NFT Contracts
Important: Any ERC721 enumerable NFTs are supported for providing a boost. Ensure that the NFT contract you plan to use is enumerable before proceeding with the setup.
We specifically need this function to be able to check whether users own NFT's:
function tokenOfOwnerByIndex(
address owner,
uint256 index
) public view virtual override returns (uint256) {
require(
index < ERC721Upgradeable.balanceOf(owner),
"ERC721Enumerable: owner index out of bounds"
);
return _ownedTokens[owner][index];
}
Steps to Set Up an NFT Boost
- Enter the NFT contract address – Specify the address of the NFT collection that will be used for the boost.
- Name the boost – Give a recognizable name to the boost (e.g., "Boost Pool 1").
- Set the multiplier – Enter the multiplier value that defines the boost. This is expressed as a percentage or a factor (e.g., a multiplier of 1.5 means a 50% boost in rewards).
- Define the eligible NFT range –
- First NFT ID: The starting ID of eligible NFTs.
- Last NFT ID: The ending ID of eligible NFTs.
- Toggle the boost activation – You can enable or disable the boost as needed. (It can be toggled later without resetting the setup.)
- Save changes – Click "Save Changes" and confirm the transaction when prompted by your wallet.
Once the transaction is confirmed on-chain, the NFT boost will be active for the specified pool.
How NFT Boost Works
The NFT boost feature operates by applying a bonus to the rewards earned by users who hold eligible NFTs. It’s essential to understand that:
- The base reward calculation remains unchanged, and the boost is applied only as an additional bonus.
- Dynamic Pools: In these pools, NFT boosts do not directly modify the APY. Instead, after determining the normal rewards based on the user's share of the pool, a bonus percentage is applied.
Example Calculation:
If a user earns 100 tokens as their normal reward and they have an NFT with a 3% boost multiplier:
- The user will receive an extra 3 tokens (3% of 100), making the total reward 103 tokens.
- The boost applies only to the calculated reward, ensuring fairness while providing additional incentives for NFT holders.
NFT Boost Across Pool Types
-
Liquidity Pools: Users stake liquidity provider (LP) tokens, and rewards are distributed based on the staked LP token amount. If an NFT boost is enabled, users holding eligible NFTs receive multiplied rewards according to the set multiplier.
-
Dynamic Pools: Unlike Liquidity and Compounding pools, Dynamic pools are time-sensitive, and the NFT boost applies as an extra percentage after normal rewards are computed.
-
Compounding Pools (MasterChef + Vault):
- In compounding pools, rewards are automatically reinvested to maximize returns.
- When an NFT boost is applied, the boost increases the compounded rewards proportionally.
- Example: A user holding an NFT with a 2x multiplier would have their compounded rewards doubled.
Additional Notes
- The boost mechanism does not interfere with deposits or withdrawals; users can stake or unstake as usual.
- Multipliers support decimal values, allowing fine-tuned reward enhancements (e.g., a multiplier of 1.25 for a 25% boost).
- Users only need to hold the NFT at the time of claiming rewards to benefit from the boost. The boost is automatically applied if the NFT is present in the user’s wallet at the time of the payout.