ETH Price: $3,842.31 (+6.21%)

Contract

0x9751C78E3BE72ce1Cf2a111f49C241c690018d61
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Token Holdings

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Send Many To Gal...138348782021-12-19 9:56:421081 days ago1639907802IN
0x9751C78E...690018d61
0 ETH0.0009937329.72395753
Claim Many Hammi...137331922021-12-03 10:51:301097 days ago1638528690IN
0x9751C78E...690018d61
0 ETH0.0027655278.0781115
Send Many To Gal...137323642021-12-03 7:49:001097 days ago1638517740IN
0x9751C78E...690018d61
0 ETH0.0025763277.06164907
Send Many To Gal...137323512021-12-03 7:46:351097 days ago1638517595IN
0x9751C78E...690018d61
0 ETH0.0020296892.25847789
Toggle Staking137290912021-12-02 19:13:411098 days ago1638472421IN
0x9751C78E...690018d61
0 ETH0.00338217141.12377018
Claim Many Hammi...137290892021-12-02 19:12:371098 days ago1638472357IN
0x9751C78E...690018d61
0 ETH0.00504455113.22846123
Unstake Many Ham...137290412021-12-02 19:02:081098 days ago1638471728IN
0x9751C78E...690018d61
0 ETH0.0607086893.46901384
Toggle Staking137290232021-12-02 18:59:271098 days ago1638471567IN
0x9751C78E...690018d61
0 ETH0.00601437131.12927041
Send Many To Gal...137256132021-12-02 5:46:341098 days ago1638423994IN
0x9751C78E...690018d61
0 ETH0.0023736771
Send Many To Gal...137253032021-12-02 4:34:531098 days ago1638419693IN
0x9751C78E...690018d61
0 ETH0.0031744794.95328309
Send Many To Gal...137253032021-12-02 4:34:531098 days ago1638419693IN
0x9751C78E...690018d61
0 ETH0.0031744794.95328309
Send Many To Gal...137243582021-12-02 0:57:171098 days ago1638406637IN
0x9751C78E...690018d61
0 ETH0.0026855780.32948783
Toggle Staking137237912021-12-01 22:51:321099 days ago1638399092IN
0x9751C78E...690018d61
0 ETH0.00310258129.45765483
Send Many To Gal...137237742021-12-01 22:47:431099 days ago1638398863IN
0x9751C78E...690018d61
0 ETH0.0166329989.95280052
Send Many To Gal...137237262021-12-01 22:35:581099 days ago1638398158IN
0x9751C78E...690018d61
0 ETH0.0185266399.86919045
Send Many To Gal...137236972021-12-01 22:31:521099 days ago1638397912IN
0x9751C78E...690018d61
0 ETH0.01864385106.4961537
Send Many To Gal...137236682021-12-01 22:25:201099 days ago1638397520IN
0x9751C78E...690018d61
0 ETH0.0147194984.07966289
Send Many To Gal...137236312021-12-01 22:17:391099 days ago1638397059IN
0x9751C78E...690018d61
0 ETH0.0196927799.85183052
Send Many To Gal...137236312021-12-01 22:17:391099 days ago1638397059IN
0x9751C78E...690018d61
0 ETH0.0207367299.85183052
Send Many To Gal...137235732021-12-01 22:04:051099 days ago1638396245IN
0x9751C78E...690018d61
0 ETH0.02687701153.52502655
Send Many To Gal...137235422021-12-01 21:58:101099 days ago1638395890IN
0x9751C78E...690018d61
0 ETH0.02903232165.8364697
Send Many To Gal...137235152021-12-01 21:49:021099 days ago1638395342IN
0x9751C78E...690018d61
0 ETH0.02927914158.33412472
Send Many To Gal...137235142021-12-01 21:48:541099 days ago1638395334IN
0x9751C78E...690018d61
0 ETH0.04345588148.48589635
Send Many To Gal...137235042021-12-01 21:45:461099 days ago1638395146IN
0x9751C78E...690018d61
0 ETH0.02184525124.78296721
Send Many To Gal...137234632021-12-01 21:34:031099 days ago1638394443IN
0x9751C78E...690018d61
0 ETH0.02002272101.52481583
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
Galaxy

Compiler Version
v0.8.7+commit.e28d00a7

Optimization Enabled:
No with 200 runs

Other Settings:
default evmVersion, MIT license

Contract Source Code (Solidity Multiple files format)

File 1 of 21: Galaxy.sol
// ________  ________  ___       ________     ___    ___ ___    ___ 
//|\   ____\|\   __  \|\  \     |\   __  \   |\  \  /  /|\  \  /  /|
//\ \  \___|\ \  \|\  \ \  \    \ \  \|\  \  \ \  \/  / | \  \/  / /
// \ \  \  __\ \   __  \ \  \    \ \   __  \  \ \    / / \ \    / / 
//  \ \  \|\  \ \  \ \  \ \  \____\ \  \ \  \  /     \/   \/  /  /  
//   \ \_______\ \__\ \__\ \_______\ \__\ \__\/  /\   \ __/  / /    
//    \|_______|\|__|\|__|\|_______|\|__|\|__/__/ /\ __\\___/ /     
//                                           |__|/ \|__\|___|/      
                                                                  
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./Ownable.sol";
import "./SafeMath.sol";
import "./IERC721Receiver.sol";
import "./Hammies.sol";
import "./Fluff.sol";

contract Galaxy is Ownable, IERC721Receiver {
    using SafeMath for uint256;
    
    //Establish interface for Hammies
    Hammies hammies;
    
    //Establish interface for $Fluff
    Fluff fluff;

    event HammieStolen(address previousOwner, address newOwner, uint256 tokenId);
    event HammieStaked(address owner, uint256 tokenId, uint256 status);
    event HammieClaimed(address owner, uint256 tokenId);
    
    //Maps tokenId to owner
    mapping(uint256 => address) public ownerById;
    /*Maps Status to tokenId
      Status is as follows:
        0 - Unstaked
        1 - Adventurer
        2 - Pirate
        3 - Salvager
    */
    mapping(uint256 => uint256) public statusById;
    //Maps tokenId to time staked
    mapping(uint256 => uint256) public timeStaked;
    //Amount of $Fluff stolen by Pirate while staked
    mapping(uint256 => uint256) public fluffStolen;
    
    //Daily $Fluff earned by adventurers
    uint256 public adventuringFluffRate = 100 ether;
    //Total number of adventurers staked
    uint256 public totalAdventurersStaked = 0;
    //Percent of $Fluff earned by adventurers that is kept
    uint256 public adventurerShare = 50;
    
    //Percent of $Fluff earned by adventurers that is stolen by pirates
    uint256 public pirateShare = 50;
    //5% chance a pirate gets lost each time it is unstaked
    uint256 public chancePirateGetsLost = 5;
    
    //Store tokenIds of all pirates staked
    uint256[] public piratesStaked;
    //Store tokenIds of all salvagers staked
    uint256[] public salvagersStaked;
    
    //1 day lock on staking
    uint256 public minStakeTime = 1 days;
    
    bool public staking = false;
    
    constructor(){}
    
    //-----------------------------------------------------------------------------//
    //------------------------------Staking----------------------------------------//
    //-----------------------------------------------------------------------------//
    
    /*sends any number of Hammies to the galaxy
        ids -> list of hammie ids to stake
        Status == 1 -> Adventurer
        Status == 2 -> Pirate
        Status == 3 -> Salvager
    */
    function sendManyToGalaxy(uint256[] calldata ids, uint256 status) external {
        for(uint256 i = 0; i < ids.length; i++){
            require(hammies.ownerOf(ids[i]) == msg.sender, "Not your Hammie");
            require(staking, "Staking is paused");

            statusById[ids[i]] = status;
            ownerById[ids[i]] = msg.sender;
            timeStaked[ids[i]] = block.timestamp;

            emit HammieStaked(msg.sender, ids[i], status);
            hammies.transferFrom(msg.sender, address(this), ids[i]);

            if (status == 1)
                totalAdventurersStaked++;
            else if (status == 2){
                piratesStaked.push(ids[i]);
            }
            else if (status == 3){
                salvagersStaked.push(ids[i]);
            }
        }
    }
    
    function unstakeManyHammies(uint256[] calldata ids) external {
        for(uint256 i = 0; i < ids.length; i++){
            require(ownerById[ids[i]] == msg.sender, "Not your Hammie");
            require(hammies.ownerOf(ids[i]) == address(this), "Hammie must be staked in order to claim");
            require(staking, "Staking is paused");
            require(block.timestamp - timeStaked[ids[i]]>= minStakeTime, "1 day stake lock");

            _claim(msg.sender, ids[i]);

            if (statusById[ids[i]] == 1){       
                totalAdventurersStaked--;
            }
            else if (statusById[ids[i]] == 2){
                for (uint256 j = 0; j < piratesStaked.length; j++){
                    if (piratesStaked[j] == ids[i]){
                        piratesStaked[j] = piratesStaked[piratesStaked.length-1];
                        piratesStaked.pop();
                    }
                }
                
            }
            else if (statusById[ids[i]] == 3){
                for (uint256 j = 0; j < salvagersStaked.length; j++){
                    if (salvagersStaked[j] == ids[i]){
                        salvagersStaked[j] = salvagersStaked[salvagersStaked.length-1];
                        salvagersStaked.pop();
                    }
                } 
            }

            emit HammieClaimed(address(this), ids[i]);
            hammies.safeTransferFrom(address(this), ownerById[ids[i]], ids[i]);
            statusById[ids[i]] = 0;
        }
    }

    function claimManyHammies(uint256[] calldata ids) external {
        for(uint256 i = 0; i < ids.length; i++){
            require(ownerById[ids[i]] == msg.sender, "Not your hammie");
            require(hammies.ownerOf(ids[i]) == address(this), "Hammie must be staked in order to claim");
            require(staking, "Staking is paused");
            
            _claim(msg.sender, ids[i]);
            emit HammieClaimed(address(this), ids[i]);
        }
    }
    
    function _claim(address owner, uint256 tokenId) internal {
        if (statusById[tokenId] == 1){
            if(piratesStaked.length > 0){
                fluff.mint(owner, getPendingFluff(tokenId).mul(adventurerShare).div(100));
                distributeAmongstPirates(getPendingFluff(tokenId).mul(pirateShare).div(100));
            }
            else {
                fluff.mint(owner, getPendingFluff(tokenId));
            }            
        }
        else if (statusById[tokenId] == 2){
            uint256 roll = randomIntInRange(tokenId, 100);
            if(roll > chancePirateGetsLost || salvagersStaked.length == 0){
                fluff.mint(owner, fluffStolen[tokenId]);
                fluffStolen[tokenId] = 0;
            } else{
                getNewOwnerForPirate(roll, tokenId);
            }
        }
        timeStaked[tokenId] = block.timestamp;
    }
    
    //Passive earning of $Fluff, 100 $Fluff per day
    function getPendingFluff(uint256 id) internal view returns(uint256) {
        return (block.timestamp - timeStaked[id]) * 100 ether / 1 days;
    }
    
    //Distribute stolen $Fluff accross all staked pirates
    function distributeAmongstPirates(uint256 amount) internal {
        for(uint256 i = 0; i < piratesStaked.length; i++){
            fluffStolen[piratesStaked[i]] += amount.div(piratesStaked.length);
        }
    }
    
    //Returns a pseudo-random integer between 0 - max
    function randomIntInRange(uint256 seed, uint256 max) internal view returns (uint256) {
        return uint256(keccak256(abi.encodePacked(
            tx.origin,
            blockhash(block.number - 1),
            block.timestamp,
            seed
        ))) % max;
    }
    
    
    //Return new owner of lost pirate from current salvagers
    function getNewOwnerForPirate(uint256 seed, uint256 tokenId) internal{
        uint256 roll = randomIntInRange(seed, salvagersStaked.length);
        emit HammieStolen(ownerById[tokenId], ownerById[salvagersStaked[roll]], tokenId);
        ownerById[tokenId] = ownerById[salvagersStaked[roll]];
        fluff.mint(ownerById[tokenId], fluffStolen[tokenId]);
        fluffStolen[tokenId] = 0;
    }
      
    function getTotalSalvagersStaked() public view returns (uint256) {
        return salvagersStaked.length;
    }

    function getTotalPiratesStaked() public view returns (uint256) {
        return piratesStaked.length;
    }

    //Set address for Hammies
    function setHammieAddress(address hammieAddr) external onlyOwner {
        hammies = Hammies(hammieAddr);
    }
    
    //Set address for $Fluff
    function setFluffAddress(address fluffAddr) external onlyOwner {
        fluff = Fluff(fluffAddr);
    }
    
    //Start/Stop staking
    function toggleStaking() public onlyOwner {
        staking = !staking;
    }

    function onERC721Received(
        address,
        address,
        uint256,
        bytes calldata
    ) external pure override returns (bytes4) {
      return IERC721Receiver.onERC721Received.selector;
    }
}

File 2 of 21: Address.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     */
    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 Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionDelegateCall(target, data, "Address: low-level delegate call failed");
    }

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

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

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

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

File 3 of 21: Context.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

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

File 4 of 21: Counters.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

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

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

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

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

File 5 of 21: ERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IERC165.sol";

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

File 6 of 21: ERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IERC20.sol";
import "./IERC20Metadata.sol";
import "./Context.sol";

/**
 * @dev Implementation of the {IERC20} interface.
 *
 * This implementation is agnostic to the way tokens are created. This means
 * that a supply mechanism has to be added in a derived contract using {_mint}.
 * For a generic mechanism see {ERC20PresetMinterPauser}.
 *
 * TIP: For a detailed writeup see our guide
 * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How
 * to implement supply mechanisms].
 *
 * We have followed general OpenZeppelin Contracts guidelines: functions revert
 * instead returning `false` on failure. This behavior is nonetheless
 * conventional and does not conflict with the expectations of ERC20
 * applications.
 *
 * Additionally, an {Approval} event is emitted on calls to {transferFrom}.
 * This allows applications to reconstruct the allowance for all accounts just
 * by listening to said events. Other implementations of the EIP may not emit
 * these events, as it isn't required by the specification.
 *
 * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}
 * functions have been added to mitigate the well-known issues around setting
 * allowances. See {IERC20-approve}.
 */
contract ERC20 is Context, IERC20, IERC20Metadata {
    mapping(address => uint256) private _balances;

    mapping(address => mapping(address => uint256)) private _allowances;

    uint256 private _totalSupply;

    string private _name;
    string private _symbol;

    /**
     * @dev Sets the values for {name} and {symbol}.
     *
     * The default value of {decimals} is 18. To select a different value for
     * {decimals} you should overload it.
     *
     * All two of these values are immutable: they can only be set once during
     * construction.
     */
    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @dev Returns the name of the token.
     */
    function name() public view virtual override returns (string memory) {
        return _name;
    }

    /**
     * @dev Returns the symbol of the token, usually a shorter version of the
     * name.
     */
    function symbol() public view virtual override returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns the number of decimals used to get its user representation.
     * For example, if `decimals` equals `2`, a balance of `505` tokens should
     * be displayed to a user as `5.05` (`505 / 10 ** 2`).
     *
     * Tokens usually opt for a value of 18, imitating the relationship between
     * Ether and Wei. This is the value {ERC20} uses, unless this function is
     * overridden;
     *
     * NOTE: This information is only used for _display_ purposes: it in
     * no way affects any of the arithmetic of the contract, including
     * {IERC20-balanceOf} and {IERC20-transfer}.
     */
    function decimals() public view virtual override returns (uint8) {
        return 18;
    }

    /**
     * @dev See {IERC20-totalSupply}.
     */
    function totalSupply() public view virtual override returns (uint256) {
        return _totalSupply;
    }

    /**
     * @dev See {IERC20-balanceOf}.
     */
    function balanceOf(address account) public view virtual override returns (uint256) {
        return _balances[account];
    }

    /**
     * @dev See {IERC20-transfer}.
     *
     * Requirements:
     *
     * - `recipient` cannot be the zero address.
     * - the caller must have a balance of at least `amount`.
     */
    function transfer(address recipient, uint256 amount) public virtual override returns (bool) {
        _transfer(_msgSender(), recipient, amount);
        return true;
    }

    /**
     * @dev See {IERC20-allowance}.
     */
    function allowance(address owner, address spender) public view virtual override returns (uint256) {
        return _allowances[owner][spender];
    }

    /**
     * @dev See {IERC20-approve}.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function approve(address spender, uint256 amount) public virtual override returns (bool) {
        _approve(_msgSender(), spender, amount);
        return true;
    }

    /**
     * @dev See {IERC20-transferFrom}.
     *
     * Emits an {Approval} event indicating the updated allowance. This is not
     * required by the EIP. See the note at the beginning of {ERC20}.
     *
     * Requirements:
     *
     * - `sender` and `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     * - the caller must have allowance for ``sender``'s tokens of at least
     * `amount`.
     */
    function transferFrom(
        address sender,
        address recipient,
        uint256 amount
    ) public virtual override returns (bool) {
        _transfer(sender, recipient, amount);

        uint256 currentAllowance = _allowances[sender][_msgSender()];
        require(currentAllowance >= amount, "ERC20: transfer amount exceeds allowance");
        unchecked {
            _approve(sender, _msgSender(), currentAllowance - amount);
        }

        return true;
    }

    /**
     * @dev Atomically increases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender] + addedValue);
        return true;
    }

    /**
     * @dev Atomically decreases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     * - `spender` must have allowance for the caller of at least
     * `subtractedValue`.
     */
    function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {
        uint256 currentAllowance = _allowances[_msgSender()][spender];
        require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero");
        unchecked {
            _approve(_msgSender(), spender, currentAllowance - subtractedValue);
        }

        return true;
    }

    /**
     * @dev Moves `amount` of tokens from `sender` to `recipient`.
     *
     * This internal function is equivalent to {transfer}, and can be used to
     * e.g. implement automatic token fees, slashing mechanisms, etc.
     *
     * Emits a {Transfer} event.
     *
     * Requirements:
     *
     * - `sender` cannot be the zero address.
     * - `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     */
    function _transfer(
        address sender,
        address recipient,
        uint256 amount
    ) internal virtual {
        require(sender != address(0), "ERC20: transfer from the zero address");
        require(recipient != address(0), "ERC20: transfer to the zero address");

        _beforeTokenTransfer(sender, recipient, amount);

        uint256 senderBalance = _balances[sender];
        require(senderBalance >= amount, "ERC20: transfer amount exceeds balance");
        unchecked {
            _balances[sender] = senderBalance - amount;
        }
        _balances[recipient] += amount;

        emit Transfer(sender, recipient, amount);

        _afterTokenTransfer(sender, recipient, amount);
    }

    /** @dev Creates `amount` tokens and assigns them to `account`, increasing
     * the total supply.
     *
     * Emits a {Transfer} event with `from` set to the zero address.
     *
     * Requirements:
     *
     * - `account` cannot be the zero address.
     */
    function _mint(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: mint to the zero address");

        _beforeTokenTransfer(address(0), account, amount);

        _totalSupply += amount;
        _balances[account] += amount;
        emit Transfer(address(0), account, amount);

        _afterTokenTransfer(address(0), account, amount);
    }

    /**
     * @dev Destroys `amount` tokens from `account`, reducing the
     * total supply.
     *
     * Emits a {Transfer} event with `to` set to the zero address.
     *
     * Requirements:
     *
     * - `account` cannot be the zero address.
     * - `account` must have at least `amount` tokens.
     */
    function _burn(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: burn from the zero address");

        _beforeTokenTransfer(account, address(0), amount);

        uint256 accountBalance = _balances[account];
        require(accountBalance >= amount, "ERC20: burn amount exceeds balance");
        unchecked {
            _balances[account] = accountBalance - amount;
        }
        _totalSupply -= amount;

        emit Transfer(account, address(0), amount);

        _afterTokenTransfer(account, address(0), amount);
    }

    /**
     * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.
     *
     * This internal function is equivalent to `approve`, and can be used to
     * e.g. set automatic allowances for certain subsystems, etc.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `owner` cannot be the zero address.
     * - `spender` cannot be the zero address.
     */
    function _approve(
        address owner,
        address spender,
        uint256 amount
    ) internal virtual {
        require(owner != address(0), "ERC20: approve from the zero address");
        require(spender != address(0), "ERC20: approve to the zero address");

        _allowances[owner][spender] = amount;
        emit Approval(owner, spender, amount);
    }

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

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

File 7 of 21: ERC721.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

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

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

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

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

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

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

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

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

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

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

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

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

    /**
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token");

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

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

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

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

        _approve(to, tokenId);
    }

    /**
     * @dev See {IERC721-getApproved}.
     */
    function getApproved(uint256 tokenId) public view virtual override returns (address) {
        require(_exists(tokenId), "ERC721: approved query for nonexistent token");

        return _tokenApprovals[tokenId];
    }

    /**
     * @dev See {IERC721-setApprovalForAll}.
     */
    function setApprovalForAll(address operator, bool approved) public virtual override {
        require(operator != _msgSender(), "ERC721: approve to caller");

        _operatorApprovals[_msgSender()][operator] = approved;
        emit ApprovalForAll(_msgSender(), operator, approved);
    }

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

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

        _transfer(from, to, tokenId);
    }

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        _beforeTokenTransfer(from, to, tokenId);

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

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

        emit Transfer(from, to, tokenId);
    }

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

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

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

File 8 of 21: ERC721Burnable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./ERC721.sol";
import "./Context.sol";

/**
 * @title ERC721 Burnable Token
 * @dev ERC721 Token that can be irreversibly burned (destroyed).
 */
abstract contract ERC721Burnable is Context, ERC721 {
    /**
     * @dev Burns `tokenId`. See {ERC721-_burn}.
     *
     * Requirements:
     *
     * - The caller must own `tokenId` or be an approved operator.
     */
    function burn(uint256 tokenId) public virtual {
        //solhint-disable-next-line max-line-length
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721Burnable: caller is not owner nor approved");
        _burn(tokenId);
    }
}

File 9 of 21: ERC721Enumerable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./ERC721.sol";
import "./IERC721Enumerable.sol";

/**
 * @dev This implements an optional extension of {ERC721} defined in the EIP that adds
 * enumerability of all the token ids in the contract as well as all token ids owned by each
 * account.
 */
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable {
    // Mapping from owner to list of owned token IDs
    mapping(address => mapping(uint256 => uint256)) private _ownedTokens;

    // Mapping from token ID to index of the owner tokens list
    mapping(uint256 => uint256) private _ownedTokensIndex;

    // Array with all token ids, used for enumeration
    uint256[] private _allTokens;

    // Mapping from token id to position in the allTokens array
    mapping(uint256 => uint256) private _allTokensIndex;

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

    /**
     * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721.balanceOf(owner), "ERC721Enumerable: owner index out of bounds");
        return _ownedTokens[owner][index];
    }

    /**
     * @dev See {IERC721Enumerable-totalSupply}.
     */
    function totalSupply() public view virtual override returns (uint256) {
        return _allTokens.length;
    }

    /**
     * @dev See {IERC721Enumerable-tokenByIndex}.
     */
    function tokenByIndex(uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721Enumerable.totalSupply(), "ERC721Enumerable: global index out of bounds");
        return _allTokens[index];
    }

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

        if (from == address(0)) {
            _addTokenToAllTokensEnumeration(tokenId);
        } else if (from != to) {
            _removeTokenFromOwnerEnumeration(from, tokenId);
        }
        if (to == address(0)) {
            _removeTokenFromAllTokensEnumeration(tokenId);
        } else if (to != from) {
            _addTokenToOwnerEnumeration(to, tokenId);
        }
    }

    /**
     * @dev Private function to add a token to this extension's ownership-tracking data structures.
     * @param to address representing the new owner of the given token ID
     * @param tokenId uint256 ID of the token to be added to the tokens list of the given address
     */
    function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private {
        uint256 length = ERC721.balanceOf(to);
        _ownedTokens[to][length] = tokenId;
        _ownedTokensIndex[tokenId] = length;
    }

    /**
     * @dev Private function to add a token to this extension's token tracking data structures.
     * @param tokenId uint256 ID of the token to be added to the tokens list
     */
    function _addTokenToAllTokensEnumeration(uint256 tokenId) private {
        _allTokensIndex[tokenId] = _allTokens.length;
        _allTokens.push(tokenId);
    }

    /**
     * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that
     * while the token is not assigned a new owner, the `_ownedTokensIndex` mapping is _not_ updated: this allows for
     * gas optimizations e.g. when performing a transfer operation (avoiding double writes).
     * This has O(1) time complexity, but alters the order of the _ownedTokens array.
     * @param from address representing the previous owner of the given token ID
     * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address
     */
    function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private {
        // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = ERC721.balanceOf(from) - 1;
        uint256 tokenIndex = _ownedTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary
        if (tokenIndex != lastTokenIndex) {
            uint256 lastTokenId = _ownedTokens[from][lastTokenIndex];

            _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
            _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index
        }

        // This also deletes the contents at the last position of the array
        delete _ownedTokensIndex[tokenId];
        delete _ownedTokens[from][lastTokenIndex];
    }

    /**
     * @dev Private function to remove a token from this extension's token tracking data structures.
     * This has O(1) time complexity, but alters the order of the _allTokens array.
     * @param tokenId uint256 ID of the token to be removed from the tokens list
     */
    function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private {
        // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = _allTokens.length - 1;
        uint256 tokenIndex = _allTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so
        // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding
        // an 'if' statement (like in _removeTokenFromOwnerEnumeration)
        uint256 lastTokenId = _allTokens[lastTokenIndex];

        _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
        _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index

        // This also deletes the contents at the last position of the array
        delete _allTokensIndex[tokenId];
        _allTokens.pop();
    }
}

File 10 of 21: Fluff.sol
// ________ ___       ___  ___  ________ ________ 
//|\  _____\\  \     |\  \|\  \|\  _____\\  _____\
//\ \  \__/\ \  \    \ \  \\\  \ \  \__/\ \  \__/ 
// \ \   __\\ \  \    \ \  \\\  \ \   __\\ \   __\
//  \ \  \_| \ \  \____\ \  \\\  \ \  \_| \ \  \_|
//   \ \__\   \ \_______\ \_______\ \__\   \ \__\ 
//    \|__|    \|_______|\|_______|\|__|    \|__| 
                                                
                                                
                                                
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./ERC20.sol";
import "./Ownable.sol";

contract Fluff is ERC20, Ownable {
    address public hammieAddress;
    address public galaxyAddress;
    
    mapping(address => bool) public allowedAddresses;

    constructor() ERC20("Fluff", "FLF") {}
    
    function setHammieAddress(address hammieAddr) external onlyOwner {
        hammieAddress = hammieAddr;
    }
    
    function setGalaxyAddress(address galaxyAddr) external onlyOwner {
        galaxyAddress = galaxyAddr;
    }
    
    function burn(address user, uint256 amount) external {
        require(msg.sender == galaxyAddress || msg.sender == hammieAddress, "Address not authorized");
        _burn(user, amount);
    }
    
    function mint(address to, uint256 value) external {
        require(msg.sender == galaxyAddress || msg.sender == hammieAddress, "Address not authorized");
        _mint(to, value);
    }
}

File 11 of 21: Hammies.sol
// ___  ___  ________  _____ ______   _____ ______   ___  _______           ________  ________  _____ ______   _______      
//|\  \|\  \|\   __  \|\   _ \  _   \|\   _ \  _   \|\  \|\  ___ \         |\   ____\|\   __  \|\   _ \  _   \|\  ___ \     
//\ \  \\\  \ \  \|\  \ \  \\\__\ \  \ \  \\\__\ \  \ \  \ \   __/|        \ \  \___|\ \  \|\  \ \  \\\__\ \  \ \   __/|    
// \ \   __  \ \   __  \ \  \\|__| \  \ \  \\|__| \  \ \  \ \  \_|/__       \ \  \  __\ \   __  \ \  \\|__| \  \ \  \_|/__  
//  \ \  \ \  \ \  \ \  \ \  \    \ \  \ \  \    \ \  \ \  \ \  \_|\ \       \ \  \|\  \ \  \ \  \ \  \    \ \  \ \  \_|\ \ 
//   \ \__\ \__\ \__\ \__\ \__\    \ \__\ \__\    \ \__\ \__\ \_______\       \ \_______\ \__\ \__\ \__\    \ \__\ \_______\
//    \|__|\|__|\|__|\|__|\|__|     \|__|\|__|     \|__|\|__|\|_______|        \|_______|\|__|\|__|\|__|     \|__|\|_______|                                                                                                                                                                                                                           

// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./ERC721.sol";
import "./ERC721Enumerable.sol";
import "./Ownable.sol";
import "./SafeMath.sol";
import "./Counters.sol";
import "./Strings.sol";
import "./Fluff.sol";
import "./Galaxy.sol";

contract Hammies is ERC721Enumerable, Ownable {
    using SafeMath for uint256;
    using Counters for Counters.Counter;
    using Strings for uint256;
    
    Counters.Counter private _tokenIdTracker;

    Fluff fluff;
    
    uint256 public maxFreeSupply = 888;
    uint256 public constant maxPublicSupply = 4888;
    uint256 public constant maxTotalSupply = 8888;
    uint256 public constant mintPrice = 0.06 ether;
    uint256 public constant maxPerTx = 10;
    uint256 public constant maxFreePerWallet = 10;

    address public constant dev1Address = 0xcd2367Fcfbd8bf8eF87C98fC53Cc2EA27437f6EE;
    address public constant dev2Address = 0x2E824997ACE675F5BdB0d56121Aa04B2599BDa8B;

    bool mintActive = false;
    bool public fluffMinting = false;
    
    mapping(address => uint256) public freeMintsClaimed; //Track free mints claimed per wallet
    
    string public baseTokenURI;

    constructor() ERC721("Hammies", "HG") {}
    
    //-----------------------------------------------------------------------------//
    //------------------------------Mint Logic-------------------------------------//
    //-----------------------------------------------------------------------------//
    
    //Resume/pause Public Sale
    function toggleMint() public onlyOwner {
        mintActive = !mintActive;
    }

    //Public Mint
    function mint(uint256 _count) public payable {
        uint256 total = _totalSupply();
        require(mintActive, "Sale has not begun");
        require(total + _count <= maxPublicSupply, "No hammies left");
        require(_count <= maxPerTx, "10 max per tx");
        require(msg.value >= price(_count), "Not enough eth sent");

        for (uint256 i = 0; i < _count; i++) {
            _mintHammie(msg.sender);
        }
    }
    
    //Free Mint for first 888
    function freeMint(uint256 _count) public {
        uint256 total = _totalSupply();
        require(mintActive, "Public Sale is not active");
        require(total + _count <= maxFreeSupply, "No more free hammies");
        require(_count + freeMintsClaimed[msg.sender] <= maxFreePerWallet, "Only 10 free mints per wallet");
        require(_count <= maxPerTx, "10 max per tx");

        for (uint256 i = 0; i < _count; i++) {
            freeMintsClaimed[msg.sender]++;
            _mintHammie(msg.sender);
        }
    }
    
    //Public Mint until 4888
    function mintHammieForFluff() public {
        uint256 total = _totalSupply();
        require(total < maxTotalSupply, "No Hammies left");
        require(fluffMinting, "Minting with $fluff has not begun");
        fluff.burn(msg.sender, getFluffCost(total));
        _mintHammie(msg.sender);
    }
    
    function getFluffCost(uint256 totalSupply) internal pure returns (uint256 cost){
        if (totalSupply < 5888)
            return 100;
        else if (totalSupply < 6887)
            return 200;
        else if (totalSupply < 7887)
            return 400;
        else if (totalSupply < 8887)
            return 800;
    }
    
    //Mint Hammie
    function _mintHammie(address _to) private {
        uint id = _tokenIdTracker.current();
        _tokenIdTracker.increment();
        _safeMint(_to, id);
    }

    //Function to get price of minting a hammie
    function price(uint256 _count) public pure returns (uint256) {
        return mintPrice.mul(_count);
    }
    
    //-----------------------------------------------------------------------------//
    //---------------------------Admin & Internal Logic----------------------------//
    //-----------------------------------------------------------------------------//

    //Set address for $Fluff
    function setFluffAddress(address fluffAddr) external onlyOwner {
        fluff = Fluff(fluffAddr);
    }
    
    //Internal URI function
    function _baseURI() internal view virtual override returns (string memory) {
        return baseTokenURI;
    }

    //Start/Stop minting hammies for $fluff
    function toggleFluffMinting() public onlyOwner {
        fluffMinting = !fluffMinting;
    }
    
    //Set URI for metadata
    function setBaseURI(string memory baseURI) public onlyOwner {
        baseTokenURI = baseURI;
    }
    
    //Withdraw from contract
    function withdrawAll() public onlyOwner {
        uint256 balance = address(this).balance;
        uint256 dev1Share = balance.mul(50).div(100);
        uint256 dev2Share = balance.mul(50).div(100);

        require(balance > 0);
        _withdraw(dev1Address, dev1Share);
        _withdraw(dev2Address, dev2Share);
    }

    //Internal withdraw
    function _withdraw(address _address, uint256 _amount) private {
        (bool success, ) = _address.call{value: _amount}("");
        require(success, "Transfer failed.");
    }
    
    //Return total supply of hammies
    function _totalSupply() public view returns (uint) {
        return _tokenIdTracker.current();
    }
}

File 12 of 21: IERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

File 13 of 21: IERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

File 14 of 21: IERC20Metadata.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IERC20.sol";

/**
 * @dev Interface for the optional metadata functions from the ERC20 standard.
 *
 * _Available since v4.1._
 */
interface IERC20Metadata is IERC20 {
    /**
     * @dev Returns the name of the token.
     */
    function name() external view returns (string memory);

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

    /**
     * @dev Returns the decimals places of the token.
     */
    function decimals() external view returns (uint8);
}

File 15 of 21: IERC721.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IERC165.sol";

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

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

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

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

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

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

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

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

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

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

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

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

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

pragma solidity ^0.8.0;

import "./IERC721.sol";

/**
 * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Enumerable is IERC721 {
    /**
     * @dev Returns the total amount of tokens stored by the contract.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns a token ID owned by `owner` at a given `index` of its token list.
     * Use along with {balanceOf} to enumerate all of ``owner``'s tokens.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256 tokenId);

    /**
     * @dev Returns a token ID at a given `index` of all the tokens stored by the contract.
     * Use along with {totalSupply} to enumerate all tokens.
     */
    function tokenByIndex(uint256 index) external view returns (uint256);
}

File 17 of 21: IERC721Metadata.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IERC721.sol";

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

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

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

File 18 of 21: IERC721Receiver.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

File 19 of 21: Ownable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./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() {
        _setOwner(_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 {
        _setOwner(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");
        _setOwner(newOwner);
    }

    function _setOwner(address newOwner) private {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}

File 20 of 21: SafeMath.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

// CAUTION
// This version of SafeMath should only be used with Solidity 0.8 or later,
// because it relies on the compiler's built in overflow checks.

/**
 * @dev Wrappers over Solidity's arithmetic operations.
 *
 * NOTE: `SafeMath` is no longer needed starting with Solidity 0.8. The compiler
 * now has built in overflow checking.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            uint256 c = a + b;
            if (c < a) return (false, 0);
            return (true, c);
        }
    }

    /**
     * @dev Returns the substraction of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b > a) return (false, 0);
            return (true, a - b);
        }
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
            // benefit is lost if 'b' is also tested.
            // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
            if (a == 0) return (true, 0);
            uint256 c = a * b;
            if (c / a != b) return (false, 0);
            return (true, c);
        }
    }

    /**
     * @dev Returns the division of two unsigned integers, with a division by zero flag.
     *
     * _Available since v3.4._
     */
    function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b == 0) return (false, 0);
            return (true, a / b);
        }
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag.
     *
     * _Available since v3.4._
     */
    function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b == 0) return (false, 0);
            return (true, a % b);
        }
    }

    /**
     * @dev Returns the addition of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `+` operator.
     *
     * Requirements:
     *
     * - Addition cannot overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        return a + b;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b) internal pure returns (uint256) {
        return a - b;
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `*` operator.
     *
     * Requirements:
     *
     * - Multiplication cannot overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        return a * b;
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator.
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        return a / b;
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b) internal pure returns (uint256) {
        return a % b;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
     * overflow (when the result is negative).
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {trySub}.
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        unchecked {
            require(b <= a, errorMessage);
            return a - b;
        }
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting with custom message on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        unchecked {
            require(b > 0, errorMessage);
            return a / b;
        }
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting with custom message when dividing by zero.
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {tryMod}.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        unchecked {
            require(b > 0, errorMessage);
            return a % b;
        }
    }
}

File 21 of 21: Strings.sol
// SPDX-License-Identifier: MIT

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);
    }
}

Contract Security Audit

Contract ABI

[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"owner","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"HammieClaimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"owner","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"status","type":"uint256"}],"name":"HammieStaked","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":false,"internalType":"address","name":"newOwner","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"HammieStolen","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[],"name":"adventurerShare","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"adventuringFluffRate","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"chancePirateGetsLost","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"}],"name":"claimManyHammies","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"fluffStolen","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalPiratesStaked","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalSalvagersStaked","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minStakeTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC721Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"ownerById","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pirateShare","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"piratesStaked","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"salvagersStaked","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256","name":"status","type":"uint256"}],"name":"sendManyToGalaxy","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"fluffAddr","type":"address"}],"name":"setFluffAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"hammieAddr","type":"address"}],"name":"setHammieAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"staking","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"statusById","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"timeStaked","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"toggleStaking","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"totalAdventurersStaked","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"}],"name":"unstakeManyHammies","outputs":[],"stateMutability":"nonpayable","type":"function"}]

608060405268056bc75e2d63100000600755600060085560326009556032600a556005600b5562015180600e556000600f60006101000a81548160ff0219169083151502179055503480156200005457600080fd5b5062000075620000696200007b60201b60201c565b6200008360201b60201c565b62000147565b600033905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b612aa080620001576000396000f3fe608060405234801561001057600080fd5b50600436106101735760003560e01c80637c0bc781116100de578063b72a476c11610097578063dd4efd5e11610071578063dd4efd5e14610428578063eafad78614610458578063ed09199914610476578063f2fde38b1461049457610173565b8063b72a476c146103d2578063b7d32a7e146103f0578063d01634e61461040c57610173565b80637c0bc781146102ea5780638cd31eba1461031a5780638da5cb5b1461033857806397ca742514610356578063acd9a97a14610386578063acee66fa146103a257610173565b80633fce24be116101305780633fce24be1461023c5780634cf088d91461025857806357a39361146102765780636d04107f146102a6578063715018a6146102c2578063734cc73e146102cc57610173565b806303fff1a5146101785780630e2d2d6614610196578063150b7a02146101c65780631f7678ce146101f65780633b8105b3146102145780633cb7860a1461021e575b600080fd5b6101806104b0565b60405161018d9190612554565b60405180910390f35b6101b060048036038101906101ab919061219b565b6104bd565b6040516101bd9190612554565b60405180910390f35b6101e060048036038101906101db9190612066565b6104d5565b6040516101ed9190612459565b60405180910390f35b6101fe6104ea565b60405161020b9190612554565b60405180910390f35b61021c6104f0565b005b610226610598565b6040516102339190612554565b60405180910390f35b6102566004803603810190610251919061200c565b61059e565b005b61026061065e565b60405161026d919061243e565b60405180910390f35b610290600480360381019061028b919061219b565b610671565b60405161029d9190612554565b60405180910390f35b6102c060048036038101906102bb919061213b565b610695565b005b6102ca610acb565b005b6102d4610b53565b6040516102e19190612554565b60405180910390f35b61030460048036038101906102ff919061219b565b610b59565b6040516103119190612554565b60405180910390f35b610322610b7d565b60405161032f9190612554565b60405180910390f35b610340610b83565b60405161034d919061238c565b60405180910390f35b610370600480360381019061036b919061219b565b610bac565b60405161037d9190612554565b60405180910390f35b6103a0600480360381019061039b91906120ee565b610bc4565b005b6103bc60048036038101906103b7919061219b565b6112bd565b6040516103c99190612554565b60405180910390f35b6103da6112d5565b6040516103e79190612554565b60405180910390f35b61040a6004803603810190610405919061200c565b6112db565b005b610426600480360381019061042191906120ee565b61139b565b005b610442600480360381019061043d919061219b565b611670565b60405161044f919061238c565b60405180910390f35b6104606116a3565b60405161046d9190612554565b60405180910390f35b61047e6116b0565b60405161048b9190612554565b60405180910390f35b6104ae60048036038101906104a9919061200c565b6116b6565b005b6000600d80549050905090565b60046020528060005260406000206000915090505481565b600063150b7a0260e01b905095945050505050565b600e5481565b6104f86117ae565b73ffffffffffffffffffffffffffffffffffffffff16610516610b83565b73ffffffffffffffffffffffffffffffffffffffff161461056c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610563906124d4565b60405180910390fd5b600f60009054906101000a900460ff1615600f60006101000a81548160ff021916908315150217905550565b600b5481565b6105a66117ae565b73ffffffffffffffffffffffffffffffffffffffff166105c4610b83565b73ffffffffffffffffffffffffffffffffffffffff161461061a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610611906124d4565b60405180910390fd5b80600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b600f60009054906101000a900460ff1681565b600c818154811061068157600080fd5b906000526020600020016000915090505481565b60005b83839050811015610ac5573373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e86868581811061070b5761070a61287c565b5b905060200201356040518263ffffffff1660e01b815260040161072e9190612554565b60206040518083038186803b15801561074657600080fd5b505afa15801561075a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061077e9190612039565b73ffffffffffffffffffffffffffffffffffffffff16146107d4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107cb906124f4565b60405180910390fd5b600f60009054906101000a900460ff16610823576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161081a90612534565b60405180910390fd5b816004600086868581811061083b5761083a61287c565b5b90506020020135815260200190815260200160002081905550336003600086868581811061086c5761086b61287c565b5b90506020020135815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555042600560008686858181106108d7576108d661287c565b5b905060200201358152602001908152602001600020819055507fd1870f0937c3ab4a35b1bf5546a26de2e59f3a57312387c505bacf5e0b84c7d7338585848181106109255761092461287c565b5b905060200201358460405161093c93929190612407565b60405180910390a1600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166323b872dd33308787868181106109975761099661287c565b5b905060200201356040518463ffffffff1660e01b81526004016109bc939291906123a7565b600060405180830381600087803b1580156109d657600080fd5b505af11580156109ea573d6000803e3d6000fd5b505050506001821415610a145760086000815480929190610a0a9061273d565b9190505550610ab2565b6002821415610a6457600c848483818110610a3257610a3161287c565b5b905060200201359080600181540180825580915050600190039060005260206000200160009091909190915055610ab1565b6003821415610ab057600d848483818110610a8257610a8161287c565b5b9050602002013590806001815401808255809150506001900390600052602060002001600090919091909150555b5b5b8080610abd9061273d565b915050610698565b50505050565b610ad36117ae565b73ffffffffffffffffffffffffffffffffffffffff16610af1610b83565b73ffffffffffffffffffffffffffffffffffffffff1614610b47576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b3e906124d4565b60405180910390fd5b610b5160006117b6565b565b60085481565b600d8181548110610b6957600080fd5b906000526020600020016000915090505481565b600a5481565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60066020528060005260406000206000915090505481565b60005b828290508110156112b8573373ffffffffffffffffffffffffffffffffffffffff1660036000858585818110610c0057610bff61287c565b5b90506020020135815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c8c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c83906124f4565b60405180910390fd5b3073ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e858585818110610cf457610cf361287c565b5b905060200201356040518263ffffffff1660e01b8152600401610d179190612554565b60206040518083038186803b158015610d2f57600080fd5b505afa158015610d43573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d679190612039565b73ffffffffffffffffffffffffffffffffffffffff1614610dbd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610db490612514565b60405180910390fd5b600f60009054906101000a900460ff16610e0c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e0390612534565b60405180910390fd5b600e5460056000858585818110610e2657610e2561287c565b5b9050602002013581526020019081526020016000205442610e479190612661565b1015610e88576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e7f906124b4565b60405180910390fd5b610eab33848484818110610e9f57610e9e61287c565b5b9050602002013561187a565b600160046000858585818110610ec457610ec361287c565b5b905060200201358152602001908152602001600020541415610efd5760086000815480929190610ef390612713565b919050555061112b565b600260046000858585818110610f1657610f1561287c565b5b9050602002013581526020019081526020016000205414156110155760005b600c8054905081101561100f57838383818110610f5557610f5461287c565b5b90506020020135600c8281548110610f7057610f6f61287c565b5b90600052602060002001541415610ffc57600c6001600c80549050610f959190612661565b81548110610fa657610fa561287c565b5b9060005260206000200154600c8281548110610fc557610fc461287c565b5b9060005260206000200181905550600c805480610fe557610fe461284d565b5b600190038181906000526020600020016000905590555b80806110079061273d565b915050610f35565b5061112a565b60036004600085858581811061102e5761102d61287c565b5b9050602002013581526020019081526020016000205414156111295760005b600d805490508110156111275783838381811061106d5761106c61287c565b5b90506020020135600d82815481106110885761108761287c565b5b9060005260206000200154141561111457600d6001600d805490506110ad9190612661565b815481106110be576110bd61287c565b5b9060005260206000200154600d82815481106110dd576110dc61287c565b5b9060005260206000200181905550600d8054806110fd576110fc61284d565b5b600190038181906000526020600020016000905590555b808061111f9061273d565b91505061104d565b505b5b5b7f0e652fb4f68db397855aa6666e889095f74013ca459e996fc5752cb5687a0c46308484848181106111605761115f61287c565b5b905060200201356040516111759291906123de565b60405180910390a1600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342842e0e30600360008787878181106111d3576111d261287c565b5b90506020020135815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1686868681811061121c5761121b61287c565b5b905060200201356040518463ffffffff1660e01b8152600401611241939291906123a7565b600060405180830381600087803b15801561125b57600080fd5b505af115801561126f573d6000803e3d6000fd5b5050505060006004600085858581811061128c5761128b61287c565b5b9050602002013581526020019081526020016000208190555080806112b09061273d565b915050610bc7565b505050565b60056020528060005260406000206000915090505481565b60075481565b6112e36117ae565b73ffffffffffffffffffffffffffffffffffffffff16611301610b83565b73ffffffffffffffffffffffffffffffffffffffff1614611357576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161134e906124d4565b60405180910390fd5b80600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b60005b8282905081101561166b573373ffffffffffffffffffffffffffffffffffffffff16600360008585858181106113d7576113d661287c565b5b90506020020135815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614611463576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161145a90612474565b60405180910390fd5b3073ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e8585858181106114cb576114ca61287c565b5b905060200201356040518263ffffffff1660e01b81526004016114ee9190612554565b60206040518083038186803b15801561150657600080fd5b505afa15801561151a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061153e9190612039565b73ffffffffffffffffffffffffffffffffffffffff1614611594576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161158b90612514565b60405180910390fd5b600f60009054906101000a900460ff166115e3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016115da90612534565b60405180910390fd5b611606338484848181106115fa576115f961287c565b5b9050602002013561187a565b7f0e652fb4f68db397855aa6666e889095f74013ca459e996fc5752cb5687a0c463084848481811061163b5761163a61287c565b5b905060200201356040516116509291906123de565b60405180910390a180806116639061273d565b91505061139e565b505050565b60036020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000600c80549050905090565b60095481565b6116be6117ae565b73ffffffffffffffffffffffffffffffffffffffff166116dc610b83565b73ffffffffffffffffffffffffffffffffffffffff1614611732576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611729906124d4565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614156117a2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161179990612494565b60405180910390fd5b6117ab816117b6565b50565b600033905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b600160046000838152602001908152602001600020541415611a3c576000600c80549050111561199f57600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166340c10f198361191360646119056009546118f788611b6b565b611bb590919063ffffffff16565b611bcb90919063ffffffff16565b6040518363ffffffff1660e01b81526004016119309291906123de565b600060405180830381600087803b15801561194a57600080fd5b505af115801561195e573d6000803e3d6000fd5b5050505061199a6119956064611987600a5461197986611b6b565b611bb590919063ffffffff16565b611bcb90919063ffffffff16565b611be1565b611a37565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166340c10f19836119e784611b6b565b6040518363ffffffff1660e01b8152600401611a049291906123de565b600060405180830381600087803b158015611a1e57600080fd5b505af1158015611a32573d6000803e3d6000fd5b505050505b611b4f565b600260046000838152602001908152602001600020541415611b4e576000611a65826064611c67565b9050600b54811180611a7c57506000600d80549050145b15611b4157600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166340c10f198460066000868152602001908152602001600020546040518363ffffffff1660e01b8152600401611af19291906123de565b600060405180830381600087803b158015611b0b57600080fd5b505af1158015611b1f573d6000803e3d6000fd5b5050505060006006600084815260200190815260200160002081905550611b4c565b611b4b8183611cb9565b5b505b5b4260056000838152602001908152602001600020819055505050565b60006201518068056bc75e2d63100000600560008581526020019081526020016000205442611b9a9190612661565b611ba49190612607565b611bae91906125d6565b9050919050565b60008183611bc39190612607565b905092915050565b60008183611bd991906125d6565b905092915050565b60005b600c80549050811015611c6357611c09600c8054905083611bcb90919063ffffffff16565b60066000600c8481548110611c2157611c2061287c565b5b906000526020600020015481526020019081526020016000206000828254611c499190612580565b925050819055508080611c5b9061273d565b915050611be4565b5050565b60008132600143611c789190612661565b404286604051602001611c8e949392919061233e565b6040516020818303038152906040528051906020012060001c611cb191906127be565b905092915050565b6000611cca83600d80549050611c67565b90507ffea7d4730e615c31dd37a7ee6b52691abdb37b6fb4da2a28648e579933cf67486003600084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1660036000600d8581548110611d3957611d3861287c565b5b9060005260206000200154815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1684604051611d83939291906123a7565b60405180910390a160036000600d8381548110611da357611da261287c565b5b9060005260206000200154815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff166003600084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166340c10f196003600085815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1660066000868152602001908152602001600020546040518363ffffffff1660e01b8152600401611ed19291906123de565b600060405180830381600087803b158015611eeb57600080fd5b505af1158015611eff573d6000803e3d6000fd5b5050505060006006600084815260200190815260200160002081905550505050565b600081359050611f3081612a3c565b92915050565b600081519050611f4581612a3c565b92915050565b60008083601f840112611f6157611f606128b0565b5b8235905067ffffffffffffffff811115611f7e57611f7d6128ab565b5b602083019150836020820283011115611f9a57611f996128b5565b5b9250929050565b60008083601f840112611fb757611fb66128b0565b5b8235905067ffffffffffffffff811115611fd457611fd36128ab565b5b602083019150836001820283011115611ff057611fef6128b5565b5b9250929050565b60008135905061200681612a53565b92915050565b600060208284031215612022576120216128bf565b5b600061203084828501611f21565b91505092915050565b60006020828403121561204f5761204e6128bf565b5b600061205d84828501611f36565b91505092915050565b600080600080600060808688031215612082576120816128bf565b5b600061209088828901611f21565b95505060206120a188828901611f21565b94505060406120b288828901611ff7565b935050606086013567ffffffffffffffff8111156120d3576120d26128ba565b5b6120df88828901611fa1565b92509250509295509295909350565b60008060208385031215612105576121046128bf565b5b600083013567ffffffffffffffff811115612123576121226128ba565b5b61212f85828601611f4b565b92509250509250929050565b600080600060408486031215612154576121536128bf565b5b600084013567ffffffffffffffff811115612172576121716128ba565b5b61217e86828701611f4b565b9350935050602061219186828701611ff7565b9150509250925092565b6000602082840312156121b1576121b06128bf565b5b60006121bf84828501611ff7565b91505092915050565b6121d181612695565b82525050565b6121e86121e382612695565b612786565b82525050565b6121f7816126a7565b82525050565b61220e612209826126b3565b612798565b82525050565b61221d816126bd565b82525050565b6000612230600f8361256f565b915061223b826128d1565b602082019050919050565b600061225360268361256f565b915061225e826128fa565b604082019050919050565b600061227660108361256f565b915061228182612949565b602082019050919050565b600061229960208361256f565b91506122a482612972565b602082019050919050565b60006122bc600f8361256f565b91506122c78261299b565b602082019050919050565b60006122df60278361256f565b91506122ea826129c4565b604082019050919050565b600061230260118361256f565b915061230d82612a13565b602082019050919050565b61232181612709565b82525050565b61233861233382612709565b6127b4565b82525050565b600061234a82876121d7565b60148201915061235a82866121fd565b60208201915061236a8285612327565b60208201915061237a8284612327565b60208201915081905095945050505050565b60006020820190506123a160008301846121c8565b92915050565b60006060820190506123bc60008301866121c8565b6123c960208301856121c8565b6123d66040830184612318565b949350505050565b60006040820190506123f360008301856121c8565b6124006020830184612318565b9392505050565b600060608201905061241c60008301866121c8565b6124296020830185612318565b6124366040830184612318565b949350505050565b600060208201905061245360008301846121ee565b92915050565b600060208201905061246e6000830184612214565b92915050565b6000602082019050818103600083015261248d81612223565b9050919050565b600060208201905081810360008301526124ad81612246565b9050919050565b600060208201905081810360008301526124cd81612269565b9050919050565b600060208201905081810360008301526124ed8161228c565b9050919050565b6000602082019050818103600083015261250d816122af565b9050919050565b6000602082019050818103600083015261252d816122d2565b9050919050565b6000602082019050818103600083015261254d816122f5565b9050919050565b60006020820190506125696000830184612318565b92915050565b600082825260208201905092915050565b600061258b82612709565b915061259683612709565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff038211156125cb576125ca6127ef565b5b828201905092915050565b60006125e182612709565b91506125ec83612709565b9250826125fc576125fb61281e565b5b828204905092915050565b600061261282612709565b915061261d83612709565b9250817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615612656576126556127ef565b5b828202905092915050565b600061266c82612709565b915061267783612709565b92508282101561268a576126896127ef565b5b828203905092915050565b60006126a0826126e9565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b600061271e82612709565b91506000821415612732576127316127ef565b5b600182039050919050565b600061274882612709565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82141561277b5761277a6127ef565b5b600182019050919050565b6000612791826127a2565b9050919050565b6000819050919050565b60006127ad826128c4565b9050919050565b6000819050919050565b60006127c982612709565b91506127d483612709565b9250826127e4576127e361281e565b5b828206905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600080fd5b600080fd5b60008160601b9050919050565b7f4e6f7420796f75722068616d6d69650000000000000000000000000000000000600082015250565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b7f3120646179207374616b65206c6f636b00000000000000000000000000000000600082015250565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b7f4e6f7420796f75722048616d6d69650000000000000000000000000000000000600082015250565b7f48616d6d6965206d757374206265207374616b656420696e206f72646572207460008201527f6f20636c61696d00000000000000000000000000000000000000000000000000602082015250565b7f5374616b696e6720697320706175736564000000000000000000000000000000600082015250565b612a4581612695565b8114612a5057600080fd5b50565b612a5c81612709565b8114612a6757600080fd5b5056fea2646970667358221220f0d8ca80809f3615857851c483b8b8a856aba4f5e4252a076b18c7d8b5a12bc364736f6c63430008070033

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106101735760003560e01c80637c0bc781116100de578063b72a476c11610097578063dd4efd5e11610071578063dd4efd5e14610428578063eafad78614610458578063ed09199914610476578063f2fde38b1461049457610173565b8063b72a476c146103d2578063b7d32a7e146103f0578063d01634e61461040c57610173565b80637c0bc781146102ea5780638cd31eba1461031a5780638da5cb5b1461033857806397ca742514610356578063acd9a97a14610386578063acee66fa146103a257610173565b80633fce24be116101305780633fce24be1461023c5780634cf088d91461025857806357a39361146102765780636d04107f146102a6578063715018a6146102c2578063734cc73e146102cc57610173565b806303fff1a5146101785780630e2d2d6614610196578063150b7a02146101c65780631f7678ce146101f65780633b8105b3146102145780633cb7860a1461021e575b600080fd5b6101806104b0565b60405161018d9190612554565b60405180910390f35b6101b060048036038101906101ab919061219b565b6104bd565b6040516101bd9190612554565b60405180910390f35b6101e060048036038101906101db9190612066565b6104d5565b6040516101ed9190612459565b60405180910390f35b6101fe6104ea565b60405161020b9190612554565b60405180910390f35b61021c6104f0565b005b610226610598565b6040516102339190612554565b60405180910390f35b6102566004803603810190610251919061200c565b61059e565b005b61026061065e565b60405161026d919061243e565b60405180910390f35b610290600480360381019061028b919061219b565b610671565b60405161029d9190612554565b60405180910390f35b6102c060048036038101906102bb919061213b565b610695565b005b6102ca610acb565b005b6102d4610b53565b6040516102e19190612554565b60405180910390f35b61030460048036038101906102ff919061219b565b610b59565b6040516103119190612554565b60405180910390f35b610322610b7d565b60405161032f9190612554565b60405180910390f35b610340610b83565b60405161034d919061238c565b60405180910390f35b610370600480360381019061036b919061219b565b610bac565b60405161037d9190612554565b60405180910390f35b6103a0600480360381019061039b91906120ee565b610bc4565b005b6103bc60048036038101906103b7919061219b565b6112bd565b6040516103c99190612554565b60405180910390f35b6103da6112d5565b6040516103e79190612554565b60405180910390f35b61040a6004803603810190610405919061200c565b6112db565b005b610426600480360381019061042191906120ee565b61139b565b005b610442600480360381019061043d919061219b565b611670565b60405161044f919061238c565b60405180910390f35b6104606116a3565b60405161046d9190612554565b60405180910390f35b61047e6116b0565b60405161048b9190612554565b60405180910390f35b6104ae60048036038101906104a9919061200c565b6116b6565b005b6000600d80549050905090565b60046020528060005260406000206000915090505481565b600063150b7a0260e01b905095945050505050565b600e5481565b6104f86117ae565b73ffffffffffffffffffffffffffffffffffffffff16610516610b83565b73ffffffffffffffffffffffffffffffffffffffff161461056c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610563906124d4565b60405180910390fd5b600f60009054906101000a900460ff1615600f60006101000a81548160ff021916908315150217905550565b600b5481565b6105a66117ae565b73ffffffffffffffffffffffffffffffffffffffff166105c4610b83565b73ffffffffffffffffffffffffffffffffffffffff161461061a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610611906124d4565b60405180910390fd5b80600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b600f60009054906101000a900460ff1681565b600c818154811061068157600080fd5b906000526020600020016000915090505481565b60005b83839050811015610ac5573373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e86868581811061070b5761070a61287c565b5b905060200201356040518263ffffffff1660e01b815260040161072e9190612554565b60206040518083038186803b15801561074657600080fd5b505afa15801561075a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061077e9190612039565b73ffffffffffffffffffffffffffffffffffffffff16146107d4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107cb906124f4565b60405180910390fd5b600f60009054906101000a900460ff16610823576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161081a90612534565b60405180910390fd5b816004600086868581811061083b5761083a61287c565b5b90506020020135815260200190815260200160002081905550336003600086868581811061086c5761086b61287c565b5b90506020020135815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555042600560008686858181106108d7576108d661287c565b5b905060200201358152602001908152602001600020819055507fd1870f0937c3ab4a35b1bf5546a26de2e59f3a57312387c505bacf5e0b84c7d7338585848181106109255761092461287c565b5b905060200201358460405161093c93929190612407565b60405180910390a1600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166323b872dd33308787868181106109975761099661287c565b5b905060200201356040518463ffffffff1660e01b81526004016109bc939291906123a7565b600060405180830381600087803b1580156109d657600080fd5b505af11580156109ea573d6000803e3d6000fd5b505050506001821415610a145760086000815480929190610a0a9061273d565b9190505550610ab2565b6002821415610a6457600c848483818110610a3257610a3161287c565b5b905060200201359080600181540180825580915050600190039060005260206000200160009091909190915055610ab1565b6003821415610ab057600d848483818110610a8257610a8161287c565b5b9050602002013590806001815401808255809150506001900390600052602060002001600090919091909150555b5b5b8080610abd9061273d565b915050610698565b50505050565b610ad36117ae565b73ffffffffffffffffffffffffffffffffffffffff16610af1610b83565b73ffffffffffffffffffffffffffffffffffffffff1614610b47576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b3e906124d4565b60405180910390fd5b610b5160006117b6565b565b60085481565b600d8181548110610b6957600080fd5b906000526020600020016000915090505481565b600a5481565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60066020528060005260406000206000915090505481565b60005b828290508110156112b8573373ffffffffffffffffffffffffffffffffffffffff1660036000858585818110610c0057610bff61287c565b5b90506020020135815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614610c8c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c83906124f4565b60405180910390fd5b3073ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e858585818110610cf457610cf361287c565b5b905060200201356040518263ffffffff1660e01b8152600401610d179190612554565b60206040518083038186803b158015610d2f57600080fd5b505afa158015610d43573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d679190612039565b73ffffffffffffffffffffffffffffffffffffffff1614610dbd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610db490612514565b60405180910390fd5b600f60009054906101000a900460ff16610e0c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e0390612534565b60405180910390fd5b600e5460056000858585818110610e2657610e2561287c565b5b9050602002013581526020019081526020016000205442610e479190612661565b1015610e88576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e7f906124b4565b60405180910390fd5b610eab33848484818110610e9f57610e9e61287c565b5b9050602002013561187a565b600160046000858585818110610ec457610ec361287c565b5b905060200201358152602001908152602001600020541415610efd5760086000815480929190610ef390612713565b919050555061112b565b600260046000858585818110610f1657610f1561287c565b5b9050602002013581526020019081526020016000205414156110155760005b600c8054905081101561100f57838383818110610f5557610f5461287c565b5b90506020020135600c8281548110610f7057610f6f61287c565b5b90600052602060002001541415610ffc57600c6001600c80549050610f959190612661565b81548110610fa657610fa561287c565b5b9060005260206000200154600c8281548110610fc557610fc461287c565b5b9060005260206000200181905550600c805480610fe557610fe461284d565b5b600190038181906000526020600020016000905590555b80806110079061273d565b915050610f35565b5061112a565b60036004600085858581811061102e5761102d61287c565b5b9050602002013581526020019081526020016000205414156111295760005b600d805490508110156111275783838381811061106d5761106c61287c565b5b90506020020135600d82815481106110885761108761287c565b5b9060005260206000200154141561111457600d6001600d805490506110ad9190612661565b815481106110be576110bd61287c565b5b9060005260206000200154600d82815481106110dd576110dc61287c565b5b9060005260206000200181905550600d8054806110fd576110fc61284d565b5b600190038181906000526020600020016000905590555b808061111f9061273d565b91505061104d565b505b5b5b7f0e652fb4f68db397855aa6666e889095f74013ca459e996fc5752cb5687a0c46308484848181106111605761115f61287c565b5b905060200201356040516111759291906123de565b60405180910390a1600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342842e0e30600360008787878181106111d3576111d261287c565b5b90506020020135815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1686868681811061121c5761121b61287c565b5b905060200201356040518463ffffffff1660e01b8152600401611241939291906123a7565b600060405180830381600087803b15801561125b57600080fd5b505af115801561126f573d6000803e3d6000fd5b5050505060006004600085858581811061128c5761128b61287c565b5b9050602002013581526020019081526020016000208190555080806112b09061273d565b915050610bc7565b505050565b60056020528060005260406000206000915090505481565b60075481565b6112e36117ae565b73ffffffffffffffffffffffffffffffffffffffff16611301610b83565b73ffffffffffffffffffffffffffffffffffffffff1614611357576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161134e906124d4565b60405180910390fd5b80600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b60005b8282905081101561166b573373ffffffffffffffffffffffffffffffffffffffff16600360008585858181106113d7576113d661287c565b5b90506020020135815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614611463576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161145a90612474565b60405180910390fd5b3073ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e8585858181106114cb576114ca61287c565b5b905060200201356040518263ffffffff1660e01b81526004016114ee9190612554565b60206040518083038186803b15801561150657600080fd5b505afa15801561151a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061153e9190612039565b73ffffffffffffffffffffffffffffffffffffffff1614611594576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161158b90612514565b60405180910390fd5b600f60009054906101000a900460ff166115e3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016115da90612534565b60405180910390fd5b611606338484848181106115fa576115f961287c565b5b9050602002013561187a565b7f0e652fb4f68db397855aa6666e889095f74013ca459e996fc5752cb5687a0c463084848481811061163b5761163a61287c565b5b905060200201356040516116509291906123de565b60405180910390a180806116639061273d565b91505061139e565b505050565b60036020528060005260406000206000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000600c80549050905090565b60095481565b6116be6117ae565b73ffffffffffffffffffffffffffffffffffffffff166116dc610b83565b73ffffffffffffffffffffffffffffffffffffffff1614611732576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611729906124d4565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614156117a2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161179990612494565b60405180910390fd5b6117ab816117b6565b50565b600033905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b600160046000838152602001908152602001600020541415611a3c576000600c80549050111561199f57600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166340c10f198361191360646119056009546118f788611b6b565b611bb590919063ffffffff16565b611bcb90919063ffffffff16565b6040518363ffffffff1660e01b81526004016119309291906123de565b600060405180830381600087803b15801561194a57600080fd5b505af115801561195e573d6000803e3d6000fd5b5050505061199a6119956064611987600a5461197986611b6b565b611bb590919063ffffffff16565b611bcb90919063ffffffff16565b611be1565b611a37565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166340c10f19836119e784611b6b565b6040518363ffffffff1660e01b8152600401611a049291906123de565b600060405180830381600087803b158015611a1e57600080fd5b505af1158015611a32573d6000803e3d6000fd5b505050505b611b4f565b600260046000838152602001908152602001600020541415611b4e576000611a65826064611c67565b9050600b54811180611a7c57506000600d80549050145b15611b4157600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166340c10f198460066000868152602001908152602001600020546040518363ffffffff1660e01b8152600401611af19291906123de565b600060405180830381600087803b158015611b0b57600080fd5b505af1158015611b1f573d6000803e3d6000fd5b5050505060006006600084815260200190815260200160002081905550611b4c565b611b4b8183611cb9565b5b505b5b4260056000838152602001908152602001600020819055505050565b60006201518068056bc75e2d63100000600560008581526020019081526020016000205442611b9a9190612661565b611ba49190612607565b611bae91906125d6565b9050919050565b60008183611bc39190612607565b905092915050565b60008183611bd991906125d6565b905092915050565b60005b600c80549050811015611c6357611c09600c8054905083611bcb90919063ffffffff16565b60066000600c8481548110611c2157611c2061287c565b5b906000526020600020015481526020019081526020016000206000828254611c499190612580565b925050819055508080611c5b9061273d565b915050611be4565b5050565b60008132600143611c789190612661565b404286604051602001611c8e949392919061233e565b6040516020818303038152906040528051906020012060001c611cb191906127be565b905092915050565b6000611cca83600d80549050611c67565b90507ffea7d4730e615c31dd37a7ee6b52691abdb37b6fb4da2a28648e579933cf67486003600084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1660036000600d8581548110611d3957611d3861287c565b5b9060005260206000200154815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1684604051611d83939291906123a7565b60405180910390a160036000600d8381548110611da357611da261287c565b5b9060005260206000200154815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff166003600084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166340c10f196003600085815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1660066000868152602001908152602001600020546040518363ffffffff1660e01b8152600401611ed19291906123de565b600060405180830381600087803b158015611eeb57600080fd5b505af1158015611eff573d6000803e3d6000fd5b5050505060006006600084815260200190815260200160002081905550505050565b600081359050611f3081612a3c565b92915050565b600081519050611f4581612a3c565b92915050565b60008083601f840112611f6157611f606128b0565b5b8235905067ffffffffffffffff811115611f7e57611f7d6128ab565b5b602083019150836020820283011115611f9a57611f996128b5565b5b9250929050565b60008083601f840112611fb757611fb66128b0565b5b8235905067ffffffffffffffff811115611fd457611fd36128ab565b5b602083019150836001820283011115611ff057611fef6128b5565b5b9250929050565b60008135905061200681612a53565b92915050565b600060208284031215612022576120216128bf565b5b600061203084828501611f21565b91505092915050565b60006020828403121561204f5761204e6128bf565b5b600061205d84828501611f36565b91505092915050565b600080600080600060808688031215612082576120816128bf565b5b600061209088828901611f21565b95505060206120a188828901611f21565b94505060406120b288828901611ff7565b935050606086013567ffffffffffffffff8111156120d3576120d26128ba565b5b6120df88828901611fa1565b92509250509295509295909350565b60008060208385031215612105576121046128bf565b5b600083013567ffffffffffffffff811115612123576121226128ba565b5b61212f85828601611f4b565b92509250509250929050565b600080600060408486031215612154576121536128bf565b5b600084013567ffffffffffffffff811115612172576121716128ba565b5b61217e86828701611f4b565b9350935050602061219186828701611ff7565b9150509250925092565b6000602082840312156121b1576121b06128bf565b5b60006121bf84828501611ff7565b91505092915050565b6121d181612695565b82525050565b6121e86121e382612695565b612786565b82525050565b6121f7816126a7565b82525050565b61220e612209826126b3565b612798565b82525050565b61221d816126bd565b82525050565b6000612230600f8361256f565b915061223b826128d1565b602082019050919050565b600061225360268361256f565b915061225e826128fa565b604082019050919050565b600061227660108361256f565b915061228182612949565b602082019050919050565b600061229960208361256f565b91506122a482612972565b602082019050919050565b60006122bc600f8361256f565b91506122c78261299b565b602082019050919050565b60006122df60278361256f565b91506122ea826129c4565b604082019050919050565b600061230260118361256f565b915061230d82612a13565b602082019050919050565b61232181612709565b82525050565b61233861233382612709565b6127b4565b82525050565b600061234a82876121d7565b60148201915061235a82866121fd565b60208201915061236a8285612327565b60208201915061237a8284612327565b60208201915081905095945050505050565b60006020820190506123a160008301846121c8565b92915050565b60006060820190506123bc60008301866121c8565b6123c960208301856121c8565b6123d66040830184612318565b949350505050565b60006040820190506123f360008301856121c8565b6124006020830184612318565b9392505050565b600060608201905061241c60008301866121c8565b6124296020830185612318565b6124366040830184612318565b949350505050565b600060208201905061245360008301846121ee565b92915050565b600060208201905061246e6000830184612214565b92915050565b6000602082019050818103600083015261248d81612223565b9050919050565b600060208201905081810360008301526124ad81612246565b9050919050565b600060208201905081810360008301526124cd81612269565b9050919050565b600060208201905081810360008301526124ed8161228c565b9050919050565b6000602082019050818103600083015261250d816122af565b9050919050565b6000602082019050818103600083015261252d816122d2565b9050919050565b6000602082019050818103600083015261254d816122f5565b9050919050565b60006020820190506125696000830184612318565b92915050565b600082825260208201905092915050565b600061258b82612709565b915061259683612709565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff038211156125cb576125ca6127ef565b5b828201905092915050565b60006125e182612709565b91506125ec83612709565b9250826125fc576125fb61281e565b5b828204905092915050565b600061261282612709565b915061261d83612709565b9250817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615612656576126556127ef565b5b828202905092915050565b600061266c82612709565b915061267783612709565b92508282101561268a576126896127ef565b5b828203905092915050565b60006126a0826126e9565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b600061271e82612709565b91506000821415612732576127316127ef565b5b600182039050919050565b600061274882612709565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82141561277b5761277a6127ef565b5b600182019050919050565b6000612791826127a2565b9050919050565b6000819050919050565b60006127ad826128c4565b9050919050565b6000819050919050565b60006127c982612709565b91506127d483612709565b9250826127e4576127e361281e565b5b828206905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600080fd5b600080fd5b60008160601b9050919050565b7f4e6f7420796f75722068616d6d69650000000000000000000000000000000000600082015250565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b7f3120646179207374616b65206c6f636b00000000000000000000000000000000600082015250565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b7f4e6f7420796f75722048616d6d69650000000000000000000000000000000000600082015250565b7f48616d6d6965206d757374206265207374616b656420696e206f72646572207460008201527f6f20636c61696d00000000000000000000000000000000000000000000000000602082015250565b7f5374616b696e6720697320706175736564000000000000000000000000000000600082015250565b612a4581612695565b8114612a5057600080fd5b50565b612a5c81612709565b8114612a6757600080fd5b5056fea2646970667358221220f0d8ca80809f3615857851c483b8b8a856aba4f5e4252a076b18c7d8b5a12bc364736f6c63430008070033

Deployed Bytecode Sourcemap

805:7982:9:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7943:111;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;1453:45;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;8575:210;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2400:36;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;8492:77;;;:::i;:::-;;2155:39;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;8203:111;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;2447:27;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2248:30;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2967:796;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;1598:92:18;;;:::i;:::-;;1834:41:9;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2329:32;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;2058:31;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;966:85:18;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;1642:46:9;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;3773:1498;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;1538:45;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;1740:47;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;8353:104;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;5277:463;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;1255:44;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;8060:107;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;1940:35;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;1839:189:18;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;7943:111:9;7999:7;8025:15;:22;;;;8018:29;;7943:111;:::o;1453:45::-;;;;;;;;;;;;;;;;;:::o;8575:210::-;8714:6;8737:41;;;8730:48;;8575:210;;;;;;;:::o;2400:36::-;;;;:::o;8492:77::-;1189:12:18;:10;:12::i;:::-;1178:23;;:7;:5;:7::i;:::-;:23;;;1170:68;;;;;;;;;;;;:::i;:::-;;;;;;;;;8555:7:9::1;;;;;;;;;;;8554:8;8544:7;;:18;;;;;;;;;;;;;;;;;;8492:77::o:0;2155:39::-;;;;:::o;8203:111::-;1189:12:18;:10;:12::i;:::-;1178:23;;:7;:5;:7::i;:::-;:23;;;1170:68;;;;;;;;;;;;:::i;:::-;;;;;;;;;8296:10:9::1;8278:7;;:29;;;;;;;;;;;;;;;;;;8203:111:::0;:::o;2447:27::-;;;;;;;;;;;;;:::o;2248:30::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2967:796::-;3056:9;3052:705;3075:3;;:10;;3071:1;:14;3052:705;;;3140:10;3113:37;;:7;;;;;;;;;;;:15;;;3129:3;;3133:1;3129:6;;;;;;;:::i;:::-;;;;;;;;3113:23;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;:37;;;3105:65;;;;;;;;;;;;:::i;:::-;;;;;;;;;3192:7;;;;;;;;;;;3184:37;;;;;;;;;;;;:::i;:::-;;;;;;;;;3257:6;3236:10;:18;3247:3;;3251:1;3247:6;;;;;;;:::i;:::-;;;;;;;;3236:18;;;;;;;;;;;:27;;;;3297:10;3277:9;:17;3287:3;;3291:1;3287:6;;;;;;;:::i;:::-;;;;;;;;3277:17;;;;;;;;;;;;:30;;;;;;;;;;;;;;;;;;3342:15;3321:10;:18;3332:3;;3336:1;3332:6;;;;;;;:::i;:::-;;;;;;;;3321:18;;;;;;;;;;;:36;;;;3377:40;3390:10;3402:3;;3406:1;3402:6;;;;;;;:::i;:::-;;;;;;;;3410;3377:40;;;;;;;;:::i;:::-;;;;;;;;3431:7;;;;;;;;;;;:20;;;3452:10;3472:4;3479:3;;3483:1;3479:6;;;;;;;:::i;:::-;;;;;;;;3431:55;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3515:1;3505:6;:11;3501:246;;;3534:22;;:24;;;;;;;;;:::i;:::-;;;;;;3501:246;;;3591:1;3581:6;:11;3577:170;;;3611:13;3630:3;;3634:1;3630:6;;;;;;;:::i;:::-;;;;;;;;3611:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3577:170;;;3684:1;3674:6;:11;3670:77;;;3704:15;3725:3;;3729:1;3725:6;;;;;;;:::i;:::-;;;;;;;;3704:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3670:77;3577:170;3501:246;3087:3;;;;;:::i;:::-;;;;3052:705;;;;2967:796;;;:::o;1598:92:18:-;1189:12;:10;:12::i;:::-;1178:23;;:7;:5;:7::i;:::-;:23;;;1170:68;;;;;;;;;;;;:::i;:::-;;;;;;;;;1662:21:::1;1680:1;1662:9;:21::i;:::-;1598:92::o:0;1834:41:9:-;;;;:::o;2329:32::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2058:31::-;;;;:::o;966:85:18:-;1012:7;1038:6;;;;;;;;;;;1031:13;;966:85;:::o;1642:46:9:-;;;;;;;;;;;;;;;;;:::o;3773:1498::-;3848:9;3844:1421;3867:3;;:10;;3863:1;:14;3844:1421;;;3926:10;3905:31;;:9;:17;3915:3;;3919:1;3915:6;;;;;;;:::i;:::-;;;;;;;;3905:17;;;;;;;;;;;;;;;;;;;;;:31;;;3897:59;;;;;;;;;;;;:::i;:::-;;;;;;;;;4013:4;3978:40;;:7;;;;;;;;;;;:15;;;3994:3;;3998:1;3994:6;;;;;;;:::i;:::-;;;;;;;;3978:23;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;:40;;;3970:92;;;;;;;;;;;;:::i;:::-;;;;;;;;;4084:7;;;;;;;;;;;4076:37;;;;;;;;;;;;:::i;:::-;;;;;;;;;4174:12;;4153:10;:18;4164:3;;4168:1;4164:6;;;;;;;:::i;:::-;;;;;;;;4153:18;;;;;;;;;;;;4135:15;:36;;;;:::i;:::-;:51;;4127:80;;;;;;;;;;;;:::i;:::-;;;;;;;;;4222:26;4229:10;4241:3;;4245:1;4241:6;;;;;;;:::i;:::-;;;;;;;;4222;:26::i;:::-;4289:1;4267:10;:18;4278:3;;4282:1;4278:6;;;;;;;:::i;:::-;;;;;;;;4267:18;;;;;;;;;;;;:23;4263:820;;;4316:22;;:24;;;;;;;;;:::i;:::-;;;;;;4263:820;;;4399:1;4377:10;:18;4388:3;;4392:1;4388:6;;;;;;;:::i;:::-;;;;;;;;4377:18;;;;;;;;;;;;:23;4373:710;;;4424:9;4419:271;4443:13;:20;;;;4439:1;:24;4419:271;;;4515:3;;4519:1;4515:6;;;;;;;:::i;:::-;;;;;;;;4495:13;4509:1;4495:16;;;;;;;;:::i;:::-;;;;;;;;;;:26;4491:181;;;4567:13;4602:1;4581:13;:20;;;;:22;;;;:::i;:::-;4567:37;;;;;;;;:::i;:::-;;;;;;;;;;4548:13;4562:1;4548:16;;;;;;;;:::i;:::-;;;;;;;;;:56;;;;4630:13;:19;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;4491:181;4465:3;;;;;:::i;:::-;;;;4419:271;;;;4373:710;;;4765:1;4743:10;:18;4754:3;;4758:1;4754:6;;;;;;;:::i;:::-;;;;;;;;4743:18;;;;;;;;;;;;:23;4739:344;;;4790:9;4785:283;4809:15;:22;;;;4805:1;:26;4785:283;;;4885:3;;4889:1;4885:6;;;;;;;:::i;:::-;;;;;;;;4863:15;4879:1;4863:18;;;;;;;;:::i;:::-;;;;;;;;;;:28;4859:191;;;4939:15;4978:1;4955:15;:22;;;;:24;;;;:::i;:::-;4939:41;;;;;;;;:::i;:::-;;;;;;;;;;4918:15;4934:1;4918:18;;;;;;;;:::i;:::-;;;;;;;;;:62;;;;5006:15;:21;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;4859:191;4833:3;;;;;:::i;:::-;;;;4785:283;;;;4739:344;4373:710;4263:820;5102:36;5124:4;5131:3;;5135:1;5131:6;;;;;;;:::i;:::-;;;;;;;;5102:36;;;;;;;:::i;:::-;;;;;;;;5152:7;;;;;;;;;;;:24;;;5185:4;5192:9;:17;5202:3;;5206:1;5202:6;;;;;;;:::i;:::-;;;;;;;;5192:17;;;;;;;;;;;;;;;;;;;;;5211:3;;5215:1;5211:6;;;;;;;:::i;:::-;;;;;;;;5152:66;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5253:1;5232:10;:18;5243:3;;5247:1;5243:6;;;;;;;:::i;:::-;;;;;;;;5232:18;;;;;;;;;;;:22;;;;3879:3;;;;;:::i;:::-;;;;3844:1421;;;;3773:1498;;:::o;1538:45::-;;;;;;;;;;;;;;;;;:::o;1740:47::-;;;;:::o;8353:104::-;1189:12:18;:10;:12::i;:::-;1178:23;;:7;:5;:7::i;:::-;:23;;;1170:68;;;;;;;;;;;;:::i;:::-;;;;;;;;;8440:9:9::1;8426:5;;:24;;;;;;;;;;;;;;;;;;8353:104:::0;:::o;5277:463::-;5350:9;5346:388;5369:3;;:10;;5365:1;:14;5346:388;;;5428:10;5407:31;;:9;:17;5417:3;;5421:1;5417:6;;;;;;;:::i;:::-;;;;;;;;5407:17;;;;;;;;;;;;;;;;;;;;;:31;;;5399:59;;;;;;;;;;;;:::i;:::-;;;;;;;;;5515:4;5480:40;;:7;;;;;;;;;;;:15;;;5496:3;;5500:1;5496:6;;;;;;;:::i;:::-;;;;;;;;5480:23;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;:40;;;5472:92;;;;;;;;;;;;:::i;:::-;;;;;;;;;5586:7;;;;;;;;;;;5578:37;;;;;;;;;;;;:::i;:::-;;;;;;;;;5642:26;5649:10;5661:3;;5665:1;5661:6;;;;;;;:::i;:::-;;;;;;;;5642;:26::i;:::-;5687:36;5709:4;5716:3;;5720:1;5716:6;;;;;;;:::i;:::-;;;;;;;;5687:36;;;;;;;:::i;:::-;;;;;;;;5381:3;;;;;:::i;:::-;;;;5346:388;;;;5277:463;;:::o;1255:44::-;;;;;;;;;;;;;;;;;;;;;;:::o;8060:107::-;8114:7;8140:13;:20;;;;8133:27;;8060:107;:::o;1940:35::-;;;;:::o;1839:189:18:-;1189:12;:10;:12::i;:::-;1178:23;;:7;:5;:7::i;:::-;:23;;;1170:68;;;;;;;;;;;;:::i;:::-;;;;;;;;;1947:1:::1;1927:22;;:8;:22;;;;1919:73;;;;;;;;;;;;:::i;:::-;;;;;;;;;2002:19;2012:8;2002:9;:19::i;:::-;1839:189:::0;:::o;587:96:1:-;640:7;666:10;659:17;;587:96;:::o;2034:169:18:-;2089:16;2108:6;;;;;;;;;;;2089:25;;2133:8;2124:6;;:17;;;;;;;;;;;;;;;;;;2187:8;2156:40;;2177:8;2156:40;;;;;;;;;;;;2079:124;2034:169;:::o;5750:882:9:-;5844:1;5821:10;:19;5832:7;5821:19;;;;;;;;;;;;:24;5817:762;;;5886:1;5863:13;:20;;;;:24;5860:322;;;5906:5;;;;;;;;;;;:10;;;5917:5;5924:54;5974:3;5924:45;5953:15;;5924:24;5940:7;5924:15;:24::i;:::-;:28;;:45;;;;:::i;:::-;:49;;:54;;;;:::i;:::-;5906:73;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5997:76;6022:50;6068:3;6022:41;6051:11;;6022:24;6038:7;6022:15;:24::i;:::-;:28;;:41;;;;:::i;:::-;:45;;:50;;;;:::i;:::-;5997:24;:76::i;:::-;5860:322;;;6124:5;;;;;;;;;;;:10;;;6135:5;6142:24;6158:7;6142:15;:24::i;:::-;6124:43;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5860:322;5817:762;;;6245:1;6222:10;:19;6233:7;6222:19;;;;;;;;;;;;:24;6218:361;;;6261:12;6276:30;6293:7;6302:3;6276:16;:30::i;:::-;6261:45;;6330:20;;6323:4;:27;:58;;;;6380:1;6354:15;:22;;;;:27;6323:58;6320:249;;;6400:5;;;;;;;;;;;:10;;;6411:5;6418:11;:20;6430:7;6418:20;;;;;;;;;;;;6400:39;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6480:1;6457:11;:20;6469:7;6457:20;;;;;;;;;;;:24;;;;6320:249;;;6519:35;6540:4;6546:7;6519:20;:35::i;:::-;6320:249;6247:332;6218:361;5817:762;6610:15;6588:10;:19;6599:7;6588:19;;;;;;;;;;;:37;;;;5750:882;;:::o;6694:147::-;6753:7;6828:6;6816:9;6798:10;:14;6809:2;6798:14;;;;;;;;;;;;6780:15;:32;;;;:::i;:::-;6779:46;;;;:::i;:::-;:55;;;;:::i;:::-;6772:62;;6694:147;;;:::o;3382:96:19:-;3440:7;3470:1;3466;:5;;;;:::i;:::-;3459:12;;3382:96;;;;:::o;3767:::-;3825:7;3855:1;3851;:5;;;;:::i;:::-;3844:12;;3767:96;;;;:::o;6909:214:9:-;6982:9;6978:139;7001:13;:20;;;;6997:1;:24;6978:139;;;7074:32;7085:13;:20;;;;7074:6;:10;;:32;;;;:::i;:::-;7041:11;:29;7053:13;7067:1;7053:16;;;;;;;;:::i;:::-;;;;;;;;;;7041:29;;;;;;;;;;;;:65;;;;;;;:::i;:::-;;;;;;;;7023:3;;;;;:::i;:::-;;;;6978:139;;;;6909:214;:::o;7187:272::-;7263:7;7449:3;7337:9;7385:1;7370:12;:16;;;;:::i;:::-;7360:27;7401:15;7430:4;7307:137;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;7297:148;;;;;;7289:157;;:163;;;;:::i;:::-;7282:170;;7187:272;;;;:::o;7535:396::-;7614:12;7629:46;7646:4;7652:15;:22;;;;7629:16;:46::i;:::-;7614:61;;7690:75;7703:9;:18;7713:7;7703:18;;;;;;;;;;;;;;;;;;;;;7723:9;:32;7733:15;7749:4;7733:21;;;;;;;;:::i;:::-;;;;;;;;;;7723:32;;;;;;;;;;;;;;;;;;;;;7757:7;7690:75;;;;;;;;:::i;:::-;;;;;;;;7796:9;:32;7806:15;7822:4;7806:21;;;;;;;;:::i;:::-;;;;;;;;;;7796:32;;;;;;;;;;;;;;;;;;;;;7775:9;:18;7785:7;7775:18;;;;;;;;;;;;:53;;;;;;;;;;;;;;;;;;7838:5;;;;;;;;;;;:10;;;7849:9;:18;7859:7;7849:18;;;;;;;;;;;;;;;;;;;;;7869:11;:20;7881:7;7869:20;;;;;;;;;;;;7838:52;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7923:1;7900:11;:20;7912:7;7900:20;;;;;;;;;;;:24;;;;7604:327;7535:396;;:::o;7:139:21:-;53:5;91:6;78:20;69:29;;107:33;134:5;107:33;:::i;:::-;7:139;;;;:::o;152:143::-;209:5;240:6;234:13;225:22;;256:33;283:5;256:33;:::i;:::-;152:143;;;;:::o;318:568::-;391:8;401:6;451:3;444:4;436:6;432:17;428:27;418:122;;459:79;;:::i;:::-;418:122;572:6;559:20;549:30;;602:18;594:6;591:30;588:117;;;624:79;;:::i;:::-;588:117;738:4;730:6;726:17;714:29;;792:3;784:4;776:6;772:17;762:8;758:32;755:41;752:128;;;799:79;;:::i;:::-;752:128;318:568;;;;;:::o;905:552::-;962:8;972:6;1022:3;1015:4;1007:6;1003:17;999:27;989:122;;1030:79;;:::i;:::-;989:122;1143:6;1130:20;1120:30;;1173:18;1165:6;1162:30;1159:117;;;1195:79;;:::i;:::-;1159:117;1309:4;1301:6;1297:17;1285:29;;1363:3;1355:4;1347:6;1343:17;1333:8;1329:32;1326:41;1323:128;;;1370:79;;:::i;:::-;1323:128;905:552;;;;;:::o;1463:139::-;1509:5;1547:6;1534:20;1525:29;;1563:33;1590:5;1563:33;:::i;:::-;1463:139;;;;:::o;1608:329::-;1667:6;1716:2;1704:9;1695:7;1691:23;1687:32;1684:119;;;1722:79;;:::i;:::-;1684:119;1842:1;1867:53;1912:7;1903:6;1892:9;1888:22;1867:53;:::i;:::-;1857:63;;1813:117;1608:329;;;;:::o;1943:351::-;2013:6;2062:2;2050:9;2041:7;2037:23;2033:32;2030:119;;;2068:79;;:::i;:::-;2030:119;2188:1;2213:64;2269:7;2260:6;2249:9;2245:22;2213:64;:::i;:::-;2203:74;;2159:128;1943:351;;;;:::o;2300:963::-;2397:6;2405;2413;2421;2429;2478:3;2466:9;2457:7;2453:23;2449:33;2446:120;;;2485:79;;:::i;:::-;2446:120;2605:1;2630:53;2675:7;2666:6;2655:9;2651:22;2630:53;:::i;:::-;2620:63;;2576:117;2732:2;2758:53;2803:7;2794:6;2783:9;2779:22;2758:53;:::i;:::-;2748:63;;2703:118;2860:2;2886:53;2931:7;2922:6;2911:9;2907:22;2886:53;:::i;:::-;2876:63;;2831:118;3016:2;3005:9;3001:18;2988:32;3047:18;3039:6;3036:30;3033:117;;;3069:79;;:::i;:::-;3033:117;3182:64;3238:7;3229:6;3218:9;3214:22;3182:64;:::i;:::-;3164:82;;;;2959:297;2300:963;;;;;;;;:::o;3269:559::-;3355:6;3363;3412:2;3400:9;3391:7;3387:23;3383:32;3380:119;;;3418:79;;:::i;:::-;3380:119;3566:1;3555:9;3551:17;3538:31;3596:18;3588:6;3585:30;3582:117;;;3618:79;;:::i;:::-;3582:117;3731:80;3803:7;3794:6;3783:9;3779:22;3731:80;:::i;:::-;3713:98;;;;3509:312;3269:559;;;;;:::o;3834:704::-;3929:6;3937;3945;3994:2;3982:9;3973:7;3969:23;3965:32;3962:119;;;4000:79;;:::i;:::-;3962:119;4148:1;4137:9;4133:17;4120:31;4178:18;4170:6;4167:30;4164:117;;;4200:79;;:::i;:::-;4164:117;4313:80;4385:7;4376:6;4365:9;4361:22;4313:80;:::i;:::-;4295:98;;;;4091:312;4442:2;4468:53;4513:7;4504:6;4493:9;4489:22;4468:53;:::i;:::-;4458:63;;4413:118;3834:704;;;;;:::o;4544:329::-;4603:6;4652:2;4640:9;4631:7;4627:23;4623:32;4620:119;;;4658:79;;:::i;:::-;4620:119;4778:1;4803:53;4848:7;4839:6;4828:9;4824:22;4803:53;:::i;:::-;4793:63;;4749:117;4544:329;;;;:::o;4879:118::-;4966:24;4984:5;4966:24;:::i;:::-;4961:3;4954:37;4879:118;;:::o;5003:157::-;5108:45;5128:24;5146:5;5128:24;:::i;:::-;5108:45;:::i;:::-;5103:3;5096:58;5003:157;;:::o;5166:109::-;5247:21;5262:5;5247:21;:::i;:::-;5242:3;5235:34;5166:109;;:::o;5281:157::-;5386:45;5406:24;5424:5;5406:24;:::i;:::-;5386:45;:::i;:::-;5381:3;5374:58;5281:157;;:::o;5444:115::-;5529:23;5546:5;5529:23;:::i;:::-;5524:3;5517:36;5444:115;;:::o;5565:366::-;5707:3;5728:67;5792:2;5787:3;5728:67;:::i;:::-;5721:74;;5804:93;5893:3;5804:93;:::i;:::-;5922:2;5917:3;5913:12;5906:19;;5565:366;;;:::o;5937:::-;6079:3;6100:67;6164:2;6159:3;6100:67;:::i;:::-;6093:74;;6176:93;6265:3;6176:93;:::i;:::-;6294:2;6289:3;6285:12;6278:19;;5937:366;;;:::o;6309:::-;6451:3;6472:67;6536:2;6531:3;6472:67;:::i;:::-;6465:74;;6548:93;6637:3;6548:93;:::i;:::-;6666:2;6661:3;6657:12;6650:19;;6309:366;;;:::o;6681:::-;6823:3;6844:67;6908:2;6903:3;6844:67;:::i;:::-;6837:74;;6920:93;7009:3;6920:93;:::i;:::-;7038:2;7033:3;7029:12;7022:19;;6681:366;;;:::o;7053:::-;7195:3;7216:67;7280:2;7275:3;7216:67;:::i;:::-;7209:74;;7292:93;7381:3;7292:93;:::i;:::-;7410:2;7405:3;7401:12;7394:19;;7053:366;;;:::o;7425:::-;7567:3;7588:67;7652:2;7647:3;7588:67;:::i;:::-;7581:74;;7664:93;7753:3;7664:93;:::i;:::-;7782:2;7777:3;7773:12;7766:19;;7425:366;;;:::o;7797:::-;7939:3;7960:67;8024:2;8019:3;7960:67;:::i;:::-;7953:74;;8036:93;8125:3;8036:93;:::i;:::-;8154:2;8149:3;8145:12;8138:19;;7797:366;;;:::o;8169:118::-;8256:24;8274:5;8256:24;:::i;:::-;8251:3;8244:37;8169:118;;:::o;8293:157::-;8398:45;8418:24;8436:5;8418:24;:::i;:::-;8398:45;:::i;:::-;8393:3;8386:58;8293:157;;:::o;8456:679::-;8652:3;8667:75;8738:3;8729:6;8667:75;:::i;:::-;8767:2;8762:3;8758:12;8751:19;;8780:75;8851:3;8842:6;8780:75;:::i;:::-;8880:2;8875:3;8871:12;8864:19;;8893:75;8964:3;8955:6;8893:75;:::i;:::-;8993:2;8988:3;8984:12;8977:19;;9006:75;9077:3;9068:6;9006:75;:::i;:::-;9106:2;9101:3;9097:12;9090:19;;9126:3;9119:10;;8456:679;;;;;;;:::o;9141:222::-;9234:4;9272:2;9261:9;9257:18;9249:26;;9285:71;9353:1;9342:9;9338:17;9329:6;9285:71;:::i;:::-;9141:222;;;;:::o;9369:442::-;9518:4;9556:2;9545:9;9541:18;9533:26;;9569:71;9637:1;9626:9;9622:17;9613:6;9569:71;:::i;:::-;9650:72;9718:2;9707:9;9703:18;9694:6;9650:72;:::i;:::-;9732;9800:2;9789:9;9785:18;9776:6;9732:72;:::i;:::-;9369:442;;;;;;:::o;9817:332::-;9938:4;9976:2;9965:9;9961:18;9953:26;;9989:71;10057:1;10046:9;10042:17;10033:6;9989:71;:::i;:::-;10070:72;10138:2;10127:9;10123:18;10114:6;10070:72;:::i;:::-;9817:332;;;;;:::o;10155:442::-;10304:4;10342:2;10331:9;10327:18;10319:26;;10355:71;10423:1;10412:9;10408:17;10399:6;10355:71;:::i;:::-;10436:72;10504:2;10493:9;10489:18;10480:6;10436:72;:::i;:::-;10518;10586:2;10575:9;10571:18;10562:6;10518:72;:::i;:::-;10155:442;;;;;;:::o;10603:210::-;10690:4;10728:2;10717:9;10713:18;10705:26;;10741:65;10803:1;10792:9;10788:17;10779:6;10741:65;:::i;:::-;10603:210;;;;:::o;10819:218::-;10910:4;10948:2;10937:9;10933:18;10925:26;;10961:69;11027:1;11016:9;11012:17;11003:6;10961:69;:::i;:::-;10819:218;;;;:::o;11043:419::-;11209:4;11247:2;11236:9;11232:18;11224:26;;11296:9;11290:4;11286:20;11282:1;11271:9;11267:17;11260:47;11324:131;11450:4;11324:131;:::i;:::-;11316:139;;11043:419;;;:::o;11468:::-;11634:4;11672:2;11661:9;11657:18;11649:26;;11721:9;11715:4;11711:20;11707:1;11696:9;11692:17;11685:47;11749:131;11875:4;11749:131;:::i;:::-;11741:139;;11468:419;;;:::o;11893:::-;12059:4;12097:2;12086:9;12082:18;12074:26;;12146:9;12140:4;12136:20;12132:1;12121:9;12117:17;12110:47;12174:131;12300:4;12174:131;:::i;:::-;12166:139;;11893:419;;;:::o;12318:::-;12484:4;12522:2;12511:9;12507:18;12499:26;;12571:9;12565:4;12561:20;12557:1;12546:9;12542:17;12535:47;12599:131;12725:4;12599:131;:::i;:::-;12591:139;;12318:419;;;:::o;12743:::-;12909:4;12947:2;12936:9;12932:18;12924:26;;12996:9;12990:4;12986:20;12982:1;12971:9;12967:17;12960:47;13024:131;13150:4;13024:131;:::i;:::-;13016:139;;12743:419;;;:::o;13168:::-;13334:4;13372:2;13361:9;13357:18;13349:26;;13421:9;13415:4;13411:20;13407:1;13396:9;13392:17;13385:47;13449:131;13575:4;13449:131;:::i;:::-;13441:139;;13168:419;;;:::o;13593:::-;13759:4;13797:2;13786:9;13782:18;13774:26;;13846:9;13840:4;13836:20;13832:1;13821:9;13817:17;13810:47;13874:131;14000:4;13874:131;:::i;:::-;13866:139;;13593:419;;;:::o;14018:222::-;14111:4;14149:2;14138:9;14134:18;14126:26;;14162:71;14230:1;14219:9;14215:17;14206:6;14162:71;:::i;:::-;14018:222;;;;:::o;14327:169::-;14411:11;14445:6;14440:3;14433:19;14485:4;14480:3;14476:14;14461:29;;14327:169;;;;:::o;14502:305::-;14542:3;14561:20;14579:1;14561:20;:::i;:::-;14556:25;;14595:20;14613:1;14595:20;:::i;:::-;14590:25;;14749:1;14681:66;14677:74;14674:1;14671:81;14668:107;;;14755:18;;:::i;:::-;14668:107;14799:1;14796;14792:9;14785:16;;14502:305;;;;:::o;14813:185::-;14853:1;14870:20;14888:1;14870:20;:::i;:::-;14865:25;;14904:20;14922:1;14904:20;:::i;:::-;14899:25;;14943:1;14933:35;;14948:18;;:::i;:::-;14933:35;14990:1;14987;14983:9;14978:14;;14813:185;;;;:::o;15004:348::-;15044:7;15067:20;15085:1;15067:20;:::i;:::-;15062:25;;15101:20;15119:1;15101:20;:::i;:::-;15096:25;;15289:1;15221:66;15217:74;15214:1;15211:81;15206:1;15199:9;15192:17;15188:105;15185:131;;;15296:18;;:::i;:::-;15185:131;15344:1;15341;15337:9;15326:20;;15004:348;;;;:::o;15358:191::-;15398:4;15418:20;15436:1;15418:20;:::i;:::-;15413:25;;15452:20;15470:1;15452:20;:::i;:::-;15447:25;;15491:1;15488;15485:8;15482:34;;;15496:18;;:::i;:::-;15482:34;15541:1;15538;15534:9;15526:17;;15358:191;;;;:::o;15555:96::-;15592:7;15621:24;15639:5;15621:24;:::i;:::-;15610:35;;15555:96;;;:::o;15657:90::-;15691:7;15734:5;15727:13;15720:21;15709:32;;15657:90;;;:::o;15753:77::-;15790:7;15819:5;15808:16;;15753:77;;;:::o;15836:149::-;15872:7;15912:66;15905:5;15901:78;15890:89;;15836:149;;;:::o;15991:126::-;16028:7;16068:42;16061:5;16057:54;16046:65;;15991:126;;;:::o;16123:77::-;16160:7;16189:5;16178:16;;16123:77;;;:::o;16206:171::-;16245:3;16268:24;16286:5;16268:24;:::i;:::-;16259:33;;16314:4;16307:5;16304:15;16301:41;;;16322:18;;:::i;:::-;16301:41;16369:1;16362:5;16358:13;16351:20;;16206:171;;;:::o;16383:233::-;16422:3;16445:24;16463:5;16445:24;:::i;:::-;16436:33;;16491:66;16484:5;16481:77;16478:103;;;16561:18;;:::i;:::-;16478:103;16608:1;16601:5;16597:13;16590:20;;16383:233;;;:::o;16622:100::-;16661:7;16690:26;16710:5;16690:26;:::i;:::-;16679:37;;16622:100;;;:::o;16728:79::-;16767:7;16796:5;16785:16;;16728:79;;;:::o;16813:94::-;16852:7;16881:20;16895:5;16881:20;:::i;:::-;16870:31;;16813:94;;;:::o;16913:79::-;16952:7;16981:5;16970:16;;16913:79;;;:::o;16998:176::-;17030:1;17047:20;17065:1;17047:20;:::i;:::-;17042:25;;17081:20;17099:1;17081:20;:::i;:::-;17076:25;;17120:1;17110:35;;17125:18;;:::i;:::-;17110:35;17166:1;17163;17159:9;17154:14;;16998:176;;;;:::o;17180:180::-;17228:77;17225:1;17218:88;17325:4;17322:1;17315:15;17349:4;17346:1;17339:15;17366:180;17414:77;17411:1;17404:88;17511:4;17508:1;17501:15;17535:4;17532:1;17525:15;17552:180;17600:77;17597:1;17590:88;17697:4;17694:1;17687:15;17721:4;17718:1;17711:15;17738:180;17786:77;17783:1;17776:88;17883:4;17880:1;17873:15;17907:4;17904:1;17897:15;17924:117;18033:1;18030;18023:12;18047:117;18156:1;18153;18146:12;18170:117;18279:1;18276;18269:12;18293:117;18402:1;18399;18392:12;18416:117;18525:1;18522;18515:12;18539:94;18572:8;18620:5;18616:2;18612:14;18591:35;;18539:94;;;:::o;18639:165::-;18779:17;18775:1;18767:6;18763:14;18756:41;18639:165;:::o;18810:225::-;18950:34;18946:1;18938:6;18934:14;18927:58;19019:8;19014:2;19006:6;19002:15;18995:33;18810:225;:::o;19041:166::-;19181:18;19177:1;19169:6;19165:14;19158:42;19041:166;:::o;19213:182::-;19353:34;19349:1;19341:6;19337:14;19330:58;19213:182;:::o;19401:165::-;19541:17;19537:1;19529:6;19525:14;19518:41;19401:165;:::o;19572:226::-;19712:34;19708:1;19700:6;19696:14;19689:58;19781:9;19776:2;19768:6;19764:15;19757:34;19572:226;:::o;19804:167::-;19944:19;19940:1;19932:6;19928:14;19921:43;19804:167;:::o;19977:122::-;20050:24;20068:5;20050:24;:::i;:::-;20043:5;20040:35;20030:63;;20089:1;20086;20079:12;20030:63;19977:122;:::o;20105:::-;20178:24;20196:5;20178:24;:::i;:::-;20171:5;20168:35;20158:63;;20217:1;20214;20207:12;20158:63;20105:122;:::o

Swarm Source

ipfs://f0d8ca80809f3615857851c483b8b8a856aba4f5e4252a076b18c7d8b5a12bc3

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.