Skip to main content

CumulativePrice

Git Source Author: @oscarsernarosero @cirsteve @Palmerg4 This contract tracks the price of the contract at the end of every block

State Variables

cumulativePrice

uint256 public cumulativePrice;

lastBlockTimestamp

uint256 public lastBlockTimestamp;

Functions

_updateCumulativePrice

This function updates the cumulativePrice and lastBlockTimestamp.
function _updateCumulativePrice(uint256 _price, uint256 _timestamp) internal;
Parameters
NameTypeDescription
_priceuint256the current spot price
_timestampuint256the current block timestamp