🎯FlashBack

FlashBack allows users to choose some number of ERC-20 tokens and the duration they wish to stake for. These parameters are used to determine how many ERC-20 reward tokens are reserved for the Stake. The reward is always paid out at the end of the Stake. FlashBack stakes can be withdrawn at any point in time however if this is done before the staking period ends, all reward tokens are forfeited and only Staked tokens are returned.

This means a user could choose to Stake 10,000 tokenA for an agreed 5,000 tokenB reward. The user can choose to unstake at any point in time but when unstaking before the agreed duration is completed, all 5,000 reward tokens will be forfeited and the user will get back their original 10,000 staked tokens.

The Staking token and Reward token can be the same ERC-20 token or different.

Reward Calculations Math

The reward a given stake is entitled to is calculated as shown when staking Flash for Flash (FlashBack):

reward=((durationβˆ—2)βˆ—(maxAPRβˆ—stakedTokens))(10000βˆ—994519296000000)reward = \frac{((duration*2) * (maxAPR * stakedTokens))} {(10000 * 994519296000000)}

The reward a given stake is entitled to is calculated as shown when staking Flash LP tokens for Flash (FlashBackLM):

reward=((flashInLPβˆ—2)βˆ—((durationβˆ—βˆ—2)βˆ—(maxAPRβˆ—stakedTokens))(10000βˆ—(31536000βˆ—maximumStakeDuration)))lpTotalSupplyreward = \frac{((flashInLP * 2) * \frac{((duration**2) * (maxAPR * stakedTokens))} {(10000 * (31536000 * maximumStakeDuration))})} {lpTotalSupply}

In the event the above calculations are higher than remaining rewards, β€œreward” will be equal to remaining rewards.

Contract Settings

The maxAPR is configurable by the Owner of the contract and can be increased or decreased at any point in time. The maxAPR variable has been designed to be an integer between 1 and 10,000 which signifies 0.01% and 100%. This variable can be configured to be higher than 10,000 which results in an annual return rate of over 100%.

The FlashBackLM contract has two additional variables that can be updated by the Owner: flashInLP and lpTotalSupply.

The changing of parameters such as maxAPR, lpTotalSupply and flashInLP only effect new stakes.

Unstaking

Users are able to unstake early at any point after the minimum staking duration has ended. The FlashBack and FlashBackLM contracts each have their own minimum and maximum staking durations.

Last updated