ETH Price: $1,584.48 (-0.31%)

Contract

0x74A498769a6B9E5c6C89bd28a4720c52C904b81f

Overview

ETH Balance

0 ETH

ETH Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Retrieve SUSD Am...1342520882025-04-08 9:02:339 days ago1744102953IN
0x74A49876...2C904b81f
0 ETH0.0000002543190.005155
Set Result For G...1342504002025-04-08 8:06:179 days ago1744099577IN
0x74A49876...2C904b81f
0 ETH0.0000002530780.0050178
Set Result Array1341640772025-04-06 8:08:5111 days ago1743926931IN
0x74A49876...2C904b81f
0 ETH0.0000004353190.001322
Set Result Array1338892452025-03-30 23:27:4718 days ago1743377267IN
0x74A49876...2C904b81f
0 ETH0.0000004692930.00143143
Set Result Array1338635542025-03-30 9:11:2518 days ago1743325885IN
0x74A49876...2C904b81f
0 ETH0.0000003880450.00118174
Set Result Array1338191942025-03-29 8:32:4519 days ago1743237165IN
0x74A49876...2C904b81f
0 ETH0.0000004406810.00119967
Set Result Array1337749762025-03-28 7:58:4920 days ago1743148729IN
0x74A49876...2C904b81f
0 ETH0.0000006278170.00119987
Set Result Array1336055442025-03-24 9:51:0524 days ago1742809865IN
0x74A49876...2C904b81f
0 ETH0.0000005140190.00119963
Set Result For G...1335802872025-03-23 19:49:1125 days ago1742759351IN
0x74A49876...2C904b81f
0 ETH0.0000000137390.0002168
Set Result Array1335630452025-03-23 10:14:2725 days ago1742724867IN
0x74A49876...2C904b81f
0 ETH0.0000004218430.0011458
Set Result For G...1335455772025-03-23 0:32:1126 days ago1742689931IN
0x74A49876...2C904b81f
0 ETH0.0000000352250.0006484
Set Result For G...1335455322025-03-23 0:30:4126 days ago1742689841IN
0x74A49876...2C904b81f
0 ETH0.0000000722490.0013975
Set Result For G...1335446592025-03-23 0:01:3526 days ago1742688095IN
0x74A49876...2C904b81f
0 ETH0.0000000232650.0004046
Set Result For G...1335346782025-03-22 18:28:5326 days ago1742668133IN
0x74A49876...2C904b81f
0 ETH0.0000001194310.0015335
Set Result Array1335177542025-03-22 9:04:4526 days ago1742634285IN
0x74A49876...2C904b81f
0 ETH0.0000005860870.0012063
Set Result For G...1334974962025-03-21 21:49:2927 days ago1742593769IN
0x74A49876...2C904b81f
0 ETH0.0000000634010.0012002
Set Result Array1334972332025-03-21 21:40:4327 days ago1742593243IN
0x74A49876...2C904b81f
0 ETH0.000000414290.00120026
Set Result For G...1334927762025-03-21 19:12:0927 days ago1742584329IN
0x74A49876...2C904b81f
0 ETH0.000000038270.0005171
Set Result For G...1334926872025-03-21 19:09:1127 days ago1742584151IN
0x74A49876...2C904b81f
0 ETH0.0000000326210.0004736
Set Result Array1334741822025-03-21 8:52:2127 days ago1742547141IN
0x74A49876...2C904b81f
0 ETH0.0000008156530.00135349
Mint1334437552025-03-20 15:58:0728 days ago1742486287IN
0x74A49876...2C904b81f
0 ETH0.0000005526960.0003106
Mint1334437022025-03-20 15:56:2128 days ago1742486181IN
0x74A49876...2C904b81f
0 ETH0.0000005507960.0003101
Mint1334436312025-03-20 15:53:5928 days ago1742486039IN
0x74A49876...2C904b81f
0 ETH0.0000005307040.0002991
Mint1334435612025-03-20 15:51:3928 days ago1742485899IN
0x74A49876...2C904b81f
0 ETH0.0000005673540.0003202
Mint1334434962025-03-20 15:49:2928 days ago1742485769IN
0x74A49876...2C904b81f
0 ETH0.0000005559490.0003114
View all transactions

Latest 15 internal transactions

Advanced mode:
Parent Transaction Hash Block From To
1334298422025-03-20 8:14:2128 days ago1742458461
0x74A49876...2C904b81f
0.010179752025312 ETH
1334254652025-03-20 5:48:2728 days ago1742449707
0x74A49876...2C904b81f
0.010135536494333 ETH
1334253722025-03-20 5:45:2128 days ago1742449521
0x74A49876...2C904b81f
0.010119835957557 ETH
1334251702025-03-20 5:38:3728 days ago1742449117
0x74A49876...2C904b81f
0.010119835957557 ETH
1333997742025-03-19 15:32:0529 days ago1742398325
0x74A49876...2C904b81f
0.010035998881453 ETH
1333683382025-03-18 22:04:1330 days ago1742335453
0x74A49876...2C904b81f
0.01067460468802 ETH
1333681242025-03-18 21:57:0530 days ago1742335025
0x74A49876...2C904b81f
0.010692683819798 ETH
1333676912025-03-18 21:42:3930 days ago1742334159
0x74A49876...2C904b81f
0.01068428690772 ETH
1333246432025-03-17 21:47:4331 days ago1742248063
0x74A49876...2C904b81f
0.010508918021263 ETH
1332882612025-03-17 1:34:5931 days ago1742175299
0x74A49876...2C904b81f
0.010749964847614 ETH
1332882072025-03-17 1:33:1131 days ago1742175191
0x74A49876...2C904b81f
0.010749964847614 ETH
1332881612025-03-17 1:31:3931 days ago1742175099
0x74A49876...2C904b81f
0.010749964847614 ETH
1332880532025-03-17 1:28:0331 days ago1742174883
0x74A49876...2C904b81f
0.010749964847614 ETH
1332879032025-03-17 1:23:0331 days ago1742174583
0x74A49876...2C904b81f
0.010749964847614 ETH
1330931372025-03-12 13:10:5136 days ago1741785051
0x74A49876...2C904b81f
0.010618299367312 ETH

Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
MarchMadnessV2

Compiler Version
v0.8.4+commit.c7e474f2

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 18 : MarchMadnessV2.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "@openzeppelin/contracts-4.4.1/utils/Counters.sol";
import "@openzeppelin/contracts-4.4.1/access/Ownable.sol";
import "@openzeppelin/contracts-4.4.1/security/Pausable.sol";
import "@openzeppelin/contracts-4.4.1/token/ERC721/extensions/ERC721URIStorage.sol";

import "@openzeppelin/contracts-upgradeable/token/ERC20/utils/SafeERC20Upgradeable.sol";
import "@openzeppelin/contracts-upgradeable/token/ERC20/IERC20Upgradeable.sol";

import "../../interfaces/IMultiCollateralOnOffRamp.sol";

contract MarchMadnessV2 is ERC721URIStorage, Pausable, Ownable {
    using SafeERC20Upgradeable for IERC20Upgradeable;

    /* ========== LIBRARIES ========== */

    using Counters for Counters.Counter;

    /* ========== STATE VARIABLES ========== */

    Counters.Counter private _tokenIds;

    string public _name = "Overtime March Madness 2025";
    string public _symbol = "OTMM";

    uint public canNotMintOrUpdateAfter;

    uint constant NUMBER_OF_ROUNDS = 6;
    uint constant NUMBER_OF_GAMES = 63;
    uint constant NUMBER_OF_TEAMS = 64;
    uint private constant MAX_APPROVAL = type(uint256).max;

    uint[NUMBER_OF_GAMES] public results;

    mapping(uint => uint[NUMBER_OF_GAMES]) public itemToBrackets;
    mapping(address => uint[]) public addressToTokenIds;
    mapping(uint => uint[]) public roundToGameIds;

    string public urlToUse;

    uint public mintingPrice = 20 * 1e6;

    IERC20Upgradeable public sUSD;
    IMultiCollateralOnOffRamp public multiCollateralOnOffRamp;

    address public safeBox;

    uint public sbFee;

    mapping(address => bool) public whitelistedAddresses;

    receive() external payable {}

    /* ========== MODIFIER ========== */

    modifier notAfterFinalDate() {
        require(canNotMintOrUpdateAfter != 0, "canNotMintOrUpdateAfter is not set");
        require(block.timestamp < canNotMintOrUpdateAfter, "Can not mint after settled date");
        _;
    }

    /* ========== CONSTRUCTOR ========== */

    constructor() ERC721(_name, _symbol) {}

    /* ========== OWC ========== */

    function mint(uint[NUMBER_OF_GAMES] calldata _brackets)
        external
        whenNotPaused
        notAfterFinalDate
        returns (uint newItemId)
    {
        require(IERC20Upgradeable(sUSD).balanceOf(msg.sender) >= mintingPrice, "Not enough balance");
        IERC20Upgradeable(sUSD).safeTransferFrom(msg.sender, address(this), mintingPrice);

        newItemId = _mintInternal(_brackets);
    }

    function mintWithDiffCollateral(
        address collateral,
        uint collateralAmount,
        uint[NUMBER_OF_GAMES] calldata _brackets
    ) external whenNotPaused notAfterFinalDate returns (uint newItemId) {
        IERC20Upgradeable(collateral).safeTransferFrom(msg.sender, address(this), collateralAmount);
        IERC20Upgradeable(collateral).approve(address(multiCollateralOnOffRamp), collateralAmount);
        uint convertedAmount = multiCollateralOnOffRamp.onramp(collateral, collateralAmount);

        require(convertedAmount > mintingPrice, "insufficient collateral");

        newItemId = _mintInternal(_brackets);
    }

    function mintWithEth(uint[NUMBER_OF_GAMES] calldata _brackets)
        external
        payable
        whenNotPaused
        notAfterFinalDate
        returns (uint newItemId)
    {
        uint convertedAmount = multiCollateralOnOffRamp.onrampWithEth{value: msg.value}(msg.value);

        require(convertedAmount > mintingPrice, "insufficient collateral");

        newItemId = _mintInternal(_brackets);
    }

    function _mintInternal(uint[NUMBER_OF_GAMES] calldata _brackets) internal returns (uint newItemId) {
        _tokenIds.increment();

        newItemId = _tokenIds.current();

        _mint(msg.sender, newItemId);

        itemToBrackets[newItemId] = _brackets;
        addressToTokenIds[msg.sender].push(newItemId);

        _setTokenURI(newItemId, urlToUse);

        if (sbFee > 0) {
            IERC20Upgradeable(sUSD).safeTransfer(safeBox, (mintingPrice * sbFee) / 1e18);
        }

        emit Mint(msg.sender, newItemId, _brackets);
    }

    function updateBracketsForAlreadyMintedItem(uint _tokenId, uint[NUMBER_OF_GAMES] memory _brackets)
        external
        whenNotPaused
        notAfterFinalDate
    {
        require(_exists(_tokenId), "Item does not exists");
        require(ownerOf(_tokenId) == msg.sender, "Caller is not owner of entered tokenId");

        itemToBrackets[_tokenId] = _brackets;

        emit UpdateBracketsForAlreadyMintedItem(msg.sender, _tokenId, _brackets);
    }

    /* ========== VIEW ========== */

    function getBracketsByItemId(uint itemId) public view returns (uint[63] memory brackets) {
        brackets = itemToBrackets[itemId];
        return brackets;
    }

    function getResults() external view returns (uint[NUMBER_OF_GAMES] memory) {
        return results;
    }

    function getAddressToTokenIds(address addressToFetchFor) external view returns (uint[] memory) {
        return addressToTokenIds[addressToFetchFor];
    }

    function isTeamWinnerOfGameId(uint _gameId, uint _teamId) public view returns (bool _flag) {
        if (isValidGameId(_gameId)) {
            if (results[_gameId] == _teamId) _flag = true;
        }
        return _flag;
    }

    function getCorrectPositionsPerRoundByTokenId(uint _roundId, uint _tokenId)
        public
        view
        returns (uint correctPredictions)
    {
        if (!isValidRoundId(_roundId)) return 0;
        if (!_exists(_tokenId)) return 0;

        uint[] memory gameIdsForRound = roundToGameIds[_roundId];
        uint[NUMBER_OF_GAMES] memory brackets = itemToBrackets[_tokenId];

        for (uint i = 0; i < gameIdsForRound.length; i++) {
            if (isTeamWinnerOfGameId(gameIdsForRound[i], brackets[gameIdsForRound[i]])) correctPredictions++;
        }

        return correctPredictions;
    }

    function getCorrectPositionsByRound(uint _tokenId) public view returns (uint[6] memory correctPositionsByRound) {
        for (uint i = 0; i < NUMBER_OF_ROUNDS; i++) {
            uint correctPositionPerRound = getCorrectPositionsPerRoundByTokenId(i, _tokenId);
            correctPositionsByRound[i] = correctPositionPerRound;
        }

        return correctPositionsByRound;
    }

    function getTotalPointsByTokenId(uint _tokenId) public view returns (uint totalPoints) {
        if (!_exists(_tokenId)) return totalPoints;

        for (uint i = 0; i < NUMBER_OF_ROUNDS; i++) {
            uint correctPositionPerRound = getCorrectPositionsPerRoundByTokenId(i, _tokenId);
            totalPoints += (correctPositionPerRound * (2**i));
        }

        return totalPoints;
    }

    function getTotalPointsByTokenIds(uint[] calldata _tokenIds) public view returns (uint[] memory totalPoints) {
        totalPoints = new uint[](_tokenIds.length);
        for (uint i = 0; i < _tokenIds.length; i++) {
            totalPoints[i] = getTotalPointsByTokenId(_tokenIds[i]);
        }
    }

    function getCurrentTokenId() external view returns (uint) {
        return _tokenIds.current();
    }

    /* ========== INTERNALS ========== */

    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual override {
        require(from == address(0) || to == address(0), "NonTransferrableERC721Token: non transferrable");
    }

    function isValidGameId(uint _gameId) internal pure returns (bool) {
        return _gameId >= 0 && _gameId < NUMBER_OF_GAMES;
    }

    function isValidRoundId(uint _roundId) internal pure returns (bool) {
        return _roundId >= 0 && _roundId < NUMBER_OF_ROUNDS;
    }

    function isValidTeamIndex(uint _teamId) internal pure returns (bool) {
        return _teamId > 0 && _teamId <= NUMBER_OF_TEAMS;
    }

    function isWhitelistedAddress(address _address) external view returns (bool) {
        return whitelistedAddresses[_address];
    }

    /* ========== CONTRACT MANAGEMENT ========== */

    function setMultiCollateralOnOffRamp(address _onramper) external onlyOwner {
        multiCollateralOnOffRamp = IMultiCollateralOnOffRamp(_onramper);
        sUSD.approve(_onramper, MAX_APPROVAL);
        emit SetMultiCollateralOnOffRamp(_onramper);
    }

    function setsUSD(address _address) external onlyOwner {
        sUSD = IERC20Upgradeable(_address);
        emit SetsUSD(_address);
    }

    function setSafeBox(address _safeBox, uint _sbFee) external onlyOwner {
        safeBox = _safeBox;
        sbFee = _sbFee;
        emit SetSafeBox(_safeBox, _sbFee);
    }

    function setWhitelistedAddress(address _address, bool enabled) external onlyOwner {
        whitelistedAddresses[_address] = enabled;
        emit SetWhitelistedAddress(_address, enabled);
    }

    function setMintingPrice(uint _mintingPrice) external onlyOwner {
        mintingPrice = _mintingPrice;
        emit SetMintingPrice(_mintingPrice);
    }

    function setPaused(bool paused) external onlyOwner {
        return paused ? _pause() : _unpause();
    }

    function setURLToUse(string memory _urlToUse) external onlyOwner {
        urlToUse = _urlToUse;
    }

    function setResultForGame(uint _gameId, uint _teamId) external {
        require(msg.sender == owner() || whitelistedAddresses[msg.sender], "Invalid caller");
        require(isValidTeamIndex(_teamId), "Not valid team index");
        require(isValidGameId(_gameId), "Not valid game index");
        results[_gameId] = _teamId;

        emit ResultForGameAdded(_gameId, _teamId);
    }

    function setResultArray(uint[NUMBER_OF_GAMES] memory _results) external {
        require(msg.sender == owner() || whitelistedAddresses[msg.sender], "Invalid caller");
        for (uint i = 0; i < _results.length; i++) {
            require(isValidGameId(i), "Not valid game index");

            results[i] = _results[i];

            emit ResultForGameAdded(i, _results[i]);
        }
    }

    function setFinalDateForPositioning(uint _toDate) external onlyOwner {
        canNotMintOrUpdateAfter = _toDate;

        emit FinalPositioningDateUpdated(_toDate);
    }

    function retrieveSUSDAmount(uint amount) external onlyOwner {
        sUSD.safeTransfer(msg.sender, amount);
    }

    function assignGameIdsToRound(uint _roundId, uint[] memory _gameIds) external onlyOwner {
        // Validation of game ids
        for (uint i = 0; i < _gameIds.length; i++) {
            require(isValidGameId(_gameIds[i]), "Not valid gameId");
        }
        require(isValidRoundId(_roundId), "Not valid round id");
        roundToGameIds[_roundId] = _gameIds;

        emit GameIdsAssignedToRound(_roundId, _gameIds);
    }

    /* ========== EVENTS ========== */

    event Mint(address _recipient, uint _id, uint[NUMBER_OF_GAMES] _brackets);
    event UpdateBracketsForAlreadyMintedItem(address _minter, uint itemIndex, uint[NUMBER_OF_GAMES] _newBrackets);

    event ResultForGameAdded(uint _gameIndex, uint _teamId);
    event FinalPositioningDateUpdated(uint _toDate);
    event GameIdsAssignedToRound(uint _roundId, uint[] _gameIds);
    event SetsUSD(address _address);
    event SetMultiCollateralOnOffRamp(address _onramper);
    event SetMintingPrice(uint mintingPrice);
    event SetSafeBox(address _safeBox, uint _sbFee);
    event SetWhitelistedAddress(address whitelisted, bool enabled);
}

File 2 of 18 : Counters.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Counters.sol)

pragma solidity ^0.8.0;

/**
 * @title Counters
 * @author Matt Condon (@shrugs)
 * @dev Provides counters that can only be incremented, decremented or reset. This can be used e.g. to track the number
 * of elements in a mapping, issuing ERC721 ids, or counting request ids.
 *
 * Include with `using Counters for Counters.Counter;`
 */
library Counters {
    struct Counter {
        // This variable should never be directly accessed by users of the library: interactions must be restricted to
        // the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add
        // this feature: see https://github.com/ethereum/solidity/issues/4637
        uint256 _value; // default: 0
    }

    function current(Counter storage counter) internal view returns (uint256) {
        return counter._value;
    }

    function increment(Counter storage counter) internal {
        unchecked {
            counter._value += 1;
        }
    }

    function decrement(Counter storage counter) internal {
        uint256 value = counter._value;
        require(value > 0, "Counter: decrement overflow");
        unchecked {
            counter._value = value - 1;
        }
    }

    function reset(Counter storage counter) internal {
        counter._value = 0;
    }
}

File 3 of 18 : Ownable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)

pragma solidity ^0.8.0;

import "../utils/Context.sol";

/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
abstract contract Ownable is Context {
    address private _owner;

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() {
        _transferOwnership(_msgSender());
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        _checkOwner();
        _;
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if the sender is not the owner.
     */
    function _checkOwner() internal view virtual {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        _transferOwnership(address(0));
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        _transferOwnership(newOwner);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Internal function without access restriction.
     */
    function _transferOwnership(address newOwner) internal virtual {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}

File 4 of 18 : Pausable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (security/Pausable.sol)

pragma solidity ^0.8.0;

import "../utils/Context.sol";

/**
 * @dev Contract module which allows children to implement an emergency stop
 * mechanism that can be triggered by an authorized account.
 *
 * This module is used through inheritance. It will make available the
 * modifiers `whenNotPaused` and `whenPaused`, which can be applied to
 * the functions of your contract. Note that they will not be pausable by
 * simply including this module, only once the modifiers are put in place.
 */
abstract contract Pausable is Context {
    /**
     * @dev Emitted when the pause is triggered by `account`.
     */
    event Paused(address account);

    /**
     * @dev Emitted when the pause is lifted by `account`.
     */
    event Unpaused(address account);

    bool private _paused;

    /**
     * @dev Initializes the contract in unpaused state.
     */
    constructor() {
        _paused = false;
    }

    /**
     * @dev Modifier to make a function callable only when the contract is not paused.
     *
     * Requirements:
     *
     * - The contract must not be paused.
     */
    modifier whenNotPaused() {
        _requireNotPaused();
        _;
    }

    /**
     * @dev Modifier to make a function callable only when the contract is paused.
     *
     * Requirements:
     *
     * - The contract must be paused.
     */
    modifier whenPaused() {
        _requirePaused();
        _;
    }

    /**
     * @dev Returns true if the contract is paused, and false otherwise.
     */
    function paused() public view virtual returns (bool) {
        return _paused;
    }

    /**
     * @dev Throws if the contract is paused.
     */
    function _requireNotPaused() internal view virtual {
        require(!paused(), "Pausable: paused");
    }

    /**
     * @dev Throws if the contract is not paused.
     */
    function _requirePaused() internal view virtual {
        require(paused(), "Pausable: not paused");
    }

    /**
     * @dev Triggers stopped state.
     *
     * Requirements:
     *
     * - The contract must not be paused.
     */
    function _pause() internal virtual whenNotPaused {
        _paused = true;
        emit Paused(_msgSender());
    }

    /**
     * @dev Returns to normal state.
     *
     * Requirements:
     *
     * - The contract must be paused.
     */
    function _unpause() internal virtual whenPaused {
        _paused = false;
        emit Unpaused(_msgSender());
    }
}

File 5 of 18 : ERC721URIStorage.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/extensions/ERC721URIStorage.sol)

pragma solidity ^0.8.0;

import "../ERC721.sol";

/**
 * @dev ERC721 token with storage based token URI management.
 */
abstract contract ERC721URIStorage is ERC721 {
    using Strings for uint256;

    // Optional mapping for token URIs
    mapping(uint256 => string) private _tokenURIs;

    /**
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        _requireMinted(tokenId);

        string memory _tokenURI = _tokenURIs[tokenId];
        string memory base = _baseURI();

        // If there is no base URI, return the token URI.
        if (bytes(base).length == 0) {
            return _tokenURI;
        }
        // If both are set, concatenate the baseURI and tokenURI (via abi.encodePacked).
        if (bytes(_tokenURI).length > 0) {
            return string(abi.encodePacked(base, _tokenURI));
        }

        return super.tokenURI(tokenId);
    }

    /**
     * @dev Sets `_tokenURI` as the tokenURI of `tokenId`.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function _setTokenURI(uint256 tokenId, string memory _tokenURI) internal virtual {
        require(_exists(tokenId), "ERC721URIStorage: URI set of nonexistent token");
        _tokenURIs[tokenId] = _tokenURI;
    }

    /**
     * @dev See {ERC721-_burn}. This override additionally checks to see if a
     * token-specific URI was set for the token, and if so, it deletes the token URI from
     * the storage mapping.
     */
    function _burn(uint256 tokenId) internal virtual override {
        super._burn(tokenId);

        if (bytes(_tokenURIs[tokenId]).length != 0) {
            delete _tokenURIs[tokenId];
        }
    }
}

File 6 of 18 : SafeERC20Upgradeable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/utils/SafeERC20.sol)

pragma solidity ^0.8.0;

import "../IERC20Upgradeable.sol";
import "../../../utils/AddressUpgradeable.sol";

/**
 * @title SafeERC20
 * @dev Wrappers around ERC20 operations that throw on failure (when the token
 * contract returns false). Tokens that return no value (and instead revert or
 * throw on failure) are also supported, non-reverting calls are assumed to be
 * successful.
 * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract,
 * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
 */
library SafeERC20Upgradeable {
    using AddressUpgradeable for address;

    function safeTransfer(
        IERC20Upgradeable token,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));
    }

    function safeTransferFrom(
        IERC20Upgradeable token,
        address from,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));
    }

    /**
     * @dev Deprecated. This function has issues similar to the ones found in
     * {IERC20-approve}, and its usage is discouraged.
     *
     * Whenever possible, use {safeIncreaseAllowance} and
     * {safeDecreaseAllowance} instead.
     */
    function safeApprove(
        IERC20Upgradeable token,
        address spender,
        uint256 value
    ) internal {
        // safeApprove should only be called when setting an initial allowance,
        // or when resetting it to zero. To increase and decrease it, use
        // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
        require(
            (value == 0) || (token.allowance(address(this), spender) == 0),
            "SafeERC20: approve from non-zero to non-zero allowance"
        );
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
    }

    function safeIncreaseAllowance(
        IERC20Upgradeable token,
        address spender,
        uint256 value
    ) internal {
        uint256 newAllowance = token.allowance(address(this), spender) + value;
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(
        IERC20Upgradeable token,
        address spender,
        uint256 value
    ) internal {
        unchecked {
            uint256 oldAllowance = token.allowance(address(this), spender);
            require(oldAllowance >= value, "SafeERC20: decreased allowance below zero");
            uint256 newAllowance = oldAllowance - value;
            _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
        }
    }

    /**
     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
     * on the return value: the return value is optional (but if data is returned, it must not be false).
     * @param token The token targeted by the call.
     * @param data The call data (encoded using abi.encode or one of its variants).
     */
    function _callOptionalReturn(IERC20Upgradeable token, bytes memory data) private {
        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
        // we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that
        // the target address contains contract code and also asserts for success in the low-level call.

        bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed");
        if (returndata.length > 0) {
            // Return data is optional
            require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
        }
    }
}

File 7 of 18 : IERC20Upgradeable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/IERC20.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20Upgradeable {
    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns the amount of tokens owned by `account`.
     */
    function balanceOf(address account) external view returns (uint256);

    /**
     * @dev Moves `amount` tokens from the caller's account to `recipient`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address recipient, uint256 amount) external returns (bool);

    /**
     * @dev Returns the remaining number of tokens that `spender` will be
     * allowed to spend on behalf of `owner` through {transferFrom}. This is
     * zero by default.
     *
     * This value changes when {approve} or {transferFrom} are called.
     */
    function allowance(address owner, address spender) external view returns (uint256);

    /**
     * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * IMPORTANT: Beware that changing an allowance with this method brings the risk
     * that someone may use both the old and the new allowance by unfortunate
     * transaction ordering. One possible solution to mitigate this race
     * condition is to first reduce the spender's allowance to 0 and set the
     * desired value afterwards:
     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
     *
     * Emits an {Approval} event.
     */
    function approve(address spender, uint256 amount) external returns (bool);

    /**
     * @dev Moves `amount` tokens from `sender` to `recipient` using the
     * allowance mechanism. `amount` is then deducted from the caller's
     * allowance.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address sender,
        address recipient,
        uint256 amount
    ) external returns (bool);

    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

    /**
     * @dev Emitted when the allowance of a `spender` for an `owner` is set by
     * a call to {approve}. `value` is the new allowance.
     */
    event Approval(address indexed owner, address indexed spender, uint256 value);
}

File 8 of 18 : IMultiCollateralOnOffRamp.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.5.16;

interface IMultiCollateralOnOffRamp {
    function onramp(address collateral, uint collateralAmount) external returns (uint);

    function onrampWithEth(uint amount) external payable returns (uint);

    function getMinimumReceived(address collateral, uint amount) external view returns (uint);

    function getMinimumNeeded(address collateral, uint amount) external view returns (uint);

    function WETH9() external view returns (address);

    function offrampIntoEth(uint amount) external returns (uint);

    function offramp(address collateral, uint amount) external returns (uint);

    function offrampFromIntoEth(address collateralFrom, uint amount) external returns (uint);

    function offrampFrom(
        address collateralFrom,
        address collateralTo,
        uint amount
    ) external returns (uint);

    function priceFeed() external view returns (address);
}

File 9 of 18 : Context.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)

pragma solidity ^0.8.0;

/**
 * @dev Provides information about the current execution context, including the
 * sender of the transaction and its data. While these are generally available
 * via msg.sender and msg.data, they should not be accessed in such a direct
 * manner, since when dealing with meta-transactions the account sending and
 * paying for execution may not be the actual sender (as far as an application
 * is concerned).
 *
 * This contract is only required for intermediate, library-like contracts.
 */
abstract contract Context {
    function _msgSender() internal view virtual returns (address) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes calldata) {
        return msg.data;
    }
}

File 10 of 18 : ERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/ERC721.sol)

pragma solidity ^0.8.0;

import "./IERC721.sol";
import "./IERC721Receiver.sol";
import "./extensions/IERC721Metadata.sol";
import "../../utils/Address.sol";
import "../../utils/Context.sol";
import "../../utils/Strings.sol";
import "../../utils/introspection/ERC165.sol";

/**
 * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
 * the Metadata extension, but not including the Enumerable extension, which is available separately as
 * {ERC721Enumerable}.
 */
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata {
    using Address for address;
    using Strings for uint256;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Mapping from token ID to owner address
    mapping(uint256 => address) private _owners;

    // Mapping owner address to token count
    mapping(address => uint256) private _balances;

    // Mapping from token ID to approved address
    mapping(uint256 => address) private _tokenApprovals;

    // Mapping from owner to operator approvals
    mapping(address => mapping(address => bool)) private _operatorApprovals;

    /**
     * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection.
     */
    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) {
        return
            interfaceId == type(IERC721).interfaceId ||
            interfaceId == type(IERC721Metadata).interfaceId ||
            super.supportsInterface(interfaceId);
    }

    /**
     * @dev See {IERC721-balanceOf}.
     */
    function balanceOf(address owner) public view virtual override returns (uint256) {
        require(owner != address(0), "ERC721: address zero is not a valid owner");
        return _balances[owner];
    }

    /**
     * @dev See {IERC721-ownerOf}.
     */
    function ownerOf(uint256 tokenId) public view virtual override returns (address) {
        address owner = _owners[tokenId];
        require(owner != address(0), "ERC721: invalid token ID");
        return owner;
    }

    /**
     * @dev See {IERC721Metadata-name}.
     */
    function name() public view virtual override returns (string memory) {
        return _name;
    }

    /**
     * @dev See {IERC721Metadata-symbol}.
     */
    function symbol() public view virtual override returns (string memory) {
        return _symbol;
    }

    /**
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        _requireMinted(tokenId);

        string memory baseURI = _baseURI();
        return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : "";
    }

    /**
     * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each
     * token will be the concatenation of the `baseURI` and the `tokenId`. Empty
     * by default, can be overridden in child contracts.
     */
    function _baseURI() internal view virtual returns (string memory) {
        return "";
    }

    /**
     * @dev See {IERC721-approve}.
     */
    function approve(address to, uint256 tokenId) public virtual override {
        address owner = ERC721.ownerOf(tokenId);
        require(to != owner, "ERC721: approval to current owner");

        require(
            _msgSender() == owner || isApprovedForAll(owner, _msgSender()),
            "ERC721: approve caller is not token owner nor approved for all"
        );

        _approve(to, tokenId);
    }

    /**
     * @dev See {IERC721-getApproved}.
     */
    function getApproved(uint256 tokenId) public view virtual override returns (address) {
        _requireMinted(tokenId);

        return _tokenApprovals[tokenId];
    }

    /**
     * @dev See {IERC721-setApprovalForAll}.
     */
    function setApprovalForAll(address operator, bool approved) public virtual override {
        _setApprovalForAll(_msgSender(), operator, approved);
    }

    /**
     * @dev See {IERC721-isApprovedForAll}.
     */
    function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) {
        return _operatorApprovals[owner][operator];
    }

    /**
     * @dev See {IERC721-transferFrom}.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public virtual override {
        //solhint-disable-next-line max-line-length
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: caller is not token owner nor approved");

        _transfer(from, to, tokenId);
    }

    /**
     * @dev See {IERC721-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public virtual override {
        safeTransferFrom(from, to, tokenId, "");
    }

    /**
     * @dev See {IERC721-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory data
    ) public virtual override {
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: caller is not token owner nor approved");
        _safeTransfer(from, to, tokenId, data);
    }

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * `data` is additional data, it has no specified format and it is sent in call to `to`.
     *
     * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g.
     * implement alternative mechanisms to perform token transfer, such as signature-based.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeTransfer(
        address from,
        address to,
        uint256 tokenId,
        bytes memory data
    ) internal virtual {
        _transfer(from, to, tokenId);
        require(_checkOnERC721Received(from, to, tokenId, data), "ERC721: transfer to non ERC721Receiver implementer");
    }

    /**
     * @dev Returns whether `tokenId` exists.
     *
     * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}.
     *
     * Tokens start existing when they are minted (`_mint`),
     * and stop existing when they are burned (`_burn`).
     */
    function _exists(uint256 tokenId) internal view virtual returns (bool) {
        return _owners[tokenId] != address(0);
    }

    /**
     * @dev Returns whether `spender` is allowed to manage `tokenId`.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) {
        address owner = ERC721.ownerOf(tokenId);
        return (spender == owner || isApprovedForAll(owner, spender) || getApproved(tokenId) == spender);
    }

    /**
     * @dev Safely mints `tokenId` and transfers it to `to`.
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeMint(address to, uint256 tokenId) internal virtual {
        _safeMint(to, tokenId, "");
    }

    /**
     * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is
     * forwarded in {IERC721Receiver-onERC721Received} to contract recipients.
     */
    function _safeMint(
        address to,
        uint256 tokenId,
        bytes memory data
    ) internal virtual {
        _mint(to, tokenId);
        require(
            _checkOnERC721Received(address(0), to, tokenId, data),
            "ERC721: transfer to non ERC721Receiver implementer"
        );
    }

    /**
     * @dev Mints `tokenId` and transfers it to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - `to` cannot be the zero address.
     *
     * Emits a {Transfer} event.
     */
    function _mint(address to, uint256 tokenId) internal virtual {
        require(to != address(0), "ERC721: mint to the zero address");
        require(!_exists(tokenId), "ERC721: token already minted");

        _beforeTokenTransfer(address(0), to, tokenId);

        _balances[to] += 1;
        _owners[tokenId] = to;

        emit Transfer(address(0), to, tokenId);

        _afterTokenTransfer(address(0), to, tokenId);
    }

    /**
     * @dev Destroys `tokenId`.
     * The approval is cleared when the token is burned.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     *
     * Emits a {Transfer} event.
     */
    function _burn(uint256 tokenId) internal virtual {
        address owner = ERC721.ownerOf(tokenId);

        _beforeTokenTransfer(owner, address(0), tokenId);

        // Clear approvals
        _approve(address(0), tokenId);

        _balances[owner] -= 1;
        delete _owners[tokenId];

        emit Transfer(owner, address(0), tokenId);

        _afterTokenTransfer(owner, address(0), tokenId);
    }

    /**
     * @dev Transfers `tokenId` from `from` to `to`.
     *  As opposed to {transferFrom}, this imposes no restrictions on msg.sender.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     *
     * Emits a {Transfer} event.
     */
    function _transfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {
        require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer from incorrect owner");
        require(to != address(0), "ERC721: transfer to the zero address");

        _beforeTokenTransfer(from, to, tokenId);

        // Clear approvals from the previous owner
        _approve(address(0), tokenId);

        _balances[from] -= 1;
        _balances[to] += 1;
        _owners[tokenId] = to;

        emit Transfer(from, to, tokenId);

        _afterTokenTransfer(from, to, tokenId);
    }

    /**
     * @dev Approve `to` to operate on `tokenId`
     *
     * Emits an {Approval} event.
     */
    function _approve(address to, uint256 tokenId) internal virtual {
        _tokenApprovals[tokenId] = to;
        emit Approval(ERC721.ownerOf(tokenId), to, tokenId);
    }

    /**
     * @dev Approve `operator` to operate on all of `owner` tokens
     *
     * Emits an {ApprovalForAll} event.
     */
    function _setApprovalForAll(
        address owner,
        address operator,
        bool approved
    ) internal virtual {
        require(owner != operator, "ERC721: approve to caller");
        _operatorApprovals[owner][operator] = approved;
        emit ApprovalForAll(owner, operator, approved);
    }

    /**
     * @dev Reverts if the `tokenId` has not been minted yet.
     */
    function _requireMinted(uint256 tokenId) internal view virtual {
        require(_exists(tokenId), "ERC721: invalid token ID");
    }

    /**
     * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address.
     * The call is not executed if the target address is not a contract.
     *
     * @param from address representing the previous owner of the given token ID
     * @param to target address that will receive the tokens
     * @param tokenId uint256 ID of the token to be transferred
     * @param data bytes optional data to send along with the call
     * @return bool whether the call correctly returned the expected magic value
     */
    function _checkOnERC721Received(
        address from,
        address to,
        uint256 tokenId,
        bytes memory data
    ) private returns (bool) {
        if (to.isContract()) {
            try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, data) returns (bytes4 retval) {
                return retval == IERC721Receiver.onERC721Received.selector;
            } catch (bytes memory reason) {
                if (reason.length == 0) {
                    revert("ERC721: transfer to non ERC721Receiver implementer");
                } else {
                    /// @solidity memory-safe-assembly
                    assembly {
                        revert(add(32, reason), mload(reason))
                    }
                }
            }
        } else {
            return true;
        }
    }

    /**
     * @dev Hook that is called before any token transfer. This includes minting
     * and burning.
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be
     * transferred to `to`.
     * - When `from` is zero, `tokenId` will be minted for `to`.
     * - When `to` is zero, ``from``'s `tokenId` will be burned.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {}

    /**
     * @dev Hook that is called after any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _afterTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {}
}

File 11 of 18 : IERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/IERC721.sol)

pragma solidity ^0.8.0;

import "../../utils/introspection/IERC165.sol";

/**
 * @dev Required interface of an ERC721 compliant contract.
 */
interface IERC721 is IERC165 {
    /**
     * @dev Emitted when `tokenId` token is transferred from `from` to `to`.
     */
    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.
     */
    event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.
     */
    event ApprovalForAll(address indexed owner, address indexed operator, bool approved);

    /**
     * @dev Returns the number of tokens in ``owner``'s account.
     */
    function balanceOf(address owner) external view returns (uint256 balance);

    /**
     * @dev Returns the owner of the `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function ownerOf(uint256 tokenId) external view returns (address owner);

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes calldata data
    ) external;

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must have been allowed to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Transfers `tokenId` token from `from` to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Gives permission to `to` to transfer `tokenId` token to another account.
     * The approval is cleared when the token is transferred.
     *
     * Only a single account can be approved at a time, so approving the zero address clears previous approvals.
     *
     * Requirements:
     *
     * - The caller must own the token or be an approved operator.
     * - `tokenId` must exist.
     *
     * Emits an {Approval} event.
     */
    function approve(address to, uint256 tokenId) external;

    /**
     * @dev Approve or remove `operator` as an operator for the caller.
     * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
     *
     * Requirements:
     *
     * - The `operator` cannot be the caller.
     *
     * Emits an {ApprovalForAll} event.
     */
    function setApprovalForAll(address operator, bool _approved) external;

    /**
     * @dev Returns the account approved for `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function getApproved(uint256 tokenId) external view returns (address operator);

    /**
     * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
     *
     * See {setApprovalForAll}
     */
    function isApprovedForAll(address owner, address operator) external view returns (bool);
}

File 12 of 18 : IERC721Receiver.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol)

pragma solidity ^0.8.0;

/**
 * @title ERC721 token receiver interface
 * @dev Interface for any contract that wants to support safeTransfers
 * from ERC721 asset contracts.
 */
interface IERC721Receiver {
    /**
     * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
     * by `operator` from `from`, this function is called.
     *
     * It must return its Solidity selector to confirm the token transfer.
     * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.
     *
     * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`.
     */
    function onERC721Received(
        address operator,
        address from,
        uint256 tokenId,
        bytes calldata data
    ) external returns (bytes4);
}

File 13 of 18 : IERC721Metadata.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol)

pragma solidity ^0.8.0;

import "../IERC721.sol";

/**
 * @title ERC-721 Non-Fungible Token Standard, optional metadata extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Metadata is IERC721 {
    /**
     * @dev Returns the token collection name.
     */
    function name() external view returns (string memory);

    /**
     * @dev Returns the token collection symbol.
     */
    function symbol() external view returns (string memory);

    /**
     * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token.
     */
    function tokenURI(uint256 tokenId) external view returns (string memory);
}

File 14 of 18 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (utils/Address.sol)

pragma solidity ^0.8.1;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     *
     * [IMPORTANT]
     * ====
     * You shouldn't rely on `isContract` to protect against flash loan attacks!
     *
     * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
     * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
     * constructor.
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize/address.code.length, which returns 0
        // for contracts in construction, since the code is only stored at the end
        // of the constructor execution.

        return account.code.length > 0;
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        (bool success, ) = recipient.call{value: amount}("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain `call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionCall(target, data, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        require(isContract(target), "Address: call to non-contract");

        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
        return functionStaticCall(target, data, "Address: low-level static call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        require(isContract(target), "Address: static call to non-contract");

        (bool success, bytes memory returndata) = target.staticcall(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionDelegateCall(target, data, "Address: low-level delegate call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(isContract(target), "Address: delegate call to non-contract");

        (bool success, bytes memory returndata) = target.delegatecall(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly
                /// @solidity memory-safe-assembly
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

File 15 of 18 : Strings.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (utils/Strings.sol)

pragma solidity ^0.8.0;

/**
 * @dev String operations.
 */
library Strings {
    bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef";
    uint8 private constant _ADDRESS_LENGTH = 20;

    /**
     * @dev Converts a `uint256` to its ASCII `string` decimal representation.
     */
    function toString(uint256 value) internal pure returns (string memory) {
        // Inspired by OraclizeAPI's implementation - MIT licence
        // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol

        if (value == 0) {
            return "0";
        }
        uint256 temp = value;
        uint256 digits;
        while (temp != 0) {
            digits++;
            temp /= 10;
        }
        bytes memory buffer = new bytes(digits);
        while (value != 0) {
            digits -= 1;
            buffer[digits] = bytes1(uint8(48 + uint256(value % 10)));
            value /= 10;
        }
        return string(buffer);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
     */
    function toHexString(uint256 value) internal pure returns (string memory) {
        if (value == 0) {
            return "0x00";
        }
        uint256 temp = value;
        uint256 length = 0;
        while (temp != 0) {
            length++;
            temp >>= 8;
        }
        return toHexString(value, length);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
     */
    function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
        bytes memory buffer = new bytes(2 * length + 2);
        buffer[0] = "0";
        buffer[1] = "x";
        for (uint256 i = 2 * length + 1; i > 1; --i) {
            buffer[i] = _HEX_SYMBOLS[value & 0xf];
            value >>= 4;
        }
        require(value == 0, "Strings: hex length insufficient");
        return string(buffer);
    }

    /**
     * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation.
     */
    function toHexString(address addr) internal pure returns (string memory) {
        return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH);
    }
}

File 16 of 18 : ERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol)

pragma solidity ^0.8.0;

import "./IERC165.sol";

/**
 * @dev Implementation of the {IERC165} interface.
 *
 * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
 * for the additional interface id that will be supported. For example:
 *
 * ```solidity
 * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
 *     return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
 * }
 * ```
 *
 * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
 */
abstract contract ERC165 is IERC165 {
    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IERC165).interfaceId;
    }
}

File 17 of 18 : IERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC165 standard, as defined in the
 * https://eips.ethereum.org/EIPS/eip-165[EIP].
 *
 * Implementers can declare support of contract interfaces, which can then be
 * queried by others ({ERC165Checker}).
 *
 * For an implementation, see {ERC165}.
 */
interface IERC165 {
    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30 000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool);
}

File 18 of 18 : AddressUpgradeable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Address.sol)

pragma solidity ^0.8.0;

/**
 * @dev Collection of functions related to the address type
 */
library AddressUpgradeable {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        assembly {
            size := extcodesize(account)
        }
        return size > 0;
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        (bool success, ) = recipient.call{value: amount}("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain `call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionCall(target, data, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        require(isContract(target), "Address: call to non-contract");

        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
        return functionStaticCall(target, data, "Address: low-level static call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        require(isContract(target), "Address: static call to non-contract");

        (bool success, bytes memory returndata) = target.staticcall(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly

                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

Settings
{
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "libraries": {}
}

Contract Security Audit

Contract ABI

API
[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_toDate","type":"uint256"}],"name":"FinalPositioningDateUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_roundId","type":"uint256"},{"indexed":false,"internalType":"uint256[]","name":"_gameIds","type":"uint256[]"}],"name":"GameIdsAssignedToRound","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_recipient","type":"address"},{"indexed":false,"internalType":"uint256","name":"_id","type":"uint256"},{"indexed":false,"internalType":"uint256[63]","name":"_brackets","type":"uint256[63]"}],"name":"Mint","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_gameIndex","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_teamId","type":"uint256"}],"name":"ResultForGameAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"mintingPrice","type":"uint256"}],"name":"SetMintingPrice","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_onramper","type":"address"}],"name":"SetMultiCollateralOnOffRamp","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_safeBox","type":"address"},{"indexed":false,"internalType":"uint256","name":"_sbFee","type":"uint256"}],"name":"SetSafeBox","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"whitelisted","type":"address"},{"indexed":false,"internalType":"bool","name":"enabled","type":"bool"}],"name":"SetWhitelistedAddress","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_address","type":"address"}],"name":"SetsUSD","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_minter","type":"address"},{"indexed":false,"internalType":"uint256","name":"itemIndex","type":"uint256"},{"indexed":false,"internalType":"uint256[63]","name":"_newBrackets","type":"uint256[63]"}],"name":"UpdateBracketsForAlreadyMintedItem","type":"event"},{"inputs":[],"name":"_name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"addressToTokenIds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_roundId","type":"uint256"},{"internalType":"uint256[]","name":"_gameIds","type":"uint256[]"}],"name":"assignGameIdsToRound","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"canNotMintOrUpdateAfter","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addressToFetchFor","type":"address"}],"name":"getAddressToTokenIds","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"itemId","type":"uint256"}],"name":"getBracketsByItemId","outputs":[{"internalType":"uint256[63]","name":"brackets","type":"uint256[63]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"getCorrectPositionsByRound","outputs":[{"internalType":"uint256[6]","name":"correctPositionsByRound","type":"uint256[6]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_roundId","type":"uint256"},{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"getCorrectPositionsPerRoundByTokenId","outputs":[{"internalType":"uint256","name":"correctPredictions","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCurrentTokenId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getResults","outputs":[{"internalType":"uint256[63]","name":"","type":"uint256[63]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"getTotalPointsByTokenId","outputs":[{"internalType":"uint256","name":"totalPoints","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_tokenIds","type":"uint256[]"}],"name":"getTotalPointsByTokenIds","outputs":[{"internalType":"uint256[]","name":"totalPoints","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_gameId","type":"uint256"},{"internalType":"uint256","name":"_teamId","type":"uint256"}],"name":"isTeamWinnerOfGameId","outputs":[{"internalType":"bool","name":"_flag","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"}],"name":"isWhitelistedAddress","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"itemToBrackets","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[63]","name":"_brackets","type":"uint256[63]"}],"name":"mint","outputs":[{"internalType":"uint256","name":"newItemId","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"collateral","type":"address"},{"internalType":"uint256","name":"collateralAmount","type":"uint256"},{"internalType":"uint256[63]","name":"_brackets","type":"uint256[63]"}],"name":"mintWithDiffCollateral","outputs":[{"internalType":"uint256","name":"newItemId","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[63]","name":"_brackets","type":"uint256[63]"}],"name":"mintWithEth","outputs":[{"internalType":"uint256","name":"newItemId","type":"uint256"}],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"mintingPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"multiCollateralOnOffRamp","outputs":[{"internalType":"contract IMultiCollateralOnOffRamp","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"results","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"retrieveSUSDAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"roundToGameIds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"sUSD","outputs":[{"internalType":"contract IERC20Upgradeable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"safeBox","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"sbFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_toDate","type":"uint256"}],"name":"setFinalDateForPositioning","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_mintingPrice","type":"uint256"}],"name":"setMintingPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_onramper","type":"address"}],"name":"setMultiCollateralOnOffRamp","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"paused","type":"bool"}],"name":"setPaused","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[63]","name":"_results","type":"uint256[63]"}],"name":"setResultArray","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_gameId","type":"uint256"},{"internalType":"uint256","name":"_teamId","type":"uint256"}],"name":"setResultForGame","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_safeBox","type":"address"},{"internalType":"uint256","name":"_sbFee","type":"uint256"}],"name":"setSafeBox","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_urlToUse","type":"string"}],"name":"setURLToUse","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"},{"internalType":"bool","name":"enabled","type":"bool"}],"name":"setWhitelistedAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"}],"name":"setsUSD","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint256[63]","name":"_brackets","type":"uint256[63]"}],"name":"updateBracketsForAlreadyMintedItem","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"urlToUse","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"whitelistedAddresses","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]

60c0604052601b60808190527f4f76657274696d65204d61726368204d61646e6573732032303235000000000060a09081526200004091600991906200024e565b50604080518082019091526004808252634f544d4d60e01b60209092019182526200006e91600a916200024e565b506301312d00604f553480156200008457600080fd5b50600980546200009490620002f4565b80601f0160208091040260200160405190810160405280929190818152602001828054620000c290620002f4565b8015620001135780601f10620000e75761010080835404028352916020019162000113565b820191906000526020600020905b815481529060010190602001808311620000f557829003601f168201915b5050505050600a80546200012790620002f4565b80601f01602080910402602001604051908101604052809291908181526020018280546200015590620002f4565b8015620001a65780601f106200017a57610100808354040283529160200191620001a6565b820191906000526020600020905b8154815290600101906020018083116200018857829003601f168201915b50508451620001c09350600092506020860191506200024e565b508051620001d69060019060208401906200024e565b50506007805460ff1916905550620001ee33620001f4565b62000331565b600780546001600160a01b03838116610100818102610100600160a81b031985161790945560405193909204169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b8280546200025c90620002f4565b90600052602060002090601f016020900481019282620002805760008555620002cb565b82601f106200029b57805160ff1916838001178555620002cb565b82800160010185558215620002cb579182015b82811115620002cb578251825591602001919060010190620002ae565b50620002d9929150620002dd565b5090565b5b80821115620002d95760008155600101620002de565b600181811c908216806200030957607f821691505b602082108114156200032b57634e487b7160e01b600052602260045260246000fd5b50919050565b613d3980620003416000396000f3fe60806040526004361061037a5760003560e01c806370a08231116101d1578063b09f126611610102578063d53d27dc116100a0578063edbb2c4b1161006f578063edbb2c4b14610a61578063f2fde38b14610a81578063fd71b28614610aa1578063ffd9420a14610ac157600080fd5b8063d53d27dc146109b8578063e985e9c5146109d8578063eb864dd914610a21578063ed652d1a14610a4157600080fd5b8063c086391c116100dc578063c086391c14610936578063c87b56dd14610956578063d28d885214610976578063d3bddf0d1461098b57600080fd5b8063b09f1266146108e1578063b3fc4a11146108f6578063b88d4fde1461091657600080fd5b80639324cac71161016f5780639a618c0f116101495780639a618c0f14610861578063a22cb46514610881578063a321c83c146108a1578063a57465e1146108c157600080fd5b80639324cac71461080c578063952a19791461082c57806395d89b411461084c57600080fd5b80637b337a36116101ab5780637b337a36146107895780638417b47f146107a95780638c29bfd2146107c95780638da5cb5b146107e957600080fd5b806370a0823114610734578063715018a61461075457806377325cbc1461076957600080fd5b8063293fb173116102ab57806356189236116102495780635fae0576116102235780635fae0576146106a657806362d7d353146106df5780636352211e146106ff57806363c117bd1461071f57600080fd5b806356189236146106595780635c975abb1461066e5780635f5a50931461068657600080fd5b8063400f8f8511610285578063400f8f85146105d757806342842e0e146105f75780634717f97c1461061757806348663e951461063957600080fd5b8063293fb173146105985780632a439ae1146105ae57806335db70b5146105c157600080fd5b80630d4e33d01161031857806317a7f68e116102f257806317a7f68e1461051857806317f64749146105385780631b0c27da1461055857806323b872dd1461057857600080fd5b80630d4e33d0146104a757806316c38b3c146104cb578063175002c7146104eb57600080fd5b8063081812fc11610354578063081812fc1461040d578063095ea7b3146104455780630b3be3f3146104675780630ca082071461048757600080fd5b806301ffc9a71461038657806306c933d8146103bb57806306fdde03146103eb57600080fd5b3661038157005b600080fd5b34801561039257600080fd5b506103a66103a13660046135f6565b610ae1565b60405190151581526020015b60405180910390f35b3480156103c757600080fd5b506103a66103d636600461337a565b60546020526000908152604090205460ff1681565b3480156103f757600080fd5b50610400610b33565b6040516103b2919061394a565b34801561041957600080fd5b5061042d610428366004613674565b610bc5565b6040516001600160a01b0390911681526020016103b2565b34801561045157600080fd5b506104656104603660046134b0565b610bec565b005b34801561047357600080fd5b5061046561048236600461337a565b610d07565b34801561049357600080fd5b506104656104a236600461337a565b610d64565b3480156104b357600080fd5b506104bd60535481565b6040519081526020016103b2565b3480156104d757600080fd5b506104656104e63660046135be565b610e44565b3480156104f757600080fd5b5061050b610506366004613674565b610e64565b6040516103b2919061390f565b34801561052457600080fd5b506104bd610533366004613516565b610ec5565b34801561054457600080fd5b506104bd6105533660046134d9565b610ff8565b34801561056457600080fd5b506104bd610573366004613674565b6111c4565b34801561058457600080fd5b506104656105933660046133c6565b6111db565b3480156105a457600080fd5b506104bd600b5481565b6104bd6105bc366004613516565b61120c565b3480156105cd57600080fd5b506104bd604f5481565b3480156105e357600080fd5b506104656105f2366004613674565b611334565b34801561060357600080fd5b506104656106123660046133c6565b611353565b34801561062357600080fd5b5061062c61136e565b6040516103b29190613900565b34801561064557600080fd5b5060525461042d906001600160a01b031681565b34801561066557600080fd5b506104bd6113aa565b34801561067a57600080fd5b5060075460ff166103a6565b34801561069257600080fd5b506104656106a136600461362e565b6113ba565b3480156106b257600080fd5b506103a66106c136600461337a565b6001600160a01b031660009081526054602052604090205460ff1690565b3480156106eb57600080fd5b506104bd6106fa36600461377c565b6113d9565b34801561070b57600080fd5b5061042d61071a366004613674565b6113fe565b34801561072b57600080fd5b5061040061145e565b34801561074057600080fd5b506104bd61074f36600461337a565b6114ec565b34801561076057600080fd5b50610465611572565b34801561077557600080fd5b506104656107843660046136c8565b611586565b34801561079557600080fd5b506104656107a436600461347a565b6116c5565b3480156107b557600080fd5b506104656107c4366004613674565b611729565b3480156107d557600080fd5b506104bd6107e436600461377c565b611766565b3480156107f557600080fd5b5060075461010090046001600160a01b031661042d565b34801561081857600080fd5b5060505461042d906001600160a01b031681565b34801561083857600080fd5b5061046561084736600461377c565b611797565b34801561085857600080fd5b50610400611906565b34801561086d57600080fd5b5060515461042d906001600160a01b031681565b34801561088d57600080fd5b5061046561089c36600461347a565b611915565b3480156108ad57600080fd5b506104656108bc3660046136a4565b611920565b3480156108cd57600080fd5b506104bd6108dc3660046134b0565b611a71565b3480156108ed57600080fd5b50610400611a8d565b34801561090257600080fd5b506104bd61091136600461377c565b611a9a565b34801561092257600080fd5b50610465610931366004613401565b611c1a565b34801561094257600080fd5b5061062c610951366004613674565b611c52565b34801561096257600080fd5b50610400610971366004613674565b611c9c565b34801561098257600080fd5b50610400611dad565b34801561099757600080fd5b506109ab6109a636600461354e565b611dba565b6040516103b29190613937565b3480156109c457600080fd5b506104656109d3366004613532565b611e8d565b3480156109e457600080fd5b506103a66109f3366004613394565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b348015610a2d57600080fd5b50610465610a3c3660046134b0565b612022565b348015610a4d57600080fd5b50610465610a5c366004613674565b612083565b348015610a6d57600080fd5b506109ab610a7c36600461337a565b6120c0565b348015610a8d57600080fd5b50610465610a9c36600461337a565b61212a565b348015610aad57600080fd5b506103a6610abc36600461377c565b6121a0565b348015610acd57600080fd5b506104bd610adc366004613674565b6121e4565b60006001600160e01b031982166380ac58cd60e01b1480610b1257506001600160e01b03198216635b5e139f60e01b145b80610b2d57506301ffc9a760e01b6001600160e01b03198316145b92915050565b606060008054610b4290613c39565b80601f0160208091040260200160405190810160405280929190818152602001828054610b6e90613c39565b8015610bbb5780601f10610b9057610100808354040283529160200191610bbb565b820191906000526020600020905b815481529060010190602001808311610b9e57829003601f168201915b5050505050905090565b6000610bd082612247565b506000908152600460205260409020546001600160a01b031690565b6000610bf7826113fe565b9050806001600160a01b0316836001600160a01b03161415610c6a5760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b336001600160a01b0382161480610c865750610c8681336109f3565b610cf85760405162461bcd60e51b815260206004820152603e60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206e6f7220617070726f76656420666f7220616c6c00006064820152608401610c61565b610d028383612297565b505050565b610d0f612305565b605080546001600160a01b0319166001600160a01b0383169081179091556040519081527fbae3da9b16d7b09b9f1a0d00cb2fafc0f94895fde1e0e2d9e31529efa028da06906020015b60405180910390a150565b610d6c612305565b605180546001600160a01b0319166001600160a01b0383811691821790925560505460405163095ea7b360e01b8152600481019290925260001960248301529091169063095ea7b390604401602060405180830381600087803b158015610dd257600080fd5b505af1158015610de6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e0a91906135da565b506040516001600160a01b03821681527f7d16d7e66eb2263f48c2c24af20e095395796ce3d05df64d84d9991a4d43624790602001610d59565b610e4c612305565b80610e5c57610e59612365565b50565b610e596123b7565b610e6c613112565b60005b6006811015610ebf576000610e848285611a9a565b905080838360068110610ea757634e487b7160e01b600052603260045260246000fd5b60200201525080610eb781613c6e565b915050610e6f565b50919050565b6000610ecf6123f4565b600b54610eee5760405162461bcd60e51b8152600401610c61906139af565b600b544210610f0f5760405162461bcd60e51b8152600401610c61906139f1565b604f546050546040516370a0823160e01b81523360048201526001600160a01b03909116906370a082319060240160206040518083038186803b158015610f5557600080fd5b505afa158015610f69573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f8d919061368c565b1015610fd05760405162461bcd60e51b81526020600482015260126024820152714e6f7420656e6f7567682062616c616e636560701b6044820152606401610c61565b604f54605054610fef916001600160a01b03909116903390309061243a565b610b2d826124a5565b60006110026123f4565b600b546110215760405162461bcd60e51b8152600401610c61906139af565b600b5442106110425760405162461bcd60e51b8152600401610c61906139f1565b6110576001600160a01b03851633308661243a565b60515460405163095ea7b360e01b81526001600160a01b039182166004820152602481018590529085169063095ea7b390604401602060405180830381600087803b1580156110a557600080fd5b505af11580156110b9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110dd91906135da565b506051546040516322ceb11360e21b81526001600160a01b038681166004830152602482018690526000921690638b3ac44c90604401602060405180830381600087803b15801561112d57600080fd5b505af1158015611141573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611165919061368c565b9050604f5481116111b25760405162461bcd60e51b81526020600482015260176024820152761a5b9cdd59999a58da595b9d0818dbdb1b185d195c985b604a1b6044820152606401610c61565b6111bb836124a5565b95945050505050565b600c81603f81106111d457600080fd5b0154905081565b6111e53382612626565b6112015760405162461bcd60e51b8152600401610c6190613a28565b610d028383836126a4565b60006112166123f4565b600b546112355760405162461bcd60e51b8152600401610c61906139af565b600b5442106112565760405162461bcd60e51b8152600401610c61906139f1565b605154604051631321b85d60e01b815234600482018190526000926001600160a01b031691631321b85d91906024016020604051808303818588803b15801561129e57600080fd5b505af11580156112b2573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906112d7919061368c565b9050604f5481116113245760405162461bcd60e51b81526020600482015260176024820152761a5b9cdd59999a58da595b9d0818dbdb1b185d195c985b604a1b6044820152606401610c61565b61132d836124a5565b9392505050565b61133c612305565b605054610e59906001600160a01b0316338361284b565b610d0283838360405180602001604052806000815250611c1a565b611376613130565b604080516107e081019182905290600c90603f9082845b81548152602001906001019080831161138d575050505050905090565b60006113b560085490565b905090565b6113c2612305565b80516113d590604e90602084019061314f565b5050565b604b60205281600052604060002081603f81106113f557600080fd5b01549150829050565b6000818152600260205260408120546001600160a01b031680610b2d5760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b6044820152606401610c61565b604e805461146b90613c39565b80601f016020809104026020016040519081016040528092919081815260200182805461149790613c39565b80156114e45780601f106114b9576101008083540402835291602001916114e4565b820191906000526020600020905b8154815290600101906020018083116114c757829003601f168201915b505050505081565b60006001600160a01b0382166115565760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b6064820152608401610c61565b506001600160a01b031660009081526003602052604090205490565b61157a612305565b611584600061287b565b565b61158e612305565b60005b815181101561161c576115cb8282815181106115bd57634e487b7160e01b600052603260045260246000fd5b6020026020010151603f1190565b61160a5760405162461bcd60e51b815260206004820152601060248201526f139bdd081d985b1a590819d85b59525960821b6044820152606401610c61565b8061161481613c6e565b915050611591565b506116278260061190565b6116685760405162461bcd60e51b8152602060048201526012602482015271139bdd081d985b1a59081c9bdd5b99081a5960721b6044820152606401610c61565b6000828152604d602090815260409091208251611687928401906131d3565b507f026ff7b0c2ab55edaf00423b668ee3b4d2c23520deccac97018477ae3aefb5ca82826040516116b9929190613a76565b60405180910390a15050565b6116cd612305565b6001600160a01b038216600081815260546020908152604091829020805460ff19168515159081179091558251938452908301527f0270cfadfea61b39d84d9208acdcb9922a3410eb8614d4f82aeaed4141d9694b91016116b9565b611731612305565b604f8190556040518181527f32e8b862887277ddc9b2ff35787acedfb967ee48f1eb362e59b4c81aa01bf97b90602001610d59565b604d602052816000526040600020818154811061178257600080fd5b90600052602060002001600091509150505481565b60075461010090046001600160a01b03166001600160a01b0316336001600160a01b031614806117d657503360009081526054602052604090205460ff165b6118135760405162461bcd60e51b815260206004820152600e60248201526d24b73b30b634b21031b0b63632b960911b6044820152606401610c61565b61181c816128d5565b61185f5760405162461bcd60e51b815260206004820152601460248201527309cdee840ecc2d8d2c840e8cac2da40d2dcc8caf60631b6044820152606401610c61565b61186982603f1190565b6118ac5760405162461bcd60e51b815260206004820152601460248201527309cdee840ecc2d8d2c840cec2daca40d2dcc8caf60631b6044820152606401610c61565b80600c83603f81106118ce57634e487b7160e01b600052603260045260246000fd5b015560408051838152602081018390527fcd0391919a6c4c4028a73549dc83917cb39bf3e561c0e8a7c29b95f45f3af41c91016116b9565b606060018054610b4290613c39565b6113d53383836128e9565b6119286123f4565b600b546119475760405162461bcd60e51b8152600401610c61906139af565b600b5442106119685760405162461bcd60e51b8152600401610c61906139f1565b611971826129b8565b6119b45760405162461bcd60e51b81526020600482015260146024820152734974656d20646f6573206e6f742065786973747360601b6044820152606401610c61565b336119be836113fe565b6001600160a01b031614611a235760405162461bcd60e51b815260206004820152602660248201527f43616c6c6572206973206e6f74206f776e6572206f6620656e746572656420746044820152651bdad95b925960d21b6064820152608401610c61565b6000828152604b60205260409020611a3d9082603f61320d565b507f98a96b21a5b9cb2322f72dec284116c680d18675f4e59dd0fc0921a2873d891b3383836040516116b9939291906138db565b604c602052816000526040600020818154811061178257600080fd5b600a805461146b90613c39565b6000611aa68360061190565b611ab257506000610b2d565b611abb826129b8565b611ac757506000610b2d565b6000838152604d6020908152604080832080548251818502810185019093528083529192909190830182828015611b1d57602002820191906000526020600020905b815481526020019060010190808311611b09575b5050506000868152604b602052604080822081516107e081019283905295965091949350909150603f9082845b815481526020019060010190808311611b4a575050505050905060005b8251811015611c1157611bec838281518110611b9357634e487b7160e01b600052603260045260246000fd5b602002602001015183858481518110611bbc57634e487b7160e01b600052603260045260246000fd5b6020026020010151603f8110611be257634e487b7160e01b600052603260045260246000fd5b60200201516121a0565b15611bff5783611bfb81613c6e565b9450505b80611c0981613c6e565b915050611b67565b50505092915050565b611c243383612626565b611c405760405162461bcd60e51b8152600401610c6190613a28565b611c4c848484846129d5565b50505050565b611c5a613130565b6000828152604b60205260409081902081516107e081019283905291603f9082845b815481526020019060010190808311611c7c575b50505050509050919050565b6060611ca782612247565b60008281526006602052604081208054611cc090613c39565b80601f0160208091040260200160405190810160405280929190818152602001828054611cec90613c39565b8015611d395780601f10611d0e57610100808354040283529160200191611d39565b820191906000526020600020905b815481529060010190602001808311611d1c57829003601f168201915b505050505090506000611d5760408051602081019091526000815290565b9050805160001415611d6a575092915050565b815115611d9c578082604051602001611d84929190613842565b60405160208183030381529060405292505050919050565b611da584612a08565b949350505050565b6009805461146b90613c39565b60608167ffffffffffffffff811115611de357634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611e0c578160200160208202803683370190505b50905060005b82811015611e8657611e49848483818110611e3d57634e487b7160e01b600052603260045260246000fd5b905060200201356121e4565b828281518110611e6957634e487b7160e01b600052603260045260246000fd5b602090810291909101015280611e7e81613c6e565b915050611e12565b5092915050565b60075461010090046001600160a01b03166001600160a01b0316336001600160a01b03161480611ecc57503360009081526054602052604090205460ff165b611f095760405162461bcd60e51b815260206004820152600e60248201526d24b73b30b634b21031b0b63632b960911b6044820152606401610c61565b60005b603f8110156113d557611f1f81603f1190565b611f625760405162461bcd60e51b815260206004820152601460248201527309cdee840ecc2d8d2c840cec2daca40d2dcc8caf60631b6044820152606401610c61565b8181603f8110611f8257634e487b7160e01b600052603260045260246000fd5b6020020151600c82603f8110611fa857634e487b7160e01b600052603260045260246000fd5b01557fcd0391919a6c4c4028a73549dc83917cb39bf3e561c0e8a7c29b95f45f3af41c818381603f8110611fec57634e487b7160e01b600052603260045260246000fd5b6020020151604051612008929190918252602082015260400190565b60405180910390a18061201a81613c6e565b915050611f0c565b61202a612305565b605280546001600160a01b0319166001600160a01b038416908117909155605382905560408051918252602082018390527fbda3110d6f1c4a52fd6b06aca9eac2f38946c0a664258555c5a88d45937e689f91016116b9565b61208b612305565b600b8190556040518181527fc1456c9966bc3681ed8acbe2d757397502d1fd47f8e7a1bd502cdb6549b480cc90602001610d59565b6001600160a01b0381166000908152604c6020908152604091829020805483518184028101840190945280845260609392830182828015611c905760200282019190600052602060002090815481526020019060010190808311611c7c5750505050509050919050565b612132612305565b6001600160a01b0381166121975760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610c61565b610e598161287b565b60006121ac83603f1190565b15610b2d5781600c84603f81106121d357634e487b7160e01b600052603260045260246000fd5b01541415610b2d5750600192915050565b60006121ef826129b8565b6121f857919050565b60005b6006811015610ebf5760006122108285611a9a565b905061221d826002613b2f565b6122279082613bd7565b6122319084613ac0565b925050808061223f90613c6e565b9150506121fb565b612250816129b8565b610e595760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b6044820152606401610c61565b600081815260046020526040902080546001600160a01b0319166001600160a01b03841690811790915581906122cc826113fe565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6007546001600160a01b036101009091041633146115845760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610c61565b61236d612a7b565b6007805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6123bf6123f4565b6007805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25861239a3390565b60075460ff16156115845760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610c61565b6040516001600160a01b0380851660248301528316604482015260648101829052611c4c9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152612ac4565b60006124b5600880546001019055565b506008546124c33382612b96565b6000818152604b602052604090206124dd9083603f61323a565b50336000908152604c6020908152604082208054600181018255908352912001819055604e805461259691839161251390613c39565b80601f016020809104026020016040519081016040528092919081815260200182805461253f90613c39565b801561258c5780601f106125615761010080835404028352916020019161258c565b820191906000526020600020905b81548152906001019060200180831161256f57829003601f168201915b5050505050612cd5565b605354156125e657605254605354604f546125e6926001600160a01b031691670de0b6b3a7640000916125c99190613bd7565b6125d39190613ad8565b6050546001600160a01b0316919061284b565b7fee0b5de5941b34401bf7c865d6b46a959d512490a3f9757e3b775aa04387a813338284604051612619939291906138ae565b60405180910390a1919050565b600080612632836113fe565b9050806001600160a01b0316846001600160a01b0316148061267957506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff165b80611da55750836001600160a01b031661269284610bc5565b6001600160a01b031614949350505050565b826001600160a01b03166126b7826113fe565b6001600160a01b03161461271b5760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b6064820152608401610c61565b6001600160a01b03821661277d5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610c61565b612788838383612d60565b612793600082612297565b6001600160a01b03831660009081526003602052604081208054600192906127bc908490613bf6565b90915550506001600160a01b03821660009081526003602052604081208054600192906127ea908490613ac0565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6040516001600160a01b038316602482015260448101829052610d0290849063a9059cbb60e01b9060640161246e565b600780546001600160a01b03838116610100818102610100600160a81b031985161790945560405193909204169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60008082118015610b2d5750506040101590565b816001600160a01b0316836001600160a01b0316141561294b5760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610c61565b6001600160a01b03838116600081815260056020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6000908152600260205260409020546001600160a01b0316151590565b6129e08484846126a4565b6129ec84848484612de0565b611c4c5760405162461bcd60e51b8152600401610c619061395d565b6060612a1382612247565b6000612a2a60408051602081019091526000815290565b90506000815111612a4a576040518060200160405280600081525061132d565b80612a5484612eed565b604051602001612a65929190613842565b6040516020818303038152906040529392505050565b60075460ff166115845760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b6044820152606401610c61565b6000612b19826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166130079092919063ffffffff16565b805190915015610d025780806020019051810190612b3791906135da565b610d025760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610c61565b6001600160a01b038216612bec5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610c61565b612bf5816129b8565b15612c425760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610c61565b612c4e60008383612d60565b6001600160a01b0382166000908152600360205260408120805460019290612c77908490613ac0565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b612cde826129b8565b612d415760405162461bcd60e51b815260206004820152602e60248201527f45524337323155524953746f726167653a2055524920736574206f66206e6f6e60448201526d32bc34b9ba32b73a103a37b5b2b760911b6064820152608401610c61565b60008281526006602090815260409091208251610d029284019061314f565b6001600160a01b0383161580612d7d57506001600160a01b038216155b610d025760405162461bcd60e51b815260206004820152602e60248201527f4e6f6e5472616e736665727261626c65455243373231546f6b656e3a206e6f6e60448201526d207472616e736665727261626c6560901b6064820152608401610c61565b60006001600160a01b0384163b15612ee257604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612e24903390899088908890600401613871565b602060405180830381600087803b158015612e3e57600080fd5b505af1925050508015612e6e575060408051601f3d908101601f19168201909252612e6b91810190613612565b60015b612ec8573d808015612e9c576040519150601f19603f3d011682016040523d82523d6000602084013e612ea1565b606091505b508051612ec05760405162461bcd60e51b8152600401610c619061395d565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611da5565b506001949350505050565b606081612f115750506040805180820190915260018152600360fc1b602082015290565b8160005b8115612f3b5780612f2581613c6e565b9150612f349050600a83613ad8565b9150612f15565b60008167ffffffffffffffff811115612f6457634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015612f8e576020820181803683370190505b5090505b8415611da557612fa3600183613bf6565b9150612fb0600a86613c89565b612fbb906030613ac0565b60f81b818381518110612fde57634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a905350613000600a86613ad8565b9450612f92565b6060611da5848460008585843b6130605760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610c61565b600080866001600160a01b0316858760405161307c9190613826565b60006040518083038185875af1925050503d80600081146130b9576040519150601f19603f3d011682016040523d82523d6000602084013e6130be565b606091505b50915091506130ce8282866130d9565b979650505050505050565b606083156130e857508161132d565b8251156130f85782518084602001fd5b8160405162461bcd60e51b8152600401610c61919061394a565b6040518060c001604052806006906020820280368337509192915050565b604051806107e00160405280603f906020820280368337509192915050565b82805461315b90613c39565b90600052602060002090601f01602090048101928261317d57600085556131c3565b82601f1061319657805160ff19168380011785556131c3565b828001600101855582156131c3579182015b828111156131c35782518255916020019190600101906131a8565b506131cf929150613268565b5090565b8280548282559060005260206000209081019282156131c357916020028201828111156131c35782518255916020019190600101906131a8565b82603f81019282156131c357916020028201828111156131c35782518255916020019190600101906131a8565b82603f81019282156131c3579160200282015b828111156131c357823582559160200191906001019061324d565b5b808211156131cf5760008155600101613269565b600067ffffffffffffffff83111561329757613297613cc9565b6132aa601f8401601f1916602001613a8f565b90508281528383830111156132be57600080fd5b828260208301376000602084830101529392505050565b80356001600160a01b03811681146132ec57600080fd5b919050565b806107e08101831015610b2d57600080fd5b600082601f830112613313578081fd5b6040516107e080820182811067ffffffffffffffff8211171561333857613338613cc9565b604052818482810187101561334b578485fd5b8492505b603f83101561336f5780358252600192909201916020918201910161334f565b509195945050505050565b60006020828403121561338b578081fd5b61132d826132d5565b600080604083850312156133a6578081fd5b6133af836132d5565b91506133bd602084016132d5565b90509250929050565b6000806000606084860312156133da578081fd5b6133e3846132d5565b92506133f1602085016132d5565b9150604084013590509250925092565b60008060008060808587031215613416578081fd5b61341f856132d5565b935061342d602086016132d5565b925060408501359150606085013567ffffffffffffffff81111561344f578182fd5b8501601f8101871361345f578182fd5b61346e8782356020840161327d565b91505092959194509250565b6000806040838503121561348c578182fd5b613495836132d5565b915060208301356134a581613cdf565b809150509250929050565b600080604083850312156134c2578182fd5b6134cb836132d5565b946020939093013593505050565b600080600061082084860312156134ee578283fd5b6134f7846132d5565b92506020840135915061350d85604086016132f1565b90509250925092565b60006107e08284031215613528578081fd5b61132d83836132f1565b60006107e08284031215613544578081fd5b61132d8383613303565b60008060208385031215613560578182fd5b823567ffffffffffffffff80821115613577578384fd5b818501915085601f83011261358a578384fd5b813581811115613598578485fd5b8660208260051b85010111156135ac578485fd5b60209290920196919550909350505050565b6000602082840312156135cf578081fd5b813561132d81613cdf565b6000602082840312156135eb578081fd5b815161132d81613cdf565b600060208284031215613607578081fd5b813561132d81613ced565b600060208284031215613623578081fd5b815161132d81613ced565b60006020828403121561363f578081fd5b813567ffffffffffffffff811115613655578182fd5b8201601f81018413613665578182fd5b611da58482356020840161327d565b600060208284031215613685578081fd5b5035919050565b60006020828403121561369d578081fd5b5051919050565b60008061080083850312156136b7578182fd5b823591506133bd8460208501613303565b600080604083850312156136da578182fd5b8235915060208084013567ffffffffffffffff808211156136f9578384fd5b818601915086601f83011261370c578384fd5b81358181111561371e5761371e613cc9565b8060051b915061372f848301613a8f565b8181528481019084860184860187018b1015613749578788fd5b8795505b8386101561376b57803583526001959095019491860191860161374d565b508096505050505050509250929050565b6000806040838503121561378e578182fd5b50508035926020909101359150565b8060005b603f811015611c4c5781518452602093840193909101906001016137a1565b6000815180845260208085019450808401835b838110156137ef578151875295820195908201906001016137d3565b509495945050505050565b60008151808452613812816020860160208601613c0d565b601f01601f19169290920160200192915050565b60008251613838818460208701613c0d565b9190910192915050565b60008351613854818460208801613c0d565b835190830190613868818360208801613c0d565b01949350505050565b6001600160a01b03858116825284166020820152604081018390526080606082018190526000906138a4908301846137fa565b9695505050505050565b6001600160a01b03841681526020810183905261082081016107e083604084013760008152949350505050565b6001600160a01b0384168152602081018390526108208101611da5604083018461379d565b6107e08101610b2d828461379d565b60c08101818360005b6006811015611c11578151835260209283019290910190600101613918565b60208152600061132d60208301846137c0565b60208152600061132d60208301846137fa565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526022908201527f63616e4e6f744d696e744f725570646174654166746572206973206e6f742073604082015261195d60f21b606082015260800190565b6020808252601f908201527f43616e206e6f74206d696e7420616674657220736574746c6564206461746500604082015260600190565b6020808252602e908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526d1c881b9bdc88185c1c1c9bdd995960921b606082015260800190565b828152604060208201526000611da560408301846137c0565b604051601f8201601f1916810167ffffffffffffffff81118282101715613ab857613ab8613cc9565b604052919050565b60008219821115613ad357613ad3613c9d565b500190565b600082613ae757613ae7613cb3565b500490565b600181815b80851115613b27578160001904821115613b0d57613b0d613c9d565b80851615613b1a57918102915b93841c9390800290613af1565b509250929050565b600061132d8383600082613b4557506001610b2d565b81613b5257506000610b2d565b8160018114613b685760028114613b7257613b8e565b6001915050610b2d565b60ff841115613b8357613b83613c9d565b50506001821b610b2d565b5060208310610133831016604e8410600b8410161715613bb1575081810a610b2d565b613bbb8383613aec565b8060001904821115613bcf57613bcf613c9d565b029392505050565b6000816000190483118215151615613bf157613bf1613c9d565b500290565b600082821015613c0857613c08613c9d565b500390565b60005b83811015613c28578181015183820152602001613c10565b83811115611c4c5750506000910152565b600181811c90821680613c4d57607f821691505b60208210811415610ebf57634e487b7160e01b600052602260045260246000fd5b6000600019821415613c8257613c82613c9d565b5060010190565b600082613c9857613c98613cb3565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b8015158114610e5957600080fd5b6001600160e01b031981168114610e5957600080fdfea26469706673582212204fbe513cb5ef5ae8f37e7064531f1e4e65d6dddf632dea94a674278c3338ef8164736f6c63430008040033

Deployed Bytecode

0x60806040526004361061037a5760003560e01c806370a08231116101d1578063b09f126611610102578063d53d27dc116100a0578063edbb2c4b1161006f578063edbb2c4b14610a61578063f2fde38b14610a81578063fd71b28614610aa1578063ffd9420a14610ac157600080fd5b8063d53d27dc146109b8578063e985e9c5146109d8578063eb864dd914610a21578063ed652d1a14610a4157600080fd5b8063c086391c116100dc578063c086391c14610936578063c87b56dd14610956578063d28d885214610976578063d3bddf0d1461098b57600080fd5b8063b09f1266146108e1578063b3fc4a11146108f6578063b88d4fde1461091657600080fd5b80639324cac71161016f5780639a618c0f116101495780639a618c0f14610861578063a22cb46514610881578063a321c83c146108a1578063a57465e1146108c157600080fd5b80639324cac71461080c578063952a19791461082c57806395d89b411461084c57600080fd5b80637b337a36116101ab5780637b337a36146107895780638417b47f146107a95780638c29bfd2146107c95780638da5cb5b146107e957600080fd5b806370a0823114610734578063715018a61461075457806377325cbc1461076957600080fd5b8063293fb173116102ab57806356189236116102495780635fae0576116102235780635fae0576146106a657806362d7d353146106df5780636352211e146106ff57806363c117bd1461071f57600080fd5b806356189236146106595780635c975abb1461066e5780635f5a50931461068657600080fd5b8063400f8f8511610285578063400f8f85146105d757806342842e0e146105f75780634717f97c1461061757806348663e951461063957600080fd5b8063293fb173146105985780632a439ae1146105ae57806335db70b5146105c157600080fd5b80630d4e33d01161031857806317a7f68e116102f257806317a7f68e1461051857806317f64749146105385780631b0c27da1461055857806323b872dd1461057857600080fd5b80630d4e33d0146104a757806316c38b3c146104cb578063175002c7146104eb57600080fd5b8063081812fc11610354578063081812fc1461040d578063095ea7b3146104455780630b3be3f3146104675780630ca082071461048757600080fd5b806301ffc9a71461038657806306c933d8146103bb57806306fdde03146103eb57600080fd5b3661038157005b600080fd5b34801561039257600080fd5b506103a66103a13660046135f6565b610ae1565b60405190151581526020015b60405180910390f35b3480156103c757600080fd5b506103a66103d636600461337a565b60546020526000908152604090205460ff1681565b3480156103f757600080fd5b50610400610b33565b6040516103b2919061394a565b34801561041957600080fd5b5061042d610428366004613674565b610bc5565b6040516001600160a01b0390911681526020016103b2565b34801561045157600080fd5b506104656104603660046134b0565b610bec565b005b34801561047357600080fd5b5061046561048236600461337a565b610d07565b34801561049357600080fd5b506104656104a236600461337a565b610d64565b3480156104b357600080fd5b506104bd60535481565b6040519081526020016103b2565b3480156104d757600080fd5b506104656104e63660046135be565b610e44565b3480156104f757600080fd5b5061050b610506366004613674565b610e64565b6040516103b2919061390f565b34801561052457600080fd5b506104bd610533366004613516565b610ec5565b34801561054457600080fd5b506104bd6105533660046134d9565b610ff8565b34801561056457600080fd5b506104bd610573366004613674565b6111c4565b34801561058457600080fd5b506104656105933660046133c6565b6111db565b3480156105a457600080fd5b506104bd600b5481565b6104bd6105bc366004613516565b61120c565b3480156105cd57600080fd5b506104bd604f5481565b3480156105e357600080fd5b506104656105f2366004613674565b611334565b34801561060357600080fd5b506104656106123660046133c6565b611353565b34801561062357600080fd5b5061062c61136e565b6040516103b29190613900565b34801561064557600080fd5b5060525461042d906001600160a01b031681565b34801561066557600080fd5b506104bd6113aa565b34801561067a57600080fd5b5060075460ff166103a6565b34801561069257600080fd5b506104656106a136600461362e565b6113ba565b3480156106b257600080fd5b506103a66106c136600461337a565b6001600160a01b031660009081526054602052604090205460ff1690565b3480156106eb57600080fd5b506104bd6106fa36600461377c565b6113d9565b34801561070b57600080fd5b5061042d61071a366004613674565b6113fe565b34801561072b57600080fd5b5061040061145e565b34801561074057600080fd5b506104bd61074f36600461337a565b6114ec565b34801561076057600080fd5b50610465611572565b34801561077557600080fd5b506104656107843660046136c8565b611586565b34801561079557600080fd5b506104656107a436600461347a565b6116c5565b3480156107b557600080fd5b506104656107c4366004613674565b611729565b3480156107d557600080fd5b506104bd6107e436600461377c565b611766565b3480156107f557600080fd5b5060075461010090046001600160a01b031661042d565b34801561081857600080fd5b5060505461042d906001600160a01b031681565b34801561083857600080fd5b5061046561084736600461377c565b611797565b34801561085857600080fd5b50610400611906565b34801561086d57600080fd5b5060515461042d906001600160a01b031681565b34801561088d57600080fd5b5061046561089c36600461347a565b611915565b3480156108ad57600080fd5b506104656108bc3660046136a4565b611920565b3480156108cd57600080fd5b506104bd6108dc3660046134b0565b611a71565b3480156108ed57600080fd5b50610400611a8d565b34801561090257600080fd5b506104bd61091136600461377c565b611a9a565b34801561092257600080fd5b50610465610931366004613401565b611c1a565b34801561094257600080fd5b5061062c610951366004613674565b611c52565b34801561096257600080fd5b50610400610971366004613674565b611c9c565b34801561098257600080fd5b50610400611dad565b34801561099757600080fd5b506109ab6109a636600461354e565b611dba565b6040516103b29190613937565b3480156109c457600080fd5b506104656109d3366004613532565b611e8d565b3480156109e457600080fd5b506103a66109f3366004613394565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b348015610a2d57600080fd5b50610465610a3c3660046134b0565b612022565b348015610a4d57600080fd5b50610465610a5c366004613674565b612083565b348015610a6d57600080fd5b506109ab610a7c36600461337a565b6120c0565b348015610a8d57600080fd5b50610465610a9c36600461337a565b61212a565b348015610aad57600080fd5b506103a6610abc36600461377c565b6121a0565b348015610acd57600080fd5b506104bd610adc366004613674565b6121e4565b60006001600160e01b031982166380ac58cd60e01b1480610b1257506001600160e01b03198216635b5e139f60e01b145b80610b2d57506301ffc9a760e01b6001600160e01b03198316145b92915050565b606060008054610b4290613c39565b80601f0160208091040260200160405190810160405280929190818152602001828054610b6e90613c39565b8015610bbb5780601f10610b9057610100808354040283529160200191610bbb565b820191906000526020600020905b815481529060010190602001808311610b9e57829003601f168201915b5050505050905090565b6000610bd082612247565b506000908152600460205260409020546001600160a01b031690565b6000610bf7826113fe565b9050806001600160a01b0316836001600160a01b03161415610c6a5760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b336001600160a01b0382161480610c865750610c8681336109f3565b610cf85760405162461bcd60e51b815260206004820152603e60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206e6f7220617070726f76656420666f7220616c6c00006064820152608401610c61565b610d028383612297565b505050565b610d0f612305565b605080546001600160a01b0319166001600160a01b0383169081179091556040519081527fbae3da9b16d7b09b9f1a0d00cb2fafc0f94895fde1e0e2d9e31529efa028da06906020015b60405180910390a150565b610d6c612305565b605180546001600160a01b0319166001600160a01b0383811691821790925560505460405163095ea7b360e01b8152600481019290925260001960248301529091169063095ea7b390604401602060405180830381600087803b158015610dd257600080fd5b505af1158015610de6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e0a91906135da565b506040516001600160a01b03821681527f7d16d7e66eb2263f48c2c24af20e095395796ce3d05df64d84d9991a4d43624790602001610d59565b610e4c612305565b80610e5c57610e59612365565b50565b610e596123b7565b610e6c613112565b60005b6006811015610ebf576000610e848285611a9a565b905080838360068110610ea757634e487b7160e01b600052603260045260246000fd5b60200201525080610eb781613c6e565b915050610e6f565b50919050565b6000610ecf6123f4565b600b54610eee5760405162461bcd60e51b8152600401610c61906139af565b600b544210610f0f5760405162461bcd60e51b8152600401610c61906139f1565b604f546050546040516370a0823160e01b81523360048201526001600160a01b03909116906370a082319060240160206040518083038186803b158015610f5557600080fd5b505afa158015610f69573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f8d919061368c565b1015610fd05760405162461bcd60e51b81526020600482015260126024820152714e6f7420656e6f7567682062616c616e636560701b6044820152606401610c61565b604f54605054610fef916001600160a01b03909116903390309061243a565b610b2d826124a5565b60006110026123f4565b600b546110215760405162461bcd60e51b8152600401610c61906139af565b600b5442106110425760405162461bcd60e51b8152600401610c61906139f1565b6110576001600160a01b03851633308661243a565b60515460405163095ea7b360e01b81526001600160a01b039182166004820152602481018590529085169063095ea7b390604401602060405180830381600087803b1580156110a557600080fd5b505af11580156110b9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110dd91906135da565b506051546040516322ceb11360e21b81526001600160a01b038681166004830152602482018690526000921690638b3ac44c90604401602060405180830381600087803b15801561112d57600080fd5b505af1158015611141573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611165919061368c565b9050604f5481116111b25760405162461bcd60e51b81526020600482015260176024820152761a5b9cdd59999a58da595b9d0818dbdb1b185d195c985b604a1b6044820152606401610c61565b6111bb836124a5565b95945050505050565b600c81603f81106111d457600080fd5b0154905081565b6111e53382612626565b6112015760405162461bcd60e51b8152600401610c6190613a28565b610d028383836126a4565b60006112166123f4565b600b546112355760405162461bcd60e51b8152600401610c61906139af565b600b5442106112565760405162461bcd60e51b8152600401610c61906139f1565b605154604051631321b85d60e01b815234600482018190526000926001600160a01b031691631321b85d91906024016020604051808303818588803b15801561129e57600080fd5b505af11580156112b2573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906112d7919061368c565b9050604f5481116113245760405162461bcd60e51b81526020600482015260176024820152761a5b9cdd59999a58da595b9d0818dbdb1b185d195c985b604a1b6044820152606401610c61565b61132d836124a5565b9392505050565b61133c612305565b605054610e59906001600160a01b0316338361284b565b610d0283838360405180602001604052806000815250611c1a565b611376613130565b604080516107e081019182905290600c90603f9082845b81548152602001906001019080831161138d575050505050905090565b60006113b560085490565b905090565b6113c2612305565b80516113d590604e90602084019061314f565b5050565b604b60205281600052604060002081603f81106113f557600080fd5b01549150829050565b6000818152600260205260408120546001600160a01b031680610b2d5760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b6044820152606401610c61565b604e805461146b90613c39565b80601f016020809104026020016040519081016040528092919081815260200182805461149790613c39565b80156114e45780601f106114b9576101008083540402835291602001916114e4565b820191906000526020600020905b8154815290600101906020018083116114c757829003601f168201915b505050505081565b60006001600160a01b0382166115565760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b6064820152608401610c61565b506001600160a01b031660009081526003602052604090205490565b61157a612305565b611584600061287b565b565b61158e612305565b60005b815181101561161c576115cb8282815181106115bd57634e487b7160e01b600052603260045260246000fd5b6020026020010151603f1190565b61160a5760405162461bcd60e51b815260206004820152601060248201526f139bdd081d985b1a590819d85b59525960821b6044820152606401610c61565b8061161481613c6e565b915050611591565b506116278260061190565b6116685760405162461bcd60e51b8152602060048201526012602482015271139bdd081d985b1a59081c9bdd5b99081a5960721b6044820152606401610c61565b6000828152604d602090815260409091208251611687928401906131d3565b507f026ff7b0c2ab55edaf00423b668ee3b4d2c23520deccac97018477ae3aefb5ca82826040516116b9929190613a76565b60405180910390a15050565b6116cd612305565b6001600160a01b038216600081815260546020908152604091829020805460ff19168515159081179091558251938452908301527f0270cfadfea61b39d84d9208acdcb9922a3410eb8614d4f82aeaed4141d9694b91016116b9565b611731612305565b604f8190556040518181527f32e8b862887277ddc9b2ff35787acedfb967ee48f1eb362e59b4c81aa01bf97b90602001610d59565b604d602052816000526040600020818154811061178257600080fd5b90600052602060002001600091509150505481565b60075461010090046001600160a01b03166001600160a01b0316336001600160a01b031614806117d657503360009081526054602052604090205460ff165b6118135760405162461bcd60e51b815260206004820152600e60248201526d24b73b30b634b21031b0b63632b960911b6044820152606401610c61565b61181c816128d5565b61185f5760405162461bcd60e51b815260206004820152601460248201527309cdee840ecc2d8d2c840e8cac2da40d2dcc8caf60631b6044820152606401610c61565b61186982603f1190565b6118ac5760405162461bcd60e51b815260206004820152601460248201527309cdee840ecc2d8d2c840cec2daca40d2dcc8caf60631b6044820152606401610c61565b80600c83603f81106118ce57634e487b7160e01b600052603260045260246000fd5b015560408051838152602081018390527fcd0391919a6c4c4028a73549dc83917cb39bf3e561c0e8a7c29b95f45f3af41c91016116b9565b606060018054610b4290613c39565b6113d53383836128e9565b6119286123f4565b600b546119475760405162461bcd60e51b8152600401610c61906139af565b600b5442106119685760405162461bcd60e51b8152600401610c61906139f1565b611971826129b8565b6119b45760405162461bcd60e51b81526020600482015260146024820152734974656d20646f6573206e6f742065786973747360601b6044820152606401610c61565b336119be836113fe565b6001600160a01b031614611a235760405162461bcd60e51b815260206004820152602660248201527f43616c6c6572206973206e6f74206f776e6572206f6620656e746572656420746044820152651bdad95b925960d21b6064820152608401610c61565b6000828152604b60205260409020611a3d9082603f61320d565b507f98a96b21a5b9cb2322f72dec284116c680d18675f4e59dd0fc0921a2873d891b3383836040516116b9939291906138db565b604c602052816000526040600020818154811061178257600080fd5b600a805461146b90613c39565b6000611aa68360061190565b611ab257506000610b2d565b611abb826129b8565b611ac757506000610b2d565b6000838152604d6020908152604080832080548251818502810185019093528083529192909190830182828015611b1d57602002820191906000526020600020905b815481526020019060010190808311611b09575b5050506000868152604b602052604080822081516107e081019283905295965091949350909150603f9082845b815481526020019060010190808311611b4a575050505050905060005b8251811015611c1157611bec838281518110611b9357634e487b7160e01b600052603260045260246000fd5b602002602001015183858481518110611bbc57634e487b7160e01b600052603260045260246000fd5b6020026020010151603f8110611be257634e487b7160e01b600052603260045260246000fd5b60200201516121a0565b15611bff5783611bfb81613c6e565b9450505b80611c0981613c6e565b915050611b67565b50505092915050565b611c243383612626565b611c405760405162461bcd60e51b8152600401610c6190613a28565b611c4c848484846129d5565b50505050565b611c5a613130565b6000828152604b60205260409081902081516107e081019283905291603f9082845b815481526020019060010190808311611c7c575b50505050509050919050565b6060611ca782612247565b60008281526006602052604081208054611cc090613c39565b80601f0160208091040260200160405190810160405280929190818152602001828054611cec90613c39565b8015611d395780601f10611d0e57610100808354040283529160200191611d39565b820191906000526020600020905b815481529060010190602001808311611d1c57829003601f168201915b505050505090506000611d5760408051602081019091526000815290565b9050805160001415611d6a575092915050565b815115611d9c578082604051602001611d84929190613842565b60405160208183030381529060405292505050919050565b611da584612a08565b949350505050565b6009805461146b90613c39565b60608167ffffffffffffffff811115611de357634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611e0c578160200160208202803683370190505b50905060005b82811015611e8657611e49848483818110611e3d57634e487b7160e01b600052603260045260246000fd5b905060200201356121e4565b828281518110611e6957634e487b7160e01b600052603260045260246000fd5b602090810291909101015280611e7e81613c6e565b915050611e12565b5092915050565b60075461010090046001600160a01b03166001600160a01b0316336001600160a01b03161480611ecc57503360009081526054602052604090205460ff165b611f095760405162461bcd60e51b815260206004820152600e60248201526d24b73b30b634b21031b0b63632b960911b6044820152606401610c61565b60005b603f8110156113d557611f1f81603f1190565b611f625760405162461bcd60e51b815260206004820152601460248201527309cdee840ecc2d8d2c840cec2daca40d2dcc8caf60631b6044820152606401610c61565b8181603f8110611f8257634e487b7160e01b600052603260045260246000fd5b6020020151600c82603f8110611fa857634e487b7160e01b600052603260045260246000fd5b01557fcd0391919a6c4c4028a73549dc83917cb39bf3e561c0e8a7c29b95f45f3af41c818381603f8110611fec57634e487b7160e01b600052603260045260246000fd5b6020020151604051612008929190918252602082015260400190565b60405180910390a18061201a81613c6e565b915050611f0c565b61202a612305565b605280546001600160a01b0319166001600160a01b038416908117909155605382905560408051918252602082018390527fbda3110d6f1c4a52fd6b06aca9eac2f38946c0a664258555c5a88d45937e689f91016116b9565b61208b612305565b600b8190556040518181527fc1456c9966bc3681ed8acbe2d757397502d1fd47f8e7a1bd502cdb6549b480cc90602001610d59565b6001600160a01b0381166000908152604c6020908152604091829020805483518184028101840190945280845260609392830182828015611c905760200282019190600052602060002090815481526020019060010190808311611c7c5750505050509050919050565b612132612305565b6001600160a01b0381166121975760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610c61565b610e598161287b565b60006121ac83603f1190565b15610b2d5781600c84603f81106121d357634e487b7160e01b600052603260045260246000fd5b01541415610b2d5750600192915050565b60006121ef826129b8565b6121f857919050565b60005b6006811015610ebf5760006122108285611a9a565b905061221d826002613b2f565b6122279082613bd7565b6122319084613ac0565b925050808061223f90613c6e565b9150506121fb565b612250816129b8565b610e595760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b6044820152606401610c61565b600081815260046020526040902080546001600160a01b0319166001600160a01b03841690811790915581906122cc826113fe565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6007546001600160a01b036101009091041633146115845760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610c61565b61236d612a7b565b6007805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6123bf6123f4565b6007805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25861239a3390565b60075460ff16156115845760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610c61565b6040516001600160a01b0380851660248301528316604482015260648101829052611c4c9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152612ac4565b60006124b5600880546001019055565b506008546124c33382612b96565b6000818152604b602052604090206124dd9083603f61323a565b50336000908152604c6020908152604082208054600181018255908352912001819055604e805461259691839161251390613c39565b80601f016020809104026020016040519081016040528092919081815260200182805461253f90613c39565b801561258c5780601f106125615761010080835404028352916020019161258c565b820191906000526020600020905b81548152906001019060200180831161256f57829003601f168201915b5050505050612cd5565b605354156125e657605254605354604f546125e6926001600160a01b031691670de0b6b3a7640000916125c99190613bd7565b6125d39190613ad8565b6050546001600160a01b0316919061284b565b7fee0b5de5941b34401bf7c865d6b46a959d512490a3f9757e3b775aa04387a813338284604051612619939291906138ae565b60405180910390a1919050565b600080612632836113fe565b9050806001600160a01b0316846001600160a01b0316148061267957506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff165b80611da55750836001600160a01b031661269284610bc5565b6001600160a01b031614949350505050565b826001600160a01b03166126b7826113fe565b6001600160a01b03161461271b5760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b6064820152608401610c61565b6001600160a01b03821661277d5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610c61565b612788838383612d60565b612793600082612297565b6001600160a01b03831660009081526003602052604081208054600192906127bc908490613bf6565b90915550506001600160a01b03821660009081526003602052604081208054600192906127ea908490613ac0565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6040516001600160a01b038316602482015260448101829052610d0290849063a9059cbb60e01b9060640161246e565b600780546001600160a01b03838116610100818102610100600160a81b031985161790945560405193909204169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60008082118015610b2d5750506040101590565b816001600160a01b0316836001600160a01b0316141561294b5760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610c61565b6001600160a01b03838116600081815260056020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6000908152600260205260409020546001600160a01b0316151590565b6129e08484846126a4565b6129ec84848484612de0565b611c4c5760405162461bcd60e51b8152600401610c619061395d565b6060612a1382612247565b6000612a2a60408051602081019091526000815290565b90506000815111612a4a576040518060200160405280600081525061132d565b80612a5484612eed565b604051602001612a65929190613842565b6040516020818303038152906040529392505050565b60075460ff166115845760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b6044820152606401610c61565b6000612b19826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166130079092919063ffffffff16565b805190915015610d025780806020019051810190612b3791906135da565b610d025760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610c61565b6001600160a01b038216612bec5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610c61565b612bf5816129b8565b15612c425760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610c61565b612c4e60008383612d60565b6001600160a01b0382166000908152600360205260408120805460019290612c77908490613ac0565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b612cde826129b8565b612d415760405162461bcd60e51b815260206004820152602e60248201527f45524337323155524953746f726167653a2055524920736574206f66206e6f6e60448201526d32bc34b9ba32b73a103a37b5b2b760911b6064820152608401610c61565b60008281526006602090815260409091208251610d029284019061314f565b6001600160a01b0383161580612d7d57506001600160a01b038216155b610d025760405162461bcd60e51b815260206004820152602e60248201527f4e6f6e5472616e736665727261626c65455243373231546f6b656e3a206e6f6e60448201526d207472616e736665727261626c6560901b6064820152608401610c61565b60006001600160a01b0384163b15612ee257604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612e24903390899088908890600401613871565b602060405180830381600087803b158015612e3e57600080fd5b505af1925050508015612e6e575060408051601f3d908101601f19168201909252612e6b91810190613612565b60015b612ec8573d808015612e9c576040519150601f19603f3d011682016040523d82523d6000602084013e612ea1565b606091505b508051612ec05760405162461bcd60e51b8152600401610c619061395d565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611da5565b506001949350505050565b606081612f115750506040805180820190915260018152600360fc1b602082015290565b8160005b8115612f3b5780612f2581613c6e565b9150612f349050600a83613ad8565b9150612f15565b60008167ffffffffffffffff811115612f6457634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015612f8e576020820181803683370190505b5090505b8415611da557612fa3600183613bf6565b9150612fb0600a86613c89565b612fbb906030613ac0565b60f81b818381518110612fde57634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a905350613000600a86613ad8565b9450612f92565b6060611da5848460008585843b6130605760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610c61565b600080866001600160a01b0316858760405161307c9190613826565b60006040518083038185875af1925050503d80600081146130b9576040519150601f19603f3d011682016040523d82523d6000602084013e6130be565b606091505b50915091506130ce8282866130d9565b979650505050505050565b606083156130e857508161132d565b8251156130f85782518084602001fd5b8160405162461bcd60e51b8152600401610c61919061394a565b6040518060c001604052806006906020820280368337509192915050565b604051806107e00160405280603f906020820280368337509192915050565b82805461315b90613c39565b90600052602060002090601f01602090048101928261317d57600085556131c3565b82601f1061319657805160ff19168380011785556131c3565b828001600101855582156131c3579182015b828111156131c35782518255916020019190600101906131a8565b506131cf929150613268565b5090565b8280548282559060005260206000209081019282156131c357916020028201828111156131c35782518255916020019190600101906131a8565b82603f81019282156131c357916020028201828111156131c35782518255916020019190600101906131a8565b82603f81019282156131c3579160200282015b828111156131c357823582559160200191906001019061324d565b5b808211156131cf5760008155600101613269565b600067ffffffffffffffff83111561329757613297613cc9565b6132aa601f8401601f1916602001613a8f565b90508281528383830111156132be57600080fd5b828260208301376000602084830101529392505050565b80356001600160a01b03811681146132ec57600080fd5b919050565b806107e08101831015610b2d57600080fd5b600082601f830112613313578081fd5b6040516107e080820182811067ffffffffffffffff8211171561333857613338613cc9565b604052818482810187101561334b578485fd5b8492505b603f83101561336f5780358252600192909201916020918201910161334f565b509195945050505050565b60006020828403121561338b578081fd5b61132d826132d5565b600080604083850312156133a6578081fd5b6133af836132d5565b91506133bd602084016132d5565b90509250929050565b6000806000606084860312156133da578081fd5b6133e3846132d5565b92506133f1602085016132d5565b9150604084013590509250925092565b60008060008060808587031215613416578081fd5b61341f856132d5565b935061342d602086016132d5565b925060408501359150606085013567ffffffffffffffff81111561344f578182fd5b8501601f8101871361345f578182fd5b61346e8782356020840161327d565b91505092959194509250565b6000806040838503121561348c578182fd5b613495836132d5565b915060208301356134a581613cdf565b809150509250929050565b600080604083850312156134c2578182fd5b6134cb836132d5565b946020939093013593505050565b600080600061082084860312156134ee578283fd5b6134f7846132d5565b92506020840135915061350d85604086016132f1565b90509250925092565b60006107e08284031215613528578081fd5b61132d83836132f1565b60006107e08284031215613544578081fd5b61132d8383613303565b60008060208385031215613560578182fd5b823567ffffffffffffffff80821115613577578384fd5b818501915085601f83011261358a578384fd5b813581811115613598578485fd5b8660208260051b85010111156135ac578485fd5b60209290920196919550909350505050565b6000602082840312156135cf578081fd5b813561132d81613cdf565b6000602082840312156135eb578081fd5b815161132d81613cdf565b600060208284031215613607578081fd5b813561132d81613ced565b600060208284031215613623578081fd5b815161132d81613ced565b60006020828403121561363f578081fd5b813567ffffffffffffffff811115613655578182fd5b8201601f81018413613665578182fd5b611da58482356020840161327d565b600060208284031215613685578081fd5b5035919050565b60006020828403121561369d578081fd5b5051919050565b60008061080083850312156136b7578182fd5b823591506133bd8460208501613303565b600080604083850312156136da578182fd5b8235915060208084013567ffffffffffffffff808211156136f9578384fd5b818601915086601f83011261370c578384fd5b81358181111561371e5761371e613cc9565b8060051b915061372f848301613a8f565b8181528481019084860184860187018b1015613749578788fd5b8795505b8386101561376b57803583526001959095019491860191860161374d565b508096505050505050509250929050565b6000806040838503121561378e578182fd5b50508035926020909101359150565b8060005b603f811015611c4c5781518452602093840193909101906001016137a1565b6000815180845260208085019450808401835b838110156137ef578151875295820195908201906001016137d3565b509495945050505050565b60008151808452613812816020860160208601613c0d565b601f01601f19169290920160200192915050565b60008251613838818460208701613c0d565b9190910192915050565b60008351613854818460208801613c0d565b835190830190613868818360208801613c0d565b01949350505050565b6001600160a01b03858116825284166020820152604081018390526080606082018190526000906138a4908301846137fa565b9695505050505050565b6001600160a01b03841681526020810183905261082081016107e083604084013760008152949350505050565b6001600160a01b0384168152602081018390526108208101611da5604083018461379d565b6107e08101610b2d828461379d565b60c08101818360005b6006811015611c11578151835260209283019290910190600101613918565b60208152600061132d60208301846137c0565b60208152600061132d60208301846137fa565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526022908201527f63616e4e6f744d696e744f725570646174654166746572206973206e6f742073604082015261195d60f21b606082015260800190565b6020808252601f908201527f43616e206e6f74206d696e7420616674657220736574746c6564206461746500604082015260600190565b6020808252602e908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526d1c881b9bdc88185c1c1c9bdd995960921b606082015260800190565b828152604060208201526000611da560408301846137c0565b604051601f8201601f1916810167ffffffffffffffff81118282101715613ab857613ab8613cc9565b604052919050565b60008219821115613ad357613ad3613c9d565b500190565b600082613ae757613ae7613cb3565b500490565b600181815b80851115613b27578160001904821115613b0d57613b0d613c9d565b80851615613b1a57918102915b93841c9390800290613af1565b509250929050565b600061132d8383600082613b4557506001610b2d565b81613b5257506000610b2d565b8160018114613b685760028114613b7257613b8e565b6001915050610b2d565b60ff841115613b8357613b83613c9d565b50506001821b610b2d565b5060208310610133831016604e8410600b8410161715613bb1575081810a610b2d565b613bbb8383613aec565b8060001904821115613bcf57613bcf613c9d565b029392505050565b6000816000190483118215151615613bf157613bf1613c9d565b500290565b600082821015613c0857613c08613c9d565b500390565b60005b83811015613c28578181015183820152602001613c10565b83811115611c4c5750506000910152565b600181811c90821680613c4d57607f821691505b60208210811415610ebf57634e487b7160e01b600052602260045260246000fd5b6000600019821415613c8257613c82613c9d565b5060010190565b600082613c9857613c98613cb3565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b8015158114610e5957600080fd5b6001600160e01b031981168114610e5957600080fdfea26469706673582212204fbe513cb5ef5ae8f37e7064531f1e4e65d6dddf632dea94a674278c3338ef8164736f6c63430008040033

Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
[ Download: CSV Export  ]
[ Download: CSV Export  ]

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.