Contract 0x7A6E3e8a2858aD19C3a6639Fc00C283CAa8a4A5B

  Note: Our ETH balance display is temporarily unavailable. Please check back later.

Contract Overview

Balance:
Txn Hash Method
Block
From
To
Value
0xfac4a1596899122cb8ec3ad59e5486abe3db947f45376280f2023bc2f26378cc0x60806040181820642023-12-05 16:03:16140 days 14 hrs ago0xd866b2332d4383c1bf719732177e2d9109c99dbc IN  Create: TherundownConsumerVerifier0 ETH0.0000553350970.00001
[ Download CSV Export 
Parent Txn Hash Block From To Value
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
TherundownConsumerVerifier

Compiler Version
v0.8.4+commit.c7e474f2

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 16 : TherundownConsumerVerifier.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import "@openzeppelin/contracts-upgradeable/security/PausableUpgradeable.sol";
import "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol";

// internal
import "../../utils/proxy/solidity-0.8.0/ProxyOwned.sol";
import "../../utils/proxy/solidity-0.8.0/ProxyPausable.sol";

// interface
import "../../interfaces/ITherundownConsumer.sol";
import "../../interfaces/IGamesOddsObtainer.sol";
import "../../interfaces/ISportPositionalMarketManager.sol";
import "../../interfaces/IGamesPlayerProps.sol";

/// @title Verifier of data which are coming from CL and stored into TherundownConsumer.sol
/// @author gruja
contract TherundownConsumerVerifier is Initializable, ProxyOwned, ProxyPausable {
    uint private constant ONE_PERCENT = 1e16;
    uint private constant ONE = 1e18;
    uint public constant CANCELLED = 0;
    uint public constant HOME_WIN = 1;
    uint public constant AWAY_WIN = 2;
    uint public constant RESULT_DRAW = 3;

    ITherundownConsumer public consumer;
    mapping(bytes32 => bool) public invalidName;
    mapping(bytes32 => bool) public supportedMarketType;
    uint public defaultOddsThreshold;
    mapping(uint => uint) public oddsThresholdForSport;

    uint256[] public defaultBookmakerIds;
    mapping(uint256 => uint256[]) public sportIdToBookmakerIds;
    IGamesOddsObtainer public obtainer;
    ISportPositionalMarketManager public sportsManager;
    mapping(address => bool) public whitelistedAddresses;

    uint public minOddsForCheckingThresholdDefault;
    mapping(uint => uint) public minOddsForCheckingThresholdPerSport;

    IGamesPlayerProps public playerProps;
    uint256[] public defaultPlayerPropsBookmakerIds;
    mapping(uint256 => uint256[]) public sportIdForPlayerPropsToBookmakerIds;

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

    function initialize(
        address _owner,
        address _consumer,
        string[] memory _invalidNames,
        string[] memory _supportedMarketTypes,
        uint _defaultOddsThreshold
    ) external initializer {
        setOwner(_owner);
        consumer = ITherundownConsumer(_consumer);
        _setInvalidNames(_invalidNames, true);
        _setSupportedMarketTypes(_supportedMarketTypes, true);
        defaultOddsThreshold = _defaultOddsThreshold;
    }

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

    /// @notice view function which returns names of teams/fighters are invalid
    /// @param _teamA team A in string (Example: Liverpool)
    /// @param _teamB team B in string (Example: Arsenal)
    /// @return bool is names invalid (true -> invalid, false -> valid)
    function isInvalidNames(string memory _teamA, string memory _teamB) external view returns (bool) {
        return
            keccak256(abi.encodePacked(_teamA)) == keccak256(abi.encodePacked(_teamB)) ||
            invalidName[keccak256(abi.encodePacked(_teamA))] ||
            invalidName[keccak256(abi.encodePacked(_teamB))];
    }

    /// @notice view function which returns if names are the same
    /// @param _teamA team A in string (Example: Liverpool)
    /// @param _teamB team B in string (Example: Arsenal)
    /// @return bool is names are the same
    function areTeamsEqual(string memory _teamA, string memory _teamB) external pure returns (bool) {
        return keccak256(abi.encodePacked(_teamA)) == keccak256(abi.encodePacked(_teamB));
    }

    /// @notice view function which returns if market type is supported, checks are done in a wrapper contract
    /// @param _market type of market (create or resolve)
    /// @return bool supported or not
    function isSupportedMarketType(string memory _market) external view returns (bool) {
        return supportedMarketType[keccak256(abi.encodePacked(_market))];
    }

    /// @notice view function which returns if odds are inside of the threshold
    /// @param _sportId sport id for which we get threshold
    /// @param _currentOddsArray current odds on a contract as array
    /// @param _newOddsArray new odds on a contract as array
    /// @param _isTwoPositionalSport is sport two positional
    /// @return bool true if odds are less then threshold false if above
    function areOddsArrayInThreshold(
        uint _sportId,
        uint[] memory _currentOddsArray,
        uint[] memory _newOddsArray,
        bool _isTwoPositionalSport
    ) external view returns (bool) {
        return
            areOddsInThreshold(_sportId, _currentOddsArray[0], _newOddsArray[0]) &&
            areOddsInThreshold(_sportId, _currentOddsArray[1], _newOddsArray[1]) &&
            (_isTwoPositionalSport || areOddsInThreshold(_sportId, _currentOddsArray[2], _newOddsArray[2]));
    }

    /// @notice view function which returns if odds are inside of the threshold
    /// @param _sportId sport id for which we get threshold
    /// @param _currentOdds current single odds on a contract
    /// @param _newOdds new single odds on a contract
    /// @return bool true if odds are less then threshold false if above
    function areOddsInThreshold(
        uint _sportId,
        uint _currentOdds,
        uint _newOdds
    ) public view returns (bool) {
        uint threshold = oddsThresholdForSport[_sportId] == 0 ? defaultOddsThreshold : oddsThresholdForSport[_sportId];
        uint minOdds = minOddsForCheckingThresholdPerSport[_sportId] == 0
            ? minOddsForCheckingThresholdDefault
            : minOddsForCheckingThresholdPerSport[_sportId];

        // Check if both _currentOdds and _newOdds are below X% (example 10%) if minOdds is set
        if (minOdds > 0 && _currentOdds < minOdds * ONE_PERCENT && _newOdds < minOdds * ONE_PERCENT) {
            return true;
        }

        // new odds appear or it is equal
        if (_currentOdds == 0 || _currentOdds == _newOdds) {
            return true;
        }

        // if current odds is GT new one
        if (_newOdds > _currentOdds) {
            return !(((ONE * _newOdds) / _currentOdds) > (ONE + (threshold * ONE_PERCENT)));
        }
        return !(ONE - ((_newOdds * ONE) / _currentOdds) > (threshold * ONE_PERCENT));
    }

    /// @notice view function which if odds are valid or not
    /// @param _isTwoPositionalSport if two positional sport dont look at draw odds
    /// @param _homeOdds odd for home win
    /// @param _awayOdds odd for away win
    /// @param _drawOdds odd for draw win
    /// @return bool true - valid, fasle - invalid
    function areOddsValid(
        bool _isTwoPositionalSport,
        int24 _homeOdds,
        int24 _awayOdds,
        int24 _drawOdds
    ) external view returns (bool) {
        return _areOddsValid(_isTwoPositionalSport, _homeOdds, _awayOdds, _drawOdds);
    }

    function areSpreadOddsValid(
        int16 spreadHome,
        int24 spreadHomeOdds,
        int16 spreadAway,
        int24 spreadAwayOdds
    ) external view returns (bool) {
        return
            spreadHome == spreadAway * -1 &&
            spreadHome != 0 &&
            spreadAway != 0 &&
            spreadHomeOdds != 0 &&
            spreadAwayOdds != 0;
    }

    function areTotalOddsValid(
        uint24 totalOver,
        int24 totalOverOdds,
        uint24 totalUnder,
        int24 totalUnderOdds
    ) external pure returns (bool) {
        return totalOver == totalUnder && totalOver > 0 && totalUnder > 0 && totalOverOdds != 0 && totalUnderOdds != 0;
    }

    function areOddsAndLinesValidForPlayer(
        uint16 _line,
        int24 _overOdds,
        int24 _underOdds
    ) external pure returns (bool) {
        return _line > 0 && _overOdds != 0 && _underOdds != 0;
    }

    /// @notice view function which returns if outcome of a game is valid
    /// @param _isTwoPositionalSport if two positional sport  draw now vallid
    /// @param _outcome home - 1, away - 2, draw - 3 (if not two positional), and cancel - 0 are valid outomes
    /// @return bool true - valid, fasle - invalid
    function isValidOutcomeForGame(bool _isTwoPositionalSport, uint _outcome) external view returns (bool) {
        return _isValidOutcomeForGame(_isTwoPositionalSport, _outcome);
    }

    /// @notice view function which returns if outcome is good with a score
    /// @param _outcome home - 1, away - 2, draw - 3 (if not two positional), and cancel - 0 are valid outomes
    /// @param _homeScore home team has scored in points
    /// @param _awayScore away team has scored in points
    /// @return bool true - valid, fasle - invalid
    function isValidOutcomeWithResult(
        uint _outcome,
        uint _homeScore,
        uint _awayScore
    ) external pure returns (bool) {
        return _isValidOutcomeWithResult(_outcome, _homeScore, _awayScore);
    }

    /// @notice calculate normalized odds based on american odds
    /// @param _americanOdds american odds in array of 3 [home,away,draw]
    /// @return uint[] array of normalized odds
    function calculateAndNormalizeOdds(int[] memory _americanOdds) external pure returns (uint[] memory) {
        return _calculateAndNormalizeOdds(_americanOdds);
    }

    /// @notice view function which returns odds in a batch of games
    /// @param _gameIds game ids for which games is looking
    /// @return odds odds array
    function getOddsForGames(bytes32[] memory _gameIds) public view returns (int24[] memory odds) {
        odds = new int24[](3 * _gameIds.length);
        for (uint i = 0; i < _gameIds.length; i++) {
            (int24 home, int24 away, int24 draw, , , , ) = obtainer.getOddsForGame(_gameIds[i]);
            odds[i * 3 + 0] = home; // 0 3 6 ...
            odds[i * 3 + 1] = away; // 1 4 7 ...
            odds[i * 3 + 2] = draw; // 2 5 8 ...
        }
    }

    /// @notice view function which returns all spread and total properties
    /// @param _gameIds game ids for which games is looking
    function getAllPropertiesForGivenGames(bytes32[] memory _gameIds)
        external
        view
        returns (
            int24[] memory oddsMain,
            int16[] memory linesSpread,
            uint24[] memory linesTotal,
            int24[] memory oddsSpreadTotals
        )
    {
        return (
            getOddsForGames(_gameIds),
            getSpreadLinesForGames(_gameIds),
            getTotalLinesForGames(_gameIds),
            getSpreadTotalsOddsForGames(_gameIds)
        );
    }

    /// @notice view function which returns odds in a batch of games
    /// @param _gameIds game ids for which games is looking
    /// @return lines odds array
    function getSpreadLinesForGames(bytes32[] memory _gameIds) public view returns (int16[] memory lines) {
        lines = new int16[](2 * _gameIds.length);
        for (uint i = 0; i < _gameIds.length; i++) {
            (int16 spreadHome, int16 spreadAway, , ) = obtainer.getLinesForGame(_gameIds[i]);
            lines[i * 2 + 0] = spreadHome; // 0 2 4 ...
            lines[i * 2 + 1] = spreadAway; // 1 3 5 ...
        }
    }

    /// @notice view function which returns odds in a batch of games
    /// @param _gameIds game ids for which games is looking
    /// @return lines odds array
    function getTotalLinesForGames(bytes32[] memory _gameIds) public view returns (uint24[] memory lines) {
        lines = new uint24[](2 * _gameIds.length);
        for (uint i = 0; i < _gameIds.length; i++) {
            (, , uint24 totalOver, uint24 totalUnder) = obtainer.getLinesForGame(_gameIds[i]);
            lines[i * 2 + 0] = totalOver; // 0 2 4 ...
            lines[i * 2 + 1] = totalUnder; // 1 3 5 ...
        }
    }

    /// @notice view function which returns odds and lnes for player props
    /// @param _gameIds game ids for which games is looking
    /// @param _playerIds player ids
    /// @param _optionIds option ids such as points etc
    /// @return odds odds array
    /// @return lines line array
    /// @return invalidOddsArray invalid odds for market
    function getPlayerPropForOption(
        bytes32[] memory _gameIds,
        bytes32[] memory _playerIds,
        uint8[] memory _optionIds
    )
        public
        view
        returns (
            int24[] memory odds,
            uint16[] memory lines,
            bool[] memory invalidOddsArray,
            bool[] memory pausedByInvalidOddsMainArray,
            bool[] memory pausedByCircuitBreakerMainArray
        )
    {
        odds = new int24[](2 * _gameIds.length);
        lines = new uint16[](_gameIds.length);
        invalidOddsArray = new bool[](_gameIds.length);
        pausedByInvalidOddsMainArray = new bool[](_gameIds.length);
        pausedByCircuitBreakerMainArray = new bool[](_gameIds.length);
        for (uint i = 0; i < _gameIds.length; i++) {
            address marketAddress = consumer.marketPerGameId(_gameIds[i]);
            (uint16 line, int24 overOdds, int24 underOdds, bool invalidOdds) = playerProps.getPlayerPropForOption(
                _gameIds[i],
                _playerIds[i],
                _optionIds[i]
            );
            lines[i] = line;
            invalidOddsArray[i] = invalidOdds;
            pausedByInvalidOddsMainArray[i] = playerProps.pausedByInvalidOddsOnMain(marketAddress);
            pausedByCircuitBreakerMainArray[i] = playerProps.pausedByCircuitBreakerOnMain(marketAddress);
            odds[i * 2 + 0] = overOdds; // 0 2 4 ...
            odds[i * 2 + 1] = underOdds; // 1 3 5 ...
        }
    }

    /// @notice view function which returns odds in a batch of games
    /// @param _gameIds game ids for which games is looking
    /// @return odds odds array
    function getSpreadTotalsOddsForGames(bytes32[] memory _gameIds) public view returns (int24[] memory odds) {
        odds = new int24[](4 * _gameIds.length);
        for (uint i = 0; i < _gameIds.length; i++) {
            (, , , int24 spreadHomeOdds, int24 spreadAwayOdds, int24 totalOverOdds, int24 totalUnderOdds) = obtainer
                .getOddsForGame(_gameIds[i]);
            odds[i * 4 + 0] = spreadHomeOdds; // 0 4 8 ...
            odds[i * 4 + 1] = spreadAwayOdds; // 1 5 9 ...
            odds[i * 4 + 2] = totalOverOdds; // 2 6 10 ...
            odds[i * 4 + 3] = totalUnderOdds; // 2 7 11 ...
        }
    }

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

    function _calculateAndNormalizeOdds(int[] memory _americanOdds) internal pure returns (uint[] memory) {
        uint[] memory normalizedOdds = new uint[](_americanOdds.length);
        uint totalOdds;
        for (uint i = 0; i < _americanOdds.length; i++) {
            uint calculationOdds;
            if (_americanOdds[i] == 0) {
                normalizedOdds[i] = 0;
            } else if (_americanOdds[i] > 0) {
                calculationOdds = uint(_americanOdds[i]);
                normalizedOdds[i] = ((10000 * 1e18) / (calculationOdds + 10000)) * 100;
            } else if (_americanOdds[i] < 0) {
                calculationOdds = uint(-_americanOdds[i]);
                normalizedOdds[i] = ((calculationOdds * 1e18) / (calculationOdds + 10000)) * 100;
            }
            totalOdds += normalizedOdds[i];
        }
        for (uint i = 0; i < normalizedOdds.length; i++) {
            if (totalOdds == 0) {
                normalizedOdds[i] = 0;
            } else {
                normalizedOdds[i] = (1e18 * normalizedOdds[i]) / totalOdds;
            }
        }
        return normalizedOdds;
    }

    function _areOddsValid(
        bool _isTwoPositionalSport,
        int24 _homeOdds,
        int24 _awayOdds,
        int24 _drawOdds
    ) internal pure returns (bool) {
        if (_isTwoPositionalSport) {
            return _awayOdds != 0 && _homeOdds != 0;
        } else {
            return _awayOdds != 0 && _homeOdds != 0 && _drawOdds != 0;
        }
    }

    function _isValidOutcomeForGame(bool _isTwoPositionalSport, uint _outcome) internal pure returns (bool) {
        if (_isTwoPositionalSport) {
            return _outcome == HOME_WIN || _outcome == AWAY_WIN || _outcome == CANCELLED;
        }
        return _outcome == HOME_WIN || _outcome == AWAY_WIN || _outcome == RESULT_DRAW || _outcome == CANCELLED;
    }

    function _isValidOutcomeWithResult(
        uint _outcome,
        uint _homeScore,
        uint _awayScore
    ) internal pure returns (bool) {
        if (_outcome == CANCELLED) {
            return _awayScore == CANCELLED && _homeScore == CANCELLED;
        } else if (_outcome == HOME_WIN) {
            return _homeScore > _awayScore;
        } else if (_outcome == AWAY_WIN) {
            return _homeScore < _awayScore;
        } else {
            return _homeScore == _awayScore;
        }
    }

    function _setInvalidNames(string[] memory _invalidNames, bool _isInvalid) internal {
        for (uint256 index = 0; index < _invalidNames.length; index++) {
            // only if current flag is different, if same skip it
            if (invalidName[keccak256(abi.encodePacked(_invalidNames[index]))] != _isInvalid) {
                invalidName[keccak256(abi.encodePacked(_invalidNames[index]))] = _isInvalid;
                emit SetInvalidName(keccak256(abi.encodePacked(_invalidNames[index])), _isInvalid);
            }
        }
    }

    function _setSupportedMarketTypes(string[] memory _supportedMarketTypes, bool _isSupported) internal {
        for (uint256 index = 0; index < _supportedMarketTypes.length; index++) {
            // only if current flag is different, if same skip it
            if (supportedMarketType[keccak256(abi.encodePacked(_supportedMarketTypes[index]))] != _isSupported) {
                supportedMarketType[keccak256(abi.encodePacked(_supportedMarketTypes[index]))] = _isSupported;
                emit SetSupportedMarketType(keccak256(abi.encodePacked(_supportedMarketTypes[index])), _isSupported);
            }
        }
    }

    /// @notice view function which returns all props needed for game
    /// @param _sportId sportid
    /// @param _date date for sport
    /// @return _isSportOnADate have sport on date true/false
    /// @return _twoPositional is two positional sport true/false
    /// @return _gameIds game Ids for that date/sport
    function getSportProperties(uint _sportId, uint _date)
        external
        view
        returns (
            bool _isSportOnADate,
            bool _twoPositional,
            bytes32[] memory _gameIds,
            bool _supportPlayerProps
        )
    {
        return (
            consumer.isSportOnADate(_date, _sportId),
            consumer.isSportTwoPositionsSport(_sportId),
            consumer.getGamesPerDatePerSport(_sportId, _date),
            playerProps.doesSportSupportPlayerProps(_sportId)
        );
    }

    /// @notice view function which returns all props needed for game
    /// @param _gameIds game id on contract
    /// @return _market address
    /// @return _marketResolved resolved true/false
    /// @return _marketCanceled canceled true/false
    /// @return _invalidOdds invalid odds true/false
    /// @return _isPausedByCanceledStatus is game paused by cancel status true/false
    /// @return _isMarketPaused is market paused
    function getGameProperties(bytes32 _gameIds)
        external
        view
        returns (
            address _market,
            bool _marketResolved,
            bool _marketCanceled,
            bool _invalidOdds,
            bool _isPausedByCanceledStatus,
            bool _isMarketPaused
        )
    {
        address marketAddress = consumer.marketPerGameId(_gameIds);
        return (
            marketAddress,
            consumer.marketResolved(marketAddress),
            consumer.marketCanceled(marketAddress),
            obtainer.invalidOdds(marketAddress),
            consumer.isPausedByCanceledStatus(marketAddress),
            marketAddress != address(0) ? sportsManager.isMarketPaused(marketAddress) : false
        );
    }

    function getAllGameProperties(bytes32[] memory _gameIds)
        external
        view
        returns (
            address[] memory _markets,
            bool[] memory _marketResolved,
            bool[] memory _marketCanceled,
            bool[] memory _invalidOdds,
            bool[] memory _isPausedByCanceledStatus,
            bool[] memory _isMarketPaused,
            uint[] memory _startTime,
            uint40[] memory _lastUpdated,
            uint[] memory _playersReportTimestamp
        )
    {
        uint256 arrayLength = _gameIds.length;
        _markets = new address[](arrayLength);
        _marketResolved = new bool[](arrayLength);
        _marketCanceled = new bool[](arrayLength);
        _invalidOdds = new bool[](arrayLength);
        _isPausedByCanceledStatus = new bool[](arrayLength);
        _isMarketPaused = new bool[](arrayLength);
        _startTime = new uint[](arrayLength);
        _lastUpdated = new uint40[](arrayLength);
        _playersReportTimestamp = new uint[](arrayLength);

        for (uint256 i = 0; i < arrayLength; i++) {
            address marketAddress = consumer.marketPerGameId(_gameIds[i]);
            _markets[i] = marketAddress;
            _marketResolved[i] = consumer.marketResolved(marketAddress);
            _marketCanceled[i] = consumer.marketCanceled(marketAddress);
            _invalidOdds[i] = obtainer.invalidOdds(marketAddress);
            _isPausedByCanceledStatus[i] = consumer.isPausedByCanceledStatus(marketAddress);
            _isMarketPaused[i] = marketAddress != address(0) ? sportsManager.isMarketPaused(marketAddress) : false;
            _startTime[i] = consumer.getGameStartTime(_gameIds[i]);
            _lastUpdated[i] = consumer.getLastUpdatedFromGameResolve(_gameIds[i]);
            _playersReportTimestamp[i] = obtainer.playersReportTimestamp(marketAddress);
        }

        return (
            _markets,
            _marketResolved,
            _marketCanceled,
            _invalidOdds,
            _isPausedByCanceledStatus,
            _isMarketPaused,
            _startTime,
            _lastUpdated,
            _playersReportTimestamp
        );
    }

    function areInvalidOdds(bytes32 _gameIds) external view returns (bool _invalidOdds) {
        return obtainer.invalidOdds(consumer.marketPerGameId(_gameIds));
    }

    /// @notice getting primary bookmaker by sports id
    /// @param _sportIds id of a sport for fetching
    function getAllPrimaryBookmakerIdsBySportIds(uint256[] memory _sportIds)
        external
        view
        returns (uint256[] memory _bookmakerIds)
    {
        _bookmakerIds = new uint256[](_sportIds.length);

        for (uint256 i = 0; i < _sportIds.length; i++) {
            uint256[] memory parentIds = sportIdToBookmakerIds[_sportIds[i]];
            _bookmakerIds[i] = parentIds.length > 0 ? parentIds[0] : defaultBookmakerIds[0];
        }
    }

    /// @notice getting bookmaker by sports id
    /// @param _sportId id of a sport for fetching
    function getBookmakerIdsBySportId(uint256 _sportId) external view returns (uint256[] memory) {
        return sportIdToBookmakerIds[_sportId].length > 0 ? sportIdToBookmakerIds[_sportId] : defaultBookmakerIds;
    }

    /// @notice getting bookmaker by sports id for playerProps
    /// @param _sportId id of a sport for fetching
    function getBookmakerIdsBySportIdForPlayerProps(uint256 _sportId) external view returns (uint256[] memory) {
        return
            sportIdForPlayerPropsToBookmakerIds[_sportId].length > 0
                ? sportIdForPlayerPropsToBookmakerIds[_sportId]
                : defaultPlayerPropsBookmakerIds;
    }

    /// @notice return string array from bytes32 array
    /// @param _ids bytes32 array of game ids
    function getStringIDsFromBytesArrayIDs(bytes32[] memory _ids) external view returns (string[] memory _gameIds) {
        if (_ids.length > 0) {
            _gameIds = new string[](_ids.length);
        }
        for (uint i = 0; i < _ids.length; i++) {
            _gameIds[i] = string(abi.encodePacked(_ids[i]));
        }
    }

    function convertUintToString(uint8[] memory _numbers) public pure returns (string[] memory strings) {
        strings = new string[](_numbers.length);

        for (uint256 i = 0; i < _numbers.length; i++) {
            strings[i] = _uintToString(_numbers[i]);
        }
    }

    function _uintToString(uint8 num) internal pure returns (string memory) {
        if (num == 0) {
            return "0";
        }

        uint8 tempNum = num;
        uint8 digits;

        while (tempNum != 0) {
            digits++;
            tempNum /= 10;
        }

        bytes memory buffer = new bytes(digits);

        while (num != 0) {
            digits--;
            buffer[digits] = bytes1(uint8(48 + (num % 10))); // Convert to ASCII
            num /= 10;
        }

        return string(buffer);
    }

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

    /// @notice sets consumer address
    /// @param _consumer consumer address
    function setConsumerAddress(address _consumer) external onlyOwner {
        require(_consumer != address(0), "Invalid address");
        consumer = ITherundownConsumer(_consumer);
        emit NewConsumerAddress(_consumer);
    }

    /// @notice sets manager address
    /// @param _manager address
    function setSportsManager(address _manager) external onlyOwner {
        require(_manager != address(0), "Invalid address");
        sportsManager = ISportPositionalMarketManager(_manager);
        emit NewSportsManagerAddress(_manager);
    }

    /// @notice sets invalid names
    /// @param _invalidNames invalid names as array of strings
    /// @param _isInvalid true/false (invalid or not)
    function setInvalidNames(string[] memory _invalidNames, bool _isInvalid) external onlyOwner {
        require(_invalidNames.length > 0, "Invalid input");
        _setInvalidNames(_invalidNames, _isInvalid);
    }

    /// @notice sets supported market types
    /// @param _supportedMarketTypes supported types as array of strings
    /// @param _isSupported true/false (invalid or not)
    function setSupportedMarketTypes(string[] memory _supportedMarketTypes, bool _isSupported) external onlyOwner {
        require(_supportedMarketTypes.length > 0, "Invalid input");
        _setSupportedMarketTypes(_supportedMarketTypes, _isSupported);
    }

    /// @notice setting default odds threshold
    /// @param _defaultOddsThreshold default odds threshold
    function setDefaultOddsThreshold(uint _defaultOddsThreshold) external onlyOwner {
        require(_defaultOddsThreshold > 0, "Must be more then ZERO");
        defaultOddsThreshold = _defaultOddsThreshold;
        emit NewDefaultOddsThreshold(_defaultOddsThreshold);
    }

    /// @notice setting custom odds threshold for sport
    /// @param _sportId sport id
    /// @param _oddsThresholdForSport custom odds threshold which will be by sport
    function setCustomOddsThresholdForSport(uint _sportId, uint _oddsThresholdForSport) external onlyOwner {
        require(defaultOddsThreshold != _oddsThresholdForSport, "Same value as default value");
        require(_oddsThresholdForSport > 0, "Must be more then ZERO");
        require(consumer.supportedSport(_sportId), "SportId is not supported");
        require(oddsThresholdForSport[_sportId] != _oddsThresholdForSport, "Same value as before");
        oddsThresholdForSport[_sportId] = _oddsThresholdForSport;
        emit NewCustomOddsThresholdForSport(_sportId, _oddsThresholdForSport);
    }

    /// @notice setting default bookmakers
    /// @param _defaultBookmakerIds array of bookmaker ids
    function setDefaultBookmakerIds(uint256[] memory _defaultBookmakerIds) external onlyOwner {
        defaultBookmakerIds = _defaultBookmakerIds;
        emit NewDefaultBookmakerIds(_defaultBookmakerIds);
    }

    /// @notice setting bookmaker by sports id
    /// @param _sportId id of a sport
    /// @param _bookmakerIds array of bookmakers
    function setBookmakerIdsBySportId(uint256 _sportId, uint256[] memory _bookmakerIds) external {
        require(
            msg.sender == owner || whitelistedAddresses[msg.sender],
            "Only owner or whitelisted address may perform this action"
        );
        require(consumer.supportedSport(_sportId), "SportId is not supported");
        sportIdToBookmakerIds[_sportId] = _bookmakerIds;
        emit NewBookmakerIdsBySportId(_sportId, _bookmakerIds);
    }

    /// @notice setting default bookmakers for player props
    /// @param _defaultPlayerPropsBookmakerIds array of bookmaker ids
    function setDefaultBookmakerIdsForPlayerProps(uint256[] memory _defaultPlayerPropsBookmakerIds) external onlyOwner {
        defaultPlayerPropsBookmakerIds = _defaultPlayerPropsBookmakerIds;
        emit NewDefaultBookmakerIdsForPlayerProps(_defaultPlayerPropsBookmakerIds);
    }

    /// @notice setting bookmaker by sports id for playerProps
    /// @param _sportId id of a sport
    /// @param _bookmakerIds array of bookmakers
    function setBookmakerIdsBySportIdForPlayerProps(uint256 _sportId, uint256[] memory _bookmakerIds) external {
        require(msg.sender == owner || whitelistedAddresses[msg.sender], "Only owner or whitelisted address");
        require(
            consumer.supportedSport(_sportId) && playerProps.doesSportSupportPlayerProps(_sportId),
            "SportId is not supported"
        );
        sportIdForPlayerPropsToBookmakerIds[_sportId] = _bookmakerIds;
        emit NewBookmakerIdsBySportIdForPlayerProps(_sportId, _bookmakerIds);
    }

    /// @notice sets the PlayerProps contract address, which only owner can execute
    /// @param _playerProps address of a player props contract
    function setPlayerPropsAddress(address _playerProps) external onlyOwner {
        require(_playerProps != address(0), "Invalid address");
        playerProps = IGamesPlayerProps(_playerProps);
        emit NewPlayerPropsAddress(_playerProps);
    }

    /// @notice sets obtainer
    /// @param _obtainer obtainer address
    function setObtainer(address _obtainer) external onlyOwner {
        obtainer = IGamesOddsObtainer(_obtainer);
        emit NewObtainerAddress(_obtainer);
    }

    /// @notice setWhitelistedAddresses enables whitelist addresses of given array
    /// @param _whitelistedAddresses array of whitelisted addresses
    /// @param _flag adding or removing from whitelist (true: add, false: remove)
    function setWhitelistedAddresses(address[] calldata _whitelistedAddresses, bool _flag) external onlyOwner {
        require(_whitelistedAddresses.length > 0, "Whitelisted addresses cannot be empty");
        for (uint256 index = 0; index < _whitelistedAddresses.length; index++) {
            // only if current flag is different, if same skip it
            if (whitelistedAddresses[_whitelistedAddresses[index]] != _flag) {
                whitelistedAddresses[_whitelistedAddresses[index]] = _flag;
                emit AddedIntoWhitelist(_whitelistedAddresses[index], _flag);
            }
        }
    }

    /// @notice setting min percentage for checking threshold
    /// @param _minOddsForCheckingThresholdDefault min percentage which threshold for odds are checked
    function setMinOddsForCheckingThresholdDefault(uint _minOddsForCheckingThresholdDefault) external onlyOwner {
        minOddsForCheckingThresholdDefault = _minOddsForCheckingThresholdDefault;
        emit NewMinOddsForCheckingThresholdDefault(_minOddsForCheckingThresholdDefault);
    }

    /// @notice setting custom min odds checking for threshold
    /// @param _sportId sport id
    /// @param _minOddsForCheckingThresholdPerSport custom custom min odds checking for threshold
    function setMinOddsForCheckingThresholdPerSport(uint _sportId, uint _minOddsForCheckingThresholdPerSport)
        external
        onlyOwner
    {
        minOddsForCheckingThresholdPerSport[_sportId] = _minOddsForCheckingThresholdPerSport;
        emit NewMinOddsForCheckingThresholdPerSport(_sportId, _minOddsForCheckingThresholdPerSport);
    }

    /* ========== EVENTS ========== */
    event NewConsumerAddress(address _consumer);
    event SetInvalidName(bytes32 _invalidName, bool _isInvalid);
    event SetSupportedMarketType(bytes32 _supportedMarketType, bool _isSupported);
    event NewDefaultOddsThreshold(uint _defaultOddsThreshold);
    event NewCustomOddsThresholdForSport(uint _sportId, uint _oddsThresholdForSport);
    event NewBookmakerIdsBySportId(uint256 _sportId, uint256[] _ids);
    event NewDefaultBookmakerIds(uint256[] _ids);
    event NewObtainerAddress(address _obtainer);
    event NewSportsManagerAddress(address _manager);
    event AddedIntoWhitelist(address _whitelistAddress, bool _flag);
    event NewMinOddsForCheckingThresholdDefault(uint _minOddsChecking);
    event NewMinOddsForCheckingThresholdPerSport(uint256 _sportId, uint _minOddsChecking);
    event NewBookmakerIdsBySportIdForPlayerProps(uint256 _sportId, uint256[] _ids);
    event NewDefaultBookmakerIdsForPlayerProps(uint256[] _ids);
    event NewPlayerPropsAddress(address _playerProps);
}

File 2 of 16 : PausableUpgradeable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (security/Pausable.sol)

pragma solidity ^0.8.0;

import "../utils/ContextUpgradeable.sol";
import "../proxy/utils/Initializable.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 PausableUpgradeable is Initializable, ContextUpgradeable {
    /**
     * @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.
     */
    function __Pausable_init() internal onlyInitializing {
        __Context_init_unchained();
        __Pausable_init_unchained();
    }

    function __Pausable_init_unchained() internal onlyInitializing {
        _paused = false;
    }

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

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

    /**
     * @dev Modifier to make a function callable only when the contract is paused.
     *
     * Requirements:
     *
     * - The contract must be paused.
     */
    modifier whenPaused() {
        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());
    }
    uint256[49] private __gap;
}

File 3 of 16 : Initializable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (proxy/utils/Initializable.sol)

pragma solidity ^0.8.0;

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

/**
 * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed
 * behind a proxy. Since a proxied contract can't have a constructor, it's common to move constructor logic to an
 * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer
 * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.
 *
 * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as
 * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}.
 *
 * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure
 * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity.
 *
 * [CAUTION]
 * ====
 * Avoid leaving a contract uninitialized.
 *
 * An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation
 * contract, which may impact the proxy. To initialize the implementation contract, you can either invoke the
 * initializer manually, or you can include a constructor to automatically mark it as initialized when it is deployed:
 *
 * [.hljs-theme-light.nopadding]
 * ```
 * /// @custom:oz-upgrades-unsafe-allow constructor
 * constructor() initializer {}
 * ```
 * ====
 */
abstract contract Initializable {
    /**
     * @dev Indicates that the contract has been initialized.
     */
    bool private _initialized;

    /**
     * @dev Indicates that the contract is in the process of being initialized.
     */
    bool private _initializing;

    /**
     * @dev Modifier to protect an initializer function from being invoked twice.
     */
    modifier initializer() {
        // If the contract is initializing we ignore whether _initialized is set in order to support multiple
        // inheritance patterns, but we only do this in the context of a constructor, because in other contexts the
        // contract may have been reentered.
        require(_initializing ? _isConstructor() : !_initialized, "Initializable: contract is already initialized");

        bool isTopLevelCall = !_initializing;
        if (isTopLevelCall) {
            _initializing = true;
            _initialized = true;
        }

        _;

        if (isTopLevelCall) {
            _initializing = false;
        }
    }

    /**
     * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the
     * {initializer} modifier, directly or indirectly.
     */
    modifier onlyInitializing() {
        require(_initializing, "Initializable: contract is not initializing");
        _;
    }

    function _isConstructor() private view returns (bool) {
        return !AddressUpgradeable.isContract(address(this));
    }
}

File 4 of 16 : ProxyOwned.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

// Clone of syntetix contract without constructor
contract ProxyOwned {
    address public owner;
    address public nominatedOwner;
    bool private _initialized;
    bool private _transferredAtInit;

    function setOwner(address _owner) public {
        require(_owner != address(0), "Owner address cannot be 0");
        require(!_initialized, "Already initialized, use nominateNewOwner");
        _initialized = true;
        owner = _owner;
        emit OwnerChanged(address(0), _owner);
    }

    function nominateNewOwner(address _owner) external onlyOwner {
        nominatedOwner = _owner;
        emit OwnerNominated(_owner);
    }

    function acceptOwnership() external {
        require(msg.sender == nominatedOwner, "You must be nominated before you can accept ownership");
        emit OwnerChanged(owner, nominatedOwner);
        owner = nominatedOwner;
        nominatedOwner = address(0);
    }

    function transferOwnershipAtInit(address proxyAddress) external onlyOwner {
        require(proxyAddress != address(0), "Invalid address");
        require(!_transferredAtInit, "Already transferred");
        owner = proxyAddress;
        _transferredAtInit = true;
        emit OwnerChanged(owner, proxyAddress);
    }

    modifier onlyOwner {
        _onlyOwner();
        _;
    }

    function _onlyOwner() private view {
        require(msg.sender == owner, "Only the contract owner may perform this action");
    }

    event OwnerNominated(address newOwner);
    event OwnerChanged(address oldOwner, address newOwner);
}

File 5 of 16 : ProxyPausable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

// Inheritance
import "./ProxyOwned.sol";

// Clone of syntetix contract without constructor

contract ProxyPausable is ProxyOwned {
    uint public lastPauseTime;
    bool public paused;

    

    /**
     * @notice Change the paused state of the contract
     * @dev Only the contract owner may call this.
     */
    function setPaused(bool _paused) external onlyOwner {
        // Ensure we're actually changing the state before we do anything
        if (_paused == paused) {
            return;
        }

        // Set our paused state.
        paused = _paused;

        // If applicable, set the last pause time.
        if (paused) {
            lastPauseTime = block.timestamp;
        }

        // Let everyone know that our pause state has changed.
        emit PauseChanged(paused);
    }

    event PauseChanged(bool isPaused);

    modifier notPaused {
        require(!paused, "This action cannot be performed while the contract is paused");
        _;
    }
}

File 6 of 16 : ITherundownConsumer.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

interface ITherundownConsumer {
    struct GameCreate {
        bytes32 gameId;
        uint256 startTime;
        int24 homeOdds;
        int24 awayOdds;
        int24 drawOdds;
        string homeTeam;
        string awayTeam;
    }

    // view functions
    function supportedSport(uint _sportId) external view returns (bool);

    function gameOnADate(bytes32 _gameId) external view returns (uint);

    function isGameResolvedOrCanceled(bytes32 _gameId) external view returns (bool);

    function getNormalizedOddsForMarket(address _market) external view returns (uint[] memory);

    function getGamesPerDatePerSport(uint _sportId, uint _date) external view returns (bytes32[] memory);

    function getGamePropsForOdds(address _market)
        external
        view
        returns (
            uint,
            uint,
            bytes32
        );

    function gameIdPerMarket(address _market) external view returns (bytes32);

    function getGameCreatedById(bytes32 _gameId) external view returns (GameCreate memory);

    function isChildMarket(address _market) external view returns (bool);

    function gameFulfilledCreated(bytes32 _gameId) external view returns (bool);

    function playerProps() external view returns (address);

    function oddsObtainer() external view returns (address);

    // write functions
    function fulfillGamesCreated(
        bytes32 _requestId,
        bytes[] memory _games,
        uint _sportsId,
        uint _date
    ) external;

    function fulfillGamesResolved(
        bytes32 _requestId,
        bytes[] memory _games,
        uint _sportsId
    ) external;

    function fulfillGamesOdds(bytes32 _requestId, bytes[] memory _games) external;

    function setPausedByCanceledStatus(address _market, bool _flag) external;

    function setGameIdPerChildMarket(bytes32 _gameId, address _child) external;

    function pauseOrUnpauseMarket(address _market, bool _pause) external;

    function pauseOrUnpauseMarketForPlayerProps(
        address _market,
        bool _pause,
        bool _invalidOdds,
        bool _circuitBreakerMain
    ) external;

    function setChildMarkets(
        bytes32 _gameId,
        address _main,
        address _child,
        bool _isSpread,
        int16 _spreadHome,
        uint24 _totalOver
    ) external;

    function resolveMarketManually(
        address _market,
        uint _outcome,
        uint8 _homeScore,
        uint8 _awayScore,
        bool _usebackupOdds
    ) external;

    function getOddsForGame(bytes32 _gameId)
        external
        view
        returns (
            int24,
            int24,
            int24
        );

    function sportsIdPerGame(bytes32 _gameId) external view returns (uint);

    function getGameStartTime(bytes32 _gameId) external view returns (uint256);

    function getLastUpdatedFromGameResolve(bytes32 _gameId) external view returns (uint40);

    function marketPerGameId(bytes32 _gameId) external view returns (address);

    function marketResolved(address _market) external view returns (bool);

    function marketCanceled(address _market) external view returns (bool);

    function invalidOdds(address _market) external view returns (bool);

    function isPausedByCanceledStatus(address _market) external view returns (bool);

    function isSportOnADate(uint _date, uint _sportId) external view returns (bool);

    function isSportTwoPositionsSport(uint _sportsId) external view returns (bool);

    function marketForTeamName(string memory _teamName) external view returns (address);
}

File 7 of 16 : IGamesOddsObtainer.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

interface IGamesOddsObtainer {
    struct GameOdds {
        bytes32 gameId;
        int24 homeOdds;
        int24 awayOdds;
        int24 drawOdds;
        int16 spreadHome;
        int24 spreadHomeOdds;
        int16 spreadAway;
        int24 spreadAwayOdds;
        uint24 totalOver;
        int24 totalOverOdds;
        uint24 totalUnder;
        int24 totalUnderOdds;
    }

    // view

    function getActiveChildMarketsFromParent(address _parent) external view returns (address, address);

    function getSpreadTotalsChildMarketsFromParent(address _parent)
        external
        view
        returns (
            uint numOfSpreadMarkets,
            address[] memory spreadMarkets,
            uint numOfTotalsMarkets,
            address[] memory totalMarkets
        );

    function areOddsValid(
        bytes32 _gameId,
        bool _useBackup,
        bool _isTwoPositional
    ) external view returns (bool);

    function invalidOdds(address _market) external view returns (bool);

    function playersReportTimestamp(address _market) external view returns (uint);

    function getNormalizedOdds(bytes32 _gameId) external view returns (uint[] memory);

    function getNormalizedOddsForMarket(address _market) external view returns (uint[] memory);

    function getOddsForGames(bytes32[] memory _gameIds) external view returns (int24[] memory odds);

    function mainMarketChildMarketIndex(address _main, uint _index) external view returns (address);

    function numberOfChildMarkets(address _main) external view returns (uint);

    function mainMarketSpreadChildMarket(address _main, int16 _spread) external view returns (address);

    function mainMarketTotalChildMarket(address _main, uint24 _total) external view returns (address);

    function childMarketMainMarket(address _market) external view returns (address);

    function childMarketTotal(address _market) external view returns (uint24);

    function currentActiveTotalChildMarket(address _main) external view returns (address);

    function currentActiveSpreadChildMarket(address _main) external view returns (address);

    function isSpreadChildMarket(address _child) external view returns (bool);

    function childMarketCreated(address _child) external view returns (bool);

    function getOddsForGame(bytes32 _gameId)
        external
        view
        returns (
            int24,
            int24,
            int24,
            int24,
            int24,
            int24,
            int24
        );

    function getLinesForGame(bytes32 _gameId)
        external
        view
        returns (
            int16,
            int16,
            uint24,
            uint24
        );

    // executable

    function obtainOdds(
        bytes32 requestId,
        GameOdds memory _game,
        uint _sportId,
        address _main,
        bool _isTwoPositional,
        bool _isPlayersReport
    ) external;

    function setFirstOdds(
        bytes32 _gameId,
        int24 _homeOdds,
        int24 _awayOdds,
        int24 _drawOdds
    ) external;

    function setFirstNormalizedOdds(bytes32 _gameId, address _market) external;

    function setBackupOddsAsMainOddsForGame(bytes32 _gameId) external;

    function pauseUnpauseChildMarkets(address _main, bool _flag) external;

    function pauseUnpauseCurrentActiveChildMarket(
        bytes32 _gameId,
        address _main,
        bool _flag
    ) external;

    function resolveChildMarkets(
        address _market,
        uint _outcome,
        uint8 _homeScore,
        uint8 _awayScore
    ) external;

    function setChildMarketGameId(bytes32 gameId, address market) external;
}

File 8 of 16 : ISportPositionalMarketManager.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import "../interfaces/ISportPositionalMarket.sol";

interface ISportPositionalMarketManager {
    /* ========== VIEWS / VARIABLES ========== */

    function marketCreationEnabled() external view returns (bool);

    function totalDeposited() external view returns (uint);

    function numActiveMarkets() external view returns (uint);

    function activeMarkets(uint index, uint pageSize) external view returns (address[] memory);

    function numMaturedMarkets() external view returns (uint);

    function maturedMarkets(uint index, uint pageSize) external view returns (address[] memory);

    function isActiveMarket(address candidate) external view returns (bool);

    function isDoubleChanceMarket(address candidate) external view returns (bool);

    function doesSportSupportDoubleChance(uint _sport) external view returns (bool);

    function isDoubleChanceSupported() external view returns (bool);

    function isKnownMarket(address candidate) external view returns (bool);

    function getActiveMarketAddress(uint _index) external view returns (address);

    function transformCollateral(uint value) external view returns (uint);

    function reverseTransformCollateral(uint value) external view returns (uint);

    function isMarketPaused(address _market) external view returns (bool);

    function expiryDuration() external view returns (uint);

    function isWhitelistedAddress(address _address) external view returns (bool);

    function getOddsObtainer() external view returns (address obtainer);

    /* ========== MUTATIVE FUNCTIONS ========== */

    function createMarket(
        bytes32 gameId,
        string memory gameLabel,
        uint maturity,
        uint initialMint, // initial sUSD to mint options for,
        uint positionCount,
        uint[] memory tags,
        bool isChild,
        address parentMarket
    ) external returns (ISportPositionalMarket);

    function setMarketPaused(address _market, bool _paused) external;

    function updateDatesForMarket(address _market, uint256 _newStartTime) external;

    function resolveMarket(address market, uint outcome) external;

    function expireMarkets(address[] calldata market) external;

    function transferSusdTo(
        address sender,
        address receiver,
        uint amount
    ) external;

    function queryMintsAndMaturityStatusForPlayerProps(address[] memory _playerPropsMarkets)
        external
        view
        returns (
            bool[] memory _hasAnyMintsArray,
            bool[] memory _isMaturedArray,
            bool[] memory _isResolvedArray,
            uint[] memory _maturities
        );
}

File 9 of 16 : IGamesPlayerProps.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

interface IGamesPlayerProps {
    struct PlayerProps {
        bytes32 gameId;
        bytes32 playerId;
        uint8 option;
        string playerName;
        uint16 line;
        int24 overOdds;
        int24 underOdds;
    }

    struct PlayerPropsResolver {
        bytes32 gameId;
        bytes32 playerId;
        uint8 option;
        uint16 score;
        uint8 statusId;
    }

    function obtainPlayerProps(PlayerProps memory _player, uint _sportId) external;

    function resolvePlayerProps(PlayerPropsResolver memory _result) external;

    function cancelMarketFromManager(address _market) external;

    function pauseAllPlayerPropsMarketForMain(
        address _main,
        bool _flag,
        bool _invalidOddsOnMain,
        bool _circuitBreakerMain
    ) external;

    function createFulfilledForPlayerProps(
        bytes32 gameId,
        bytes32 playerId,
        uint8 option
    ) external view returns (bool);

    function cancelPlayerPropsMarketForMain(address _main) external;

    function getNormalizedOddsForMarket(address _market) external view returns (uint[] memory);

    function mainMarketChildMarketIndex(address _main, uint _index) external view returns (address);

    function numberOfChildMarkets(address _main) external view returns (uint);

    function doesSportSupportPlayerProps(uint _sportId) external view returns (bool);

    function pausedByInvalidOddsOnMain(address _main) external view returns (bool);

    function pausedByCircuitBreakerOnMain(address _main) external view returns (bool);

    function playerIdPerChildMarket(address _market) external view returns (bytes32);

    function optionIdPerChildMarket(address _market) external view returns (uint8);

    function getAllOptionsWithPlayersForGameId(bytes32 _gameId)
        external
        view
        returns (
            bytes32[] memory _playerIds,
            uint8[] memory _options,
            bool[] memory _isResolved,
            address[][] memory _childMarketsPerOption
        );

    function getPlayerPropsDataForMarket(address _market)
        external
        view
        returns (
            address,
            bytes32,
            bytes32,
            uint8
        );

    function getPlayerPropForOption(
        bytes32 gameId,
        bytes32 playerId,
        uint8 option
    )
        external
        view
        returns (
            uint16,
            int24,
            int24,
            bool
        );

    function fulfillPlayerPropsCLResolved(bytes[] memory _playerProps) external;
}

File 10 of 16 : ContextUpgradeable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)

pragma solidity ^0.8.0;
import "../proxy/utils/Initializable.sol";

/**
 * @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 ContextUpgradeable is Initializable {
    function __Context_init() internal onlyInitializing {
        __Context_init_unchained();
    }

    function __Context_init_unchained() internal onlyInitializing {
    }
    function _msgSender() internal view virtual returns (address) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes calldata) {
        return msg.data;
    }
    uint256[50] private __gap;
}

File 11 of 16 : 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);
            }
        }
    }
}

File 12 of 16 : ISportPositionalMarket.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.5.16;

import "../interfaces/IPositionalMarketManager.sol";
import "../interfaces/IPosition.sol";
import "../interfaces/IPriceFeed.sol";

interface ISportPositionalMarket {
    /* ========== TYPES ========== */

    enum Phase {
        Trading,
        Maturity,
        Expiry
    }
    enum Side {
        Cancelled,
        Home,
        Away,
        Draw
    }

    /* ========== VIEWS / VARIABLES ========== */

    function getOptions()
        external
        view
        returns (
            IPosition home,
            IPosition away,
            IPosition draw
        );

    function times() external view returns (uint maturity, uint destruction);

    function getGameDetails() external view returns (bytes32 gameId, string memory gameLabel);

    function getGameId() external view returns (bytes32);

    function deposited() external view returns (uint);

    function optionsCount() external view returns (uint);

    function creator() external view returns (address);

    function resolved() external view returns (bool);

    function cancelled() external view returns (bool);

    function paused() external view returns (bool);

    function phase() external view returns (Phase);

    function canResolve() external view returns (bool);

    function result() external view returns (Side);

    function isChild() external view returns (bool);

    function optionsInitialized() external view returns (bool);

    function tags(uint idx) external view returns (uint);

    function getTags() external view returns (uint tag1, uint tag2);

    function getTagsLength() external view returns (uint tagsLength);

    function getParentMarketPositions() external view returns (IPosition position1, IPosition position2);

    function getParentMarketPositionsUint() external view returns (uint position1, uint position2);

    function getStampedOdds()
        external
        view
        returns (
            uint,
            uint,
            uint
        );

    function balancesOf(address account)
        external
        view
        returns (
            uint home,
            uint away,
            uint draw
        );

    function totalSupplies()
        external
        view
        returns (
            uint home,
            uint away,
            uint draw
        );

    function isDoubleChance() external view returns (bool);

    function parentMarket() external view returns (ISportPositionalMarket);

    /* ========== MUTATIVE FUNCTIONS ========== */

    function setPaused(bool _paused) external;

    function updateDates(uint256 _maturity, uint256 _expiry) external;

    function mint(uint value) external;

    function exerciseOptions() external;

    function restoreInvalidOdds(
        uint _homeOdds,
        uint _awayOdds,
        uint _drawOdds
    ) external;
}

File 13 of 16 : IPositionalMarketManager.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.5.16;

import "../interfaces/IPositionalMarket.sol";

interface IPositionalMarketManager {
    /* ========== VIEWS / VARIABLES ========== */

    function durations() external view returns (uint expiryDuration, uint maxTimeToMaturity);

    function capitalRequirement() external view returns (uint);

    function marketCreationEnabled() external view returns (bool);

    function onlyAMMMintingAndBurning() external view returns (bool);

    function transformCollateral(uint value) external view returns (uint);

    function reverseTransformCollateral(uint value) external view returns (uint);

    function totalDeposited() external view returns (uint);

    function numActiveMarkets() external view returns (uint);

    function activeMarkets(uint index, uint pageSize) external view returns (address[] memory);

    function numMaturedMarkets() external view returns (uint);

    function maturedMarkets(uint index, uint pageSize) external view returns (address[] memory);

    function isActiveMarket(address candidate) external view returns (bool);

    function isKnownMarket(address candidate) external view returns (bool);

    function getThalesAMM() external view returns (address);

    /* ========== MUTATIVE FUNCTIONS ========== */

    function createMarket(
        bytes32 oracleKey,
        uint strikePrice,
        uint maturity,
        uint initialMint // initial sUSD to mint options for,
    ) external returns (IPositionalMarket);

    function resolveMarket(address market) external;

    function expireMarkets(address[] calldata market) external;

    function transferSusdTo(
        address sender,
        address receiver,
        uint amount
    ) external;
}

File 14 of 16 : IPosition.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.5.16;

import "./IPositionalMarket.sol";

interface IPosition {
    /* ========== VIEWS / VARIABLES ========== */

    function getBalanceOf(address account) external view returns (uint);

    function getTotalSupply() external view returns (uint);

    function exerciseWithAmount(address claimant, uint amount) external;
}

File 15 of 16 : IPriceFeed.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.5.16;

interface IPriceFeed {
    // Structs
    struct RateAndUpdatedTime {
        uint216 rate;
        uint40 time;
    }

    // Mutative functions
    function addAggregator(bytes32 currencyKey, address aggregatorAddress) external;

    function removeAggregator(bytes32 currencyKey) external;

    // Views

    function rateForCurrency(bytes32 currencyKey) external view returns (uint);

    function rateAndUpdatedTime(bytes32 currencyKey) external view returns (uint rate, uint time);

    function getRates() external view returns (uint[] memory);

    function getCurrencies() external view returns (bytes32[] memory);
}

File 16 of 16 : IPositionalMarket.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.5.16;

import "../interfaces/IPositionalMarketManager.sol";
import "../interfaces/IPosition.sol";
import "../interfaces/IPriceFeed.sol";

interface IPositionalMarket {
    /* ========== TYPES ========== */

    enum Phase {
        Trading,
        Maturity,
        Expiry
    }
    enum Side {
        Up,
        Down
    }

    /* ========== VIEWS / VARIABLES ========== */

    function getOptions() external view returns (IPosition up, IPosition down);

    function times() external view returns (uint maturity, uint destructino);

    function getOracleDetails()
        external
        view
        returns (
            bytes32 key,
            uint strikePrice,
            uint finalPrice
        );

    function fees() external view returns (uint poolFee, uint creatorFee);

    function deposited() external view returns (uint);

    function creator() external view returns (address);

    function resolved() external view returns (bool);

    function phase() external view returns (Phase);

    function oraclePrice() external view returns (uint);

    function oraclePriceAndTimestamp() external view returns (uint price, uint updatedAt);

    function canResolve() external view returns (bool);

    function result() external view returns (Side);

    function balancesOf(address account) external view returns (uint up, uint down);

    function totalSupplies() external view returns (uint up, uint down);

    function getMaximumBurnable(address account) external view returns (uint amount);

    /* ========== MUTATIVE FUNCTIONS ========== */

    function mint(uint value) external;

    function exerciseOptions() external returns (uint);

    function burnOptions(uint amount) external;

    function burnOptionsMaximum() external;
}

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

Contract ABI

[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_whitelistAddress","type":"address"},{"indexed":false,"internalType":"bool","name":"_flag","type":"bool"}],"name":"AddedIntoWhitelist","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_sportId","type":"uint256"},{"indexed":false,"internalType":"uint256[]","name":"_ids","type":"uint256[]"}],"name":"NewBookmakerIdsBySportId","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_sportId","type":"uint256"},{"indexed":false,"internalType":"uint256[]","name":"_ids","type":"uint256[]"}],"name":"NewBookmakerIdsBySportIdForPlayerProps","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_consumer","type":"address"}],"name":"NewConsumerAddress","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_sportId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_oddsThresholdForSport","type":"uint256"}],"name":"NewCustomOddsThresholdForSport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256[]","name":"_ids","type":"uint256[]"}],"name":"NewDefaultBookmakerIds","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256[]","name":"_ids","type":"uint256[]"}],"name":"NewDefaultBookmakerIdsForPlayerProps","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_defaultOddsThreshold","type":"uint256"}],"name":"NewDefaultOddsThreshold","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_minOddsChecking","type":"uint256"}],"name":"NewMinOddsForCheckingThresholdDefault","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_sportId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_minOddsChecking","type":"uint256"}],"name":"NewMinOddsForCheckingThresholdPerSport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_obtainer","type":"address"}],"name":"NewObtainerAddress","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_playerProps","type":"address"}],"name":"NewPlayerPropsAddress","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_manager","type":"address"}],"name":"NewSportsManagerAddress","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"oldOwner","type":"address"},{"indexed":false,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnerChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnerNominated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"isPaused","type":"bool"}],"name":"PauseChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"_invalidName","type":"bytes32"},{"indexed":false,"internalType":"bool","name":"_isInvalid","type":"bool"}],"name":"SetInvalidName","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"_supportedMarketType","type":"bytes32"},{"indexed":false,"internalType":"bool","name":"_isSupported","type":"bool"}],"name":"SetSupportedMarketType","type":"event"},{"inputs":[],"name":"AWAY_WIN","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"CANCELLED","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"HOME_WIN","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"RESULT_DRAW","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_gameIds","type":"bytes32"}],"name":"areInvalidOdds","outputs":[{"internalType":"bool","name":"_invalidOdds","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint16","name":"_line","type":"uint16"},{"internalType":"int24","name":"_overOdds","type":"int24"},{"internalType":"int24","name":"_underOdds","type":"int24"}],"name":"areOddsAndLinesValidForPlayer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"_sportId","type":"uint256"},{"internalType":"uint256[]","name":"_currentOddsArray","type":"uint256[]"},{"internalType":"uint256[]","name":"_newOddsArray","type":"uint256[]"},{"internalType":"bool","name":"_isTwoPositionalSport","type":"bool"}],"name":"areOddsArrayInThreshold","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_sportId","type":"uint256"},{"internalType":"uint256","name":"_currentOdds","type":"uint256"},{"internalType":"uint256","name":"_newOdds","type":"uint256"}],"name":"areOddsInThreshold","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_isTwoPositionalSport","type":"bool"},{"internalType":"int24","name":"_homeOdds","type":"int24"},{"internalType":"int24","name":"_awayOdds","type":"int24"},{"internalType":"int24","name":"_drawOdds","type":"int24"}],"name":"areOddsValid","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"int16","name":"spreadHome","type":"int16"},{"internalType":"int24","name":"spreadHomeOdds","type":"int24"},{"internalType":"int16","name":"spreadAway","type":"int16"},{"internalType":"int24","name":"spreadAwayOdds","type":"int24"}],"name":"areSpreadOddsValid","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"_teamA","type":"string"},{"internalType":"string","name":"_teamB","type":"string"}],"name":"areTeamsEqual","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint24","name":"totalOver","type":"uint24"},{"internalType":"int24","name":"totalOverOdds","type":"int24"},{"internalType":"uint24","name":"totalUnder","type":"uint24"},{"internalType":"int24","name":"totalUnderOdds","type":"int24"}],"name":"areTotalOddsValid","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"int256[]","name":"_americanOdds","type":"int256[]"}],"name":"calculateAndNormalizeOdds","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"consumer","outputs":[{"internalType":"contract ITherundownConsumer","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint8[]","name":"_numbers","type":"uint8[]"}],"name":"convertUintToString","outputs":[{"internalType":"string[]","name":"strings","type":"string[]"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"defaultBookmakerIds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"defaultOddsThreshold","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"defaultPlayerPropsBookmakerIds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"_gameIds","type":"bytes32[]"}],"name":"getAllGameProperties","outputs":[{"internalType":"address[]","name":"_markets","type":"address[]"},{"internalType":"bool[]","name":"_marketResolved","type":"bool[]"},{"internalType":"bool[]","name":"_marketCanceled","type":"bool[]"},{"internalType":"bool[]","name":"_invalidOdds","type":"bool[]"},{"internalType":"bool[]","name":"_isPausedByCanceledStatus","type":"bool[]"},{"internalType":"bool[]","name":"_isMarketPaused","type":"bool[]"},{"internalType":"uint256[]","name":"_startTime","type":"uint256[]"},{"internalType":"uint40[]","name":"_lastUpdated","type":"uint40[]"},{"internalType":"uint256[]","name":"_playersReportTimestamp","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_sportIds","type":"uint256[]"}],"name":"getAllPrimaryBookmakerIdsBySportIds","outputs":[{"internalType":"uint256[]","name":"_bookmakerIds","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"_gameIds","type":"bytes32[]"}],"name":"getAllPropertiesForGivenGames","outputs":[{"internalType":"int24[]","name":"oddsMain","type":"int24[]"},{"internalType":"int16[]","name":"linesSpread","type":"int16[]"},{"internalType":"uint24[]","name":"linesTotal","type":"uint24[]"},{"internalType":"int24[]","name":"oddsSpreadTotals","type":"int24[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_sportId","type":"uint256"}],"name":"getBookmakerIdsBySportId","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_sportId","type":"uint256"}],"name":"getBookmakerIdsBySportIdForPlayerProps","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_gameIds","type":"bytes32"}],"name":"getGameProperties","outputs":[{"internalType":"address","name":"_market","type":"address"},{"internalType":"bool","name":"_marketResolved","type":"bool"},{"internalType":"bool","name":"_marketCanceled","type":"bool"},{"internalType":"bool","name":"_invalidOdds","type":"bool"},{"internalType":"bool","name":"_isPausedByCanceledStatus","type":"bool"},{"internalType":"bool","name":"_isMarketPaused","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"_gameIds","type":"bytes32[]"}],"name":"getOddsForGames","outputs":[{"internalType":"int24[]","name":"odds","type":"int24[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"_gameIds","type":"bytes32[]"},{"internalType":"bytes32[]","name":"_playerIds","type":"bytes32[]"},{"internalType":"uint8[]","name":"_optionIds","type":"uint8[]"}],"name":"getPlayerPropForOption","outputs":[{"internalType":"int24[]","name":"odds","type":"int24[]"},{"internalType":"uint16[]","name":"lines","type":"uint16[]"},{"internalType":"bool[]","name":"invalidOddsArray","type":"bool[]"},{"internalType":"bool[]","name":"pausedByInvalidOddsMainArray","type":"bool[]"},{"internalType":"bool[]","name":"pausedByCircuitBreakerMainArray","type":"bool[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_sportId","type":"uint256"},{"internalType":"uint256","name":"_date","type":"uint256"}],"name":"getSportProperties","outputs":[{"internalType":"bool","name":"_isSportOnADate","type":"bool"},{"internalType":"bool","name":"_twoPositional","type":"bool"},{"internalType":"bytes32[]","name":"_gameIds","type":"bytes32[]"},{"internalType":"bool","name":"_supportPlayerProps","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"_gameIds","type":"bytes32[]"}],"name":"getSpreadLinesForGames","outputs":[{"internalType":"int16[]","name":"lines","type":"int16[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"_gameIds","type":"bytes32[]"}],"name":"getSpreadTotalsOddsForGames","outputs":[{"internalType":"int24[]","name":"odds","type":"int24[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"_ids","type":"bytes32[]"}],"name":"getStringIDsFromBytesArrayIDs","outputs":[{"internalType":"string[]","name":"_gameIds","type":"string[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"_gameIds","type":"bytes32[]"}],"name":"getTotalLinesForGames","outputs":[{"internalType":"uint24[]","name":"lines","type":"uint24[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"},{"internalType":"address","name":"_consumer","type":"address"},{"internalType":"string[]","name":"_invalidNames","type":"string[]"},{"internalType":"string[]","name":"_supportedMarketTypes","type":"string[]"},{"internalType":"uint256","name":"_defaultOddsThreshold","type":"uint256"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"invalidName","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"_teamA","type":"string"},{"internalType":"string","name":"_teamB","type":"string"}],"name":"isInvalidNames","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"_market","type":"string"}],"name":"isSupportedMarketType","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_isTwoPositionalSport","type":"bool"},{"internalType":"uint256","name":"_outcome","type":"uint256"}],"name":"isValidOutcomeForGame","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_outcome","type":"uint256"},{"internalType":"uint256","name":"_homeScore","type":"uint256"},{"internalType":"uint256","name":"_awayScore","type":"uint256"}],"name":"isValidOutcomeWithResult","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"lastPauseTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minOddsForCheckingThresholdDefault","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"minOddsForCheckingThresholdPerSport","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"}],"name":"nominateNewOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"nominatedOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"obtainer","outputs":[{"internalType":"contract IGamesOddsObtainer","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"oddsThresholdForSport","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","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":"playerProps","outputs":[{"internalType":"contract IGamesPlayerProps","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_sportId","type":"uint256"},{"internalType":"uint256[]","name":"_bookmakerIds","type":"uint256[]"}],"name":"setBookmakerIdsBySportId","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_sportId","type":"uint256"},{"internalType":"uint256[]","name":"_bookmakerIds","type":"uint256[]"}],"name":"setBookmakerIdsBySportIdForPlayerProps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_consumer","type":"address"}],"name":"setConsumerAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_sportId","type":"uint256"},{"internalType":"uint256","name":"_oddsThresholdForSport","type":"uint256"}],"name":"setCustomOddsThresholdForSport","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_defaultBookmakerIds","type":"uint256[]"}],"name":"setDefaultBookmakerIds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_defaultPlayerPropsBookmakerIds","type":"uint256[]"}],"name":"setDefaultBookmakerIdsForPlayerProps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_defaultOddsThreshold","type":"uint256"}],"name":"setDefaultOddsThreshold","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string[]","name":"_invalidNames","type":"string[]"},{"internalType":"bool","name":"_isInvalid","type":"bool"}],"name":"setInvalidNames","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_minOddsForCheckingThresholdDefault","type":"uint256"}],"name":"setMinOddsForCheckingThresholdDefault","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_sportId","type":"uint256"},{"internalType":"uint256","name":"_minOddsForCheckingThresholdPerSport","type":"uint256"}],"name":"setMinOddsForCheckingThresholdPerSport","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_obtainer","type":"address"}],"name":"setObtainer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"}],"name":"setOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_paused","type":"bool"}],"name":"setPaused","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_playerProps","type":"address"}],"name":"setPlayerPropsAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_manager","type":"address"}],"name":"setSportsManager","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string[]","name":"_supportedMarketTypes","type":"string[]"},{"internalType":"bool","name":"_isSupported","type":"bool"}],"name":"setSupportedMarketTypes","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_whitelistedAddresses","type":"address[]"},{"internalType":"bool","name":"_flag","type":"bool"}],"name":"setWhitelistedAddresses","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"sportIdForPlayerPropsToBookmakerIds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"sportIdToBookmakerIds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"sportsManager","outputs":[{"internalType":"contract ISportPositionalMarketManager","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"supportedMarketType","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"proxyAddress","type":"address"}],"name":"transferOwnershipAtInit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"whitelistedAddresses","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}]

608060405234801561001057600080fd5b50615f2880620000216000396000f3fe608060405234801561001057600080fd5b506004361061041d5760003560e01c8063730d62501161022b5780639c74a76e11610130578063c3b83f5f116100b8578063df2ba25011610087578063df2ba25014610a07578063df5a00ae14610a1a578063efe2c8a414610a2d578063f595901b14610a40578063f7a679b914610a5357600080fd5b8063c3b83f5f146109ae578063c8bbcd96146109c1578063d06c1467146109d4578063da5b82d2146109f457600080fd5b8063ae71dcdf116100ff578063ae71dcdf1461095f578063af765c9714610967578063b216d97414610970578063b4fd729614610983578063c128f77b1461099b57600080fd5b80639c74a76e14610913578063a1380dcf14610926578063aaae1cb514610939578063abc7b9881461094c57600080fd5b80638da5cb5b116101b357806397dc205d1161018257806397dc205d146108b457806398350f9a146108c757806399d9f2b9146108da5780639a066f5d146108ed5780639ab21a771461090057600080fd5b80638da5cb5b1461086c5780638e5b53341461088557806391b4ded9146108985780639265a4e6146108a157600080fd5b80637f56efb1116101fa5780637f56efb1146107f35780637f70290b146108135780637fabe16b1461083357806380be635514610846578063879c0c5e1461085957600080fd5b8063730d625014610792578063760ec8df146107a557806377874ce2146107c857806379ba5097146107eb57600080fd5b806338d30ea711610331578063519822f6116102b95780635d0fde6c116102885780635d0fde6c146107165780635d7412fd146107295780635d7fb8e21461073c57806365c235921461074f57806369b4840e1461077257600080fd5b8063519822f6146106d057806353a47bb7146106e35780635c2b764a146106f65780635c975abb1461070957600080fd5b806346e38c281161030057806346e38c281461065d57806348cd0f671461067d5780634b15c920146106a1578063500b218c146106aa578063503005ba146106bd57600080fd5b806338d30ea71461060c5780633d011ac91461061f57806342fa646a14610642578063459c0bd01461065557600080fd5b80631627540c116103b457806321f5908e1161038357806321f5908e146105745780632c95f596146105c85780632f893de7146105db5780632fff7020146105ee578063300a02981461060457600080fd5b80631627540c14610506578063165464621461051957806316c38b3c14610541578063199b49591461055457600080fd5b80630ae8a262116103f05780630ae8a262146104955780630fb2e042146104b557806310063fdc146104c857806313af4035146104f357600080fd5b806301fe9c881461042257806303727eb9146104375780630691dc171461045f57806306c933d814610472575b600080fd5b610435610430366004615047565b610a66565b005b61044a6104453660046156e1565b610abc565b60405190151581526020015b60405180910390f35b61043561046d366004615047565b610ad3565b61044a610480366004614f02565b600c6020526000908152604090205460ff1681565b6104a86104a3366004615047565b610b1e565b6040516104569190615a90565b6104356104c3366004615615565b610c1f565b600b546104db906001600160a01b031681565b6040516001600160a01b039091168152602001610456565b610435610501366004614f02565b610dbd565b610435610514366004614f02565b610ef1565b61052c610527366004615047565b610f47565b60405161045699989796959493929190615886565b61043561054f366004615295565b611960565b610567610562366004615047565b6119d6565b604051610456919061598e565b610587610582366004615353565b611c55565b604080516001600160a01b039097168752941515602087015292151593850193909352151560608401529015156080830152151560a082015260c001610456565b6105676105d6366004615047565b611f95565b6104356105e9366004614fc7565b6121b8565b6105f6600181565b604051908152602001610456565b6105f6600281565b6105f661061a366004615353565b612379565b61044a61062d366004615353565b60046020526000908152604090205460ff1681565b61044a61065036600461564f565b61239a565b6105f6600381565b61067061066b366004615353565b6124b3565b6040516104569190615b1c565b61069061068b36600461510b565b612535565b6040516104569594939291906159f9565b6105f660065481565b61044a6106b8366004615353565b612b5a565b6104356106cb366004615214565b612c69565b6104356106de366004615214565b612cc0565b6001546104db906001600160a01b031681565b6105f66107043660046156c0565b612d13565b60035461044a9060ff1681565b61044a61072436600461552b565b612d44565b600a546104db906001600160a01b031681565b600f546104db906001600160a01b031681565b61076261075d3660046156c0565b612d70565b6040516104569493929190615b2f565b6105f6610780366004615353565b600e6020526000908152604090205481565b6104356107a0366004614f02565b612f98565b6107b86107b3366004615047565b612fee565b60405161045694939291906159a1565b61044a6107d6366004615353565b60056020526000908152604090205460ff1681565b610435613027565b610806610801366004615047565b613124565b6040516104569190615b09565b610826610821366004615047565b6132f8565b604051610456919061597b565b61044a6108413660046154cb565b6134ca565b610435610854366004614f02565b613523565b61044a610867366004615328565b61359f565b6000546104db906201000090046001600160a01b031681565b610670610893366004615047565b6135ab565b6105f660025481565b6104356108af3660046156c0565b61373c565b61044a6108c23660046154cb565b61378c565b6104356108d53660046156c0565b61386d565b6106706108e8366004615353565b613a49565b6104356108fb366004614f02565b613ac8565b61043561090e366004615353565b613b44565b61044a6109213660046155bd565b613bca565b6105f66109343660046156c0565b613c1f565b610435610947366004615353565b613c3b565b61044a61095a3660046152cd565b613c78565b6105f6600081565b6105f6600d5481565b61067061097e36600461518e565b613c86565b6003546104db9061010090046001600160a01b031681565b6104356109a9366004614f3a565b613c91565b6104356109bc366004614f02565b613d93565b61044a6109cf366004615499565b613e8a565b6105f66109e2366004615353565b60076020526000908152604090205481565b6104a8610a02366004615263565b613ed0565b61044a610a153660046153be565b613fa9565b6105f6610a28366004615353565b614001565b610435610a3b366004614f02565b614011565b61044a610a4e3660046156e1565b614095565b610435610a61366004615615565b6141fa565b610a6e6143ee565b8051610a81906010906020840190614cdf565b507fe1ce43eeefe5feb41d71b43a7ebf155416f9e5aa2db76fe18438c0ff07b89b4781604051610ab19190615b1c565b60405180910390a150565b6000610ac9848484614468565b90505b9392505050565b610adb6143ee565b8051610aee906008906020840190614cdf565b507fede12a8d509a65e2bac4bd9f8719e741f609c9c6d35d7c356dd21fd3bb6360d781604051610ab19190615b1c565b805160609015610b865781516001600160401b03811115610b4f57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015610b8257816020015b6060815260200190600190039081610b6d5790505b5090505b60005b8251811015610c1957828181518110610bb257634e487b7160e01b600052603260045260246000fd5b6020026020010151604051602001610bcc91815260200190565b604051602081830303815290604052828281518110610bfb57634e487b7160e01b600052603260045260246000fd5b60200260200101819052508080610c1190615dd7565b915050610b89565b50919050565b6000546201000090046001600160a01b0316331480610c4d5750336000908152600c602052604090205460ff165b610cc45760405162461bcd60e51b815260206004820152603960248201527f4f6e6c79206f776e6572206f722077686974656c69737465642061646472657360448201527f73206d617920706572666f726d207468697320616374696f6e0000000000000060648201526084015b60405180910390fd5b6003546040516334d2a49760e11b8152600481018490526101009091046001600160a01b0316906369a5492e9060240160206040518083038186803b158015610d0c57600080fd5b505afa158015610d20573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d4491906152b1565b610d605760405162461bcd60e51b8152600401610cbb90615bbb565b60008281526009602090815260409091208251610d7f92840190614cdf565b507f135ace08ded18cc43c25348c6633584d72fcac208fdcfeb55d2c4337276f6b438282604051610db1929190615bf2565b60405180910390a15050565b6001600160a01b038116610e135760405162461bcd60e51b815260206004820152601960248201527f4f776e657220616464726573732063616e6e6f742062652030000000000000006044820152606401610cbb565b600154600160a01b900460ff1615610e7f5760405162461bcd60e51b815260206004820152602960248201527f416c726561647920696e697469616c697a65642c20757365206e6f6d696e617460448201526832a732bba7bbb732b960b91b6064820152608401610cbb565b6001805460ff60a01b1916600160a01b179055600080546001600160a01b03831662010000810262010000600160b01b03199092169190911782556040805192835260208301919091527fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c9101610ab1565b610ef96143ee565b600180546001600160a01b0319166001600160a01b0383169081179091556040519081527f906a1c6bd7e3091ea86693dd029a831c19049ce77f1dce2ce0bab1cacbabce2290602001610ab1565b606080606080606080606080606060008a519050806001600160401b03811115610f8157634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015610faa578160200160208202803683370190505b509950806001600160401b03811115610fd357634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015610ffc578160200160208202803683370190505b509850806001600160401b0381111561102557634e487b7160e01b600052604160045260246000fd5b60405190808252806020026020018201604052801561104e578160200160208202803683370190505b509750806001600160401b0381111561107757634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156110a0578160200160208202803683370190505b509650806001600160401b038111156110c957634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156110f2578160200160208202803683370190505b509550806001600160401b0381111561111b57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611144578160200160208202803683370190505b509450806001600160401b0381111561116d57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611196578160200160208202803683370190505b509350806001600160401b038111156111bf57634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156111e8578160200160208202803683370190505b509250806001600160401b0381111561121157634e487b7160e01b600052604160045260246000fd5b60405190808252806020026020018201604052801561123a578160200160208202803683370190505b50915060005b81811015611951576000600360019054906101000a90046001600160a01b03166001600160a01b031663f89c6f188e848151811061128e57634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b81526004016112b491815260200190565b60206040518083038186803b1580156112cc57600080fd5b505afa1580156112e0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113049190614f1e565b9050808c838151811061132757634e487b7160e01b600052603260045260246000fd5b6001600160a01b039283166020918202929092010152600354604051635b9fbe0760e01b8152838316600482015261010090910490911690635b9fbe079060240160206040518083038186803b15801561138057600080fd5b505afa158015611394573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113b891906152b1565b8b83815181106113d857634e487b7160e01b600052603260045260246000fd5b9115156020928302919091019091015260035460405163dec72d6360e01b81526001600160a01b0383811660048301526101009092049091169063dec72d639060240160206040518083038186803b15801561143357600080fd5b505afa158015611447573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061146b91906152b1565b8a838151811061148b57634e487b7160e01b600052603260045260246000fd5b91151560209283029190910190910152600a546040516336c0d85560e01b81526001600160a01b038381166004830152909116906336c0d8559060240160206040518083038186803b1580156114e057600080fd5b505afa1580156114f4573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061151891906152b1565b89838151811061153857634e487b7160e01b600052603260045260246000fd5b91151560209283029190910190910152600354604051630a928f9f60e21b81526001600160a01b03838116600483015261010090920490911690632a4a3e7c9060240160206040518083038186803b15801561159357600080fd5b505afa1580156115a7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115cb91906152b1565b8883815181106115eb57634e487b7160e01b600052603260045260246000fd5b911515602092830291909101909101526001600160a01b03811661161057600061168d565b600b546040516333dfec9960e21b81526001600160a01b0383811660048301529091169063cf7fb2649060240160206040518083038186803b15801561165557600080fd5b505afa158015611669573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061168d91906152b1565b8783815181106116ad57634e487b7160e01b600052603260045260246000fd5b602002602001019015159081151581525050600360019054906101000a90046001600160a01b03166001600160a01b03166376d423db8e848151811061170357634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b815260040161172991815260200190565b60206040518083038186803b15801561174157600080fd5b505afa158015611755573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061177991906155fd565b86838151811061179957634e487b7160e01b600052603260045260246000fd5b602002602001018181525050600360019054906101000a90046001600160a01b03166001600160a01b031663af4cbdfc8e84815181106117e957634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b815260040161180f91815260200190565b60206040518083038186803b15801561182757600080fd5b505afa15801561183b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061185f919061570c565b85838151811061187f57634e487b7160e01b600052603260045260246000fd5b64ffffffffff9290921660209283029190910190910152600a546040516305813afd60e51b81526001600160a01b0383811660048301529091169063b0275fa09060240160206040518083038186803b1580156118db57600080fd5b505afa1580156118ef573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061191391906155fd565b84838151811061193357634e487b7160e01b600052603260045260246000fd5b6020908102919091010152508061194981615dd7565b915050611240565b50509193959799909294969850565b6119686143ee565b60035460ff161515811515141561197c5750565b6003805460ff191682151590811790915560ff161561199a57426002555b60035460405160ff909116151581527f8fb6c181ee25a520cf3dd6565006ef91229fcfe5a989566c2a3b8c115570cec590602001610ab1565b50565b6060815160046119e69190615d58565b6001600160401b03811115611a0b57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611a34578160200160208202803683370190505b50905060005b8251811015610c1957600080600080600a60009054906101000a90046001600160a01b03166001600160a01b03166360b4df85888781518110611a8d57634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b8152600401611ab391815260200190565b60e06040518083038186803b158015611acb57600080fd5b505afa158015611adf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611b0391906153fe565b96509650965096505050508386866004611b1d9190615d58565b611b28906000615c5e565b81518110611b4657634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b815250508286866004611b699190615d58565b611b74906001615c5e565b81518110611b9257634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b815250508186866004611bb59190615d58565b611bc0906002615c5e565b81518110611bde57634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b815250508086866004611c019190615d58565b611c0c906003615c5e565b81518110611c2a57634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b81525050505050508080611c4d90615dd7565b915050611a3a565b600354604051631f138de360e31b81526004810183905260009182918291829182918291829161010090046001600160a01b03169063f89c6f189060240160206040518083038186803b158015611cab57600080fd5b505afa158015611cbf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611ce39190614f1e565b600354604051635b9fbe0760e01b81526001600160a01b038084166004830152929350839261010090920490911690635b9fbe079060240160206040518083038186803b158015611d3357600080fd5b505afa158015611d47573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d6b91906152b1565b60035460405163dec72d6360e01b81526001600160a01b0385811660048301526101009092049091169063dec72d639060240160206040518083038186803b158015611db657600080fd5b505afa158015611dca573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dee91906152b1565b600a546040516336c0d85560e01b81526001600160a01b038681166004830152909116906336c0d8559060240160206040518083038186803b158015611e3357600080fd5b505afa158015611e47573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e6b91906152b1565b600354604051630a928f9f60e21b81526001600160a01b03878116600483015261010090920490911690632a4a3e7c9060240160206040518083038186803b158015611eb657600080fd5b505afa158015611eca573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611eee91906152b1565b6001600160a01b038616611f03576000611f80565b600b546040516333dfec9960e21b81526001600160a01b0388811660048301529091169063cf7fb2649060240160206040518083038186803b158015611f4857600080fd5b505afa158015611f5c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611f8091906152b1565b949d939c50919a509850965090945092505050565b606081516003611fa59190615d58565b6001600160401b03811115611fca57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611ff3578160200160208202803683370190505b50905060005b8251811015610c1957600a548351600091829182916001600160a01b0316906360b4df859088908790811061203e57634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b815260040161206491815260200190565b60e06040518083038186803b15801561207c57600080fd5b505afa158015612090573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906120b491906153fe565b5050505092509250925082858560036120cd9190615d58565b6120d8906000615c5e565b815181106120f657634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b8152505081858560036121199190615d58565b612124906001615c5e565b8151811061214257634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b8152505080858560036121659190615d58565b612170906002615c5e565b8151811061218e57634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b8152505050505080806121b090615dd7565b915050611ff9565b6121c06143ee565b8161221b5760405162461bcd60e51b815260206004820152602560248201527f57686974656c6973746564206164647265737365732063616e6e6f7420626520604482015264656d70747960d81b6064820152608401610cbb565b60005b8281101561237357811515600c600086868581811061224d57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906122629190614f02565b6001600160a01b0316815260208101919091526040016000205460ff161515146123615781600c60008686858181106122ab57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906122c09190614f02565b6001600160a01b031681526020810191909152604001600020805460ff19169115159190911790557f58d7a3ccc34541e162fcfc87b84be7b78c34d1e1e7f15de6e4dd67d0fe70aecd84848381811061232957634e487b7160e01b600052603260045260246000fd5b905060200201602081019061233e9190614f02565b604080516001600160a01b03909216825284151560208301520160405180910390a15b8061236b81615dd7565b91505061221e565b50505050565b6010818154811061238957600080fd5b600091825260209091200154905081565b60006123f785856000815181106123c157634e487b7160e01b600052603260045260246000fd5b6020026020010151856000815181106123ea57634e487b7160e01b600052603260045260246000fd5b6020026020010151614095565b801561244c575061244c858560018151811061242357634e487b7160e01b600052603260045260246000fd5b6020026020010151856001815181106123ea57634e487b7160e01b600052603260045260246000fd5b80156124a8575081806124a857506124a8858560028151811061247f57634e487b7160e01b600052603260045260246000fd5b6020026020010151856002815181106123ea57634e487b7160e01b600052603260045260246000fd5b90505b949350505050565b6000818152601160205260409020546060906124d05760106124df565b60008281526011602052604090205b80548060200260200160405190810160405280929190818152602001828054801561252957602002820191906000526020600020905b815481526020019060010190808311612515575b50505050509050919050565b60608060608060608751600261254b9190615d58565b6001600160401b0381111561257057634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015612599578160200160208202803683370190505b50945087516001600160401b038111156125c357634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156125ec578160200160208202803683370190505b50935087516001600160401b0381111561261657634e487b7160e01b600052604160045260246000fd5b60405190808252806020026020018201604052801561263f578160200160208202803683370190505b50925087516001600160401b0381111561266957634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015612692578160200160208202803683370190505b50915087516001600160401b038111156126bc57634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156126e5578160200160208202803683370190505b50905060005b8851811015612b4e576000600360019054906101000a90046001600160a01b03166001600160a01b031663f89c6f188b848151811061273a57634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b815260040161276091815260200190565b60206040518083038186803b15801561277857600080fd5b505afa15801561278c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127b09190614f1e565b9050600080600080600f60009054906101000a90046001600160a01b03166001600160a01b03166305c84a548f88815181106127fc57634e487b7160e01b600052603260045260246000fd5b60200260200101518f898151811061282457634e487b7160e01b600052603260045260246000fd5b60200260200101518f8a8151811061284c57634e487b7160e01b600052603260045260246000fd5b60200260200101516040518463ffffffff1660e01b815260040161288693929190928352602083019190915260ff16604082015260600190565b60806040518083038186803b15801561289e57600080fd5b505afa1580156128b2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128d6919061556a565b9350935093509350838a87815181106128ff57634e487b7160e01b600052603260045260246000fd5b602002602001019061ffff16908161ffff16815250508089878151811061293657634e487b7160e01b600052603260045260246000fd5b91151560209283029190910190910152600f5460405163017023c560e71b81526001600160a01b0387811660048301529091169063b811e2809060240160206040518083038186803b15801561298b57600080fd5b505afa15801561299f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906129c391906152b1565b8887815181106129e357634e487b7160e01b600052603260045260246000fd5b91151560209283029190910190910152600f5460405163052f16ad60e31b81526001600160a01b03878116600483015290911690632978b5689060240160206040518083038186803b158015612a3857600080fd5b505afa158015612a4c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612a7091906152b1565b878781518110612a9057634e487b7160e01b600052603260045260246000fd5b91151560209283029190910190910152828b612aad886002615d58565b612ab8906000615c5e565b81518110612ad657634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b81525050818b876002612af99190615d58565b612b04906001615c5e565b81518110612b2257634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b8152505050505050508080612b4690615dd7565b9150506126eb565b50939792965093509350565b600a54600354604051631f138de360e31b8152600481018490526000926001600160a01b03908116926336c0d855926101009091049091169063f89c6f189060240160206040518083038186803b158015612bb457600080fd5b505afa158015612bc8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612bec9190614f1e565b6040516001600160e01b031960e084901b1681526001600160a01b03909116600482015260240160206040518083038186803b158015612c2b57600080fd5b505afa158015612c3f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c6391906152b1565b92915050565b612c716143ee565b6000825111612cb25760405162461bcd60e51b815260206004820152600d60248201526c125b9d985b1a59081a5b9c1d5d609a1b6044820152606401610cbb565b612cbc82826144af565b5050565b612cc86143ee565b6000825111612d095760405162461bcd60e51b815260206004820152600d60248201526c125b9d985b1a59081a5b9c1d5d609a1b6044820152606401610cbb565b612cbc828261463d565b60116020528160005260406000208181548110612d2f57600080fd5b90600052602060002001600091509150505481565b6000808461ffff16118015612d5d57508260020b600014155b8015610ac957505060020b151592915050565b60035460405163feee9ca360e01b81526004810183905260248101849052600091829160609183916101009091046001600160a01b03169063feee9ca39060440160206040518083038186803b158015612dc957600080fd5b505afa158015612ddd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e0191906152b1565b60035460405163be27f89d60e01b8152600481018990526101009091046001600160a01b03169063be27f89d9060240160206040518083038186803b158015612e4957600080fd5b505afa158015612e5d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e8191906152b1565b60035460405163a50267a560e01b8152600481018a9052602481018990526101009091046001600160a01b03169063a50267a59060440160006040518083038186803b158015612ed057600080fd5b505afa158015612ee4573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052612f0c9190810190615079565b600f546040516314cb6a7160e01b8152600481018b90526001600160a01b03909116906314cb6a719060240160206040518083038186803b158015612f5057600080fd5b505afa158015612f64573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612f8891906152b1565b9299919850965090945092505050565b612fa06143ee565b600a80546001600160a01b0319166001600160a01b0383169081179091556040519081527f9aba0b0687cee6f6112358c0b3ce99e8237c38737e09cf1a71f3142f0d5910ba90602001610ab1565b606080606080612ffd85611f95565b613006866132f8565b61300f87613124565b613018886119d6565b93509350935093509193509193565b6001546001600160a01b0316331461309f5760405162461bcd60e51b815260206004820152603560248201527f596f75206d757374206265206e6f6d696e61746564206265666f726520796f7560448201527402063616e20616363657074206f776e65727368697605c1b6064820152608401610cbb565b60005460015460408051620100009093046001600160a01b03908116845290911660208301527fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c910160405180910390a1600180546000805462010000600160b01b0319166001600160a01b03831662010000021790556001600160a01b0319169055565b6060815160026131349190615d58565b6001600160401b0381111561315957634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015613182578160200160208202803683370190505b50905060005b8251811015610c1957600a54835160009182916001600160a01b03909116906332b566a9908790869081106131cd57634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b81526004016131f391815260200190565b60806040518083038186803b15801561320b57600080fd5b505afa15801561321f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613243919061536b565b93509350505081848460026132589190615d58565b613263906000615c5e565b8151811061328157634e487b7160e01b600052603260045260246000fd5b62ffffff9092166020928302919091019091015280846132a2856002615d58565b6132ad906001615c5e565b815181106132cb57634e487b7160e01b600052603260045260246000fd5b602002602001019062ffffff16908162ffffff1681525050505080806132f090615dd7565b915050613188565b6060815160026133089190615d58565b6001600160401b0381111561332d57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015613356578160200160208202803683370190505b50905060005b8251811015610c1957600a54835160009182916001600160a01b03909116906332b566a9908790869081106133a157634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b81526004016133c791815260200190565b60806040518083038186803b1580156133df57600080fd5b505afa1580156133f3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613417919061536b565b505091509150818484600261342c9190615d58565b613437906000615c5e565b8151811061345557634e487b7160e01b600052603260045260246000fd5b602002602001019060010b908160010b8152505080848460026134789190615d58565b613483906001615c5e565b815181106134a157634e487b7160e01b600052603260045260246000fd5b602002602001019060010b908160010b81525050505080806134c290615dd7565b91505061335c565b6000816040516020016134dd919061586a565b6040516020818303038152906040528051906020012083604051602001613504919061586a565b6040516020818303038152906040528051906020012014905092915050565b61352b6143ee565b6001600160a01b0381166135515760405162461bcd60e51b8152600401610cbb90615b92565b600b80546001600160a01b0319166001600160a01b0383169081179091556040519081527f81b77cb294d5a20ca475a4a84c7f2c08edd0d34162b8a72bd44d103e5fbfa2f090602001610ab1565b6000610acc83836147c6565b606081516001600160401b038111156135d457634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156135fd578160200160208202803683370190505b50905060005b8251811015610c195760006009600085848151811061363257634e487b7160e01b600052603260045260246000fd5b6020026020010151815260200190815260200160002080548060200260200160405190810160405280929190818152602001828054801561369257602002820191906000526020600020905b81548152602001906001019080831161367e575b5050505050905060008151116136d45760086000815481106136c457634e487b7160e01b600052603260045260246000fd5b90600052602060002001546136fe565b806000815181106136f557634e487b7160e01b600052603260045260246000fd5b60200260200101515b83838151811061371e57634e487b7160e01b600052603260045260246000fd5b6020908102919091010152508061373481615dd7565b915050613603565b6137446143ee565b6000828152600e602090815260409182902083905581518481529081018390527f912707207097e53d30ad2fe2ca3aa44e255c823982d25e13ef638e284a48b6019101610db1565b60008160405160200161379f919061586a565b60405160208183030381529060405280519060200120836040516020016137c6919061586a565b604051602081830303815290604052805190602001201480613822575060046000846040516020016137f8919061586a565b60408051601f198184030181529181528151602092830120835290820192909252016000205460ff165b80610acc5750600460008360405160200161383d919061586a565b60408051808303601f190181529181528151602092830120835290820192909252016000205460ff169392505050565b6138756143ee565b8060065414156138c75760405162461bcd60e51b815260206004820152601b60248201527f53616d652076616c75652061732064656661756c742076616c756500000000006044820152606401610cbb565b600081116139105760405162461bcd60e51b81526020600482015260166024820152754d757374206265206d6f7265207468656e205a45524f60501b6044820152606401610cbb565b6003546040516334d2a49760e11b8152600481018490526101009091046001600160a01b0316906369a5492e9060240160206040518083038186803b15801561395857600080fd5b505afa15801561396c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061399091906152b1565b6139ac5760405162461bcd60e51b8152600401610cbb90615bbb565b600082815260076020526040902054811415613a015760405162461bcd60e51b815260206004820152601460248201527353616d652076616c7565206173206265666f726560601b6044820152606401610cbb565b60008281526007602090815260409182902083905581518481529081018390527f69fd20fd8a4b59cc555abc063627a7fcecd991b0cf18c48122248455bf29699f9101610db1565b600081815260096020526040902054606090613a665760086124df565b600082815260096020526040902080548060200260200160405190810160405280929190818152602001828054801561252957602002820191906000526020600020908154815260200190600101908083116125155750505050509050919050565b613ad06143ee565b6001600160a01b038116613af65760405162461bcd60e51b8152600401610cbb90615b92565b600f80546001600160a01b0319166001600160a01b0383169081179091556040519081527f59cf4cddc1a33ae5f2e8785ba9dcc3c6e66807281882aa0afc75d385a1158cac90602001610ab1565b613b4c6143ee565b60008111613b955760405162461bcd60e51b81526020600482015260166024820152754d757374206265206d6f7265207468656e205a45524f60501b6044820152606401610cbb565b60068190556040518181527f69d8ae57c22ebc10935a3fccebcf33c37abcf90af05eeafdf9d47b066c7a7b1f90602001610ab1565b60008262ffffff168562ffffff16148015613bea575060008562ffffff16115b8015613bfb575060008362ffffff16115b8015613c0b57508360020b600014155b80156124a857505060020b15159392505050565b60096020528160005260406000208181548110612d2f57600080fd5b613c436143ee565b600d8190556040518181527f19eaf2f356d99bcfaf883654316c3c12a7771e09c4058e60691681a6c61b571f90602001610ab1565b60006124a885858585614814565b6060612c6382614867565b600054610100900460ff16613cac5760005460ff1615613cb0565b303b155b613d135760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610cbb565b600054610100900460ff16158015613d35576000805461ffff19166101011790555b613d3e86610dbd565b60038054610100600160a81b0319166101006001600160a01b03881602179055613d6984600161463d565b613d748360016144af565b60068290558015613d8b576000805461ff00191690555b505050505050565b613d9b6143ee565b6001600160a01b038116613dc15760405162461bcd60e51b8152600401610cbb90615b92565b600154600160a81b900460ff1615613e115760405162461bcd60e51b8152602060048201526013602482015272105b1c9958591e481d1c985b9cd9995c9c9959606a1b6044820152606401610cbb565b600080546001600160a01b038381166201000081810262010000600160b01b031990941693909317938490556001805460ff60a81b1916600160a81b1790556040805193909404909116825260208201527fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c9101610ab1565b60006005600083604051602001613ea1919061586a565b60408051601f198184030181529181528151602092830120835290820192909252016000205460ff1692915050565b606081516001600160401b03811115613ef957634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015613f2c57816020015b6060815260200190600190039081613f175790505b50905060005b8251811015610c1957613f6b838281518110613f5e57634e487b7160e01b600052603260045260246000fd5b6020026020010151614bb6565b828281518110613f8b57634e487b7160e01b600052603260045260246000fd5b60200260200101819052508080613fa190615dd7565b915050613f32565b6000613fb783600019615cd1565b60010b8560010b148015613fcf57508460010b600014155b8015613bfb57508260010b600014158015613c0b57508360020b6000141580156124a857505060020b15159392505050565b6008818154811061238957600080fd5b6140196143ee565b6001600160a01b03811661403f5760405162461bcd60e51b8152600401610cbb90615b92565b60038054610100600160a81b0319166101006001600160a01b038416908102919091179091556040519081527f5f56489645cc15092ffab877840903cb7715aca3464f50d3e323ed6465777bbb90602001610ab1565b6000838152600760205260408120548190156140bf576000858152600760205260409020546140c3565b6006545b6000868152600e602052604081205491925090156140ef576000868152600e60205260409020546140f3565b600d545b90506000811180156141145750614111662386f26fc1000082615d58565b85105b801561412f575061412c662386f26fc1000082615d58565b84105b1561413f57600192505050610acc565b84158061414b57508385145b1561415b57600192505050610acc565b848411156141ae57614174662386f26fc1000083615d58565b61418690670de0b6b3a7640000615c5e565b8561419986670de0b6b3a7640000615d58565b6141a39190615c9b565b111592505050610acc565b6141bf662386f26fc1000083615d58565b856141d2670de0b6b3a764000087615d58565b6141dc9190615c9b565b6141ee90670de0b6b3a7640000615d77565b11159695505050505050565b6000546201000090046001600160a01b03163314806142285750336000908152600c602052604090205460ff165b61427e5760405162461bcd60e51b815260206004820152602160248201527f4f6e6c79206f776e6572206f722077686974656c6973746564206164647265736044820152607360f81b6064820152608401610cbb565b6003546040516334d2a49760e11b8152600481018490526101009091046001600160a01b0316906369a5492e9060240160206040518083038186803b1580156142c657600080fd5b505afa1580156142da573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906142fe91906152b1565b80156143815750600f546040516314cb6a7160e01b8152600481018490526001600160a01b03909116906314cb6a719060240160206040518083038186803b15801561434957600080fd5b505afa15801561435d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061438191906152b1565b61439d5760405162461bcd60e51b8152600401610cbb90615bbb565b600082815260116020908152604090912082516143bc92840190614cdf565b507f9c657e838c705c59a50bbb5bccc540f9f11c35d7c3b97ba8bb46d7b39b682ca88282604051610db1929190615bf2565b6000546201000090046001600160a01b031633146144665760405162461bcd60e51b815260206004820152602f60248201527f4f6e6c792074686520636f6e7472616374206f776e6572206d6179207065726660448201526e37b936903a3434b99030b1ba34b7b760891b6064820152608401610cbb565b565b600083614482578115801561447b575082155b9050610acc565b60018414156144945750808211610acc565b60028414156144a65750808210610acc565b50818114610acc565b60005b825181101561463857811515600560008584815181106144e257634e487b7160e01b600052603260045260246000fd5b60200260200101516040516020016144fa919061586a565b60408051601f198184030181529181528151602092830120835290820192909252016000205460ff1615151461462657816005600085848151811061454f57634e487b7160e01b600052603260045260246000fd5b6020026020010151604051602001614567919061586a565b60405160208183030381529060405280519060200120815260200190815260200160002060006101000a81548160ff0219169083151502179055507fa8ffdf44a3dd40e8518ed36f55dbddd07d532e8d4e62cfc9af80dabb7a93c6148382815181106145e357634e487b7160e01b600052603260045260246000fd5b60200260200101516040516020016145fb919061586a565b60408051601f1981840301815282825280516020918201208352851515908301520160405180910390a15b8061463081615dd7565b9150506144b2565b505050565b60005b8251811015614638578115156004600085848151811061467057634e487b7160e01b600052603260045260246000fd5b6020026020010151604051602001614688919061586a565b60408051601f198184030181529181528151602092830120835290820192909252016000205460ff161515146147b45781600460008584815181106146dd57634e487b7160e01b600052603260045260246000fd5b60200260200101516040516020016146f5919061586a565b60405160208183030381529060405280519060200120815260200190815260200160002060006101000a81548160ff0219169083151502179055507ffe28881086408823936cdab8f3b6bb8baf3b5cfe62e5c5c136ba3fefbb5d09c283828151811061477157634e487b7160e01b600052603260045260246000fd5b6020026020010151604051602001614789919061586a565b60408051601f1981840301815282825280516020918201208352851515908301520160405180910390a15b806147be81615dd7565b915050614640565b600082156147ed5760018214806147dd5750600282145b806147e6575081155b9050612c63565b60018214806147fc5750600282145b806148075750600382145b80610acc57505015919050565b6000841561483b578260020b60001415801561483457508360020b600014155b90506124ab565b8260020b60001415801561485357508360020b600014155b8015614834575050600281900b15156124ab565b6060600082516001600160401b0381111561489257634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156148bb578160200160208202803683370190505b5090506000805b8451811015614ae35760008582815181106148ed57634e487b7160e01b600052603260045260246000fd5b60200260200101516000141561493057600084838151811061491f57634e487b7160e01b600052603260045260246000fd5b602002602001018181525050614a9a565b600086838151811061495257634e487b7160e01b600052603260045260246000fd5b602002602001015113156149d75785828151811061498057634e487b7160e01b600052603260045260246000fd5b60200260200101519050806127106149989190615c5e565b6149ac9069021e19e0c9bab2400000615c9b565b6149b7906064615d58565b84838151811061491f57634e487b7160e01b600052603260045260246000fd5b60008683815181106149f957634e487b7160e01b600052603260045260246000fd5b60200260200101511215614a9a57858281518110614a2757634e487b7160e01b600052603260045260246000fd5b6020026020010151614a3890615e34565b9050614a4681612710615c5e565b614a5882670de0b6b3a7640000615d58565b614a629190615c9b565b614a6d906064615d58565b848381518110614a8d57634e487b7160e01b600052603260045260246000fd5b6020026020010181815250505b838281518110614aba57634e487b7160e01b600052603260045260246000fd5b602002602001015183614acd9190615c5e565b9250508080614adb90615dd7565b9150506148c2565b5060005b8251811015614bad5781614b28576000838281518110614b1757634e487b7160e01b600052603260045260246000fd5b602002602001018181525050614b9b565b81838281518110614b4957634e487b7160e01b600052603260045260246000fd5b6020026020010151670de0b6b3a7640000614b649190615d58565b614b6e9190615c9b565b838281518110614b8e57634e487b7160e01b600052603260045260246000fd5b6020026020010181815250505b80614ba581615dd7565b915050614ae7565b50909392505050565b606060ff8216614bdd5750506040805180820190915260018152600360fc1b602082015290565b8160005b60ff821615614c0a5780614bf481615df2565b9150614c039050600a83615caf565b9150614be1565b60008160ff166001600160401b03811115614c3557634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015614c5f576020820181803683370190505b5090505b60ff8516156124ab5781614c7681615dba565b9250614c859050600a86615e12565b614c90906030615c76565b60f81b818360ff1681518110614cb657634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a905350614cd8600a86615caf565b9450614c63565b828054828255906000526020600020908101928215614d1a579160200282015b82811115614d1a578251825591602001919060010190614cff565b50614d26929150614d2a565b5090565b5b80821115614d265760008155600101614d2b565b600082601f830112614d4f578081fd5b81356020614d64614d5f83615c3b565b615c0b565b80838252828201915082860187848660051b8901011115614d83578586fd5b855b85811015614da157813584529284019290840190600101614d85565b5090979650505050505050565b600082601f830112614dbe578081fd5b81356020614dce614d5f83615c3b565b80838252828201915082860187848660051b8901011115614ded578586fd5b855b85811015614da15781356001600160401b03811115614e0c578788fd5b614e1a8a87838c0101614e98565b8552509284019290840190600101614def565b600082601f830112614e3d578081fd5b81356020614e4d614d5f83615c3b565b80838252828201915082860187848660051b8901011115614e6c578586fd5b855b85811015614da157813560ff81168114614e86578788fd5b84529284019290840190600101614e6e565b600082601f830112614ea8578081fd5b81356001600160401b03811115614ec157614ec1615e7a565b614ed4601f8201601f1916602001615c0b565b818152846020838601011115614ee8578283fd5b816020850160208301379081016020019190915292915050565b600060208284031215614f13578081fd5b8135610acc81615e90565b600060208284031215614f2f578081fd5b8151610acc81615e90565b600080600080600060a08688031215614f51578081fd5b8535614f5c81615e90565b94506020860135614f6c81615e90565b935060408601356001600160401b0380821115614f87578283fd5b614f9389838a01614dae565b94506060880135915080821115614fa8578283fd5b50614fb588828901614dae565b95989497509295608001359392505050565b600080600060408486031215614fdb578081fd5b83356001600160401b0380821115614ff1578283fd5b818601915086601f830112615004578283fd5b813581811115615012578384fd5b8760208260051b8501011115615026578384fd5b6020928301955093505084013561503c81615ea5565b809150509250925092565b600060208284031215615058578081fd5b81356001600160401b0381111561506d578182fd5b6124ab84828501614d3f565b6000602080838503121561508b578182fd5b82516001600160401b038111156150a0578283fd5b8301601f810185136150b0578283fd5b80516150be614d5f82615c3b565b80828252848201915084840188868560051b87010111156150dd578687fd5b8694505b838510156150ff5780518352600194909401939185019185016150e1565b50979650505050505050565b60008060006060848603121561511f578081fd5b83356001600160401b0380821115615135578283fd5b61514187838801614d3f565b94506020860135915080821115615156578283fd5b61516287838801614d3f565b93506040860135915080821115615177578283fd5b5061518486828701614e2d565b9150509250925092565b600060208083850312156151a0578182fd5b82356001600160401b038111156151b5578283fd5b8301601f810185136151c5578283fd5b80356151d3614d5f82615c3b565b80828252848201915084840188868560051b87010111156151f2578687fd5b8694505b838510156150ff5780358352600194909401939185019185016151f6565b60008060408385031215615226578182fd5b82356001600160401b0381111561523b578283fd5b61524785828601614dae565b925050602083013561525881615ea5565b809150509250929050565b600060208284031215615274578081fd5b81356001600160401b03811115615289578182fd5b6124ab84828501614e2d565b6000602082840312156152a6578081fd5b8135610acc81615ea5565b6000602082840312156152c2578081fd5b8151610acc81615ea5565b600080600080608085870312156152e2578182fd5b84356152ed81615ea5565b935060208501356152fd81615ec2565b9250604085013561530d81615ec2565b9150606085013561531d81615ec2565b939692955090935050565b6000806040838503121561533a578182fd5b823561534581615ea5565b946020939093013593505050565b600060208284031215615364578081fd5b5035919050565b60008060008060808587031215615380578182fd5b845161538b81615eb3565b602086015190945061539c81615eb3565b60408601519093506153ad81615ee1565b606086015190925061531d81615ee1565b600080600080608085870312156153d3578182fd5b84356153de81615eb3565b935060208501356153ee81615ec2565b9250604085013561530d81615eb3565b600080600080600080600060e0888a031215615418578485fd5b875161542381615ec2565b602089015190975061543481615ec2565b604089015190965061544581615ec2565b606089015190955061545681615ec2565b608089015190945061546781615ec2565b60a089015190935061547881615ec2565b60c089015190925061548981615ec2565b8091505092959891949750929550565b6000602082840312156154aa578081fd5b81356001600160401b038111156154bf578182fd5b6124ab84828501614e98565b600080604083850312156154dd578182fd5b82356001600160401b03808211156154f3578384fd5b6154ff86838701614e98565b93506020850135915080821115615514578283fd5b5061552185828601614e98565b9150509250929050565b60008060006060848603121561553f578081fd5b833561554a81615ed1565b9250602084013561555a81615ec2565b9150604084013561503c81615ec2565b6000806000806080858703121561557f578182fd5b845161558a81615ed1565b602086015190945061559b81615ec2565b60408601519093506155ac81615ec2565b606086015190925061531d81615ea5565b600080600080608085870312156155d2578182fd5b84356155dd81615ee1565b935060208501356155ed81615ec2565b9250604085013561530d81615ee1565b60006020828403121561560e578081fd5b5051919050565b60008060408385031215615627578182fd5b8235915060208301356001600160401b03811115615643578182fd5b61552185828601614d3f565b60008060008060808587031215615664578182fd5b8435935060208501356001600160401b0380821115615681578384fd5b61568d88838901614d3f565b945060408701359150808211156156a2578384fd5b506156af87828801614d3f565b925050606085013561531d81615ea5565b600080604083850312156156d2578182fd5b50508035926020909101359150565b6000806000606084860312156156f5578081fd5b505081359360208301359350604090920135919050565b60006020828403121561571d578081fd5b815164ffffffffff81168114610acc578182fd5b6000815180845260208085019450808401835b83811015615762578151151587529582019590820190600101615744565b509495945050505050565b6000815180845260208085019450808401835b83811015615762578151600190810b8852968301969183019101615780565b6000815180845260208085019450808401835b8381101561576257815160020b875295820195908201906001016157b2565b6000815180845260208085019450808401835b8381101561576257815162ffffff16875295820195908201906001016157e4565b6000815180845260208085019450808401835b8381101561576257815187529582019590820190600101615818565b6000815180845260208085019450808401835b8381101561576257815164ffffffffff1687529582019590820190600101615847565b6000825161587c818460208701615d8e565b9190910192915050565b6101208082528a51908201819052600090610140830190602090818e01845b828110156158ca5781516001600160a01b0316855293830193908301906001016158a5565b505050838203908401526158de818c615731565b905082810360408401526158f2818b615731565b90508281036060840152615906818a615731565b9050828103608084015261591a8189615731565b905082810360a084015261592e8188615731565b905082810360c08401526159428187615805565b905082810360e08401526159568186615834565b905082810361010084015261596b8185615805565b9c9b505050505050505050505050565b602081526000610acc602083018461576d565b602081526000610acc602083018461579f565b6080815260006159b4608083018761579f565b82810360208401526159c6818761576d565b905082810360408401526159da81866157d1565b905082810360608401526159ee818561579f565b979650505050505050565b60a081526000615a0c60a083018861579f565b828103602084810191909152875180835288820192820190845b81811015615a4657845161ffff1683529383019391830191600101615a26565b50508481036040860152615a5a8189615731565b925050508281036060840152615a708186615731565b90508281036080840152615a848185615731565b98975050505050505050565b6000602080830181845280855180835260408601915060408160051b8701019250838701855b82811015615afc57878503603f1901845281518051808752615add818989018a8501615d8e565b601f01601f191695909501860194509285019290850190600101615ab6565b5092979650505050505050565b602081526000610acc60208301846157d1565b602081526000610acc6020830184615805565b60006080820186151583526020861515818501526080604085015281865180845260a0860191508288019350845b81811015615b7957845183529383019391830191600101615b5d565b5050809350505050821515606083015295945050505050565b6020808252600f908201526e496e76616c6964206164647265737360881b604082015260600190565b60208082526018908201527f53706f72744964206973206e6f7420737570706f727465640000000000000000604082015260600190565b828152604060208201526000610ac96040830184615805565b604051601f8201601f191681016001600160401b0381118282101715615c3357615c33615e7a565b604052919050565b60006001600160401b03821115615c5457615c54615e7a565b5060051b60200190565b60008219821115615c7157615c71615e4e565b500190565b600060ff821660ff84168060ff03821115615c9357615c93615e4e565b019392505050565b600082615caa57615caa615e64565b500490565b600060ff831680615cc257615cc2615e64565b8060ff84160491505092915050565b60008160010b8360010b617fff83821384841383830485118282161615615cfa57615cfa615e4e565b617fff1986851282811687830587121615615d1757615d17615e4e565b878712925085820587128484161615615d3257615d32615e4e565b85850587128184161615615d4857615d48615e4e565b5050509290910295945050505050565b6000816000190483118215151615615d7257615d72615e4e565b500290565b600082821015615d8957615d89615e4e565b500390565b60005b83811015615da9578181015183820152602001615d91565b838111156123735750506000910152565b600060ff821680615dcd57615dcd615e4e565b6000190192915050565b6000600019821415615deb57615deb615e4e565b5060010190565b600060ff821660ff811415615e0957615e09615e4e565b60010192915050565b600060ff831680615e2557615e25615e64565b8060ff84160691505092915050565b6000600160ff1b821415615e4a57615e4a615e4e565b0390565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b03811681146119d357600080fd5b80151581146119d357600080fd5b8060010b81146119d357600080fd5b8060020b81146119d357600080fd5b61ffff811681146119d357600080fd5b62ffffff811681146119d357600080fdfea264697066735822122077bc9c90196c678f72e17dbf095b9305118c9bbdcd56b09baeec790a536c31a564736f6c63430008040033

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061041d5760003560e01c8063730d62501161022b5780639c74a76e11610130578063c3b83f5f116100b8578063df2ba25011610087578063df2ba25014610a07578063df5a00ae14610a1a578063efe2c8a414610a2d578063f595901b14610a40578063f7a679b914610a5357600080fd5b8063c3b83f5f146109ae578063c8bbcd96146109c1578063d06c1467146109d4578063da5b82d2146109f457600080fd5b8063ae71dcdf116100ff578063ae71dcdf1461095f578063af765c9714610967578063b216d97414610970578063b4fd729614610983578063c128f77b1461099b57600080fd5b80639c74a76e14610913578063a1380dcf14610926578063aaae1cb514610939578063abc7b9881461094c57600080fd5b80638da5cb5b116101b357806397dc205d1161018257806397dc205d146108b457806398350f9a146108c757806399d9f2b9146108da5780639a066f5d146108ed5780639ab21a771461090057600080fd5b80638da5cb5b1461086c5780638e5b53341461088557806391b4ded9146108985780639265a4e6146108a157600080fd5b80637f56efb1116101fa5780637f56efb1146107f35780637f70290b146108135780637fabe16b1461083357806380be635514610846578063879c0c5e1461085957600080fd5b8063730d625014610792578063760ec8df146107a557806377874ce2146107c857806379ba5097146107eb57600080fd5b806338d30ea711610331578063519822f6116102b95780635d0fde6c116102885780635d0fde6c146107165780635d7412fd146107295780635d7fb8e21461073c57806365c235921461074f57806369b4840e1461077257600080fd5b8063519822f6146106d057806353a47bb7146106e35780635c2b764a146106f65780635c975abb1461070957600080fd5b806346e38c281161030057806346e38c281461065d57806348cd0f671461067d5780634b15c920146106a1578063500b218c146106aa578063503005ba146106bd57600080fd5b806338d30ea71461060c5780633d011ac91461061f57806342fa646a14610642578063459c0bd01461065557600080fd5b80631627540c116103b457806321f5908e1161038357806321f5908e146105745780632c95f596146105c85780632f893de7146105db5780632fff7020146105ee578063300a02981461060457600080fd5b80631627540c14610506578063165464621461051957806316c38b3c14610541578063199b49591461055457600080fd5b80630ae8a262116103f05780630ae8a262146104955780630fb2e042146104b557806310063fdc146104c857806313af4035146104f357600080fd5b806301fe9c881461042257806303727eb9146104375780630691dc171461045f57806306c933d814610472575b600080fd5b610435610430366004615047565b610a66565b005b61044a6104453660046156e1565b610abc565b60405190151581526020015b60405180910390f35b61043561046d366004615047565b610ad3565b61044a610480366004614f02565b600c6020526000908152604090205460ff1681565b6104a86104a3366004615047565b610b1e565b6040516104569190615a90565b6104356104c3366004615615565b610c1f565b600b546104db906001600160a01b031681565b6040516001600160a01b039091168152602001610456565b610435610501366004614f02565b610dbd565b610435610514366004614f02565b610ef1565b61052c610527366004615047565b610f47565b60405161045699989796959493929190615886565b61043561054f366004615295565b611960565b610567610562366004615047565b6119d6565b604051610456919061598e565b610587610582366004615353565b611c55565b604080516001600160a01b039097168752941515602087015292151593850193909352151560608401529015156080830152151560a082015260c001610456565b6105676105d6366004615047565b611f95565b6104356105e9366004614fc7565b6121b8565b6105f6600181565b604051908152602001610456565b6105f6600281565b6105f661061a366004615353565b612379565b61044a61062d366004615353565b60046020526000908152604090205460ff1681565b61044a61065036600461564f565b61239a565b6105f6600381565b61067061066b366004615353565b6124b3565b6040516104569190615b1c565b61069061068b36600461510b565b612535565b6040516104569594939291906159f9565b6105f660065481565b61044a6106b8366004615353565b612b5a565b6104356106cb366004615214565b612c69565b6104356106de366004615214565b612cc0565b6001546104db906001600160a01b031681565b6105f66107043660046156c0565b612d13565b60035461044a9060ff1681565b61044a61072436600461552b565b612d44565b600a546104db906001600160a01b031681565b600f546104db906001600160a01b031681565b61076261075d3660046156c0565b612d70565b6040516104569493929190615b2f565b6105f6610780366004615353565b600e6020526000908152604090205481565b6104356107a0366004614f02565b612f98565b6107b86107b3366004615047565b612fee565b60405161045694939291906159a1565b61044a6107d6366004615353565b60056020526000908152604090205460ff1681565b610435613027565b610806610801366004615047565b613124565b6040516104569190615b09565b610826610821366004615047565b6132f8565b604051610456919061597b565b61044a6108413660046154cb565b6134ca565b610435610854366004614f02565b613523565b61044a610867366004615328565b61359f565b6000546104db906201000090046001600160a01b031681565b610670610893366004615047565b6135ab565b6105f660025481565b6104356108af3660046156c0565b61373c565b61044a6108c23660046154cb565b61378c565b6104356108d53660046156c0565b61386d565b6106706108e8366004615353565b613a49565b6104356108fb366004614f02565b613ac8565b61043561090e366004615353565b613b44565b61044a6109213660046155bd565b613bca565b6105f66109343660046156c0565b613c1f565b610435610947366004615353565b613c3b565b61044a61095a3660046152cd565b613c78565b6105f6600081565b6105f6600d5481565b61067061097e36600461518e565b613c86565b6003546104db9061010090046001600160a01b031681565b6104356109a9366004614f3a565b613c91565b6104356109bc366004614f02565b613d93565b61044a6109cf366004615499565b613e8a565b6105f66109e2366004615353565b60076020526000908152604090205481565b6104a8610a02366004615263565b613ed0565b61044a610a153660046153be565b613fa9565b6105f6610a28366004615353565b614001565b610435610a3b366004614f02565b614011565b61044a610a4e3660046156e1565b614095565b610435610a61366004615615565b6141fa565b610a6e6143ee565b8051610a81906010906020840190614cdf565b507fe1ce43eeefe5feb41d71b43a7ebf155416f9e5aa2db76fe18438c0ff07b89b4781604051610ab19190615b1c565b60405180910390a150565b6000610ac9848484614468565b90505b9392505050565b610adb6143ee565b8051610aee906008906020840190614cdf565b507fede12a8d509a65e2bac4bd9f8719e741f609c9c6d35d7c356dd21fd3bb6360d781604051610ab19190615b1c565b805160609015610b865781516001600160401b03811115610b4f57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015610b8257816020015b6060815260200190600190039081610b6d5790505b5090505b60005b8251811015610c1957828181518110610bb257634e487b7160e01b600052603260045260246000fd5b6020026020010151604051602001610bcc91815260200190565b604051602081830303815290604052828281518110610bfb57634e487b7160e01b600052603260045260246000fd5b60200260200101819052508080610c1190615dd7565b915050610b89565b50919050565b6000546201000090046001600160a01b0316331480610c4d5750336000908152600c602052604090205460ff165b610cc45760405162461bcd60e51b815260206004820152603960248201527f4f6e6c79206f776e6572206f722077686974656c69737465642061646472657360448201527f73206d617920706572666f726d207468697320616374696f6e0000000000000060648201526084015b60405180910390fd5b6003546040516334d2a49760e11b8152600481018490526101009091046001600160a01b0316906369a5492e9060240160206040518083038186803b158015610d0c57600080fd5b505afa158015610d20573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d4491906152b1565b610d605760405162461bcd60e51b8152600401610cbb90615bbb565b60008281526009602090815260409091208251610d7f92840190614cdf565b507f135ace08ded18cc43c25348c6633584d72fcac208fdcfeb55d2c4337276f6b438282604051610db1929190615bf2565b60405180910390a15050565b6001600160a01b038116610e135760405162461bcd60e51b815260206004820152601960248201527f4f776e657220616464726573732063616e6e6f742062652030000000000000006044820152606401610cbb565b600154600160a01b900460ff1615610e7f5760405162461bcd60e51b815260206004820152602960248201527f416c726561647920696e697469616c697a65642c20757365206e6f6d696e617460448201526832a732bba7bbb732b960b91b6064820152608401610cbb565b6001805460ff60a01b1916600160a01b179055600080546001600160a01b03831662010000810262010000600160b01b03199092169190911782556040805192835260208301919091527fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c9101610ab1565b610ef96143ee565b600180546001600160a01b0319166001600160a01b0383169081179091556040519081527f906a1c6bd7e3091ea86693dd029a831c19049ce77f1dce2ce0bab1cacbabce2290602001610ab1565b606080606080606080606080606060008a519050806001600160401b03811115610f8157634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015610faa578160200160208202803683370190505b509950806001600160401b03811115610fd357634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015610ffc578160200160208202803683370190505b509850806001600160401b0381111561102557634e487b7160e01b600052604160045260246000fd5b60405190808252806020026020018201604052801561104e578160200160208202803683370190505b509750806001600160401b0381111561107757634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156110a0578160200160208202803683370190505b509650806001600160401b038111156110c957634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156110f2578160200160208202803683370190505b509550806001600160401b0381111561111b57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611144578160200160208202803683370190505b509450806001600160401b0381111561116d57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611196578160200160208202803683370190505b509350806001600160401b038111156111bf57634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156111e8578160200160208202803683370190505b509250806001600160401b0381111561121157634e487b7160e01b600052604160045260246000fd5b60405190808252806020026020018201604052801561123a578160200160208202803683370190505b50915060005b81811015611951576000600360019054906101000a90046001600160a01b03166001600160a01b031663f89c6f188e848151811061128e57634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b81526004016112b491815260200190565b60206040518083038186803b1580156112cc57600080fd5b505afa1580156112e0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113049190614f1e565b9050808c838151811061132757634e487b7160e01b600052603260045260246000fd5b6001600160a01b039283166020918202929092010152600354604051635b9fbe0760e01b8152838316600482015261010090910490911690635b9fbe079060240160206040518083038186803b15801561138057600080fd5b505afa158015611394573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113b891906152b1565b8b83815181106113d857634e487b7160e01b600052603260045260246000fd5b9115156020928302919091019091015260035460405163dec72d6360e01b81526001600160a01b0383811660048301526101009092049091169063dec72d639060240160206040518083038186803b15801561143357600080fd5b505afa158015611447573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061146b91906152b1565b8a838151811061148b57634e487b7160e01b600052603260045260246000fd5b91151560209283029190910190910152600a546040516336c0d85560e01b81526001600160a01b038381166004830152909116906336c0d8559060240160206040518083038186803b1580156114e057600080fd5b505afa1580156114f4573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061151891906152b1565b89838151811061153857634e487b7160e01b600052603260045260246000fd5b91151560209283029190910190910152600354604051630a928f9f60e21b81526001600160a01b03838116600483015261010090920490911690632a4a3e7c9060240160206040518083038186803b15801561159357600080fd5b505afa1580156115a7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115cb91906152b1565b8883815181106115eb57634e487b7160e01b600052603260045260246000fd5b911515602092830291909101909101526001600160a01b03811661161057600061168d565b600b546040516333dfec9960e21b81526001600160a01b0383811660048301529091169063cf7fb2649060240160206040518083038186803b15801561165557600080fd5b505afa158015611669573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061168d91906152b1565b8783815181106116ad57634e487b7160e01b600052603260045260246000fd5b602002602001019015159081151581525050600360019054906101000a90046001600160a01b03166001600160a01b03166376d423db8e848151811061170357634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b815260040161172991815260200190565b60206040518083038186803b15801561174157600080fd5b505afa158015611755573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061177991906155fd565b86838151811061179957634e487b7160e01b600052603260045260246000fd5b602002602001018181525050600360019054906101000a90046001600160a01b03166001600160a01b031663af4cbdfc8e84815181106117e957634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b815260040161180f91815260200190565b60206040518083038186803b15801561182757600080fd5b505afa15801561183b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061185f919061570c565b85838151811061187f57634e487b7160e01b600052603260045260246000fd5b64ffffffffff9290921660209283029190910190910152600a546040516305813afd60e51b81526001600160a01b0383811660048301529091169063b0275fa09060240160206040518083038186803b1580156118db57600080fd5b505afa1580156118ef573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061191391906155fd565b84838151811061193357634e487b7160e01b600052603260045260246000fd5b6020908102919091010152508061194981615dd7565b915050611240565b50509193959799909294969850565b6119686143ee565b60035460ff161515811515141561197c5750565b6003805460ff191682151590811790915560ff161561199a57426002555b60035460405160ff909116151581527f8fb6c181ee25a520cf3dd6565006ef91229fcfe5a989566c2a3b8c115570cec590602001610ab1565b50565b6060815160046119e69190615d58565b6001600160401b03811115611a0b57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611a34578160200160208202803683370190505b50905060005b8251811015610c1957600080600080600a60009054906101000a90046001600160a01b03166001600160a01b03166360b4df85888781518110611a8d57634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b8152600401611ab391815260200190565b60e06040518083038186803b158015611acb57600080fd5b505afa158015611adf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611b0391906153fe565b96509650965096505050508386866004611b1d9190615d58565b611b28906000615c5e565b81518110611b4657634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b815250508286866004611b699190615d58565b611b74906001615c5e565b81518110611b9257634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b815250508186866004611bb59190615d58565b611bc0906002615c5e565b81518110611bde57634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b815250508086866004611c019190615d58565b611c0c906003615c5e565b81518110611c2a57634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b81525050505050508080611c4d90615dd7565b915050611a3a565b600354604051631f138de360e31b81526004810183905260009182918291829182918291829161010090046001600160a01b03169063f89c6f189060240160206040518083038186803b158015611cab57600080fd5b505afa158015611cbf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611ce39190614f1e565b600354604051635b9fbe0760e01b81526001600160a01b038084166004830152929350839261010090920490911690635b9fbe079060240160206040518083038186803b158015611d3357600080fd5b505afa158015611d47573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d6b91906152b1565b60035460405163dec72d6360e01b81526001600160a01b0385811660048301526101009092049091169063dec72d639060240160206040518083038186803b158015611db657600080fd5b505afa158015611dca573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dee91906152b1565b600a546040516336c0d85560e01b81526001600160a01b038681166004830152909116906336c0d8559060240160206040518083038186803b158015611e3357600080fd5b505afa158015611e47573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e6b91906152b1565b600354604051630a928f9f60e21b81526001600160a01b03878116600483015261010090920490911690632a4a3e7c9060240160206040518083038186803b158015611eb657600080fd5b505afa158015611eca573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611eee91906152b1565b6001600160a01b038616611f03576000611f80565b600b546040516333dfec9960e21b81526001600160a01b0388811660048301529091169063cf7fb2649060240160206040518083038186803b158015611f4857600080fd5b505afa158015611f5c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611f8091906152b1565b949d939c50919a509850965090945092505050565b606081516003611fa59190615d58565b6001600160401b03811115611fca57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611ff3578160200160208202803683370190505b50905060005b8251811015610c1957600a548351600091829182916001600160a01b0316906360b4df859088908790811061203e57634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b815260040161206491815260200190565b60e06040518083038186803b15801561207c57600080fd5b505afa158015612090573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906120b491906153fe565b5050505092509250925082858560036120cd9190615d58565b6120d8906000615c5e565b815181106120f657634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b8152505081858560036121199190615d58565b612124906001615c5e565b8151811061214257634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b8152505080858560036121659190615d58565b612170906002615c5e565b8151811061218e57634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b8152505050505080806121b090615dd7565b915050611ff9565b6121c06143ee565b8161221b5760405162461bcd60e51b815260206004820152602560248201527f57686974656c6973746564206164647265737365732063616e6e6f7420626520604482015264656d70747960d81b6064820152608401610cbb565b60005b8281101561237357811515600c600086868581811061224d57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906122629190614f02565b6001600160a01b0316815260208101919091526040016000205460ff161515146123615781600c60008686858181106122ab57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906122c09190614f02565b6001600160a01b031681526020810191909152604001600020805460ff19169115159190911790557f58d7a3ccc34541e162fcfc87b84be7b78c34d1e1e7f15de6e4dd67d0fe70aecd84848381811061232957634e487b7160e01b600052603260045260246000fd5b905060200201602081019061233e9190614f02565b604080516001600160a01b03909216825284151560208301520160405180910390a15b8061236b81615dd7565b91505061221e565b50505050565b6010818154811061238957600080fd5b600091825260209091200154905081565b60006123f785856000815181106123c157634e487b7160e01b600052603260045260246000fd5b6020026020010151856000815181106123ea57634e487b7160e01b600052603260045260246000fd5b6020026020010151614095565b801561244c575061244c858560018151811061242357634e487b7160e01b600052603260045260246000fd5b6020026020010151856001815181106123ea57634e487b7160e01b600052603260045260246000fd5b80156124a8575081806124a857506124a8858560028151811061247f57634e487b7160e01b600052603260045260246000fd5b6020026020010151856002815181106123ea57634e487b7160e01b600052603260045260246000fd5b90505b949350505050565b6000818152601160205260409020546060906124d05760106124df565b60008281526011602052604090205b80548060200260200160405190810160405280929190818152602001828054801561252957602002820191906000526020600020905b815481526020019060010190808311612515575b50505050509050919050565b60608060608060608751600261254b9190615d58565b6001600160401b0381111561257057634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015612599578160200160208202803683370190505b50945087516001600160401b038111156125c357634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156125ec578160200160208202803683370190505b50935087516001600160401b0381111561261657634e487b7160e01b600052604160045260246000fd5b60405190808252806020026020018201604052801561263f578160200160208202803683370190505b50925087516001600160401b0381111561266957634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015612692578160200160208202803683370190505b50915087516001600160401b038111156126bc57634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156126e5578160200160208202803683370190505b50905060005b8851811015612b4e576000600360019054906101000a90046001600160a01b03166001600160a01b031663f89c6f188b848151811061273a57634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b815260040161276091815260200190565b60206040518083038186803b15801561277857600080fd5b505afa15801561278c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127b09190614f1e565b9050600080600080600f60009054906101000a90046001600160a01b03166001600160a01b03166305c84a548f88815181106127fc57634e487b7160e01b600052603260045260246000fd5b60200260200101518f898151811061282457634e487b7160e01b600052603260045260246000fd5b60200260200101518f8a8151811061284c57634e487b7160e01b600052603260045260246000fd5b60200260200101516040518463ffffffff1660e01b815260040161288693929190928352602083019190915260ff16604082015260600190565b60806040518083038186803b15801561289e57600080fd5b505afa1580156128b2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128d6919061556a565b9350935093509350838a87815181106128ff57634e487b7160e01b600052603260045260246000fd5b602002602001019061ffff16908161ffff16815250508089878151811061293657634e487b7160e01b600052603260045260246000fd5b91151560209283029190910190910152600f5460405163017023c560e71b81526001600160a01b0387811660048301529091169063b811e2809060240160206040518083038186803b15801561298b57600080fd5b505afa15801561299f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906129c391906152b1565b8887815181106129e357634e487b7160e01b600052603260045260246000fd5b91151560209283029190910190910152600f5460405163052f16ad60e31b81526001600160a01b03878116600483015290911690632978b5689060240160206040518083038186803b158015612a3857600080fd5b505afa158015612a4c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612a7091906152b1565b878781518110612a9057634e487b7160e01b600052603260045260246000fd5b91151560209283029190910190910152828b612aad886002615d58565b612ab8906000615c5e565b81518110612ad657634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b81525050818b876002612af99190615d58565b612b04906001615c5e565b81518110612b2257634e487b7160e01b600052603260045260246000fd5b602002602001019060020b908160020b8152505050505050508080612b4690615dd7565b9150506126eb565b50939792965093509350565b600a54600354604051631f138de360e31b8152600481018490526000926001600160a01b03908116926336c0d855926101009091049091169063f89c6f189060240160206040518083038186803b158015612bb457600080fd5b505afa158015612bc8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612bec9190614f1e565b6040516001600160e01b031960e084901b1681526001600160a01b03909116600482015260240160206040518083038186803b158015612c2b57600080fd5b505afa158015612c3f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c6391906152b1565b92915050565b612c716143ee565b6000825111612cb25760405162461bcd60e51b815260206004820152600d60248201526c125b9d985b1a59081a5b9c1d5d609a1b6044820152606401610cbb565b612cbc82826144af565b5050565b612cc86143ee565b6000825111612d095760405162461bcd60e51b815260206004820152600d60248201526c125b9d985b1a59081a5b9c1d5d609a1b6044820152606401610cbb565b612cbc828261463d565b60116020528160005260406000208181548110612d2f57600080fd5b90600052602060002001600091509150505481565b6000808461ffff16118015612d5d57508260020b600014155b8015610ac957505060020b151592915050565b60035460405163feee9ca360e01b81526004810183905260248101849052600091829160609183916101009091046001600160a01b03169063feee9ca39060440160206040518083038186803b158015612dc957600080fd5b505afa158015612ddd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e0191906152b1565b60035460405163be27f89d60e01b8152600481018990526101009091046001600160a01b03169063be27f89d9060240160206040518083038186803b158015612e4957600080fd5b505afa158015612e5d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e8191906152b1565b60035460405163a50267a560e01b8152600481018a9052602481018990526101009091046001600160a01b03169063a50267a59060440160006040518083038186803b158015612ed057600080fd5b505afa158015612ee4573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052612f0c9190810190615079565b600f546040516314cb6a7160e01b8152600481018b90526001600160a01b03909116906314cb6a719060240160206040518083038186803b158015612f5057600080fd5b505afa158015612f64573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612f8891906152b1565b9299919850965090945092505050565b612fa06143ee565b600a80546001600160a01b0319166001600160a01b0383169081179091556040519081527f9aba0b0687cee6f6112358c0b3ce99e8237c38737e09cf1a71f3142f0d5910ba90602001610ab1565b606080606080612ffd85611f95565b613006866132f8565b61300f87613124565b613018886119d6565b93509350935093509193509193565b6001546001600160a01b0316331461309f5760405162461bcd60e51b815260206004820152603560248201527f596f75206d757374206265206e6f6d696e61746564206265666f726520796f7560448201527402063616e20616363657074206f776e65727368697605c1b6064820152608401610cbb565b60005460015460408051620100009093046001600160a01b03908116845290911660208301527fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c910160405180910390a1600180546000805462010000600160b01b0319166001600160a01b03831662010000021790556001600160a01b0319169055565b6060815160026131349190615d58565b6001600160401b0381111561315957634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015613182578160200160208202803683370190505b50905060005b8251811015610c1957600a54835160009182916001600160a01b03909116906332b566a9908790869081106131cd57634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b81526004016131f391815260200190565b60806040518083038186803b15801561320b57600080fd5b505afa15801561321f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613243919061536b565b93509350505081848460026132589190615d58565b613263906000615c5e565b8151811061328157634e487b7160e01b600052603260045260246000fd5b62ffffff9092166020928302919091019091015280846132a2856002615d58565b6132ad906001615c5e565b815181106132cb57634e487b7160e01b600052603260045260246000fd5b602002602001019062ffffff16908162ffffff1681525050505080806132f090615dd7565b915050613188565b6060815160026133089190615d58565b6001600160401b0381111561332d57634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015613356578160200160208202803683370190505b50905060005b8251811015610c1957600a54835160009182916001600160a01b03909116906332b566a9908790869081106133a157634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b81526004016133c791815260200190565b60806040518083038186803b1580156133df57600080fd5b505afa1580156133f3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613417919061536b565b505091509150818484600261342c9190615d58565b613437906000615c5e565b8151811061345557634e487b7160e01b600052603260045260246000fd5b602002602001019060010b908160010b8152505080848460026134789190615d58565b613483906001615c5e565b815181106134a157634e487b7160e01b600052603260045260246000fd5b602002602001019060010b908160010b81525050505080806134c290615dd7565b91505061335c565b6000816040516020016134dd919061586a565b6040516020818303038152906040528051906020012083604051602001613504919061586a565b6040516020818303038152906040528051906020012014905092915050565b61352b6143ee565b6001600160a01b0381166135515760405162461bcd60e51b8152600401610cbb90615b92565b600b80546001600160a01b0319166001600160a01b0383169081179091556040519081527f81b77cb294d5a20ca475a4a84c7f2c08edd0d34162b8a72bd44d103e5fbfa2f090602001610ab1565b6000610acc83836147c6565b606081516001600160401b038111156135d457634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156135fd578160200160208202803683370190505b50905060005b8251811015610c195760006009600085848151811061363257634e487b7160e01b600052603260045260246000fd5b6020026020010151815260200190815260200160002080548060200260200160405190810160405280929190818152602001828054801561369257602002820191906000526020600020905b81548152602001906001019080831161367e575b5050505050905060008151116136d45760086000815481106136c457634e487b7160e01b600052603260045260246000fd5b90600052602060002001546136fe565b806000815181106136f557634e487b7160e01b600052603260045260246000fd5b60200260200101515b83838151811061371e57634e487b7160e01b600052603260045260246000fd5b6020908102919091010152508061373481615dd7565b915050613603565b6137446143ee565b6000828152600e602090815260409182902083905581518481529081018390527f912707207097e53d30ad2fe2ca3aa44e255c823982d25e13ef638e284a48b6019101610db1565b60008160405160200161379f919061586a565b60405160208183030381529060405280519060200120836040516020016137c6919061586a565b604051602081830303815290604052805190602001201480613822575060046000846040516020016137f8919061586a565b60408051601f198184030181529181528151602092830120835290820192909252016000205460ff165b80610acc5750600460008360405160200161383d919061586a565b60408051808303601f190181529181528151602092830120835290820192909252016000205460ff169392505050565b6138756143ee565b8060065414156138c75760405162461bcd60e51b815260206004820152601b60248201527f53616d652076616c75652061732064656661756c742076616c756500000000006044820152606401610cbb565b600081116139105760405162461bcd60e51b81526020600482015260166024820152754d757374206265206d6f7265207468656e205a45524f60501b6044820152606401610cbb565b6003546040516334d2a49760e11b8152600481018490526101009091046001600160a01b0316906369a5492e9060240160206040518083038186803b15801561395857600080fd5b505afa15801561396c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061399091906152b1565b6139ac5760405162461bcd60e51b8152600401610cbb90615bbb565b600082815260076020526040902054811415613a015760405162461bcd60e51b815260206004820152601460248201527353616d652076616c7565206173206265666f726560601b6044820152606401610cbb565b60008281526007602090815260409182902083905581518481529081018390527f69fd20fd8a4b59cc555abc063627a7fcecd991b0cf18c48122248455bf29699f9101610db1565b600081815260096020526040902054606090613a665760086124df565b600082815260096020526040902080548060200260200160405190810160405280929190818152602001828054801561252957602002820191906000526020600020908154815260200190600101908083116125155750505050509050919050565b613ad06143ee565b6001600160a01b038116613af65760405162461bcd60e51b8152600401610cbb90615b92565b600f80546001600160a01b0319166001600160a01b0383169081179091556040519081527f59cf4cddc1a33ae5f2e8785ba9dcc3c6e66807281882aa0afc75d385a1158cac90602001610ab1565b613b4c6143ee565b60008111613b955760405162461bcd60e51b81526020600482015260166024820152754d757374206265206d6f7265207468656e205a45524f60501b6044820152606401610cbb565b60068190556040518181527f69d8ae57c22ebc10935a3fccebcf33c37abcf90af05eeafdf9d47b066c7a7b1f90602001610ab1565b60008262ffffff168562ffffff16148015613bea575060008562ffffff16115b8015613bfb575060008362ffffff16115b8015613c0b57508360020b600014155b80156124a857505060020b15159392505050565b60096020528160005260406000208181548110612d2f57600080fd5b613c436143ee565b600d8190556040518181527f19eaf2f356d99bcfaf883654316c3c12a7771e09c4058e60691681a6c61b571f90602001610ab1565b60006124a885858585614814565b6060612c6382614867565b600054610100900460ff16613cac5760005460ff1615613cb0565b303b155b613d135760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610cbb565b600054610100900460ff16158015613d35576000805461ffff19166101011790555b613d3e86610dbd565b60038054610100600160a81b0319166101006001600160a01b03881602179055613d6984600161463d565b613d748360016144af565b60068290558015613d8b576000805461ff00191690555b505050505050565b613d9b6143ee565b6001600160a01b038116613dc15760405162461bcd60e51b8152600401610cbb90615b92565b600154600160a81b900460ff1615613e115760405162461bcd60e51b8152602060048201526013602482015272105b1c9958591e481d1c985b9cd9995c9c9959606a1b6044820152606401610cbb565b600080546001600160a01b038381166201000081810262010000600160b01b031990941693909317938490556001805460ff60a81b1916600160a81b1790556040805193909404909116825260208201527fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c9101610ab1565b60006005600083604051602001613ea1919061586a565b60408051601f198184030181529181528151602092830120835290820192909252016000205460ff1692915050565b606081516001600160401b03811115613ef957634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015613f2c57816020015b6060815260200190600190039081613f175790505b50905060005b8251811015610c1957613f6b838281518110613f5e57634e487b7160e01b600052603260045260246000fd5b6020026020010151614bb6565b828281518110613f8b57634e487b7160e01b600052603260045260246000fd5b60200260200101819052508080613fa190615dd7565b915050613f32565b6000613fb783600019615cd1565b60010b8560010b148015613fcf57508460010b600014155b8015613bfb57508260010b600014158015613c0b57508360020b6000141580156124a857505060020b15159392505050565b6008818154811061238957600080fd5b6140196143ee565b6001600160a01b03811661403f5760405162461bcd60e51b8152600401610cbb90615b92565b60038054610100600160a81b0319166101006001600160a01b038416908102919091179091556040519081527f5f56489645cc15092ffab877840903cb7715aca3464f50d3e323ed6465777bbb90602001610ab1565b6000838152600760205260408120548190156140bf576000858152600760205260409020546140c3565b6006545b6000868152600e602052604081205491925090156140ef576000868152600e60205260409020546140f3565b600d545b90506000811180156141145750614111662386f26fc1000082615d58565b85105b801561412f575061412c662386f26fc1000082615d58565b84105b1561413f57600192505050610acc565b84158061414b57508385145b1561415b57600192505050610acc565b848411156141ae57614174662386f26fc1000083615d58565b61418690670de0b6b3a7640000615c5e565b8561419986670de0b6b3a7640000615d58565b6141a39190615c9b565b111592505050610acc565b6141bf662386f26fc1000083615d58565b856141d2670de0b6b3a764000087615d58565b6141dc9190615c9b565b6141ee90670de0b6b3a7640000615d77565b11159695505050505050565b6000546201000090046001600160a01b03163314806142285750336000908152600c602052604090205460ff165b61427e5760405162461bcd60e51b815260206004820152602160248201527f4f6e6c79206f776e6572206f722077686974656c6973746564206164647265736044820152607360f81b6064820152608401610cbb565b6003546040516334d2a49760e11b8152600481018490526101009091046001600160a01b0316906369a5492e9060240160206040518083038186803b1580156142c657600080fd5b505afa1580156142da573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906142fe91906152b1565b80156143815750600f546040516314cb6a7160e01b8152600481018490526001600160a01b03909116906314cb6a719060240160206040518083038186803b15801561434957600080fd5b505afa15801561435d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061438191906152b1565b61439d5760405162461bcd60e51b8152600401610cbb90615bbb565b600082815260116020908152604090912082516143bc92840190614cdf565b507f9c657e838c705c59a50bbb5bccc540f9f11c35d7c3b97ba8bb46d7b39b682ca88282604051610db1929190615bf2565b6000546201000090046001600160a01b031633146144665760405162461bcd60e51b815260206004820152602f60248201527f4f6e6c792074686520636f6e7472616374206f776e6572206d6179207065726660448201526e37b936903a3434b99030b1ba34b7b760891b6064820152608401610cbb565b565b600083614482578115801561447b575082155b9050610acc565b60018414156144945750808211610acc565b60028414156144a65750808210610acc565b50818114610acc565b60005b825181101561463857811515600560008584815181106144e257634e487b7160e01b600052603260045260246000fd5b60200260200101516040516020016144fa919061586a565b60408051601f198184030181529181528151602092830120835290820192909252016000205460ff1615151461462657816005600085848151811061454f57634e487b7160e01b600052603260045260246000fd5b6020026020010151604051602001614567919061586a565b60405160208183030381529060405280519060200120815260200190815260200160002060006101000a81548160ff0219169083151502179055507fa8ffdf44a3dd40e8518ed36f55dbddd07d532e8d4e62cfc9af80dabb7a93c6148382815181106145e357634e487b7160e01b600052603260045260246000fd5b60200260200101516040516020016145fb919061586a565b60408051601f1981840301815282825280516020918201208352851515908301520160405180910390a15b8061463081615dd7565b9150506144b2565b505050565b60005b8251811015614638578115156004600085848151811061467057634e487b7160e01b600052603260045260246000fd5b6020026020010151604051602001614688919061586a565b60408051601f198184030181529181528151602092830120835290820192909252016000205460ff161515146147b45781600460008584815181106146dd57634e487b7160e01b600052603260045260246000fd5b60200260200101516040516020016146f5919061586a565b60405160208183030381529060405280519060200120815260200190815260200160002060006101000a81548160ff0219169083151502179055507ffe28881086408823936cdab8f3b6bb8baf3b5cfe62e5c5c136ba3fefbb5d09c283828151811061477157634e487b7160e01b600052603260045260246000fd5b6020026020010151604051602001614789919061586a565b60408051601f1981840301815282825280516020918201208352851515908301520160405180910390a15b806147be81615dd7565b915050614640565b600082156147ed5760018214806147dd5750600282145b806147e6575081155b9050612c63565b60018214806147fc5750600282145b806148075750600382145b80610acc57505015919050565b6000841561483b578260020b60001415801561483457508360020b600014155b90506124ab565b8260020b60001415801561485357508360020b600014155b8015614834575050600281900b15156124ab565b6060600082516001600160401b0381111561489257634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156148bb578160200160208202803683370190505b5090506000805b8451811015614ae35760008582815181106148ed57634e487b7160e01b600052603260045260246000fd5b60200260200101516000141561493057600084838151811061491f57634e487b7160e01b600052603260045260246000fd5b602002602001018181525050614a9a565b600086838151811061495257634e487b7160e01b600052603260045260246000fd5b602002602001015113156149d75785828151811061498057634e487b7160e01b600052603260045260246000fd5b60200260200101519050806127106149989190615c5e565b6149ac9069021e19e0c9bab2400000615c9b565b6149b7906064615d58565b84838151811061491f57634e487b7160e01b600052603260045260246000fd5b60008683815181106149f957634e487b7160e01b600052603260045260246000fd5b60200260200101511215614a9a57858281518110614a2757634e487b7160e01b600052603260045260246000fd5b6020026020010151614a3890615e34565b9050614a4681612710615c5e565b614a5882670de0b6b3a7640000615d58565b614a629190615c9b565b614a6d906064615d58565b848381518110614a8d57634e487b7160e01b600052603260045260246000fd5b6020026020010181815250505b838281518110614aba57634e487b7160e01b600052603260045260246000fd5b602002602001015183614acd9190615c5e565b9250508080614adb90615dd7565b9150506148c2565b5060005b8251811015614bad5781614b28576000838281518110614b1757634e487b7160e01b600052603260045260246000fd5b602002602001018181525050614b9b565b81838281518110614b4957634e487b7160e01b600052603260045260246000fd5b6020026020010151670de0b6b3a7640000614b649190615d58565b614b6e9190615c9b565b838281518110614b8e57634e487b7160e01b600052603260045260246000fd5b6020026020010181815250505b80614ba581615dd7565b915050614ae7565b50909392505050565b606060ff8216614bdd5750506040805180820190915260018152600360fc1b602082015290565b8160005b60ff821615614c0a5780614bf481615df2565b9150614c039050600a83615caf565b9150614be1565b60008160ff166001600160401b03811115614c3557634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015614c5f576020820181803683370190505b5090505b60ff8516156124ab5781614c7681615dba565b9250614c859050600a86615e12565b614c90906030615c76565b60f81b818360ff1681518110614cb657634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a905350614cd8600a86615caf565b9450614c63565b828054828255906000526020600020908101928215614d1a579160200282015b82811115614d1a578251825591602001919060010190614cff565b50614d26929150614d2a565b5090565b5b80821115614d265760008155600101614d2b565b600082601f830112614d4f578081fd5b81356020614d64614d5f83615c3b565b615c0b565b80838252828201915082860187848660051b8901011115614d83578586fd5b855b85811015614da157813584529284019290840190600101614d85565b5090979650505050505050565b600082601f830112614dbe578081fd5b81356020614dce614d5f83615c3b565b80838252828201915082860187848660051b8901011115614ded578586fd5b855b85811015614da15781356001600160401b03811115614e0c578788fd5b614e1a8a87838c0101614e98565b8552509284019290840190600101614def565b600082601f830112614e3d578081fd5b81356020614e4d614d5f83615c3b565b80838252828201915082860187848660051b8901011115614e6c578586fd5b855b85811015614da157813560ff81168114614e86578788fd5b84529284019290840190600101614e6e565b600082601f830112614ea8578081fd5b81356001600160401b03811115614ec157614ec1615e7a565b614ed4601f8201601f1916602001615c0b565b818152846020838601011115614ee8578283fd5b816020850160208301379081016020019190915292915050565b600060208284031215614f13578081fd5b8135610acc81615e90565b600060208284031215614f2f578081fd5b8151610acc81615e90565b600080600080600060a08688031215614f51578081fd5b8535614f5c81615e90565b94506020860135614f6c81615e90565b935060408601356001600160401b0380821115614f87578283fd5b614f9389838a01614dae565b94506060880135915080821115614fa8578283fd5b50614fb588828901614dae565b95989497509295608001359392505050565b600080600060408486031215614fdb578081fd5b83356001600160401b0380821115614ff1578283fd5b818601915086601f830112615004578283fd5b813581811115615012578384fd5b8760208260051b8501011115615026578384fd5b6020928301955093505084013561503c81615ea5565b809150509250925092565b600060208284031215615058578081fd5b81356001600160401b0381111561506d578182fd5b6124ab84828501614d3f565b6000602080838503121561508b578182fd5b82516001600160401b038111156150a0578283fd5b8301601f810185136150b0578283fd5b80516150be614d5f82615c3b565b80828252848201915084840188868560051b87010111156150dd578687fd5b8694505b838510156150ff5780518352600194909401939185019185016150e1565b50979650505050505050565b60008060006060848603121561511f578081fd5b83356001600160401b0380821115615135578283fd5b61514187838801614d3f565b94506020860135915080821115615156578283fd5b61516287838801614d3f565b93506040860135915080821115615177578283fd5b5061518486828701614e2d565b9150509250925092565b600060208083850312156151a0578182fd5b82356001600160401b038111156151b5578283fd5b8301601f810185136151c5578283fd5b80356151d3614d5f82615c3b565b80828252848201915084840188868560051b87010111156151f2578687fd5b8694505b838510156150ff5780358352600194909401939185019185016151f6565b60008060408385031215615226578182fd5b82356001600160401b0381111561523b578283fd5b61524785828601614dae565b925050602083013561525881615ea5565b809150509250929050565b600060208284031215615274578081fd5b81356001600160401b03811115615289578182fd5b6124ab84828501614e2d565b6000602082840312156152a6578081fd5b8135610acc81615ea5565b6000602082840312156152c2578081fd5b8151610acc81615ea5565b600080600080608085870312156152e2578182fd5b84356152ed81615ea5565b935060208501356152fd81615ec2565b9250604085013561530d81615ec2565b9150606085013561531d81615ec2565b939692955090935050565b6000806040838503121561533a578182fd5b823561534581615ea5565b946020939093013593505050565b600060208284031215615364578081fd5b5035919050565b60008060008060808587031215615380578182fd5b845161538b81615eb3565b602086015190945061539c81615eb3565b60408601519093506153ad81615ee1565b606086015190925061531d81615ee1565b600080600080608085870312156153d3578182fd5b84356153de81615eb3565b935060208501356153ee81615ec2565b9250604085013561530d81615eb3565b600080600080600080600060e0888a031215615418578485fd5b875161542381615ec2565b602089015190975061543481615ec2565b604089015190965061544581615ec2565b606089015190955061545681615ec2565b608089015190945061546781615ec2565b60a089015190935061547881615ec2565b60c089015190925061548981615ec2565b8091505092959891949750929550565b6000602082840312156154aa578081fd5b81356001600160401b038111156154bf578182fd5b6124ab84828501614e98565b600080604083850312156154dd578182fd5b82356001600160401b03808211156154f3578384fd5b6154ff86838701614e98565b93506020850135915080821115615514578283fd5b5061552185828601614e98565b9150509250929050565b60008060006060848603121561553f578081fd5b833561554a81615ed1565b9250602084013561555a81615ec2565b9150604084013561503c81615ec2565b6000806000806080858703121561557f578182fd5b845161558a81615ed1565b602086015190945061559b81615ec2565b60408601519093506155ac81615ec2565b606086015190925061531d81615ea5565b600080600080608085870312156155d2578182fd5b84356155dd81615ee1565b935060208501356155ed81615ec2565b9250604085013561530d81615ee1565b60006020828403121561560e578081fd5b5051919050565b60008060408385031215615627578182fd5b8235915060208301356001600160401b03811115615643578182fd5b61552185828601614d3f565b60008060008060808587031215615664578182fd5b8435935060208501356001600160401b0380821115615681578384fd5b61568d88838901614d3f565b945060408701359150808211156156a2578384fd5b506156af87828801614d3f565b925050606085013561531d81615ea5565b600080604083850312156156d2578182fd5b50508035926020909101359150565b6000806000606084860312156156f5578081fd5b505081359360208301359350604090920135919050565b60006020828403121561571d578081fd5b815164ffffffffff81168114610acc578182fd5b6000815180845260208085019450808401835b83811015615762578151151587529582019590820190600101615744565b509495945050505050565b6000815180845260208085019450808401835b83811015615762578151600190810b8852968301969183019101615780565b6000815180845260208085019450808401835b8381101561576257815160020b875295820195908201906001016157b2565b6000815180845260208085019450808401835b8381101561576257815162ffffff16875295820195908201906001016157e4565b6000815180845260208085019450808401835b8381101561576257815187529582019590820190600101615818565b6000815180845260208085019450808401835b8381101561576257815164ffffffffff1687529582019590820190600101615847565b6000825161587c818460208701615d8e565b9190910192915050565b6101208082528a51908201819052600090610140830190602090818e01845b828110156158ca5781516001600160a01b0316855293830193908301906001016158a5565b505050838203908401526158de818c615731565b905082810360408401526158f2818b615731565b90508281036060840152615906818a615731565b9050828103608084015261591a8189615731565b905082810360a084015261592e8188615731565b905082810360c08401526159428187615805565b905082810360e08401526159568186615834565b905082810361010084015261596b8185615805565b9c9b505050505050505050505050565b602081526000610acc602083018461576d565b602081526000610acc602083018461579f565b6080815260006159b4608083018761579f565b82810360208401526159c6818761576d565b905082810360408401526159da81866157d1565b905082810360608401526159ee818561579f565b979650505050505050565b60a081526000615a0c60a083018861579f565b828103602084810191909152875180835288820192820190845b81811015615a4657845161ffff1683529383019391830191600101615a26565b50508481036040860152615a5a8189615731565b925050508281036060840152615a708186615731565b90508281036080840152615a848185615731565b98975050505050505050565b6000602080830181845280855180835260408601915060408160051b8701019250838701855b82811015615afc57878503603f1901845281518051808752615add818989018a8501615d8e565b601f01601f191695909501860194509285019290850190600101615ab6565b5092979650505050505050565b602081526000610acc60208301846157d1565b602081526000610acc6020830184615805565b60006080820186151583526020861515818501526080604085015281865180845260a0860191508288019350845b81811015615b7957845183529383019391830191600101615b5d565b5050809350505050821515606083015295945050505050565b6020808252600f908201526e496e76616c6964206164647265737360881b604082015260600190565b60208082526018908201527f53706f72744964206973206e6f7420737570706f727465640000000000000000604082015260600190565b828152604060208201526000610ac96040830184615805565b604051601f8201601f191681016001600160401b0381118282101715615c3357615c33615e7a565b604052919050565b60006001600160401b03821115615c5457615c54615e7a565b5060051b60200190565b60008219821115615c7157615c71615e4e565b500190565b600060ff821660ff84168060ff03821115615c9357615c93615e4e565b019392505050565b600082615caa57615caa615e64565b500490565b600060ff831680615cc257615cc2615e64565b8060ff84160491505092915050565b60008160010b8360010b617fff83821384841383830485118282161615615cfa57615cfa615e4e565b617fff1986851282811687830587121615615d1757615d17615e4e565b878712925085820587128484161615615d3257615d32615e4e565b85850587128184161615615d4857615d48615e4e565b5050509290910295945050505050565b6000816000190483118215151615615d7257615d72615e4e565b500290565b600082821015615d8957615d89615e4e565b500390565b60005b83811015615da9578181015183820152602001615d91565b838111156123735750506000910152565b600060ff821680615dcd57615dcd615e4e565b6000190192915050565b6000600019821415615deb57615deb615e4e565b5060010190565b600060ff821660ff811415615e0957615e09615e4e565b60010192915050565b600060ff831680615e2557615e25615e64565b8060ff84160691505092915050565b6000600160ff1b821415615e4a57615e4a615e4e565b0390565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b03811681146119d357600080fd5b80151581146119d357600080fd5b8060010b81146119d357600080fd5b8060020b81146119d357600080fd5b61ffff811681146119d357600080fd5b62ffffff811681146119d357600080fdfea264697066735822122077bc9c90196c678f72e17dbf095b9305118c9bbdcd56b09baeec790a536c31a564736f6c63430008040033

Block Transaction Difficulty Gas Used Reward
Block Uncle Number Difficulty Gas Used Reward
Loading