ETH Price: $2,225.69 (-2.99%)

Contract

0xfE3bac024C7ec54BB825c8133457E3a651d6D501
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Apply Latest Pic...157927782022-10-21 0:04:47861 days ago1666310687IN
0xfE3bac02...651d6D501
0 ETH0.0085124123.99268145
Start Next Round157927702022-10-21 0:03:11861 days ago1666310591IN
0xfE3bac02...651d6D501
0 ETH0.0032574522.50975105
Apply Latest Pic...157927112022-10-20 23:51:23861 days ago1666309883IN
0xfE3bac02...651d6D501
0 ETH0.0070712720.15802699
Start Next Round157927022022-10-20 23:49:35861 days ago1666309775IN
0xfE3bac02...651d6D501
0 ETH0.0033716623.29898288
Apply Latest Pic...157845952022-10-19 20:40:23862 days ago1666212023IN
0xfE3bac02...651d6D501
0 ETH0.01213434.00862498
Start Next Round157845832022-10-19 20:37:59862 days ago1666211879IN
0xfE3bac02...651d6D501
0 ETH0.0047808333.03663762
Apply Latest Pic...157845762022-10-19 20:36:35862 days ago1666211795IN
0xfE3bac02...651d6D501
0 ETH0.0138020638.68379425
Start Next Round157845622022-10-19 20:33:35862 days ago1666211615IN
0xfE3bac02...651d6D501
0 ETH0.0051566335.63350243
Apply Latest Pic...157771832022-10-18 19:48:47863 days ago1666122527IN
0xfE3bac02...651d6D501
0 ETH0.0088900424.91659191
Start Next Round157771722022-10-18 19:46:35863 days ago1666122395IN
0xfE3bac02...651d6D501
0 ETH0.0040852728.2301613
Apply Latest Pic...157770762022-10-18 19:27:23863 days ago1666121243IN
0xfE3bac02...651d6D501
0 ETH0.0084595523.84371617
Start Next Round157770662022-10-18 19:25:23863 days ago1666121123IN
0xfE3bac02...651d6D501
0 ETH0.0037920726.20414106
Apply Latest Pic...157698742022-10-17 19:20:23864 days ago1666034423IN
0xfE3bac02...651d6D501
0 ETH0.0107131330.19552557
Start Next Round157698642022-10-17 19:18:23864 days ago1666034303IN
0xfE3bac02...651d6D501
0 ETH0.0042662729.48096489
Apply Latest Pic...157641922022-10-17 0:15:59865 days ago1665965759IN
0xfE3bac02...651d6D501
0 ETH0.004182811.7233693
Start Next Round157641752022-10-17 0:12:35865 days ago1665965555IN
0xfE3bac02...651d6D501
0 ETH0.001766812.20900971
Apply Latest Pic...157556732022-10-15 19:41:23866 days ago1665862883IN
0xfE3bac02...651d6D501
0 ETH0.0058016316.26054174
Start Next Round157556572022-10-15 19:37:59866 days ago1665862679IN
0xfE3bac02...651d6D501
0 ETH0.0020503414.16833369
Apply Latest Pic...157483532022-10-14 19:11:23867 days ago1665774683IN
0xfE3bac02...651d6D501
0 ETH0.0084209423.60184149
Start Next Round157483372022-10-14 19:08:11867 days ago1665774491IN
0xfE3bac02...651d6D501
0 ETH0.0040420927.93180502
Apply Latest Pic...157408542022-10-13 18:02:23868 days ago1665684143IN
0xfE3bac02...651d6D501
0 ETH0.0099862727.98905578
Start Next Round157408382022-10-13 17:58:59868 days ago1665683939IN
0xfE3bac02...651d6D501
0 ETH0.0042365921.61385097

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
FloatingCityDraftPicker

Compiler Version
v0.8.13+commit.abaa5c0e

Optimization Enabled:
No with 200 runs

Other Settings:
default evmVersion
File 1 of 10 : FloatingCityDraftPicker.sol
// SPDX-License-Identifier: MIT
// base64.tech
pragma solidity ^0.8.13;

import './FloatingCityVRFHandler.sol';
import {Ownable} from "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/utils/Strings.sol";

interface IFloatingCity {
    function unAllocatedTokens(uint256 i) external returns (uint256);
    function getUnAllocatedTokensLength() external returns (uint256);
}

/*


   ▄████████  ▄█        ▄██████▄     ▄████████     ███      ▄█  ███▄▄▄▄      ▄██████▄        ▄████████  ▄█      ███     ▄██   ▄       
  ███    ███ ███       ███    ███   ███    ███ ▀█████████▄ ███  ███▀▀▀██▄   ███    ███      ███    ███ ███  ▀█████████▄ ███   ██▄     
  ███    █▀  ███       ███    ███   ███    ███    ▀███▀▀██ ███▌ ███   ███   ███    █▀       ███    █▀  ███▌    ▀███▀▀██ ███▄▄▄███     
 ▄███▄▄▄     ███       ███    ███   ███    ███     ███   ▀ ███▌ ███   ███  ▄███             ███        ███▌     ███   ▀ ▀▀▀▀▀▀███     
▀▀███▀▀▀     ███       ███    ███ ▀███████████     ███     ███▌ ███   ███ ▀▀███ ████▄       ███        ███▌     ███     ▄██   ███     
  ███        ███       ███    ███   ███    ███     ███     ███  ███   ███   ███    ███      ███    █▄  ███      ███     ███   ███     
  ███        ███▌    ▄ ███    ███   ███    ███     ███     ███  ███   ███   ███    ███      ███    ███ ███      ███     ███   ███     
  ███        █████▄▄██  ▀██████▀    ███    █▀     ▄████▀   █▀    ▀█   █▀    ████████▀       ████████▀  █▀      ▄████▀    ▀█████▀      
             ▀                                                                                                                        
████████▄     ▄████████    ▄████████    ▄████████     ███             ▄███████▄  ▄█   ▄████████    ▄█   ▄█▄    ▄████████    ▄████████ 
███   ▀███   ███    ███   ███    ███   ███    ███ ▀█████████▄        ███    ███ ███  ███    ███   ███ ▄███▀   ███    ███   ███    ███ 
███    ███   ███    ███   ███    ███   ███    █▀     ▀███▀▀██        ███    ███ ███▌ ███    █▀    ███▐██▀     ███    █▀    ███    ███ 
███    ███  ▄███▄▄▄▄██▀   ███    ███  ▄███▄▄▄         ███   ▀        ███    ███ ███▌ ███         ▄█████▀     ▄███▄▄▄      ▄███▄▄▄▄██▀ 
███    ███ ▀▀███▀▀▀▀▀   ▀███████████ ▀▀███▀▀▀         ███          ▀█████████▀  ███▌ ███        ▀▀█████▄    ▀▀███▀▀▀     ▀▀███▀▀▀▀▀   
███    ███ ▀███████████   ███    ███   ███            ███            ███        ███  ███    █▄    ███▐██▄     ███    █▄  ▀███████████ 
███   ▄███   ███    ███   ███    ███   ███            ███            ███        ███  ███    ███   ███ ▀███▄   ███    ███   ███    ███ 
████████▀    ███    ███   ███    █▀    ███           ▄████▀         ▄████▀      █▀   ████████▀    ███   ▀█▀   ██████████   ███    ███ 
             ███    ███                                                                           ▀                        ███    ███ 


*/
contract FloatingCityDraftPicker is FloatingCityVRFHandler {
    IFloatingCity public floatingCityContract;
    bool public latestRoundPicked = true;
    mapping(uint256 => uint256[]) public draftRoundPicks;
    uint256 public draftRound;

    constructor(uint64 _subscriptionId, address _vrfCoordinator, bytes32 _keyHash, IFloatingCity _floatingCityContract)
       FloatingCityVRFHandler(_subscriptionId, _vrfCoordinator, _keyHash)
    {
        floatingCityContract = _floatingCityContract;
    }

    function isLatestRoundReady() public view returns(bool) {
        return s_requests[lastRequestId].fulfilled;
    }

    function getDraftRoundPicks(uint256 round) public view returns(string[10] memory) {
        string[10] memory draftRoundPick;

        for(uint256 i = 0; i < 10; i++) {
            draftRoundPick[i] = Strings.toString(draftRoundPicks[round][i]);
        }

        return draftRoundPick;
    }


    function getLatestPicks() public view returns(string[10] memory) {
        return getDraftRoundPicks(draftRound);
    }


    // == ONLY OWNER FUNCTIONS ==

    function startNextRound() public onlyOwner{
        if(!latestRoundPicked) revert RoundInProgress();
        if(floatingCityContract.getUnAllocatedTokensLength() <= 10) revert NotEnoughTokensForDraft();

        requestRandomWords();
        latestRoundPicked = false;
        draftRound++;
    }

    function applyLatestPicks() public onlyOwner {
        if(!isLatestRoundReady()) revert VRFHasNotReturnedYet();
        if(latestRoundPicked) revert RoundAlreadyComplete();
        uint256[] memory randomNumbers = s_requests[lastRequestId].randomWords;
        
        latestRoundPicked = true;
        uint256 unallocatedTokensLength = floatingCityContract.getUnAllocatedTokensLength();
        for(uint i = 0; i < randomNumbers.length; i++) {
            uint256 randomIndex = randomNumbers[i];
            if(randomNumbers[i] >= unallocatedTokensLength){
                randomIndex = randomNumbers[i] % unallocatedTokensLength;
            }
            draftRoundPicks[draftRound].push(floatingCityContract.unAllocatedTokens(randomIndex));
        }
    }

    function setCallbackGasLimit(uint32 _limit) public onlyOwner {
        callbackGasLimit = _limit;
    }

    function setKeyHash(bytes32 _keyHash) public onlyOwner {
        keyHash = _keyHash;
    }

    function setFloatingCityContract(address _address) public onlyOwner {
        floatingCityContract = IFloatingCity(_address);
    }

    /* THIS IS ONLY CALLED IN THE EVENT CHAINLINK CALL FAILS */
    function restartNextRound() public onlyOwner{
        if(floatingCityContract.getUnAllocatedTokensLength() <= 10) revert NotEnoughTokensForDraft();

        requestRandomWords();
        latestRoundPicked = false;
    }


}

error VRFHasNotReturnedYet();
error RoundAlreadyComplete();
error RoundInProgress();
error LatestPicksNotAppliedYet();
error NotEnoughTokensForDraft();

File 2 of 10 : FloatingCityVRFHandler.sol
// SPDX-License-Identifier: MIT
// base64.tech
pragma solidity ^0.8.13;

import '@chainlink/contracts/src/v0.8/interfaces/VRFCoordinatorV2Interface.sol';
import '@chainlink/contracts/src/v0.8/VRFConsumerBaseV2.sol';
import '@chainlink/contracts/src/v0.8/ConfirmedOwner.sol';

contract FloatingCityVRFHandler is VRFConsumerBaseV2, ConfirmedOwner {
    event RequestSent(uint256 requestId, uint32 numWords);
    event RequestFulfilled(uint256 requestId, uint256[] randomWords);

    struct RequestStatus {
        bool fulfilled; // whether the request has been successfully fulfilled
        bool exists; // whether a requestId exists
        uint256[] randomWords;
    }
    mapping(uint256 => RequestStatus) public s_requests; /* requestId --> requestStatus */
    VRFCoordinatorV2Interface COORDINATOR;

    uint64 s_subscriptionId;

    // past requests Id.
    uint256[] public requestIds;
    uint256 public lastRequestId;

    bytes32 public keyHash;

    uint32 public callbackGasLimit = 500000;

    uint16 public requestConfirmations = 3;

    uint32 public numWords = 10;

    constructor(uint64 subscriptionId, address coordinator, bytes32 _keyHash)
        VRFConsumerBaseV2(coordinator)
        ConfirmedOwner(msg.sender)
    {
        COORDINATOR = VRFCoordinatorV2Interface(coordinator);
        s_subscriptionId = subscriptionId;
        keyHash = _keyHash;
    }

    // Assumes the subscription is funded sufficiently.
    function requestRandomWords() internal returns (uint256 requestId) {
        // Will revert if subscription is not set and funded.
        requestId = COORDINATOR.requestRandomWords(
            keyHash,
            s_subscriptionId,
            requestConfirmations,
            callbackGasLimit,
            numWords
        );
        s_requests[requestId] = RequestStatus({randomWords: new uint256[](0), exists: true, fulfilled: false});
        requestIds.push(requestId);
        lastRequestId = requestId;
        emit RequestSent(requestId, numWords);
        return requestId;
    }

    function fulfillRandomWords(uint256 _requestId, uint256[] memory _randomWords) internal override {
        require(s_requests[_requestId].exists, 'request not found');
        s_requests[_requestId].fulfilled = true;
        s_requests[_requestId].randomWords = _randomWords;
        emit RequestFulfilled(_requestId, _randomWords);
    }

    function getRequestStatus(uint256 _requestId) external view returns (bool fulfilled, uint256[] memory randomWords) {
        require(s_requests[_requestId].exists, 'request not found');
        RequestStatus memory request = s_requests[_requestId];
        return (request.fulfilled, request.randomWords);
    }

}

File 3 of 10 : Ownable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (access/Ownable.sol)

pragma solidity ^0.8.0;

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

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

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

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

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

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
        _;
    }

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

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

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

File 4 of 10 : Strings.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Strings.sol)

pragma solidity ^0.8.0;

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

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

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

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

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

File 5 of 10 : VRFCoordinatorV2Interface.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

interface VRFCoordinatorV2Interface {
  /**
   * @notice Get configuration relevant for making requests
   * @return minimumRequestConfirmations global min for request confirmations
   * @return maxGasLimit global max for request gas limit
   * @return s_provingKeyHashes list of registered key hashes
   */
  function getRequestConfig()
    external
    view
    returns (
      uint16,
      uint32,
      bytes32[] memory
    );

  /**
   * @notice Request a set of random words.
   * @param keyHash - Corresponds to a particular oracle job which uses
   * that key for generating the VRF proof. Different keyHash's have different gas price
   * ceilings, so you can select a specific one to bound your maximum per request cost.
   * @param subId  - The ID of the VRF subscription. Must be funded
   * with the minimum subscription balance required for the selected keyHash.
   * @param minimumRequestConfirmations - How many blocks you'd like the
   * oracle to wait before responding to the request. See SECURITY CONSIDERATIONS
   * for why you may want to request more. The acceptable range is
   * [minimumRequestBlockConfirmations, 200].
   * @param callbackGasLimit - How much gas you'd like to receive in your
   * fulfillRandomWords callback. Note that gasleft() inside fulfillRandomWords
   * may be slightly less than this amount because of gas used calling the function
   * (argument decoding etc.), so you may need to request slightly more than you expect
   * to have inside fulfillRandomWords. The acceptable range is
   * [0, maxGasLimit]
   * @param numWords - The number of uint256 random values you'd like to receive
   * in your fulfillRandomWords callback. Note these numbers are expanded in a
   * secure way by the VRFCoordinator from a single random value supplied by the oracle.
   * @return requestId - A unique identifier of the request. Can be used to match
   * a request to a response in fulfillRandomWords.
   */
  function requestRandomWords(
    bytes32 keyHash,
    uint64 subId,
    uint16 minimumRequestConfirmations,
    uint32 callbackGasLimit,
    uint32 numWords
  ) external returns (uint256 requestId);

  /**
   * @notice Create a VRF subscription.
   * @return subId - A unique subscription id.
   * @dev You can manage the consumer set dynamically with addConsumer/removeConsumer.
   * @dev Note to fund the subscription, use transferAndCall. For example
   * @dev  LINKTOKEN.transferAndCall(
   * @dev    address(COORDINATOR),
   * @dev    amount,
   * @dev    abi.encode(subId));
   */
  function createSubscription() external returns (uint64 subId);

  /**
   * @notice Get a VRF subscription.
   * @param subId - ID of the subscription
   * @return balance - LINK balance of the subscription in juels.
   * @return reqCount - number of requests for this subscription, determines fee tier.
   * @return owner - owner of the subscription.
   * @return consumers - list of consumer address which are able to use this subscription.
   */
  function getSubscription(uint64 subId)
    external
    view
    returns (
      uint96 balance,
      uint64 reqCount,
      address owner,
      address[] memory consumers
    );

  /**
   * @notice Request subscription owner transfer.
   * @param subId - ID of the subscription
   * @param newOwner - proposed new owner of the subscription
   */
  function requestSubscriptionOwnerTransfer(uint64 subId, address newOwner) external;

  /**
   * @notice Request subscription owner transfer.
   * @param subId - ID of the subscription
   * @dev will revert if original owner of subId has
   * not requested that msg.sender become the new owner.
   */
  function acceptSubscriptionOwnerTransfer(uint64 subId) external;

  /**
   * @notice Add a consumer to a VRF subscription.
   * @param subId - ID of the subscription
   * @param consumer - New consumer which can use the subscription
   */
  function addConsumer(uint64 subId, address consumer) external;

  /**
   * @notice Remove a consumer from a VRF subscription.
   * @param subId - ID of the subscription
   * @param consumer - Consumer to remove from the subscription
   */
  function removeConsumer(uint64 subId, address consumer) external;

  /**
   * @notice Cancel a subscription
   * @param subId - ID of the subscription
   * @param to - Where to send the remaining LINK to
   */
  function cancelSubscription(uint64 subId, address to) external;
}

File 6 of 10 : VRFConsumerBaseV2.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.4;

/** ****************************************************************************
 * @notice Interface for contracts using VRF randomness
 * *****************************************************************************
 * @dev PURPOSE
 *
 * @dev Reggie the Random Oracle (not his real job) wants to provide randomness
 * @dev to Vera the verifier in such a way that Vera can be sure he's not
 * @dev making his output up to suit himself. Reggie provides Vera a public key
 * @dev to which he knows the secret key. Each time Vera provides a seed to
 * @dev Reggie, he gives back a value which is computed completely
 * @dev deterministically from the seed and the secret key.
 *
 * @dev Reggie provides a proof by which Vera can verify that the output was
 * @dev correctly computed once Reggie tells it to her, but without that proof,
 * @dev the output is indistinguishable to her from a uniform random sample
 * @dev from the output space.
 *
 * @dev The purpose of this contract is to make it easy for unrelated contracts
 * @dev to talk to Vera the verifier about the work Reggie is doing, to provide
 * @dev simple access to a verifiable source of randomness. It ensures 2 things:
 * @dev 1. The fulfillment came from the VRFCoordinator
 * @dev 2. The consumer contract implements fulfillRandomWords.
 * *****************************************************************************
 * @dev USAGE
 *
 * @dev Calling contracts must inherit from VRFConsumerBase, and can
 * @dev initialize VRFConsumerBase's attributes in their constructor as
 * @dev shown:
 *
 * @dev   contract VRFConsumer {
 * @dev     constructor(<other arguments>, address _vrfCoordinator, address _link)
 * @dev       VRFConsumerBase(_vrfCoordinator) public {
 * @dev         <initialization with other arguments goes here>
 * @dev       }
 * @dev   }
 *
 * @dev The oracle will have given you an ID for the VRF keypair they have
 * @dev committed to (let's call it keyHash). Create subscription, fund it
 * @dev and your consumer contract as a consumer of it (see VRFCoordinatorInterface
 * @dev subscription management functions).
 * @dev Call requestRandomWords(keyHash, subId, minimumRequestConfirmations,
 * @dev callbackGasLimit, numWords),
 * @dev see (VRFCoordinatorInterface for a description of the arguments).
 *
 * @dev Once the VRFCoordinator has received and validated the oracle's response
 * @dev to your request, it will call your contract's fulfillRandomWords method.
 *
 * @dev The randomness argument to fulfillRandomWords is a set of random words
 * @dev generated from your requestId and the blockHash of the request.
 *
 * @dev If your contract could have concurrent requests open, you can use the
 * @dev requestId returned from requestRandomWords to track which response is associated
 * @dev with which randomness request.
 * @dev See "SECURITY CONSIDERATIONS" for principles to keep in mind,
 * @dev if your contract could have multiple requests in flight simultaneously.
 *
 * @dev Colliding `requestId`s are cryptographically impossible as long as seeds
 * @dev differ.
 *
 * *****************************************************************************
 * @dev SECURITY CONSIDERATIONS
 *
 * @dev A method with the ability to call your fulfillRandomness method directly
 * @dev could spoof a VRF response with any random value, so it's critical that
 * @dev it cannot be directly called by anything other than this base contract
 * @dev (specifically, by the VRFConsumerBase.rawFulfillRandomness method).
 *
 * @dev For your users to trust that your contract's random behavior is free
 * @dev from malicious interference, it's best if you can write it so that all
 * @dev behaviors implied by a VRF response are executed *during* your
 * @dev fulfillRandomness method. If your contract must store the response (or
 * @dev anything derived from it) and use it later, you must ensure that any
 * @dev user-significant behavior which depends on that stored value cannot be
 * @dev manipulated by a subsequent VRF request.
 *
 * @dev Similarly, both miners and the VRF oracle itself have some influence
 * @dev over the order in which VRF responses appear on the blockchain, so if
 * @dev your contract could have multiple VRF requests in flight simultaneously,
 * @dev you must ensure that the order in which the VRF responses arrive cannot
 * @dev be used to manipulate your contract's user-significant behavior.
 *
 * @dev Since the block hash of the block which contains the requestRandomness
 * @dev call is mixed into the input to the VRF *last*, a sufficiently powerful
 * @dev miner could, in principle, fork the blockchain to evict the block
 * @dev containing the request, forcing the request to be included in a
 * @dev different block with a different hash, and therefore a different input
 * @dev to the VRF. However, such an attack would incur a substantial economic
 * @dev cost. This cost scales with the number of blocks the VRF oracle waits
 * @dev until it calls responds to a request. It is for this reason that
 * @dev that you can signal to an oracle you'd like them to wait longer before
 * @dev responding to the request (however this is not enforced in the contract
 * @dev and so remains effective only in the case of unmodified oracle software).
 */
abstract contract VRFConsumerBaseV2 {
  error OnlyCoordinatorCanFulfill(address have, address want);
  address private immutable vrfCoordinator;

  /**
   * @param _vrfCoordinator address of VRFCoordinator contract
   */
  constructor(address _vrfCoordinator) {
    vrfCoordinator = _vrfCoordinator;
  }

  /**
   * @notice fulfillRandomness handles the VRF response. Your contract must
   * @notice implement it. See "SECURITY CONSIDERATIONS" above for important
   * @notice principles to keep in mind when implementing your fulfillRandomness
   * @notice method.
   *
   * @dev VRFConsumerBaseV2 expects its subcontracts to have a method with this
   * @dev signature, and will call it once it has verified the proof
   * @dev associated with the randomness. (It is triggered via a call to
   * @dev rawFulfillRandomness, below.)
   *
   * @param requestId The Id initially returned by requestRandomness
   * @param randomWords the VRF output expanded to the requested number of words
   */
  function fulfillRandomWords(uint256 requestId, uint256[] memory randomWords) internal virtual;

  // rawFulfillRandomness is called by VRFCoordinator when it receives a valid VRF
  // proof. rawFulfillRandomness then calls fulfillRandomness, after validating
  // the origin of the call
  function rawFulfillRandomWords(uint256 requestId, uint256[] memory randomWords) external {
    if (msg.sender != vrfCoordinator) {
      revert OnlyCoordinatorCanFulfill(msg.sender, vrfCoordinator);
    }
    fulfillRandomWords(requestId, randomWords);
  }
}

File 7 of 10 : ConfirmedOwner.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import "./ConfirmedOwnerWithProposal.sol";

/**
 * @title The ConfirmedOwner contract
 * @notice A contract with helpers for basic contract ownership.
 */
contract ConfirmedOwner is ConfirmedOwnerWithProposal {
  constructor(address newOwner) ConfirmedOwnerWithProposal(newOwner, address(0)) {}
}

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

import "./interfaces/OwnableInterface.sol";

/**
 * @title The ConfirmedOwner contract
 * @notice A contract with helpers for basic contract ownership.
 */
contract ConfirmedOwnerWithProposal is OwnableInterface {
  address private s_owner;
  address private s_pendingOwner;

  event OwnershipTransferRequested(address indexed from, address indexed to);
  event OwnershipTransferred(address indexed from, address indexed to);

  constructor(address newOwner, address pendingOwner) {
    require(newOwner != address(0), "Cannot set owner to zero");

    s_owner = newOwner;
    if (pendingOwner != address(0)) {
      _transferOwnership(pendingOwner);
    }
  }

  /**
   * @notice Allows an owner to begin transferring ownership to a new address,
   * pending.
   */
  function transferOwnership(address to) public override onlyOwner {
    _transferOwnership(to);
  }

  /**
   * @notice Allows an ownership transfer to be completed by the recipient.
   */
  function acceptOwnership() external override {
    require(msg.sender == s_pendingOwner, "Must be proposed owner");

    address oldOwner = s_owner;
    s_owner = msg.sender;
    s_pendingOwner = address(0);

    emit OwnershipTransferred(oldOwner, msg.sender);
  }

  /**
   * @notice Get the current owner
   */
  function owner() public view override returns (address) {
    return s_owner;
  }

  /**
   * @notice validate, transfer ownership, and emit relevant events
   */
  function _transferOwnership(address to) private {
    require(to != msg.sender, "Cannot transfer to self");

    s_pendingOwner = to;

    emit OwnershipTransferRequested(s_owner, to);
  }

  /**
   * @notice validate access
   */
  function _validateOwnership() internal view {
    require(msg.sender == s_owner, "Only callable by owner");
  }

  /**
   * @notice Reverts if called by anyone other than the contract owner.
   */
  modifier onlyOwner() {
    _validateOwnership();
    _;
  }
}

File 9 of 10 : OwnableInterface.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

interface OwnableInterface {
  function owner() external returns (address);

  function transferOwnership(address recipient) external;

  function acceptOwnership() external;
}

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

pragma solidity ^0.8.0;

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

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

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

Contract Security Audit

Contract ABI

API
[{"inputs":[{"internalType":"uint64","name":"_subscriptionId","type":"uint64"},{"internalType":"address","name":"_vrfCoordinator","type":"address"},{"internalType":"bytes32","name":"_keyHash","type":"bytes32"},{"internalType":"contract IFloatingCity","name":"_floatingCityContract","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"NotEnoughTokensForDraft","type":"error"},{"inputs":[{"internalType":"address","name":"have","type":"address"},{"internalType":"address","name":"want","type":"address"}],"name":"OnlyCoordinatorCanFulfill","type":"error"},{"inputs":[],"name":"RoundAlreadyComplete","type":"error"},{"inputs":[],"name":"RoundInProgress","type":"error"},{"inputs":[],"name":"VRFHasNotReturnedYet","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"OwnershipTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"requestId","type":"uint256"},{"indexed":false,"internalType":"uint256[]","name":"randomWords","type":"uint256[]"}],"name":"RequestFulfilled","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"requestId","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"numWords","type":"uint32"}],"name":"RequestSent","type":"event"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"applyLatestPicks","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"callbackGasLimit","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"draftRound","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"draftRoundPicks","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"floatingCityContract","outputs":[{"internalType":"contract IFloatingCity","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"round","type":"uint256"}],"name":"getDraftRoundPicks","outputs":[{"internalType":"string[10]","name":"","type":"string[10]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLatestPicks","outputs":[{"internalType":"string[10]","name":"","type":"string[10]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_requestId","type":"uint256"}],"name":"getRequestStatus","outputs":[{"internalType":"bool","name":"fulfilled","type":"bool"},{"internalType":"uint256[]","name":"randomWords","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isLatestRoundReady","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"keyHash","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lastRequestId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestRoundPicked","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"numWords","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"requestId","type":"uint256"},{"internalType":"uint256[]","name":"randomWords","type":"uint256[]"}],"name":"rawFulfillRandomWords","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"requestConfirmations","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"requestIds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"restartNextRound","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"s_requests","outputs":[{"internalType":"bool","name":"fulfilled","type":"bool"},{"internalType":"bool","name":"exists","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"_limit","type":"uint32"}],"name":"setCallbackGasLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"}],"name":"setFloatingCityContract","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_keyHash","type":"bytes32"}],"name":"setKeyHash","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"startNextRound","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60a06040526207a120600760006101000a81548163ffffffff021916908363ffffffff1602179055506003600760046101000a81548161ffff021916908361ffff160217905550600a600760066101000a81548163ffffffff021916908363ffffffff16021790555060016007601e6101000a81548160ff0219169083151502179055503480156200009057600080fd5b5060405162002a4c38038062002a4c8339818101604052810190620000b691906200050c565b83838333806000848073ffffffffffffffffffffffffffffffffffffffff1660808173ffffffffffffffffffffffffffffffffffffffff168152505050600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff160362000165576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016200015c90620005df565b60405180910390fd5b816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614620001ec57620001eb81620002ae60201b60201c565b5b50505081600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555082600360146101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555080600681905550505050806007600a6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505050505062000673565b3373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16036200031f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401620003169062000651565b60405180910390fd5b80600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff1660008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127860405160405180910390a350565b600080fd5b600067ffffffffffffffff82169050919050565b6200040181620003e2565b81146200040d57600080fd5b50565b6000815190506200042181620003f6565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000620004548262000427565b9050919050565b620004668162000447565b81146200047257600080fd5b50565b60008151905062000486816200045b565b92915050565b6000819050919050565b620004a1816200048c565b8114620004ad57600080fd5b50565b600081519050620004c18162000496565b92915050565b6000620004d48262000447565b9050919050565b620004e681620004c7565b8114620004f257600080fd5b50565b6000815190506200050681620004db565b92915050565b60008060008060808587031215620005295762000528620003dd565b5b6000620005398782880162000410565b94505060206200054c8782880162000475565b93505060406200055f87828801620004b0565b92505060606200057287828801620004f5565b91505092959194509250565b600082825260208201905092915050565b7f43616e6e6f7420736574206f776e657220746f207a65726f0000000000000000600082015250565b6000620005c76018836200057e565b9150620005d4826200058f565b602082019050919050565b60006020820190508181036000830152620005fa81620005b8565b9050919050565b7f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000600082015250565b6000620006396017836200057e565b9150620006468262000601565b602082019050919050565b600060208201905081810360008301526200066c816200062a565b9050919050565b6080516123b6620006966000396000818161046a01526104be01526123b66000f3fe608060405234801561001057600080fd5b50600436106101735760003560e01c80637ccfd7fc116100de578063afd306dc11610097578063ce9bcac311610071578063ce9bcac3146103df578063d8a4676f146103fd578063f2fde38b1461042e578063fc2a88c31461044a57610173565b8063afd306dc14610385578063b0fb162f146103a3578063c67a3efe146103c157610173565b80637ccfd7fc146102b05780638796ba8c146102ce5780638da5cb5b146102fe578063985447101461031c578063a168fa8914610338578063a4eb718c1461036957610173565b80634113f45d116101305780634113f45d14610214578063594c388a1461024457806361728f391461026057806365c815191461027e578063666ff3a61461028857806379ba5097146102a657610173565b80631fe543e31461017857806324f746971461019457806329ec0e67146101b25780632ce0ad9f146101d05780633079ab6e146102005780633c3ccc441461020a575b600080fd5b610192600480360381019061018d919061189d565b610468565b005b61019c610528565b6040516101a99190611918565b60405180910390f35b6101ba61053e565b6040516101c7919061194e565b60405180910390f35b6101ea60048036038101906101e59190611969565b610551565b6040516101f791906119b8565b60405180910390f35b610208610582565b005b610212610893565b005b61022e600480360381019061022991906119d3565b6109eb565b60405161023b9190611b3e565b60405180910390f35b61025e60048036038101906102599190611bbe565b610a77565b005b610268610ac3565b6040516102759190611c04565b60405180910390f35b610286610ac9565b005b610290610bc3565b60405161029d91906119b8565b60405180910390f35b6102ae610bc9565b005b6102b8610d5e565b6040516102c59190611918565b60405180910390f35b6102e860048036038101906102e391906119d3565b610d74565b6040516102f591906119b8565b60405180910390f35b610306610d98565b6040516103139190611c2e565b60405180910390f35b61033660048036038101906103319190611c75565b610dc1565b005b610352600480360381019061034d91906119d3565b610dd3565b604051610360929190611ca2565b60405180910390f35b610383600480360381019061037e9190611cf7565b610e11565b005b61038d610e3d565b60405161039a919061194e565b60405180910390f35b6103ab610e6a565b6040516103b89190611d41565b60405180910390f35b6103c9610e7e565b6040516103d69190611dbb565b60405180910390f35b6103e7610ea4565b6040516103f49190611b3e565b60405180910390f35b610417600480360381019061041291906119d3565b610ebc565b604051610425929190611e94565b60405180910390f35b61044860048036038101906104439190611bbe565b610fe7565b005b610452610ffb565b60405161045f91906119b8565b60405180910390f35b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461051a57337f00000000000000000000000000000000000000000000000000000000000000006040517f1cf993f4000000000000000000000000000000000000000000000000000000008152600401610511929190611ec4565b60405180910390fd5b6105248282611001565b5050565b600760009054906101000a900463ffffffff1681565b6007601e9054906101000a900460ff1681565b6008602052816000526040600020818154811061056d57600080fd5b90600052602060002001600091509150505481565b61058a6110fb565b610592610e3d565b6105c8576040517f0beb0ea100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6007601e9054906101000a900460ff161561060f576040517fddd5602a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060026000600554815260200190815260200160002060010180548060200260200160405190810160405280929190818152602001828054801561067357602002820191906000526020600020905b81548152602001906001019080831161065f575b5050505050905060016007601e6101000a81548160ff02191690831515021790555060006007600a9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e7599d456040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610706573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061072a9190611f02565b905060005b825181101561088e57600083828151811061074d5761074c611f2f565b5b602002602001015190508284838151811061076b5761076a611f2f565b5b6020026020010151106107a1578284838151811061078c5761078b611f2f565b5b602002602001015161079e9190611f8d565b90505b6008600060095481526020019081526020016000206007600a9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16637f7f2df9836040518263ffffffff1660e01b815260040161081191906119b8565b6020604051808303816000875af1158015610830573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108549190611f02565b908060018154018082558091505060019003906000526020600020016000909190919091505550808061088690611fed565b91505061072f565b505050565b61089b6110fb565b6007601e9054906101000a900460ff166108e1576040517f8c665a2c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600a6007600a9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e7599d456040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610952573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109769190611f02565b116109ad576040517f322b96bb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109b561118b565b5060006007601e6101000a81548160ff021916908315150217905550600960008154809291906109e490611fed565b9190505550565b6109f3611668565b6109fb611668565b60005b600a811015610a6d57610a3f600860008681526020019081526020016000208281548110610a2f57610a2e611f2f565b5b90600052602060002001546113dc565b8282600a8110610a5257610a51611f2f565b5b60200201819052508080610a6590611fed565b9150506109fe565b5080915050919050565b610a7f6110fb565b806007600a6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b60065481565b610ad16110fb565b600a6007600a9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e7599d456040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610b42573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b669190611f02565b11610b9d576040517f322b96bb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610ba561118b565b5060006007601e6101000a81548160ff021916908315150217905550565b60095481565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610c59576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c5090612092565b60405180910390fd5b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506000600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055503373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a350565b600760069054906101000a900463ffffffff1681565b60048181548110610d8457600080fd5b906000526020600020016000915090505481565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b610dc96110fb565b8060068190555050565b60026020528060005260406000206000915090508060000160009054906101000a900460ff16908060000160019054906101000a900460ff16905082565b610e196110fb565b80600760006101000a81548163ffffffff021916908363ffffffff16021790555050565b600060026000600554815260200190815260200160002060000160009054906101000a900460ff16905090565b600760049054906101000a900461ffff1681565b6007600a9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b610eac611668565b610eb76009546109eb565b905090565b600060606002600084815260200190815260200160002060000160019054906101000a900460ff16610f23576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f1a906120fe565b60405180910390fd5b6000600260008581526020019081526020016000206040518060600160405290816000820160009054906101000a900460ff161515151581526020016000820160019054906101000a900460ff1615151515815260200160018201805480602002602001604051908101604052809291908181526020018280548015610fc857602002820191906000526020600020905b815481526020019060010190808311610fb4575b5050505050815250509050806000015181604001519250925050915091565b610fef6110fb565b610ff88161153c565b50565b60055481565b6002600083815260200190815260200160002060000160019054906101000a900460ff16611064576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161105b906120fe565b60405180910390fd5b60016002600084815260200190815260200160002060000160006101000a81548160ff021916908315150217905550806002600084815260200190815260200160002060010190805190602001906110bd929190611690565b507ffe2e2d779dba245964d4e3ef9b994be63856fd568bf7d3ca9e224755cb1bd54d82826040516110ef92919061211e565b60405180910390a15050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611189576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016111809061219a565b60405180910390fd5b565b6000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635d3b1d30600654600360149054906101000a900467ffffffffffffffff16600760049054906101000a900461ffff16600760009054906101000a900463ffffffff16600760069054906101000a900463ffffffff166040518663ffffffff1660e01b815260040161123c9594939291906121dd565b6020604051808303816000875af115801561125b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061127f9190611f02565b90506040518060600160405280600015158152602001600115158152602001600067ffffffffffffffff8111156112b9576112b861175a565b5b6040519080825280602002602001820160405280156112e75781602001602082028036833780820191505090505b508152506002600083815260200190815260200160002060008201518160000160006101000a81548160ff02191690831515021790555060208201518160000160016101000a81548160ff021916908315150217905550604082015181600101908051906020019061135a929190611690565b509050506004819080600181540180825580915050600190039060005260206000200160009091909190915055806005819055507fcc58b13ad3eab50626c6a6300b1d139cd6ebb1688a7cced9461c2f7e762665ee81600760069054906101000a900463ffffffff166040516113d1929190612230565b60405180910390a190565b606060008203611423576040518060400160405280600181526020017f30000000000000000000000000000000000000000000000000000000000000008152509050611537565b600082905060005b6000821461145557808061143e90611fed565b915050600a8261144e9190612259565b915061142b565b60008167ffffffffffffffff8111156114715761147061175a565b5b6040519080825280601f01601f1916602001820160405280156114a35781602001600182028036833780820191505090505b5090505b60008514611530576001826114bc919061228a565b9150600a856114cb9190611f8d565b60306114d791906122be565b60f81b8183815181106114ed576114ec611f2f565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600a856115299190612259565b94506114a7565b8093505050505b919050565b3373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16036115aa576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016115a190612360565b60405180910390fd5b80600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff1660008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127860405160405180910390a350565b604051806101400160405280600a905b60608152602001906001900390816116785790505090565b8280548282559060005260206000209081019282156116cc579160200282015b828111156116cb5782518255916020019190600101906116b0565b5b5090506116d991906116dd565b5090565b5b808211156116f65760008160009055506001016116de565b5090565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6117218161170e565b811461172c57600080fd5b50565b60008135905061173e81611718565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61179282611749565b810181811067ffffffffffffffff821117156117b1576117b061175a565b5b80604052505050565b60006117c46116fa565b90506117d08282611789565b919050565b600067ffffffffffffffff8211156117f0576117ef61175a565b5b602082029050602081019050919050565b600080fd5b6000611819611814846117d5565b6117ba565b9050808382526020820190506020840283018581111561183c5761183b611801565b5b835b818110156118655780611851888261172f565b84526020840193505060208101905061183e565b5050509392505050565b600082601f83011261188457611883611744565b5b8135611894848260208601611806565b91505092915050565b600080604083850312156118b4576118b3611704565b5b60006118c28582860161172f565b925050602083013567ffffffffffffffff8111156118e3576118e2611709565b5b6118ef8582860161186f565b9150509250929050565b600063ffffffff82169050919050565b611912816118f9565b82525050565b600060208201905061192d6000830184611909565b92915050565b60008115159050919050565b61194881611933565b82525050565b6000602082019050611963600083018461193f565b92915050565b600080604083850312156119805761197f611704565b5b600061198e8582860161172f565b925050602061199f8582860161172f565b9150509250929050565b6119b28161170e565b82525050565b60006020820190506119cd60008301846119a9565b92915050565b6000602082840312156119e9576119e8611704565b5b60006119f78482850161172f565b91505092915050565b6000600a9050919050565b600081905092915050565b6000819050919050565b600081519050919050565b600082825260208201905092915050565b60005b83811015611a5a578082015181840152602081019050611a3f565b83811115611a69576000848401525b50505050565b6000611a7a82611a20565b611a848185611a2b565b9350611a94818560208601611a3c565b611a9d81611749565b840191505092915050565b6000611ab48383611a6f565b905092915050565b6000602082019050919050565b6000611ad482611a00565b611ade8185611a0b565b935083602082028501611af085611a16565b8060005b85811015611b2c5784840389528151611b0d8582611aa8565b9450611b1883611abc565b925060208a01995050600181019050611af4565b50829750879550505050505092915050565b60006020820190508181036000830152611b588184611ac9565b905092915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000611b8b82611b60565b9050919050565b611b9b81611b80565b8114611ba657600080fd5b50565b600081359050611bb881611b92565b92915050565b600060208284031215611bd457611bd3611704565b5b6000611be284828501611ba9565b91505092915050565b6000819050919050565b611bfe81611beb565b82525050565b6000602082019050611c196000830184611bf5565b92915050565b611c2881611b80565b82525050565b6000602082019050611c436000830184611c1f565b92915050565b611c5281611beb565b8114611c5d57600080fd5b50565b600081359050611c6f81611c49565b92915050565b600060208284031215611c8b57611c8a611704565b5b6000611c9984828501611c60565b91505092915050565b6000604082019050611cb7600083018561193f565b611cc4602083018461193f565b9392505050565b611cd4816118f9565b8114611cdf57600080fd5b50565b600081359050611cf181611ccb565b92915050565b600060208284031215611d0d57611d0c611704565b5b6000611d1b84828501611ce2565b91505092915050565b600061ffff82169050919050565b611d3b81611d24565b82525050565b6000602082019050611d566000830184611d32565b92915050565b6000819050919050565b6000611d81611d7c611d7784611b60565b611d5c565b611b60565b9050919050565b6000611d9382611d66565b9050919050565b6000611da582611d88565b9050919050565b611db581611d9a565b82525050565b6000602082019050611dd06000830184611dac565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611e0b8161170e565b82525050565b6000611e1d8383611e02565b60208301905092915050565b6000602082019050919050565b6000611e4182611dd6565b611e4b8185611de1565b9350611e5683611df2565b8060005b83811015611e87578151611e6e8882611e11565b9750611e7983611e29565b925050600181019050611e5a565b5085935050505092915050565b6000604082019050611ea9600083018561193f565b8181036020830152611ebb8184611e36565b90509392505050565b6000604082019050611ed96000830185611c1f565b611ee66020830184611c1f565b9392505050565b600081519050611efc81611718565b92915050565b600060208284031215611f1857611f17611704565b5b6000611f2684828501611eed565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000611f988261170e565b9150611fa38361170e565b925082611fb357611fb2611f5e565b5b828206905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000611ff88261170e565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361202a57612029611fbe565b5b600182019050919050565b600082825260208201905092915050565b7f4d7573742062652070726f706f736564206f776e657200000000000000000000600082015250565b600061207c601683612035565b915061208782612046565b602082019050919050565b600060208201905081810360008301526120ab8161206f565b9050919050565b7f72657175657374206e6f7420666f756e64000000000000000000000000000000600082015250565b60006120e8601183612035565b91506120f3826120b2565b602082019050919050565b60006020820190508181036000830152612117816120db565b9050919050565b600060408201905061213360008301856119a9565b81810360208301526121458184611e36565b90509392505050565b7f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000600082015250565b6000612184601683612035565b915061218f8261214e565b602082019050919050565b600060208201905081810360008301526121b381612177565b9050919050565b600067ffffffffffffffff82169050919050565b6121d7816121ba565b82525050565b600060a0820190506121f26000830188611bf5565b6121ff60208301876121ce565b61220c6040830186611d32565b6122196060830185611909565b6122266080830184611909565b9695505050505050565b600060408201905061224560008301856119a9565b6122526020830184611909565b9392505050565b60006122648261170e565b915061226f8361170e565b92508261227f5761227e611f5e565b5b828204905092915050565b60006122958261170e565b91506122a08361170e565b9250828210156122b3576122b2611fbe565b5b828203905092915050565b60006122c98261170e565b91506122d48361170e565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0382111561230957612308611fbe565b5b828201905092915050565b7f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000600082015250565b600061234a601783612035565b915061235582612314565b602082019050919050565b600060208201905081810360008301526123798161233d565b905091905056fea26469706673582212208615f0daff78e822b790ebea7e3cf1dcac802adb7315d53d35b4bcd232945d1464736f6c634300080d003300000000000000000000000000000000000000000000000000000000000001c8000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e699098af398995b04c28e9951adb9721ef74c74f93e6a478f39e7e0777be13527e7ef000000000000000000000000d69bdeca98a8b4f24952353b32d46878b21116eb

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106101735760003560e01c80637ccfd7fc116100de578063afd306dc11610097578063ce9bcac311610071578063ce9bcac3146103df578063d8a4676f146103fd578063f2fde38b1461042e578063fc2a88c31461044a57610173565b8063afd306dc14610385578063b0fb162f146103a3578063c67a3efe146103c157610173565b80637ccfd7fc146102b05780638796ba8c146102ce5780638da5cb5b146102fe578063985447101461031c578063a168fa8914610338578063a4eb718c1461036957610173565b80634113f45d116101305780634113f45d14610214578063594c388a1461024457806361728f391461026057806365c815191461027e578063666ff3a61461028857806379ba5097146102a657610173565b80631fe543e31461017857806324f746971461019457806329ec0e67146101b25780632ce0ad9f146101d05780633079ab6e146102005780633c3ccc441461020a575b600080fd5b610192600480360381019061018d919061189d565b610468565b005b61019c610528565b6040516101a99190611918565b60405180910390f35b6101ba61053e565b6040516101c7919061194e565b60405180910390f35b6101ea60048036038101906101e59190611969565b610551565b6040516101f791906119b8565b60405180910390f35b610208610582565b005b610212610893565b005b61022e600480360381019061022991906119d3565b6109eb565b60405161023b9190611b3e565b60405180910390f35b61025e60048036038101906102599190611bbe565b610a77565b005b610268610ac3565b6040516102759190611c04565b60405180910390f35b610286610ac9565b005b610290610bc3565b60405161029d91906119b8565b60405180910390f35b6102ae610bc9565b005b6102b8610d5e565b6040516102c59190611918565b60405180910390f35b6102e860048036038101906102e391906119d3565b610d74565b6040516102f591906119b8565b60405180910390f35b610306610d98565b6040516103139190611c2e565b60405180910390f35b61033660048036038101906103319190611c75565b610dc1565b005b610352600480360381019061034d91906119d3565b610dd3565b604051610360929190611ca2565b60405180910390f35b610383600480360381019061037e9190611cf7565b610e11565b005b61038d610e3d565b60405161039a919061194e565b60405180910390f35b6103ab610e6a565b6040516103b89190611d41565b60405180910390f35b6103c9610e7e565b6040516103d69190611dbb565b60405180910390f35b6103e7610ea4565b6040516103f49190611b3e565b60405180910390f35b610417600480360381019061041291906119d3565b610ebc565b604051610425929190611e94565b60405180910390f35b61044860048036038101906104439190611bbe565b610fe7565b005b610452610ffb565b60405161045f91906119b8565b60405180910390f35b7f000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e6990973ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461051a57337f000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e699096040517f1cf993f4000000000000000000000000000000000000000000000000000000008152600401610511929190611ec4565b60405180910390fd5b6105248282611001565b5050565b600760009054906101000a900463ffffffff1681565b6007601e9054906101000a900460ff1681565b6008602052816000526040600020818154811061056d57600080fd5b90600052602060002001600091509150505481565b61058a6110fb565b610592610e3d565b6105c8576040517f0beb0ea100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6007601e9054906101000a900460ff161561060f576040517fddd5602a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060026000600554815260200190815260200160002060010180548060200260200160405190810160405280929190818152602001828054801561067357602002820191906000526020600020905b81548152602001906001019080831161065f575b5050505050905060016007601e6101000a81548160ff02191690831515021790555060006007600a9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e7599d456040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610706573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061072a9190611f02565b905060005b825181101561088e57600083828151811061074d5761074c611f2f565b5b602002602001015190508284838151811061076b5761076a611f2f565b5b6020026020010151106107a1578284838151811061078c5761078b611f2f565b5b602002602001015161079e9190611f8d565b90505b6008600060095481526020019081526020016000206007600a9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16637f7f2df9836040518263ffffffff1660e01b815260040161081191906119b8565b6020604051808303816000875af1158015610830573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108549190611f02565b908060018154018082558091505060019003906000526020600020016000909190919091505550808061088690611fed565b91505061072f565b505050565b61089b6110fb565b6007601e9054906101000a900460ff166108e1576040517f8c665a2c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600a6007600a9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e7599d456040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610952573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109769190611f02565b116109ad576040517f322b96bb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109b561118b565b5060006007601e6101000a81548160ff021916908315150217905550600960008154809291906109e490611fed565b9190505550565b6109f3611668565b6109fb611668565b60005b600a811015610a6d57610a3f600860008681526020019081526020016000208281548110610a2f57610a2e611f2f565b5b90600052602060002001546113dc565b8282600a8110610a5257610a51611f2f565b5b60200201819052508080610a6590611fed565b9150506109fe565b5080915050919050565b610a7f6110fb565b806007600a6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b60065481565b610ad16110fb565b600a6007600a9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e7599d456040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610b42573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b669190611f02565b11610b9d576040517f322b96bb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610ba561118b565b5060006007601e6101000a81548160ff021916908315150217905550565b60095481565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610c59576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c5090612092565b60405180910390fd5b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506000600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055503373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a350565b600760069054906101000a900463ffffffff1681565b60048181548110610d8457600080fd5b906000526020600020016000915090505481565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b610dc96110fb565b8060068190555050565b60026020528060005260406000206000915090508060000160009054906101000a900460ff16908060000160019054906101000a900460ff16905082565b610e196110fb565b80600760006101000a81548163ffffffff021916908363ffffffff16021790555050565b600060026000600554815260200190815260200160002060000160009054906101000a900460ff16905090565b600760049054906101000a900461ffff1681565b6007600a9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b610eac611668565b610eb76009546109eb565b905090565b600060606002600084815260200190815260200160002060000160019054906101000a900460ff16610f23576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f1a906120fe565b60405180910390fd5b6000600260008581526020019081526020016000206040518060600160405290816000820160009054906101000a900460ff161515151581526020016000820160019054906101000a900460ff1615151515815260200160018201805480602002602001604051908101604052809291908181526020018280548015610fc857602002820191906000526020600020905b815481526020019060010190808311610fb4575b5050505050815250509050806000015181604001519250925050915091565b610fef6110fb565b610ff88161153c565b50565b60055481565b6002600083815260200190815260200160002060000160019054906101000a900460ff16611064576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161105b906120fe565b60405180910390fd5b60016002600084815260200190815260200160002060000160006101000a81548160ff021916908315150217905550806002600084815260200190815260200160002060010190805190602001906110bd929190611690565b507ffe2e2d779dba245964d4e3ef9b994be63856fd568bf7d3ca9e224755cb1bd54d82826040516110ef92919061211e565b60405180910390a15050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611189576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016111809061219a565b60405180910390fd5b565b6000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635d3b1d30600654600360149054906101000a900467ffffffffffffffff16600760049054906101000a900461ffff16600760009054906101000a900463ffffffff16600760069054906101000a900463ffffffff166040518663ffffffff1660e01b815260040161123c9594939291906121dd565b6020604051808303816000875af115801561125b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061127f9190611f02565b90506040518060600160405280600015158152602001600115158152602001600067ffffffffffffffff8111156112b9576112b861175a565b5b6040519080825280602002602001820160405280156112e75781602001602082028036833780820191505090505b508152506002600083815260200190815260200160002060008201518160000160006101000a81548160ff02191690831515021790555060208201518160000160016101000a81548160ff021916908315150217905550604082015181600101908051906020019061135a929190611690565b509050506004819080600181540180825580915050600190039060005260206000200160009091909190915055806005819055507fcc58b13ad3eab50626c6a6300b1d139cd6ebb1688a7cced9461c2f7e762665ee81600760069054906101000a900463ffffffff166040516113d1929190612230565b60405180910390a190565b606060008203611423576040518060400160405280600181526020017f30000000000000000000000000000000000000000000000000000000000000008152509050611537565b600082905060005b6000821461145557808061143e90611fed565b915050600a8261144e9190612259565b915061142b565b60008167ffffffffffffffff8111156114715761147061175a565b5b6040519080825280601f01601f1916602001820160405280156114a35781602001600182028036833780820191505090505b5090505b60008514611530576001826114bc919061228a565b9150600a856114cb9190611f8d565b60306114d791906122be565b60f81b8183815181106114ed576114ec611f2f565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600a856115299190612259565b94506114a7565b8093505050505b919050565b3373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16036115aa576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016115a190612360565b60405180910390fd5b80600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff1660008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127860405160405180910390a350565b604051806101400160405280600a905b60608152602001906001900390816116785790505090565b8280548282559060005260206000209081019282156116cc579160200282015b828111156116cb5782518255916020019190600101906116b0565b5b5090506116d991906116dd565b5090565b5b808211156116f65760008160009055506001016116de565b5090565b6000604051905090565b600080fd5b600080fd5b6000819050919050565b6117218161170e565b811461172c57600080fd5b50565b60008135905061173e81611718565b92915050565b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61179282611749565b810181811067ffffffffffffffff821117156117b1576117b061175a565b5b80604052505050565b60006117c46116fa565b90506117d08282611789565b919050565b600067ffffffffffffffff8211156117f0576117ef61175a565b5b602082029050602081019050919050565b600080fd5b6000611819611814846117d5565b6117ba565b9050808382526020820190506020840283018581111561183c5761183b611801565b5b835b818110156118655780611851888261172f565b84526020840193505060208101905061183e565b5050509392505050565b600082601f83011261188457611883611744565b5b8135611894848260208601611806565b91505092915050565b600080604083850312156118b4576118b3611704565b5b60006118c28582860161172f565b925050602083013567ffffffffffffffff8111156118e3576118e2611709565b5b6118ef8582860161186f565b9150509250929050565b600063ffffffff82169050919050565b611912816118f9565b82525050565b600060208201905061192d6000830184611909565b92915050565b60008115159050919050565b61194881611933565b82525050565b6000602082019050611963600083018461193f565b92915050565b600080604083850312156119805761197f611704565b5b600061198e8582860161172f565b925050602061199f8582860161172f565b9150509250929050565b6119b28161170e565b82525050565b60006020820190506119cd60008301846119a9565b92915050565b6000602082840312156119e9576119e8611704565b5b60006119f78482850161172f565b91505092915050565b6000600a9050919050565b600081905092915050565b6000819050919050565b600081519050919050565b600082825260208201905092915050565b60005b83811015611a5a578082015181840152602081019050611a3f565b83811115611a69576000848401525b50505050565b6000611a7a82611a20565b611a848185611a2b565b9350611a94818560208601611a3c565b611a9d81611749565b840191505092915050565b6000611ab48383611a6f565b905092915050565b6000602082019050919050565b6000611ad482611a00565b611ade8185611a0b565b935083602082028501611af085611a16565b8060005b85811015611b2c5784840389528151611b0d8582611aa8565b9450611b1883611abc565b925060208a01995050600181019050611af4565b50829750879550505050505092915050565b60006020820190508181036000830152611b588184611ac9565b905092915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000611b8b82611b60565b9050919050565b611b9b81611b80565b8114611ba657600080fd5b50565b600081359050611bb881611b92565b92915050565b600060208284031215611bd457611bd3611704565b5b6000611be284828501611ba9565b91505092915050565b6000819050919050565b611bfe81611beb565b82525050565b6000602082019050611c196000830184611bf5565b92915050565b611c2881611b80565b82525050565b6000602082019050611c436000830184611c1f565b92915050565b611c5281611beb565b8114611c5d57600080fd5b50565b600081359050611c6f81611c49565b92915050565b600060208284031215611c8b57611c8a611704565b5b6000611c9984828501611c60565b91505092915050565b6000604082019050611cb7600083018561193f565b611cc4602083018461193f565b9392505050565b611cd4816118f9565b8114611cdf57600080fd5b50565b600081359050611cf181611ccb565b92915050565b600060208284031215611d0d57611d0c611704565b5b6000611d1b84828501611ce2565b91505092915050565b600061ffff82169050919050565b611d3b81611d24565b82525050565b6000602082019050611d566000830184611d32565b92915050565b6000819050919050565b6000611d81611d7c611d7784611b60565b611d5c565b611b60565b9050919050565b6000611d9382611d66565b9050919050565b6000611da582611d88565b9050919050565b611db581611d9a565b82525050565b6000602082019050611dd06000830184611dac565b92915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b611e0b8161170e565b82525050565b6000611e1d8383611e02565b60208301905092915050565b6000602082019050919050565b6000611e4182611dd6565b611e4b8185611de1565b9350611e5683611df2565b8060005b83811015611e87578151611e6e8882611e11565b9750611e7983611e29565b925050600181019050611e5a565b5085935050505092915050565b6000604082019050611ea9600083018561193f565b8181036020830152611ebb8184611e36565b90509392505050565b6000604082019050611ed96000830185611c1f565b611ee66020830184611c1f565b9392505050565b600081519050611efc81611718565b92915050565b600060208284031215611f1857611f17611704565b5b6000611f2684828501611eed565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000611f988261170e565b9150611fa38361170e565b925082611fb357611fb2611f5e565b5b828206905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000611ff88261170e565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361202a57612029611fbe565b5b600182019050919050565b600082825260208201905092915050565b7f4d7573742062652070726f706f736564206f776e657200000000000000000000600082015250565b600061207c601683612035565b915061208782612046565b602082019050919050565b600060208201905081810360008301526120ab8161206f565b9050919050565b7f72657175657374206e6f7420666f756e64000000000000000000000000000000600082015250565b60006120e8601183612035565b91506120f3826120b2565b602082019050919050565b60006020820190508181036000830152612117816120db565b9050919050565b600060408201905061213360008301856119a9565b81810360208301526121458184611e36565b90509392505050565b7f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000600082015250565b6000612184601683612035565b915061218f8261214e565b602082019050919050565b600060208201905081810360008301526121b381612177565b9050919050565b600067ffffffffffffffff82169050919050565b6121d7816121ba565b82525050565b600060a0820190506121f26000830188611bf5565b6121ff60208301876121ce565b61220c6040830186611d32565b6122196060830185611909565b6122266080830184611909565b9695505050505050565b600060408201905061224560008301856119a9565b6122526020830184611909565b9392505050565b60006122648261170e565b915061226f8361170e565b92508261227f5761227e611f5e565b5b828204905092915050565b60006122958261170e565b91506122a08361170e565b9250828210156122b3576122b2611fbe565b5b828203905092915050565b60006122c98261170e565b91506122d48361170e565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0382111561230957612308611fbe565b5b828201905092915050565b7f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000600082015250565b600061234a601783612035565b915061235582612314565b602082019050919050565b600060208201905081810360008301526123798161233d565b905091905056fea26469706673582212208615f0daff78e822b790ebea7e3cf1dcac802adb7315d53d35b4bcd232945d1464736f6c634300080d0033

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

00000000000000000000000000000000000000000000000000000000000001c8000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e699098af398995b04c28e9951adb9721ef74c74f93e6a478f39e7e0777be13527e7ef000000000000000000000000d69bdeca98a8b4f24952353b32d46878b21116eb

-----Decoded View---------------
Arg [0] : _subscriptionId (uint64): 456
Arg [1] : _vrfCoordinator (address): 0x271682DEB8C4E0901D1a1550aD2e64D568E69909
Arg [2] : _keyHash (bytes32): 0x8af398995b04c28e9951adb9721ef74c74f93e6a478f39e7e0777be13527e7ef
Arg [3] : _floatingCityContract (address): 0xD69BdecA98a8b4f24952353B32D46878B21116Eb

-----Encoded View---------------
4 Constructor Arguments found :
Arg [0] : 00000000000000000000000000000000000000000000000000000000000001c8
Arg [1] : 000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e69909
Arg [2] : 8af398995b04c28e9951adb9721ef74c74f93e6a478f39e7e0777be13527e7ef
Arg [3] : 000000000000000000000000d69bdeca98a8b4f24952353b32d46878b21116eb


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

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

Validator Index Block Amount
View All Withdrawals

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

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