ETH Price: $3,633.00 (-6.69%)

Contract

0x08Fa9Adc51e4D45b5e1C72675abC74AD78d2b1a3
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Set Approval For...155910252022-09-22 19:39:23818 days ago1663875563IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.0004918210.54986295
Set Approval For...155730942022-09-20 7:06:11820 days ago1663657571IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000419779.00444971
Set Approval For...155730832022-09-20 7:03:59820 days ago1663657439IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000419919.00736938
Set Approval For...155730462022-09-20 6:56:35820 days ago1663656995IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000430239.22875595
Set Approval For...155730132022-09-20 6:49:47820 days ago1663656587IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.0004850710.40509402
Set Approval For...155730082022-09-20 6:48:47820 days ago1663656527IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000420469.01926827
Set Approval For...155654342022-09-19 5:18:47821 days ago1663564727IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000163453.50609535
Set Approval For...155654252022-09-19 5:16:59821 days ago1663564619IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000162583.48743787
Set Approval For...155654172022-09-19 5:15:23821 days ago1663564523IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000167873.60109785
Set Approval For...155654072022-09-19 5:13:23821 days ago1663564403IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000190174.07930187
Set Approval For...155611232022-09-18 14:47:59822 days ago1663512479IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000381148.17580689
Set Approval For...155606602022-09-18 13:14:11822 days ago1663506851IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.0001415.27748471
Set Approval For...155606602022-09-18 13:14:11822 days ago1663506851IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.0001415.27748471
Set Approval For...155606602022-09-18 13:14:11822 days ago1663506851IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000124734.6683316
Set Approval For...155606602022-09-18 13:14:11822 days ago1663506851IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000117094.38260251
Set Approval For...155606602022-09-18 13:14:11822 days ago1663506851IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000138715.19153012
Set Approval For...155606602022-09-18 13:14:11822 days ago1663506851IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000127974.78969416
Set Approval For...155606602022-09-18 13:14:11822 days ago1663506851IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000135345.06554197
Set Approval For...155606602022-09-18 13:14:11822 days ago1663506851IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000140855.27154376
Set Approval For...155606602022-09-18 13:14:11822 days ago1663506851IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000246035.27748471
Set Approval For...155580812022-09-18 4:33:35822 days ago1663475615IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000164693.5327854
Set Approval For...155580682022-09-18 4:30:59822 days ago1663475459IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000179283.84566278
Transfer From155578182022-09-18 3:40:47822 days ago1663472447IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000320933.58756778
Transfer From155577952022-09-18 3:36:11822 days ago1663472171IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000321213.68293745
Withdraw155574892022-09-18 2:34:47822 days ago1663468487IN
0x08Fa9Adc...D78d2b1a3
0 ETH0.000134694.40255107
View all transactions

Latest 2 internal transactions

Advanced mode:
Parent Transaction Hash Block
From
To
155574892022-09-18 2:34:47822 days ago1663468487
0x08Fa9Adc...D78d2b1a3
49.956 ETH
155479032022-09-16 18:17:47824 days ago1663352267
0x08Fa9Adc...D78d2b1a3
11.316 ETH
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
SpookyBirdsCandy

Compiler Version
v0.8.9+commit.e5eed63a

Optimization Enabled:
No with 200 runs

Other Settings:
default evmVersion
File 1 of 9 : SpookyBirdsCandy.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.9;

import "erc721a/contracts/extensions/ERC721AQueryable.sol";
import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/security/Pausable.sol";
import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol";

//import "hardhat/console.sol";

interface IZombieBirdContract {
    function mint(address to, uint qty) external returns (bool);
}

contract SpookyBirdsCandy is ERC721AQueryable, Ownable, Pausable {

    /**
     * Enums
     */

    enum Phase {
        NULL,
        PRE_SALE,
        PUBLIC_MINT
    }

    /**
     * Storage variables
     */

    uint public constant MAX_SUPPLY = 9_776;
    string public _myBaseURI;
    Phase public _currentPhase;
    bytes32 public _currentMerkleRoot;

    // Stage 1 - PRE_SALE
    uint public _presaleMintQty;
    mapping(address => bool) public _hasPresaleAddressSold;

    // Stage 2 - PUBLIC_MINT
    mapping(address => uint) public _publicMintAirDropAddressQty;

    IZombieBirdContract public _zombieBirdContract;
    bool public _hasZombieBirdContractSet;
    mapping(address => uint) public _addressZombieBirdBoughtTimes;
    mapping(address => mapping(uint => uint)) public _addressZombieBirdBoughtQtys;
    mapping(address => mapping(uint => uint)) public _addressZombieBirdBoughtTimestamps;
    mapping(address => mapping(uint => bool)) public _addressZombieBirdBoughtHasDistributed;

    /**
     * Events
     */

    event PreSaleMint(address indexed to, uint indexed timestamp);
    event PublicMintClaimAirdrop(address indexed to, uint indexed timestamp, uint qty);
    event ZombieBirdSaleBurnCandyTokenId(address indexed to, uint indexed timestamp, uint tokenId);
    event ZombieBirdSaleBurnCandy(address indexed to, uint indexed timestamp, uint qty);
    event ZombieBirdClaimed(address indexed to, uint indexed timestamp, uint qty);

    /**
     * Errors
     */

    // Global errors
    error NotCorrectPhase();
    error TotalSupplyHasReached();
    error NotAWhitelistedAddress();
    // Presale errors
    error PreSaleQtyHasReached();
    error PurchasedEtherMustBeCorrect();
    error CannotPurchaseMoreThan1Time();
    // Public mint errors
    error AddressesAndQtysLengthAreDifferent();
    error NoPublicMintAirdrop();
    // Zombie mint errors
    error CandyQtyMustNotBe0();
    error CandyQtyMustBeInMutiplyOf4();
    error CandyQtyMustBeLessOrEqualToBalance();
    error IsNotCandyOwner();
    error ZombieBirdAddressWasSetBefore();
    error ZombieBirdAddressWasNotYetSet();
    error NoZombieBirdCanBeClaimed();
    error UnableToMintZombieBird();

    /**
     * Constructor
     */

    constructor(string memory myBaseURI_) ERC721A("Spooky Birds Candy", "Candy") {
        _myBaseURI = myBaseURI_;
    }

    /**
     * Modifiers
     */

    modifier phaseRequired(Phase currentPhase_) {
        if (_currentPhase != currentPhase_) revert NotCorrectPhase();
        _;
    }

    /**
     * Openzeppelin functions
     */

    function pause() external onlyOwner {
        _pause();
    }

    function unpause() external onlyOwner {
        _unpause();
    }

    /**
     * ERC721A functions
     */

    function _beforeTokenTransfers(
        address from,
        address to,
        uint256 startTokenId,
        uint256 quantity
    ) internal whenNotPaused override{
        super._beforeTokenTransfers(from, to, startTokenId, quantity);
    }

    function _baseURI() internal view override returns (string memory) {
        return _myBaseURI;
    }

    function setBaseURI(string memory myBaseURI_) external onlyOwner {
        _myBaseURI = myBaseURI_;
    }

    /**
     * Customize functions - utility functions
     */

    function setPhase(Phase currentPhase_, bytes32 currentMerkleRoot_) external onlyOwner {
        _currentPhase = currentPhase_;
        _currentMerkleRoot = currentMerkleRoot_;
    }

    function mint(address to, uint256 qty) external onlyOwner {
        if ((totalSupply() + qty) > MAX_SUPPLY) revert TotalSupplyHasReached();
        _safeMint(to, qty);
    }

    function burn(uint256 tokenId) external onlyOwner {
        _burn(tokenId);
    }

    function withdraw() external onlyOwner {
        payable(owner()).transfer(address(this).balance);
    }

    function getCurrentBlockTimestamp() external view returns (uint) {
        return block.timestamp;
    }

    /**
     * 154_312 Gas unit per function call
     * At 1584.25 usd/eth, 5.13 USD per call (May not be accurate)
     *
     * Customize functions - PRE_SALE functions
     * 1 - Allow 222 different whitelisted addresses to buy candy.
     * 2 - Every address can only buy 4 candies with 0.276 Ether in 1 purchase.
     */

    function presaleMint(bytes32[] calldata proof_) external payable phaseRequired(Phase.PRE_SALE) {
        if (!MerkleProof.verify(proof_, _currentMerkleRoot, keccak256(abi.encodePacked(msg.sender)))) revert NotAWhitelistedAddress();
        if (totalSupply() >= MAX_SUPPLY) revert TotalSupplyHasReached();
        // While testing, comment the next line and use this line => if (_presaleMintQty >= 4) revert PreSaleClosed();
        if (_presaleMintQty >= 888) revert PreSaleQtyHasReached();
        if (msg.value != 0.276 ether) revert PurchasedEtherMustBeCorrect();
        if (_hasPresaleAddressSold[msg.sender]) revert CannotPurchaseMoreThan1Time();
        {
            unchecked{_presaleMintQty = _presaleMintQty + 4;} // Save gas
        }
        _hasPresaleAddressSold[msg.sender] = true;
        _safeMint(msg.sender, 4);
        emit PreSaleMint(msg.sender, block.timestamp);
    }

    /**
     * 2_990_931 Gas unit per function call by passing in 128 addresses
     * At 1736.29 usd/eth, 105.63 USD per call
     * 8_888 Airdrop = 8_888 / 128 = 69.4375 which is at least 70 times
     * Recommendation: Call this function 70 times, every time 128 addresses
     * Estimate total cost: 70 * 105.63 = 7394.1 USD for 8888 airdrops (May not be accurate)  (See 11_calculateGas.ts)
     *
     * Customize functions - PUBLIC_MINT functions
     * 1 - Admin airdrops candy(s) to different whitelisted addresses. (Could be more than 1 time)
     * 2 - User claims his airdropped candy(s). (Could be more than 1 time)
     */

    function publicMintAirDrop(address[] calldata addresses_, uint[] calldata qtys_) external onlyOwner phaseRequired(Phase.PUBLIC_MINT) {
        uint addressLength = addresses_.length; // Save gas

        if (addressLength != qtys_.length) revert AddressesAndQtysLengthAreDifferent();
        for (uint i = 0; i < addressLength;) {
            _publicMintAirDropAddressQty[addresses_[i]] = qtys_[i];
            {
            unchecked{++i;} // Save gas
            }
        }
    }

    function publicMint(bytes32[] calldata proof_) external phaseRequired(Phase.PUBLIC_MINT) {
        if (!MerkleProof.verify(proof_, _currentMerkleRoot, keccak256(abi.encodePacked(msg.sender)))) revert NotAWhitelistedAddress();
        if (_publicMintAirDropAddressQty[msg.sender] == 0) revert NoPublicMintAirdrop();
        uint airDropAddressQty = _publicMintAirDropAddressQty[msg.sender]; // Save gas
        _publicMintAirDropAddressQty[msg.sender] = 0;
        _safeMint(msg.sender, airDropAddressQty);
        emit PublicMintClaimAirdrop(msg.sender, block.timestamp, airDropAddressQty);
    }

    /**
     * 2_896_956 Gas unit per function call by passing in maximum 88 tokenIds
     * At 1736.29 usd/eth, 105.63 USD per call (May not be accurate)
     * Recommendation: Call this function with maximum 88 tokenIds (See 11_calculateGas.ts)
     *
     * Customize functions - ZOMBIE_BIRD_MINT functions
     * 1 - User burns 4 candies to buy a zombie bird.
     * 2 - Admin need to set zombie bird address (Only can set once).
     * 3 - User claims his bought zombie bird after 30 days.
     */

    function burnCandyToMintZombieBird(uint[] calldata tokenIds_) external {
        uint length = tokenIds_.length; // Save gas
        if (length == 0) revert CandyQtyMustNotBe0();
        if (length % 4 != 0) revert CandyQtyMustBeInMutiplyOf4();
        if (length > balanceOf(msg.sender)) revert CandyQtyMustBeLessOrEqualToBalance();

        uint times = _addressZombieBirdBoughtTimes[msg.sender];
        _addressZombieBirdBoughtQtys[msg.sender][times] = length / 4;
        _addressZombieBirdBoughtTimestamps[msg.sender][times] = block.timestamp;
        {
        unchecked{++_addressZombieBirdBoughtTimes[msg.sender];} // Save gas
        }

        for (uint i = 0; i < length;) {
            uint tokenId = tokenIds_[i]; // Save gas
            if(ownerOf(tokenId) == msg.sender){
                _burn(tokenId);
            } else {
                revert IsNotCandyOwner();
            }
            emit ZombieBirdSaleBurnCandyTokenId(msg.sender, block.timestamp, tokenId);
            {
            unchecked{++i;} // Save gas
            }
        }

        emit ZombieBirdSaleBurnCandy(msg.sender, block.timestamp, length);
    }

    function setZombieBirdAddress(address address_) external onlyOwner {
        if (_hasZombieBirdContractSet) revert ZombieBirdAddressWasSetBefore();
        _zombieBirdContract = IZombieBirdContract(address_);
        _hasZombieBirdContractSet = true;
    }

    function mintZombieBird() external {
        if (!_hasZombieBirdContractSet) revert ZombieBirdAddressWasNotYetSet();
        uint times = _addressZombieBirdBoughtTimes[msg.sender];
        uint addressBoughtZombieBirdQty = 0;

        for (uint i = 0; i < times;) {
            uint addressBoughtTimestamp = _addressZombieBirdBoughtTimestamps[msg.sender][i];
            if (block.timestamp - addressBoughtTimestamp >= 2_592_000 && !_addressZombieBirdBoughtHasDistributed[msg.sender][i]) {
                addressBoughtZombieBirdQty = addressBoughtZombieBirdQty + _addressZombieBirdBoughtQtys[msg.sender][i];
                _addressZombieBirdBoughtHasDistributed[msg.sender][i] = true;
            }
            {
            unchecked{++i;} // Save gas
            }
        }

        if(addressBoughtZombieBirdQty == 0) revert NoZombieBirdCanBeClaimed(); // Need more or equal to 30 days
        //console.log("Qty minted", addressBoughtZombieBirdQty);
        bool canMint = _zombieBirdContract.mint(msg.sender, addressBoughtZombieBirdQty);
        if (!canMint) revert UnableToMintZombieBird();
        emit ZombieBirdClaimed(msg.sender, block.timestamp, addressBoughtZombieBirdQty);
    }
}

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

pragma solidity ^0.8.0;

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

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

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

    bool private _paused;

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

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

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

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

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

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

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

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

File 3 of 9 : ERC721AQueryable.sol
// SPDX-License-Identifier: MIT
// ERC721A Contracts v4.2.2
// Creator: Chiru Labs

pragma solidity ^0.8.4;

import './IERC721AQueryable.sol';
import '../ERC721A.sol';

/**
 * @title ERC721AQueryable.
 *
 * @dev ERC721A subclass with convenience query functions.
 */
abstract contract ERC721AQueryable is ERC721A, IERC721AQueryable {
    /**
     * @dev Returns the `TokenOwnership` struct at `tokenId` without reverting.
     *
     * If the `tokenId` is out of bounds:
     *
     * - `addr = address(0)`
     * - `startTimestamp = 0`
     * - `burned = false`
     * - `extraData = 0`
     *
     * If the `tokenId` is burned:
     *
     * - `addr = <Address of owner before token was burned>`
     * - `startTimestamp = <Timestamp when token was burned>`
     * - `burned = true`
     * - `extraData = <Extra data when token was burned>`
     *
     * Otherwise:
     *
     * - `addr = <Address of owner>`
     * - `startTimestamp = <Timestamp of start of ownership>`
     * - `burned = false`
     * - `extraData = <Extra data at start of ownership>`
     */
    function explicitOwnershipOf(uint256 tokenId) public view virtual override returns (TokenOwnership memory) {
        TokenOwnership memory ownership;
        if (tokenId < _startTokenId() || tokenId >= _nextTokenId()) {
            return ownership;
        }
        ownership = _ownershipAt(tokenId);
        if (ownership.burned) {
            return ownership;
        }
        return _ownershipOf(tokenId);
    }

    /**
     * @dev Returns an array of `TokenOwnership` structs at `tokenIds` in order.
     * See {ERC721AQueryable-explicitOwnershipOf}
     */
    function explicitOwnershipsOf(uint256[] calldata tokenIds)
        external
        view
        virtual
        override
        returns (TokenOwnership[] memory)
    {
        unchecked {
            uint256 tokenIdsLength = tokenIds.length;
            TokenOwnership[] memory ownerships = new TokenOwnership[](tokenIdsLength);
            for (uint256 i; i != tokenIdsLength; ++i) {
                ownerships[i] = explicitOwnershipOf(tokenIds[i]);
            }
            return ownerships;
        }
    }

    /**
     * @dev Returns an array of token IDs owned by `owner`,
     * in the range [`start`, `stop`)
     * (i.e. `start <= tokenId < stop`).
     *
     * This function allows for tokens to be queried if the collection
     * grows too big for a single call of {ERC721AQueryable-tokensOfOwner}.
     *
     * Requirements:
     *
     * - `start < stop`
     */
    function tokensOfOwnerIn(
        address owner,
        uint256 start,
        uint256 stop
    ) external view virtual override returns (uint256[] memory) {
        unchecked {
            if (start >= stop) revert InvalidQueryRange();
            uint256 tokenIdsIdx;
            uint256 stopLimit = _nextTokenId();
            // Set `start = max(start, _startTokenId())`.
            if (start < _startTokenId()) {
                start = _startTokenId();
            }
            // Set `stop = min(stop, stopLimit)`.
            if (stop > stopLimit) {
                stop = stopLimit;
            }
            uint256 tokenIdsMaxLength = balanceOf(owner);
            // Set `tokenIdsMaxLength = min(balanceOf(owner), stop - start)`,
            // to cater for cases where `balanceOf(owner)` is too big.
            if (start < stop) {
                uint256 rangeLength = stop - start;
                if (rangeLength < tokenIdsMaxLength) {
                    tokenIdsMaxLength = rangeLength;
                }
            } else {
                tokenIdsMaxLength = 0;
            }
            uint256[] memory tokenIds = new uint256[](tokenIdsMaxLength);
            if (tokenIdsMaxLength == 0) {
                return tokenIds;
            }
            // We need to call `explicitOwnershipOf(start)`,
            // because the slot at `start` may not be initialized.
            TokenOwnership memory ownership = explicitOwnershipOf(start);
            address currOwnershipAddr;
            // If the starting slot exists (i.e. not burned), initialize `currOwnershipAddr`.
            // `ownership.address` will not be zero, as `start` is clamped to the valid token ID range.
            if (!ownership.burned) {
                currOwnershipAddr = ownership.addr;
            }
            for (uint256 i = start; i != stop && tokenIdsIdx != tokenIdsMaxLength; ++i) {
                ownership = _ownershipAt(i);
                if (ownership.burned) {
                    continue;
                }
                if (ownership.addr != address(0)) {
                    currOwnershipAddr = ownership.addr;
                }
                if (currOwnershipAddr == owner) {
                    tokenIds[tokenIdsIdx++] = i;
                }
            }
            // Downsize the array to fit.
            assembly {
                mstore(tokenIds, tokenIdsIdx)
            }
            return tokenIds;
        }
    }

    /**
     * @dev Returns an array of token IDs owned by `owner`.
     *
     * This function scans the ownership mapping and is O(`totalSupply`) in complexity.
     * It is meant to be called off-chain.
     *
     * See {ERC721AQueryable-tokensOfOwnerIn} for splitting the scan into
     * multiple smaller scans if the collection is large enough to cause
     * an out-of-gas error (10K collections should be fine).
     */
    function tokensOfOwner(address owner) external view virtual override returns (uint256[] memory) {
        unchecked {
            uint256 tokenIdsIdx;
            address currOwnershipAddr;
            uint256 tokenIdsLength = balanceOf(owner);
            uint256[] memory tokenIds = new uint256[](tokenIdsLength);
            TokenOwnership memory ownership;
            for (uint256 i = _startTokenId(); tokenIdsIdx != tokenIdsLength; ++i) {
                ownership = _ownershipAt(i);
                if (ownership.burned) {
                    continue;
                }
                if (ownership.addr != address(0)) {
                    currOwnershipAddr = ownership.addr;
                }
                if (currOwnershipAddr == owner) {
                    tokenIds[tokenIdsIdx++] = i;
                }
            }
            return tokenIds;
        }
    }
}

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

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

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

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

File 5 of 9 : MerkleProof.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (utils/cryptography/MerkleProof.sol)

pragma solidity ^0.8.0;

/**
 * @dev These functions deal with verification of Merkle Tree proofs.
 *
 * The proofs can be generated using the JavaScript library
 * https://github.com/miguelmota/merkletreejs[merkletreejs].
 * Note: the hashing algorithm should be keccak256 and pair sorting should be enabled.
 *
 * See `test/utils/cryptography/MerkleProof.test.js` for some examples.
 *
 * WARNING: You should avoid using leaf values that are 64 bytes long prior to
 * hashing, or use a hash function other than keccak256 for hashing leaves.
 * This is because the concatenation of a sorted pair of internal nodes in
 * the merkle tree could be reinterpreted as a leaf value.
 */
library MerkleProof {
    /**
     * @dev Returns true if a `leaf` can be proved to be a part of a Merkle tree
     * defined by `root`. For this, a `proof` must be provided, containing
     * sibling hashes on the branch from the leaf to the root of the tree. Each
     * pair of leaves and each pair of pre-images are assumed to be sorted.
     */
    function verify(
        bytes32[] memory proof,
        bytes32 root,
        bytes32 leaf
    ) internal pure returns (bool) {
        return processProof(proof, leaf) == root;
    }

    /**
     * @dev Calldata version of {verify}
     *
     * _Available since v4.7._
     */
    function verifyCalldata(
        bytes32[] calldata proof,
        bytes32 root,
        bytes32 leaf
    ) internal pure returns (bool) {
        return processProofCalldata(proof, leaf) == root;
    }

    /**
     * @dev Returns the rebuilt hash obtained by traversing a Merkle tree up
     * from `leaf` using `proof`. A `proof` is valid if and only if the rebuilt
     * hash matches the root of the tree. When processing the proof, the pairs
     * of leafs & pre-images are assumed to be sorted.
     *
     * _Available since v4.4._
     */
    function processProof(bytes32[] memory proof, bytes32 leaf) internal pure returns (bytes32) {
        bytes32 computedHash = leaf;
        for (uint256 i = 0; i < proof.length; i++) {
            computedHash = _hashPair(computedHash, proof[i]);
        }
        return computedHash;
    }

    /**
     * @dev Calldata version of {processProof}
     *
     * _Available since v4.7._
     */
    function processProofCalldata(bytes32[] calldata proof, bytes32 leaf) internal pure returns (bytes32) {
        bytes32 computedHash = leaf;
        for (uint256 i = 0; i < proof.length; i++) {
            computedHash = _hashPair(computedHash, proof[i]);
        }
        return computedHash;
    }

    /**
     * @dev Returns true if the `leaves` can be proved to be a part of a Merkle tree defined by
     * `root`, according to `proof` and `proofFlags` as described in {processMultiProof}.
     *
     * _Available since v4.7._
     */
    function multiProofVerify(
        bytes32[] memory proof,
        bool[] memory proofFlags,
        bytes32 root,
        bytes32[] memory leaves
    ) internal pure returns (bool) {
        return processMultiProof(proof, proofFlags, leaves) == root;
    }

    /**
     * @dev Calldata version of {multiProofVerify}
     *
     * _Available since v4.7._
     */
    function multiProofVerifyCalldata(
        bytes32[] calldata proof,
        bool[] calldata proofFlags,
        bytes32 root,
        bytes32[] memory leaves
    ) internal pure returns (bool) {
        return processMultiProofCalldata(proof, proofFlags, leaves) == root;
    }

    /**
     * @dev Returns the root of a tree reconstructed from `leaves` and the sibling nodes in `proof`,
     * consuming from one or the other at each step according to the instructions given by
     * `proofFlags`.
     *
     * _Available since v4.7._
     */
    function processMultiProof(
        bytes32[] memory proof,
        bool[] memory proofFlags,
        bytes32[] memory leaves
    ) internal pure returns (bytes32 merkleRoot) {
        // This function rebuild the root hash by traversing the tree up from the leaves. The root is rebuilt by
        // consuming and producing values on a queue. The queue starts with the `leaves` array, then goes onto the
        // `hashes` array. At the end of the process, the last hash in the `hashes` array should contain the root of
        // the merkle tree.
        uint256 leavesLen = leaves.length;
        uint256 totalHashes = proofFlags.length;

        // Check proof validity.
        require(leavesLen + proof.length - 1 == totalHashes, "MerkleProof: invalid multiproof");

        // The xxxPos values are "pointers" to the next value to consume in each array. All accesses are done using
        // `xxx[xxxPos++]`, which return the current value and increment the pointer, thus mimicking a queue's "pop".
        bytes32[] memory hashes = new bytes32[](totalHashes);
        uint256 leafPos = 0;
        uint256 hashPos = 0;
        uint256 proofPos = 0;
        // At each step, we compute the next hash using two values:
        // - a value from the "main queue". If not all leaves have been consumed, we get the next leaf, otherwise we
        //   get the next hash.
        // - depending on the flag, either another value for the "main queue" (merging branches) or an element from the
        //   `proof` array.
        for (uint256 i = 0; i < totalHashes; i++) {
            bytes32 a = leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++];
            bytes32 b = proofFlags[i] ? leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++] : proof[proofPos++];
            hashes[i] = _hashPair(a, b);
        }

        if (totalHashes > 0) {
            return hashes[totalHashes - 1];
        } else if (leavesLen > 0) {
            return leaves[0];
        } else {
            return proof[0];
        }
    }

    /**
     * @dev Calldata version of {processMultiProof}
     *
     * _Available since v4.7._
     */
    function processMultiProofCalldata(
        bytes32[] calldata proof,
        bool[] calldata proofFlags,
        bytes32[] memory leaves
    ) internal pure returns (bytes32 merkleRoot) {
        // This function rebuild the root hash by traversing the tree up from the leaves. The root is rebuilt by
        // consuming and producing values on a queue. The queue starts with the `leaves` array, then goes onto the
        // `hashes` array. At the end of the process, the last hash in the `hashes` array should contain the root of
        // the merkle tree.
        uint256 leavesLen = leaves.length;
        uint256 totalHashes = proofFlags.length;

        // Check proof validity.
        require(leavesLen + proof.length - 1 == totalHashes, "MerkleProof: invalid multiproof");

        // The xxxPos values are "pointers" to the next value to consume in each array. All accesses are done using
        // `xxx[xxxPos++]`, which return the current value and increment the pointer, thus mimicking a queue's "pop".
        bytes32[] memory hashes = new bytes32[](totalHashes);
        uint256 leafPos = 0;
        uint256 hashPos = 0;
        uint256 proofPos = 0;
        // At each step, we compute the next hash using two values:
        // - a value from the "main queue". If not all leaves have been consumed, we get the next leaf, otherwise we
        //   get the next hash.
        // - depending on the flag, either another value for the "main queue" (merging branches) or an element from the
        //   `proof` array.
        for (uint256 i = 0; i < totalHashes; i++) {
            bytes32 a = leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++];
            bytes32 b = proofFlags[i] ? leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++] : proof[proofPos++];
            hashes[i] = _hashPair(a, b);
        }

        if (totalHashes > 0) {
            return hashes[totalHashes - 1];
        } else if (leavesLen > 0) {
            return leaves[0];
        } else {
            return proof[0];
        }
    }

    function _hashPair(bytes32 a, bytes32 b) private pure returns (bytes32) {
        return a < b ? _efficientHash(a, b) : _efficientHash(b, a);
    }

    function _efficientHash(bytes32 a, bytes32 b) private pure returns (bytes32 value) {
        /// @solidity memory-safe-assembly
        assembly {
            mstore(0x00, a)
            mstore(0x20, b)
            value := keccak256(0x00, 0x40)
        }
    }
}

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

pragma solidity ^0.8.0;

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

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

File 7 of 9 : ERC721A.sol
// SPDX-License-Identifier: MIT
// ERC721A Contracts v4.2.2
// Creator: Chiru Labs

pragma solidity ^0.8.4;

import './IERC721A.sol';

/**
 * @dev Interface of ERC721 token receiver.
 */
interface ERC721A__IERC721Receiver {
    function onERC721Received(
        address operator,
        address from,
        uint256 tokenId,
        bytes calldata data
    ) external returns (bytes4);
}

/**
 * @title ERC721A
 *
 * @dev Implementation of the [ERC721](https://eips.ethereum.org/EIPS/eip-721)
 * Non-Fungible Token Standard, including the Metadata extension.
 * Optimized for lower gas during batch mints.
 *
 * Token IDs are minted in sequential order (e.g. 0, 1, 2, 3, ...)
 * starting from `_startTokenId()`.
 *
 * Assumptions:
 *
 * - An owner cannot have more than 2**64 - 1 (max value of uint64) of supply.
 * - The maximum token ID cannot exceed 2**256 - 1 (max value of uint256).
 */
contract ERC721A is IERC721A {
    // Reference type for token approval.
    struct TokenApprovalRef {
        address value;
    }

    // =============================================================
    //                           CONSTANTS
    // =============================================================

    // Mask of an entry in packed address data.
    uint256 private constant _BITMASK_ADDRESS_DATA_ENTRY = (1 << 64) - 1;

    // The bit position of `numberMinted` in packed address data.
    uint256 private constant _BITPOS_NUMBER_MINTED = 64;

    // The bit position of `numberBurned` in packed address data.
    uint256 private constant _BITPOS_NUMBER_BURNED = 128;

    // The bit position of `aux` in packed address data.
    uint256 private constant _BITPOS_AUX = 192;

    // Mask of all 256 bits in packed address data except the 64 bits for `aux`.
    uint256 private constant _BITMASK_AUX_COMPLEMENT = (1 << 192) - 1;

    // The bit position of `startTimestamp` in packed ownership.
    uint256 private constant _BITPOS_START_TIMESTAMP = 160;

    // The bit mask of the `burned` bit in packed ownership.
    uint256 private constant _BITMASK_BURNED = 1 << 224;

    // The bit position of the `nextInitialized` bit in packed ownership.
    uint256 private constant _BITPOS_NEXT_INITIALIZED = 225;

    // The bit mask of the `nextInitialized` bit in packed ownership.
    uint256 private constant _BITMASK_NEXT_INITIALIZED = 1 << 225;

    // The bit position of `extraData` in packed ownership.
    uint256 private constant _BITPOS_EXTRA_DATA = 232;

    // Mask of all 256 bits in a packed ownership except the 24 bits for `extraData`.
    uint256 private constant _BITMASK_EXTRA_DATA_COMPLEMENT = (1 << 232) - 1;

    // The mask of the lower 160 bits for addresses.
    uint256 private constant _BITMASK_ADDRESS = (1 << 160) - 1;

    // The maximum `quantity` that can be minted with {_mintERC2309}.
    // This limit is to prevent overflows on the address data entries.
    // For a limit of 5000, a total of 3.689e15 calls to {_mintERC2309}
    // is required to cause an overflow, which is unrealistic.
    uint256 private constant _MAX_MINT_ERC2309_QUANTITY_LIMIT = 5000;

    // The `Transfer` event signature is given by:
    // `keccak256(bytes("Transfer(address,address,uint256)"))`.
    bytes32 private constant _TRANSFER_EVENT_SIGNATURE =
        0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef;

    // =============================================================
    //                            STORAGE
    // =============================================================

    // The next token ID to be minted.
    uint256 private _currentIndex;

    // The number of tokens burned.
    uint256 private _burnCounter;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Mapping from token ID to ownership details
    // An empty struct value does not necessarily mean the token is unowned.
    // See {_packedOwnershipOf} implementation for details.
    //
    // Bits Layout:
    // - [0..159]   `addr`
    // - [160..223] `startTimestamp`
    // - [224]      `burned`
    // - [225]      `nextInitialized`
    // - [232..255] `extraData`
    mapping(uint256 => uint256) private _packedOwnerships;

    // Mapping owner address to address data.
    //
    // Bits Layout:
    // - [0..63]    `balance`
    // - [64..127]  `numberMinted`
    // - [128..191] `numberBurned`
    // - [192..255] `aux`
    mapping(address => uint256) private _packedAddressData;

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

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

    // =============================================================
    //                          CONSTRUCTOR
    // =============================================================

    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
        _currentIndex = _startTokenId();
    }

    // =============================================================
    //                   TOKEN COUNTING OPERATIONS
    // =============================================================

    /**
     * @dev Returns the starting token ID.
     * To change the starting token ID, please override this function.
     */
    function _startTokenId() internal view virtual returns (uint256) {
        return 0;
    }

    /**
     * @dev Returns the next token ID to be minted.
     */
    function _nextTokenId() internal view virtual returns (uint256) {
        return _currentIndex;
    }

    /**
     * @dev Returns the total number of tokens in existence.
     * Burned tokens will reduce the count.
     * To get the total number of tokens minted, please see {_totalMinted}.
     */
    function totalSupply() public view virtual override returns (uint256) {
        // Counter underflow is impossible as _burnCounter cannot be incremented
        // more than `_currentIndex - _startTokenId()` times.
        unchecked {
            return _currentIndex - _burnCounter - _startTokenId();
        }
    }

    /**
     * @dev Returns the total amount of tokens minted in the contract.
     */
    function _totalMinted() internal view virtual returns (uint256) {
        // Counter underflow is impossible as `_currentIndex` does not decrement,
        // and it is initialized to `_startTokenId()`.
        unchecked {
            return _currentIndex - _startTokenId();
        }
    }

    /**
     * @dev Returns the total number of tokens burned.
     */
    function _totalBurned() internal view virtual returns (uint256) {
        return _burnCounter;
    }

    // =============================================================
    //                    ADDRESS DATA OPERATIONS
    // =============================================================

    /**
     * @dev Returns the number of tokens in `owner`'s account.
     */
    function balanceOf(address owner) public view virtual override returns (uint256) {
        if (owner == address(0)) revert BalanceQueryForZeroAddress();
        return _packedAddressData[owner] & _BITMASK_ADDRESS_DATA_ENTRY;
    }

    /**
     * Returns the number of tokens minted by `owner`.
     */
    function _numberMinted(address owner) internal view returns (uint256) {
        return (_packedAddressData[owner] >> _BITPOS_NUMBER_MINTED) & _BITMASK_ADDRESS_DATA_ENTRY;
    }

    /**
     * Returns the number of tokens burned by or on behalf of `owner`.
     */
    function _numberBurned(address owner) internal view returns (uint256) {
        return (_packedAddressData[owner] >> _BITPOS_NUMBER_BURNED) & _BITMASK_ADDRESS_DATA_ENTRY;
    }

    /**
     * Returns the auxiliary data for `owner`. (e.g. number of whitelist mint slots used).
     */
    function _getAux(address owner) internal view returns (uint64) {
        return uint64(_packedAddressData[owner] >> _BITPOS_AUX);
    }

    /**
     * Sets the auxiliary data for `owner`. (e.g. number of whitelist mint slots used).
     * If there are multiple variables, please pack them into a uint64.
     */
    function _setAux(address owner, uint64 aux) internal virtual {
        uint256 packed = _packedAddressData[owner];
        uint256 auxCasted;
        // Cast `aux` with assembly to avoid redundant masking.
        assembly {
            auxCasted := aux
        }
        packed = (packed & _BITMASK_AUX_COMPLEMENT) | (auxCasted << _BITPOS_AUX);
        _packedAddressData[owner] = packed;
    }

    // =============================================================
    //                            IERC165
    // =============================================================

    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * [EIP section](https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified)
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30000 gas.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        // The interface IDs are constants representing the first 4 bytes
        // of the XOR of all function selectors in the interface.
        // See: [ERC165](https://eips.ethereum.org/EIPS/eip-165)
        // (e.g. `bytes4(i.functionA.selector ^ i.functionB.selector ^ ...)`)
        return
            interfaceId == 0x01ffc9a7 || // ERC165 interface ID for ERC165.
            interfaceId == 0x80ac58cd || // ERC165 interface ID for ERC721.
            interfaceId == 0x5b5e139f; // ERC165 interface ID for ERC721Metadata.
    }

    // =============================================================
    //                        IERC721Metadata
    // =============================================================

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

    /**
     * @dev Returns the token collection symbol.
     */
    function symbol() public view virtual override returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        if (!_exists(tokenId)) revert URIQueryForNonexistentToken();

        string memory baseURI = _baseURI();
        return bytes(baseURI).length != 0 ? string(abi.encodePacked(baseURI, _toString(tokenId))) : '';
    }

    /**
     * @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, it can be overridden in child contracts.
     */
    function _baseURI() internal view virtual returns (string memory) {
        return '';
    }

    // =============================================================
    //                     OWNERSHIPS OPERATIONS
    // =============================================================

    /**
     * @dev Returns the owner of the `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function ownerOf(uint256 tokenId) public view virtual override returns (address) {
        return address(uint160(_packedOwnershipOf(tokenId)));
    }

    /**
     * @dev Gas spent here starts off proportional to the maximum mint batch size.
     * It gradually moves to O(1) as tokens get transferred around over time.
     */
    function _ownershipOf(uint256 tokenId) internal view virtual returns (TokenOwnership memory) {
        return _unpackedOwnership(_packedOwnershipOf(tokenId));
    }

    /**
     * @dev Returns the unpacked `TokenOwnership` struct at `index`.
     */
    function _ownershipAt(uint256 index) internal view virtual returns (TokenOwnership memory) {
        return _unpackedOwnership(_packedOwnerships[index]);
    }

    /**
     * @dev Initializes the ownership slot minted at `index` for efficiency purposes.
     */
    function _initializeOwnershipAt(uint256 index) internal virtual {
        if (_packedOwnerships[index] == 0) {
            _packedOwnerships[index] = _packedOwnershipOf(index);
        }
    }

    /**
     * Returns the packed ownership data of `tokenId`.
     */
    function _packedOwnershipOf(uint256 tokenId) private view returns (uint256) {
        uint256 curr = tokenId;

        unchecked {
            if (_startTokenId() <= curr)
                if (curr < _currentIndex) {
                    uint256 packed = _packedOwnerships[curr];
                    // If not burned.
                    if (packed & _BITMASK_BURNED == 0) {
                        // Invariant:
                        // There will always be an initialized ownership slot
                        // (i.e. `ownership.addr != address(0) && ownership.burned == false`)
                        // before an unintialized ownership slot
                        // (i.e. `ownership.addr == address(0) && ownership.burned == false`)
                        // Hence, `curr` will not underflow.
                        //
                        // We can directly compare the packed value.
                        // If the address is zero, packed will be zero.
                        while (packed == 0) {
                            packed = _packedOwnerships[--curr];
                        }
                        return packed;
                    }
                }
        }
        revert OwnerQueryForNonexistentToken();
    }

    /**
     * @dev Returns the unpacked `TokenOwnership` struct from `packed`.
     */
    function _unpackedOwnership(uint256 packed) private pure returns (TokenOwnership memory ownership) {
        ownership.addr = address(uint160(packed));
        ownership.startTimestamp = uint64(packed >> _BITPOS_START_TIMESTAMP);
        ownership.burned = packed & _BITMASK_BURNED != 0;
        ownership.extraData = uint24(packed >> _BITPOS_EXTRA_DATA);
    }

    /**
     * @dev Packs ownership data into a single uint256.
     */
    function _packOwnershipData(address owner, uint256 flags) private view returns (uint256 result) {
        assembly {
            // Mask `owner` to the lower 160 bits, in case the upper bits somehow aren't clean.
            owner := and(owner, _BITMASK_ADDRESS)
            // `owner | (block.timestamp << _BITPOS_START_TIMESTAMP) | flags`.
            result := or(owner, or(shl(_BITPOS_START_TIMESTAMP, timestamp()), flags))
        }
    }

    /**
     * @dev Returns the `nextInitialized` flag set if `quantity` equals 1.
     */
    function _nextInitializedFlag(uint256 quantity) private pure returns (uint256 result) {
        // For branchless setting of the `nextInitialized` flag.
        assembly {
            // `(quantity == 1) << _BITPOS_NEXT_INITIALIZED`.
            result := shl(_BITPOS_NEXT_INITIALIZED, eq(quantity, 1))
        }
    }

    // =============================================================
    //                      APPROVAL OPERATIONS
    // =============================================================

    /**
     * @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) public virtual override {
        address owner = ownerOf(tokenId);

        if (_msgSenderERC721A() != owner)
            if (!isApprovedForAll(owner, _msgSenderERC721A())) {
                revert ApprovalCallerNotOwnerNorApproved();
            }

        _tokenApprovals[tokenId].value = to;
        emit Approval(owner, to, tokenId);
    }

    /**
     * @dev Returns the account approved for `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function getApproved(uint256 tokenId) public view virtual override returns (address) {
        if (!_exists(tokenId)) revert ApprovalQueryForNonexistentToken();

        return _tokenApprovals[tokenId].value;
    }

    /**
     * @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) public virtual override {
        if (operator == _msgSenderERC721A()) revert ApproveToCaller();

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

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

    /**
     * @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. See {_mint}.
     */
    function _exists(uint256 tokenId) internal view virtual returns (bool) {
        return
            _startTokenId() <= tokenId &&
            tokenId < _currentIndex && // If within bounds,
            _packedOwnerships[tokenId] & _BITMASK_BURNED == 0; // and not burned.
    }

    /**
     * @dev Returns whether `msgSender` is equal to `approvedAddress` or `owner`.
     */
    function _isSenderApprovedOrOwner(
        address approvedAddress,
        address owner,
        address msgSender
    ) private pure returns (bool result) {
        assembly {
            // Mask `owner` to the lower 160 bits, in case the upper bits somehow aren't clean.
            owner := and(owner, _BITMASK_ADDRESS)
            // Mask `msgSender` to the lower 160 bits, in case the upper bits somehow aren't clean.
            msgSender := and(msgSender, _BITMASK_ADDRESS)
            // `msgSender == owner || msgSender == approvedAddress`.
            result := or(eq(msgSender, owner), eq(msgSender, approvedAddress))
        }
    }

    /**
     * @dev Returns the storage slot and value for the approved address of `tokenId`.
     */
    function _getApprovedSlotAndAddress(uint256 tokenId)
        private
        view
        returns (uint256 approvedAddressSlot, address approvedAddress)
    {
        TokenApprovalRef storage tokenApproval = _tokenApprovals[tokenId];
        // The following is equivalent to `approvedAddress = _tokenApprovals[tokenId]`.
        assembly {
            approvedAddressSlot := tokenApproval.slot
            approvedAddress := sload(approvedAddressSlot)
        }
    }

    // =============================================================
    //                      TRANSFER OPERATIONS
    // =============================================================

    /**
     * @dev Transfers `tokenId` from `from` to `to`.
     *
     * 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
    ) public virtual override {
        uint256 prevOwnershipPacked = _packedOwnershipOf(tokenId);

        if (address(uint160(prevOwnershipPacked)) != from) revert TransferFromIncorrectOwner();

        (uint256 approvedAddressSlot, address approvedAddress) = _getApprovedSlotAndAddress(tokenId);

        // The nested ifs save around 20+ gas over a compound boolean condition.
        if (!_isSenderApprovedOrOwner(approvedAddress, from, _msgSenderERC721A()))
            if (!isApprovedForAll(from, _msgSenderERC721A())) revert TransferCallerNotOwnerNorApproved();

        if (to == address(0)) revert TransferToZeroAddress();

        _beforeTokenTransfers(from, to, tokenId, 1);

        // Clear approvals from the previous owner.
        assembly {
            if approvedAddress {
                // This is equivalent to `delete _tokenApprovals[tokenId]`.
                sstore(approvedAddressSlot, 0)
            }
        }

        // Underflow of the sender's balance is impossible because we check for
        // ownership above and the recipient's balance can't realistically overflow.
        // Counter overflow is incredibly unrealistic as `tokenId` would have to be 2**256.
        unchecked {
            // We can directly increment and decrement the balances.
            --_packedAddressData[from]; // Updates: `balance -= 1`.
            ++_packedAddressData[to]; // Updates: `balance += 1`.

            // Updates:
            // - `address` to the next owner.
            // - `startTimestamp` to the timestamp of transfering.
            // - `burned` to `false`.
            // - `nextInitialized` to `true`.
            _packedOwnerships[tokenId] = _packOwnershipData(
                to,
                _BITMASK_NEXT_INITIALIZED | _nextExtraData(from, to, prevOwnershipPacked)
            );

            // If the next slot may not have been initialized (i.e. `nextInitialized == false`) .
            if (prevOwnershipPacked & _BITMASK_NEXT_INITIALIZED == 0) {
                uint256 nextTokenId = tokenId + 1;
                // If the next slot's address is zero and not burned (i.e. packed value is zero).
                if (_packedOwnerships[nextTokenId] == 0) {
                    // If the next slot is within bounds.
                    if (nextTokenId != _currentIndex) {
                        // Initialize the next slot to maintain correctness for `ownerOf(tokenId + 1)`.
                        _packedOwnerships[nextTokenId] = prevOwnershipPacked;
                    }
                }
            }
        }

        emit Transfer(from, to, tokenId);
        _afterTokenTransfers(from, to, tokenId, 1);
    }

    /**
     * @dev Equivalent to `safeTransferFrom(from, to, tokenId, '')`.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public virtual override {
        safeTransferFrom(from, to, tokenId, '');
    }

    /**
     * @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 memory _data
    ) public virtual override {
        transferFrom(from, to, tokenId);
        if (to.code.length != 0)
            if (!_checkContractOnERC721Received(from, to, tokenId, _data)) {
                revert TransferToNonERC721ReceiverImplementer();
            }
    }

    /**
     * @dev Hook that is called before a set of serially-ordered token IDs
     * are about to be transferred. This includes minting.
     * And also called before burning one token.
     *
     * `startTokenId` - the first token ID to be transferred.
     * `quantity` - the amount to be transferred.
     *
     * 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, `tokenId` will be burned by `from`.
     * - `from` and `to` are never both zero.
     */
    function _beforeTokenTransfers(
        address from,
        address to,
        uint256 startTokenId,
        uint256 quantity
    ) internal virtual {}

    /**
     * @dev Hook that is called after a set of serially-ordered token IDs
     * have been transferred. This includes minting.
     * And also called after one token has been burned.
     *
     * `startTokenId` - the first token ID to be transferred.
     * `quantity` - the amount to be transferred.
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, `from`'s `tokenId` has been
     * transferred to `to`.
     * - When `from` is zero, `tokenId` has been minted for `to`.
     * - When `to` is zero, `tokenId` has been burned by `from`.
     * - `from` and `to` are never both zero.
     */
    function _afterTokenTransfers(
        address from,
        address to,
        uint256 startTokenId,
        uint256 quantity
    ) internal virtual {}

    /**
     * @dev Private function to invoke {IERC721Receiver-onERC721Received} on a target contract.
     *
     * `from` - Previous owner of the given token ID.
     * `to` - Target address that will receive the token.
     * `tokenId` - Token ID to be transferred.
     * `_data` - Optional data to send along with the call.
     *
     * Returns whether the call correctly returned the expected magic value.
     */
    function _checkContractOnERC721Received(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) private returns (bool) {
        try ERC721A__IERC721Receiver(to).onERC721Received(_msgSenderERC721A(), from, tokenId, _data) returns (
            bytes4 retval
        ) {
            return retval == ERC721A__IERC721Receiver(to).onERC721Received.selector;
        } catch (bytes memory reason) {
            if (reason.length == 0) {
                revert TransferToNonERC721ReceiverImplementer();
            } else {
                assembly {
                    revert(add(32, reason), mload(reason))
                }
            }
        }
    }

    // =============================================================
    //                        MINT OPERATIONS
    // =============================================================

    /**
     * @dev Mints `quantity` tokens and transfers them to `to`.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `quantity` must be greater than 0.
     *
     * Emits a {Transfer} event for each mint.
     */
    function _mint(address to, uint256 quantity) internal virtual {
        uint256 startTokenId = _currentIndex;
        if (quantity == 0) revert MintZeroQuantity();

        _beforeTokenTransfers(address(0), to, startTokenId, quantity);

        // Overflows are incredibly unrealistic.
        // `balance` and `numberMinted` have a maximum limit of 2**64.
        // `tokenId` has a maximum limit of 2**256.
        unchecked {
            // Updates:
            // - `balance += quantity`.
            // - `numberMinted += quantity`.
            //
            // We can directly add to the `balance` and `numberMinted`.
            _packedAddressData[to] += quantity * ((1 << _BITPOS_NUMBER_MINTED) | 1);

            // Updates:
            // - `address` to the owner.
            // - `startTimestamp` to the timestamp of minting.
            // - `burned` to `false`.
            // - `nextInitialized` to `quantity == 1`.
            _packedOwnerships[startTokenId] = _packOwnershipData(
                to,
                _nextInitializedFlag(quantity) | _nextExtraData(address(0), to, 0)
            );

            uint256 toMasked;
            uint256 end = startTokenId + quantity;

            // Use assembly to loop and emit the `Transfer` event for gas savings.
            assembly {
                // Mask `to` to the lower 160 bits, in case the upper bits somehow aren't clean.
                toMasked := and(to, _BITMASK_ADDRESS)
                // Emit the `Transfer` event.
                log4(
                    0, // Start of data (0, since no data).
                    0, // End of data (0, since no data).
                    _TRANSFER_EVENT_SIGNATURE, // Signature.
                    0, // `address(0)`.
                    toMasked, // `to`.
                    startTokenId // `tokenId`.
                )

                for {
                    let tokenId := add(startTokenId, 1)
                } iszero(eq(tokenId, end)) {
                    tokenId := add(tokenId, 1)
                } {
                    // Emit the `Transfer` event. Similar to above.
                    log4(0, 0, _TRANSFER_EVENT_SIGNATURE, 0, toMasked, tokenId)
                }
            }
            if (toMasked == 0) revert MintToZeroAddress();

            _currentIndex = end;
        }
        _afterTokenTransfers(address(0), to, startTokenId, quantity);
    }

    /**
     * @dev Mints `quantity` tokens and transfers them to `to`.
     *
     * This function is intended for efficient minting only during contract creation.
     *
     * It emits only one {ConsecutiveTransfer} as defined in
     * [ERC2309](https://eips.ethereum.org/EIPS/eip-2309),
     * instead of a sequence of {Transfer} event(s).
     *
     * Calling this function outside of contract creation WILL make your contract
     * non-compliant with the ERC721 standard.
     * For full ERC721 compliance, substituting ERC721 {Transfer} event(s) with the ERC2309
     * {ConsecutiveTransfer} event is only permissible during contract creation.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `quantity` must be greater than 0.
     *
     * Emits a {ConsecutiveTransfer} event.
     */
    function _mintERC2309(address to, uint256 quantity) internal virtual {
        uint256 startTokenId = _currentIndex;
        if (to == address(0)) revert MintToZeroAddress();
        if (quantity == 0) revert MintZeroQuantity();
        if (quantity > _MAX_MINT_ERC2309_QUANTITY_LIMIT) revert MintERC2309QuantityExceedsLimit();

        _beforeTokenTransfers(address(0), to, startTokenId, quantity);

        // Overflows are unrealistic due to the above check for `quantity` to be below the limit.
        unchecked {
            // Updates:
            // - `balance += quantity`.
            // - `numberMinted += quantity`.
            //
            // We can directly add to the `balance` and `numberMinted`.
            _packedAddressData[to] += quantity * ((1 << _BITPOS_NUMBER_MINTED) | 1);

            // Updates:
            // - `address` to the owner.
            // - `startTimestamp` to the timestamp of minting.
            // - `burned` to `false`.
            // - `nextInitialized` to `quantity == 1`.
            _packedOwnerships[startTokenId] = _packOwnershipData(
                to,
                _nextInitializedFlag(quantity) | _nextExtraData(address(0), to, 0)
            );

            emit ConsecutiveTransfer(startTokenId, startTokenId + quantity - 1, address(0), to);

            _currentIndex = startTokenId + quantity;
        }
        _afterTokenTransfers(address(0), to, startTokenId, quantity);
    }

    /**
     * @dev Safely mints `quantity` tokens and transfers them to `to`.
     *
     * Requirements:
     *
     * - If `to` refers to a smart contract, it must implement
     * {IERC721Receiver-onERC721Received}, which is called for each safe transfer.
     * - `quantity` must be greater than 0.
     *
     * See {_mint}.
     *
     * Emits a {Transfer} event for each mint.
     */
    function _safeMint(
        address to,
        uint256 quantity,
        bytes memory _data
    ) internal virtual {
        _mint(to, quantity);

        unchecked {
            if (to.code.length != 0) {
                uint256 end = _currentIndex;
                uint256 index = end - quantity;
                do {
                    if (!_checkContractOnERC721Received(address(0), to, index++, _data)) {
                        revert TransferToNonERC721ReceiverImplementer();
                    }
                } while (index < end);
                // Reentrancy protection.
                if (_currentIndex != end) revert();
            }
        }
    }

    /**
     * @dev Equivalent to `_safeMint(to, quantity, '')`.
     */
    function _safeMint(address to, uint256 quantity) internal virtual {
        _safeMint(to, quantity, '');
    }

    // =============================================================
    //                        BURN OPERATIONS
    // =============================================================

    /**
     * @dev Equivalent to `_burn(tokenId, false)`.
     */
    function _burn(uint256 tokenId) internal virtual {
        _burn(tokenId, false);
    }

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

        address from = address(uint160(prevOwnershipPacked));

        (uint256 approvedAddressSlot, address approvedAddress) = _getApprovedSlotAndAddress(tokenId);

        if (approvalCheck) {
            // The nested ifs save around 20+ gas over a compound boolean condition.
            if (!_isSenderApprovedOrOwner(approvedAddress, from, _msgSenderERC721A()))
                if (!isApprovedForAll(from, _msgSenderERC721A())) revert TransferCallerNotOwnerNorApproved();
        }

        _beforeTokenTransfers(from, address(0), tokenId, 1);

        // Clear approvals from the previous owner.
        assembly {
            if approvedAddress {
                // This is equivalent to `delete _tokenApprovals[tokenId]`.
                sstore(approvedAddressSlot, 0)
            }
        }

        // Underflow of the sender's balance is impossible because we check for
        // ownership above and the recipient's balance can't realistically overflow.
        // Counter overflow is incredibly unrealistic as `tokenId` would have to be 2**256.
        unchecked {
            // Updates:
            // - `balance -= 1`.
            // - `numberBurned += 1`.
            //
            // We can directly decrement the balance, and increment the number burned.
            // This is equivalent to `packed -= 1; packed += 1 << _BITPOS_NUMBER_BURNED;`.
            _packedAddressData[from] += (1 << _BITPOS_NUMBER_BURNED) - 1;

            // Updates:
            // - `address` to the last owner.
            // - `startTimestamp` to the timestamp of burning.
            // - `burned` to `true`.
            // - `nextInitialized` to `true`.
            _packedOwnerships[tokenId] = _packOwnershipData(
                from,
                (_BITMASK_BURNED | _BITMASK_NEXT_INITIALIZED) | _nextExtraData(from, address(0), prevOwnershipPacked)
            );

            // If the next slot may not have been initialized (i.e. `nextInitialized == false`) .
            if (prevOwnershipPacked & _BITMASK_NEXT_INITIALIZED == 0) {
                uint256 nextTokenId = tokenId + 1;
                // If the next slot's address is zero and not burned (i.e. packed value is zero).
                if (_packedOwnerships[nextTokenId] == 0) {
                    // If the next slot is within bounds.
                    if (nextTokenId != _currentIndex) {
                        // Initialize the next slot to maintain correctness for `ownerOf(tokenId + 1)`.
                        _packedOwnerships[nextTokenId] = prevOwnershipPacked;
                    }
                }
            }
        }

        emit Transfer(from, address(0), tokenId);
        _afterTokenTransfers(from, address(0), tokenId, 1);

        // Overflow not possible, as _burnCounter cannot be exceed _currentIndex times.
        unchecked {
            _burnCounter++;
        }
    }

    // =============================================================
    //                     EXTRA DATA OPERATIONS
    // =============================================================

    /**
     * @dev Directly sets the extra data for the ownership data `index`.
     */
    function _setExtraDataAt(uint256 index, uint24 extraData) internal virtual {
        uint256 packed = _packedOwnerships[index];
        if (packed == 0) revert OwnershipNotInitializedForExtraData();
        uint256 extraDataCasted;
        // Cast `extraData` with assembly to avoid redundant masking.
        assembly {
            extraDataCasted := extraData
        }
        packed = (packed & _BITMASK_EXTRA_DATA_COMPLEMENT) | (extraDataCasted << _BITPOS_EXTRA_DATA);
        _packedOwnerships[index] = packed;
    }

    /**
     * @dev Called during each token transfer to set the 24bit `extraData` field.
     * Intended to be overridden by the cosumer contract.
     *
     * `previousExtraData` - the value of `extraData` before transfer.
     *
     * 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, `tokenId` will be burned by `from`.
     * - `from` and `to` are never both zero.
     */
    function _extraData(
        address from,
        address to,
        uint24 previousExtraData
    ) internal view virtual returns (uint24) {}

    /**
     * @dev Returns the next extra data for the packed ownership data.
     * The returned result is shifted into position.
     */
    function _nextExtraData(
        address from,
        address to,
        uint256 prevOwnershipPacked
    ) private view returns (uint256) {
        uint24 extraData = uint24(prevOwnershipPacked >> _BITPOS_EXTRA_DATA);
        return uint256(_extraData(from, to, extraData)) << _BITPOS_EXTRA_DATA;
    }

    // =============================================================
    //                       OTHER OPERATIONS
    // =============================================================

    /**
     * @dev Returns the message sender (defaults to `msg.sender`).
     *
     * If you are writing GSN compatible contracts, you need to override this function.
     */
    function _msgSenderERC721A() internal view virtual returns (address) {
        return msg.sender;
    }

    /**
     * @dev Converts a uint256 to its ASCII string decimal representation.
     */
    function _toString(uint256 value) internal pure virtual returns (string memory str) {
        assembly {
            // The maximum value of a uint256 contains 78 digits (1 byte per digit),
            // but we allocate 0x80 bytes to keep the free memory pointer 32-byte word aliged.
            // We will need 1 32-byte word to store the length,
            // and 3 32-byte words to store a maximum of 78 digits. Total: 0x20 + 3 * 0x20 = 0x80.
            str := add(mload(0x40), 0x80)
            // Update the free memory pointer to allocate.
            mstore(0x40, str)

            // Cache the end of the memory to calculate the length later.
            let end := str

            // We write the string from rightmost digit to leftmost digit.
            // The following is essentially a do-while loop that also handles the zero case.
            // prettier-ignore
            for { let temp := value } 1 {} {
                str := sub(str, 1)
                // Write the character to the pointer.
                // The ASCII index of the '0' character is 48.
                mstore8(str, add(48, mod(temp, 10)))
                // Keep dividing `temp` until zero.
                temp := div(temp, 10)
                // prettier-ignore
                if iszero(temp) { break }
            }

            let length := sub(end, str)
            // Move the pointer 32 bytes leftwards to make room for the length.
            str := sub(str, 0x20)
            // Store the length.
            mstore(str, length)
        }
    }
}

File 8 of 9 : IERC721AQueryable.sol
// SPDX-License-Identifier: MIT
// ERC721A Contracts v4.2.2
// Creator: Chiru Labs

pragma solidity ^0.8.4;

import '../IERC721A.sol';

/**
 * @dev Interface of ERC721AQueryable.
 */
interface IERC721AQueryable is IERC721A {
    /**
     * Invalid query range (`start` >= `stop`).
     */
    error InvalidQueryRange();

    /**
     * @dev Returns the `TokenOwnership` struct at `tokenId` without reverting.
     *
     * If the `tokenId` is out of bounds:
     *
     * - `addr = address(0)`
     * - `startTimestamp = 0`
     * - `burned = false`
     * - `extraData = 0`
     *
     * If the `tokenId` is burned:
     *
     * - `addr = <Address of owner before token was burned>`
     * - `startTimestamp = <Timestamp when token was burned>`
     * - `burned = true`
     * - `extraData = <Extra data when token was burned>`
     *
     * Otherwise:
     *
     * - `addr = <Address of owner>`
     * - `startTimestamp = <Timestamp of start of ownership>`
     * - `burned = false`
     * - `extraData = <Extra data at start of ownership>`
     */
    function explicitOwnershipOf(uint256 tokenId) external view returns (TokenOwnership memory);

    /**
     * @dev Returns an array of `TokenOwnership` structs at `tokenIds` in order.
     * See {ERC721AQueryable-explicitOwnershipOf}
     */
    function explicitOwnershipsOf(uint256[] memory tokenIds) external view returns (TokenOwnership[] memory);

    /**
     * @dev Returns an array of token IDs owned by `owner`,
     * in the range [`start`, `stop`)
     * (i.e. `start <= tokenId < stop`).
     *
     * This function allows for tokens to be queried if the collection
     * grows too big for a single call of {ERC721AQueryable-tokensOfOwner}.
     *
     * Requirements:
     *
     * - `start < stop`
     */
    function tokensOfOwnerIn(
        address owner,
        uint256 start,
        uint256 stop
    ) external view returns (uint256[] memory);

    /**
     * @dev Returns an array of token IDs owned by `owner`.
     *
     * This function scans the ownership mapping and is O(`totalSupply`) in complexity.
     * It is meant to be called off-chain.
     *
     * See {ERC721AQueryable-tokensOfOwnerIn} for splitting the scan into
     * multiple smaller scans if the collection is large enough to cause
     * an out-of-gas error (10K collections should be fine).
     */
    function tokensOfOwner(address owner) external view returns (uint256[] memory);
}

File 9 of 9 : IERC721A.sol
// SPDX-License-Identifier: MIT
// ERC721A Contracts v4.2.2
// Creator: Chiru Labs

pragma solidity ^0.8.4;

/**
 * @dev Interface of ERC721A.
 */
interface IERC721A {
    /**
     * The caller must own the token or be an approved operator.
     */
    error ApprovalCallerNotOwnerNorApproved();

    /**
     * The token does not exist.
     */
    error ApprovalQueryForNonexistentToken();

    /**
     * The caller cannot approve to their own address.
     */
    error ApproveToCaller();

    /**
     * Cannot query the balance for the zero address.
     */
    error BalanceQueryForZeroAddress();

    /**
     * Cannot mint to the zero address.
     */
    error MintToZeroAddress();

    /**
     * The quantity of tokens minted must be more than zero.
     */
    error MintZeroQuantity();

    /**
     * The token does not exist.
     */
    error OwnerQueryForNonexistentToken();

    /**
     * The caller must own the token or be an approved operator.
     */
    error TransferCallerNotOwnerNorApproved();

    /**
     * The token must be owned by `from`.
     */
    error TransferFromIncorrectOwner();

    /**
     * Cannot safely transfer to a contract that does not implement the
     * ERC721Receiver interface.
     */
    error TransferToNonERC721ReceiverImplementer();

    /**
     * Cannot transfer to the zero address.
     */
    error TransferToZeroAddress();

    /**
     * The token does not exist.
     */
    error URIQueryForNonexistentToken();

    /**
     * The `quantity` minted with ERC2309 exceeds the safety limit.
     */
    error MintERC2309QuantityExceedsLimit();

    /**
     * The `extraData` cannot be set on an unintialized ownership slot.
     */
    error OwnershipNotInitializedForExtraData();

    // =============================================================
    //                            STRUCTS
    // =============================================================

    struct TokenOwnership {
        // The address of the owner.
        address addr;
        // Stores the start time of ownership with minimal overhead for tokenomics.
        uint64 startTimestamp;
        // Whether the token has been burned.
        bool burned;
        // Arbitrary data similar to `startTimestamp` that can be set via {_extraData}.
        uint24 extraData;
    }

    // =============================================================
    //                         TOKEN COUNTERS
    // =============================================================

    /**
     * @dev Returns the total number of tokens in existence.
     * Burned tokens will reduce the count.
     * To get the total number of tokens minted, please see {_totalMinted}.
     */
    function totalSupply() external view returns (uint256);

    // =============================================================
    //                            IERC165
    // =============================================================

    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * [EIP section](https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified)
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool);

    // =============================================================
    //                            IERC721
    // =============================================================

    /**
     * @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,
        bytes calldata data
    ) external;

    /**
     * @dev Equivalent to `safeTransferFrom(from, to, tokenId, '')`.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

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

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

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

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

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

    // =============================================================
    //                        IERC721Metadata
    // =============================================================

    /**
     * @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);

    // =============================================================
    //                           IERC2309
    // =============================================================

    /**
     * @dev Emitted when tokens in `fromTokenId` to `toTokenId`
     * (inclusive) is transferred from `from` to `to`, as defined in the
     * [ERC2309](https://eips.ethereum.org/EIPS/eip-2309) standard.
     *
     * See {_mintERC2309} for more details.
     */
    event ConsecutiveTransfer(uint256 indexed fromTokenId, uint256 toTokenId, address indexed from, address indexed to);
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"string","name":"myBaseURI_","type":"string"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"AddressesAndQtysLengthAreDifferent","type":"error"},{"inputs":[],"name":"ApprovalCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"ApprovalQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"ApproveToCaller","type":"error"},{"inputs":[],"name":"BalanceQueryForZeroAddress","type":"error"},{"inputs":[],"name":"CandyQtyMustBeInMutiplyOf4","type":"error"},{"inputs":[],"name":"CandyQtyMustBeLessOrEqualToBalance","type":"error"},{"inputs":[],"name":"CandyQtyMustNotBe0","type":"error"},{"inputs":[],"name":"CannotPurchaseMoreThan1Time","type":"error"},{"inputs":[],"name":"InvalidQueryRange","type":"error"},{"inputs":[],"name":"IsNotCandyOwner","type":"error"},{"inputs":[],"name":"MintERC2309QuantityExceedsLimit","type":"error"},{"inputs":[],"name":"MintToZeroAddress","type":"error"},{"inputs":[],"name":"MintZeroQuantity","type":"error"},{"inputs":[],"name":"NoPublicMintAirdrop","type":"error"},{"inputs":[],"name":"NoZombieBirdCanBeClaimed","type":"error"},{"inputs":[],"name":"NotAWhitelistedAddress","type":"error"},{"inputs":[],"name":"NotCorrectPhase","type":"error"},{"inputs":[],"name":"OwnerQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"OwnershipNotInitializedForExtraData","type":"error"},{"inputs":[],"name":"PreSaleQtyHasReached","type":"error"},{"inputs":[],"name":"PurchasedEtherMustBeCorrect","type":"error"},{"inputs":[],"name":"TotalSupplyHasReached","type":"error"},{"inputs":[],"name":"TransferCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"TransferFromIncorrectOwner","type":"error"},{"inputs":[],"name":"TransferToNonERC721ReceiverImplementer","type":"error"},{"inputs":[],"name":"TransferToZeroAddress","type":"error"},{"inputs":[],"name":"URIQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"UnableToMintZombieBird","type":"error"},{"inputs":[],"name":"ZombieBirdAddressWasNotYetSet","type":"error"},{"inputs":[],"name":"ZombieBirdAddressWasSetBefore","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"fromTokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"toTokenId","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"ConsecutiveTransfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"PreSaleMint","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"timestamp","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"qty","type":"uint256"}],"name":"PublicMintClaimAirdrop","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"timestamp","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"qty","type":"uint256"}],"name":"ZombieBirdClaimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"timestamp","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"qty","type":"uint256"}],"name":"ZombieBirdSaleBurnCandy","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"timestamp","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ZombieBirdSaleBurnCandyTokenId","type":"event"},{"inputs":[],"name":"MAX_SUPPLY","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"_addressZombieBirdBoughtHasDistributed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"_addressZombieBirdBoughtQtys","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"_addressZombieBirdBoughtTimes","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"_addressZombieBirdBoughtTimestamps","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_currentMerkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_currentPhase","outputs":[{"internalType":"enum SpookyBirdsCandy.Phase","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"_hasPresaleAddressSold","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_hasZombieBirdContractSet","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_myBaseURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_presaleMintQty","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"_publicMintAirDropAddressQty","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_zombieBirdContract","outputs":[{"internalType":"contract IZombieBirdContract","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"tokenIds_","type":"uint256[]"}],"name":"burnCandyToMintZombieBird","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"explicitOwnershipOf","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint64","name":"startTimestamp","type":"uint64"},{"internalType":"bool","name":"burned","type":"bool"},{"internalType":"uint24","name":"extraData","type":"uint24"}],"internalType":"struct IERC721A.TokenOwnership","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"explicitOwnershipsOf","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint64","name":"startTimestamp","type":"uint64"},{"internalType":"bool","name":"burned","type":"bool"},{"internalType":"uint24","name":"extraData","type":"uint24"}],"internalType":"struct IERC721A.TokenOwnership[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCurrentBlockTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"qty","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"mintZombieBird","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"proof_","type":"bytes32[]"}],"name":"presaleMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"proof_","type":"bytes32[]"}],"name":"publicMint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"addresses_","type":"address[]"},{"internalType":"uint256[]","name":"qtys_","type":"uint256[]"}],"name":"publicMintAirDrop","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"myBaseURI_","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum SpookyBirdsCandy.Phase","name":"currentPhase_","type":"uint8"},{"internalType":"bytes32","name":"currentMerkleRoot_","type":"bytes32"}],"name":"setPhase","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"address_","type":"address"}],"name":"setZombieBirdAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"tokensOfOwner","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"start","type":"uint256"},{"internalType":"uint256","name":"stop","type":"uint256"}],"name":"tokensOfOwnerIn","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60806040523480156200001157600080fd5b506040516200554738038062005547833981810160405281019062000037919062000468565b6040518060400160405280601281526020017f53706f6f6b792042697264732043616e647900000000000000000000000000008152506040518060400160405280600581526020017f43616e64790000000000000000000000000000000000000000000000000000008152508160029080519060200190620000bb9291906200021b565b508060039080519060200190620000d49291906200021b565b50620000e56200014860201b60201c565b60008190555050506200010d620001016200014d60201b60201c565b6200015560201b60201c565b6000600860146101000a81548160ff0219169083151502179055508060099080519060200190620001409291906200021b565b50506200051e565b600090565b600033905090565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905081600860006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b8280546200022990620004e8565b90600052602060002090601f0160209004810192826200024d576000855562000299565b82601f106200026857805160ff191683800117855562000299565b8280016001018555821562000299579182015b82811115620002985782518255916020019190600101906200027b565b5b509050620002a89190620002ac565b5090565b5b80821115620002c7576000816000905550600101620002ad565b5090565b6000604051905090565b600080fd5b600080fd5b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6200033482620002e9565b810181811067ffffffffffffffff82111715620003565762000355620002fa565b5b80604052505050565b60006200036b620002cb565b905062000379828262000329565b919050565b600067ffffffffffffffff8211156200039c576200039b620002fa565b5b620003a782620002e9565b9050602081019050919050565b60005b83811015620003d4578082015181840152602081019050620003b7565b83811115620003e4576000848401525b50505050565b600062000401620003fb846200037e565b6200035f565b90508281526020810184848401111562000420576200041f620002e4565b5b6200042d848285620003b4565b509392505050565b600082601f8301126200044d576200044c620002df565b5b81516200045f848260208601620003ea565b91505092915050565b600060208284031215620004815762000480620002d5565b5b600082015167ffffffffffffffff811115620004a257620004a1620002da565b5b620004b08482850162000435565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b600060028204905060018216806200050157607f821691505b60208210811415620005185762000517620004b9565b5b50919050565b615019806200052e6000396000f3fe6080604052600436106102ae5760003560e01c80635bbb217711610175578063a22cb465116100dc578063d4db554711610095578063edc0c72c1161006f578063edc0c72c14610ad4578063f2fde38b14610af0578063f797d7bc14610b19578063fb88f0a414610b42576102ae565b8063d4db554714610a2f578063de16bc0f14610a5a578063e985e9c514610a97576102ae565b8063a22cb46514610921578063aaf8ba8e1461094a578063b88d4fde14610961578063b8df93eb1461098a578063c23dc68f146109b5578063c87b56dd146109f2576102ae565b8063715018a61161012e578063715018a6146108235780638456cb591461083a5780638462151c146108515780638da5cb5b1461088e57806395d89b41146108b957806399a2557a146108e4576102ae565b80635bbb2177146106ed5780635c975abb1461072a5780635d3aa87e146107555780636352211e146107805780636f77197d146107bd57806370a08231146107e6576102ae565b806322e0ab9c116102195780633ccfd60b116101d25780633ccfd60b1461061b5780633f4ba83a1461063257806340c10f191461064957806342842e0e1461067257806342966c681461069b57806355f804b3146106c4576102ae565b806322e0ab9c1461052157806323b872dd1461054c57806325b3ec381461057557806332cb6b0c1461059e57806336372ac5146105c957806336dab767146105f2576102ae565b80631302a66f1161026b5780631302a66f146103e957806318160ddd14610414578063192051cf1461043f5780631f6bebff1461047c5780631f7dcafe146104a757806321ea9e20146104e4576102ae565b806301ffc9a7146102b357806303ad62bb146102f057806306fdde031461032d578063081812fc14610358578063095ea7b3146103955780630f28c97d146103be575b600080fd5b3480156102bf57600080fd5b506102da60048036038101906102d59190613c78565b610b7f565b6040516102e79190613cc0565b60405180910390f35b3480156102fc57600080fd5b5061031760048036038101906103129190613d39565b610c11565b6040516103249190613cc0565b60405180910390f35b34801561033957600080fd5b50610342610c31565b60405161034f9190613dff565b60405180910390f35b34801561036457600080fd5b5061037f600480360381019061037a9190613e57565b610cc3565b60405161038c9190613e93565b60405180910390f35b3480156103a157600080fd5b506103bc60048036038101906103b79190613eae565b610d42565b005b3480156103ca57600080fd5b506103d3610e86565b6040516103e09190613efd565b60405180910390f35b3480156103f557600080fd5b506103fe610e8e565b60405161040b9190613f77565b60405180910390f35b34801561042057600080fd5b50610429610eb4565b6040516104369190613efd565b60405180910390f35b34801561044b57600080fd5b5061046660048036038101906104619190613d39565b610ecb565b6040516104739190613efd565b60405180910390f35b34801561048857600080fd5b50610491610ee3565b60405161049e9190613cc0565b60405180910390f35b3480156104b357600080fd5b506104ce60048036038101906104c99190613d39565b610ef6565b6040516104db9190613efd565b60405180910390f35b3480156104f057600080fd5b5061050b60048036038101906105069190613eae565b610f0e565b6040516105189190613cc0565b60405180910390f35b34801561052d57600080fd5b50610536610f3d565b6040516105439190613dff565b60405180910390f35b34801561055857600080fd5b50610573600480360381019061056e9190613f92565b610fcb565b005b34801561058157600080fd5b5061059c60048036038101906105979190613d39565b6112f0565b005b3480156105aa57600080fd5b506105b361139e565b6040516105c09190613efd565b60405180910390f35b3480156105d557600080fd5b506105f060048036038101906105eb9190614040565b6113a4565b005b3480156105fe57600080fd5b50610619600480360381019061061491906140e5565b6113e1565b005b34801561062757600080fd5b50610630611749565b005b34801561063e57600080fd5b506106476117a1565b005b34801561065557600080fd5b50610670600480360381019061066b9190613eae565b6117b3565b005b34801561067e57600080fd5b5061069960048036038101906106949190613f92565b611817565b005b3480156106a757600080fd5b506106c260048036038101906106bd9190613e57565b611837565b005b3480156106d057600080fd5b506106eb60048036038101906106e69190614262565b61184b565b005b3480156106f957600080fd5b50610714600480360381019061070f91906140e5565b61186d565b604051610721919061440e565b60405180910390f35b34801561073657600080fd5b5061073f611930565b60405161074c9190613cc0565b60405180910390f35b34801561076157600080fd5b5061076a611947565b60405161077791906144a7565b60405180910390f35b34801561078c57600080fd5b506107a760048036038101906107a29190613e57565b61195a565b6040516107b49190613e93565b60405180910390f35b3480156107c957600080fd5b506107e460048036038101906107df9190614518565b61196c565b005b3480156107f257600080fd5b5061080d60048036038101906108089190613d39565b611be6565b60405161081a9190613efd565b60405180910390f35b34801561082f57600080fd5b50610838611c9f565b005b34801561084657600080fd5b5061084f611cb3565b005b34801561085d57600080fd5b5061087860048036038101906108739190613d39565b611cc5565b6040516108859190614623565b60405180910390f35b34801561089a57600080fd5b506108a3611e0f565b6040516108b09190613e93565b60405180910390f35b3480156108c557600080fd5b506108ce611e39565b6040516108db9190613dff565b60405180910390f35b3480156108f057600080fd5b5061090b60048036038101906109069190614645565b611ecb565b6040516109189190614623565b60405180910390f35b34801561092d57600080fd5b50610948600480360381019061094391906146c4565b6120df565b005b34801561095657600080fd5b5061095f612257565b005b34801561096d57600080fd5b50610988600480360381019061098391906147a5565b61260e565b005b34801561099657600080fd5b5061099f612681565b6040516109ac9190613efd565b60405180910390f35b3480156109c157600080fd5b506109dc60048036038101906109d79190613e57565b612687565b6040516109e9919061487d565b60405180910390f35b3480156109fe57600080fd5b50610a196004803603810190610a149190613e57565b6126f1565b604051610a269190613dff565b60405180910390f35b348015610a3b57600080fd5b50610a44612790565b604051610a5191906148a7565b60405180910390f35b348015610a6657600080fd5b50610a816004803603810190610a7c9190613eae565b612796565b604051610a8e9190613efd565b60405180910390f35b348015610aa357600080fd5b50610abe6004803603810190610ab991906148c2565b6127bb565b604051610acb9190613cc0565b60405180910390f35b610aee6004803603810190610ae99190614518565b61284f565b005b348015610afc57600080fd5b50610b176004803603810190610b129190613d39565b612b63565b005b348015610b2557600080fd5b50610b406004803603810190610b3b9190614958565b612be7565b005b348015610b4e57600080fd5b50610b696004803603810190610b649190613eae565b612d44565b604051610b769190613efd565b60405180910390f35b60006301ffc9a760e01b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480610bda57506380ac58cd60e01b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b80610c0a5750635b5e139f60e01b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b9050919050565b600d6020528060005260406000206000915054906101000a900460ff1681565b606060028054610c4090614a08565b80601f0160208091040260200160405190810160405280929190818152602001828054610c6c90614a08565b8015610cb95780601f10610c8e57610100808354040283529160200191610cb9565b820191906000526020600020905b815481529060010190602001808311610c9c57829003601f168201915b5050505050905090565b6000610cce82612d69565b610d04576040517fcf4700e400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6006600083815260200190815260200160002060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b6000610d4d8261195a565b90508073ffffffffffffffffffffffffffffffffffffffff16610d6e612dc8565b73ffffffffffffffffffffffffffffffffffffffff1614610dd157610d9a81610d95612dc8565b6127bb565b610dd0576040517fcfb3b94200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b826006600084815260200190815260200160002060000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550818373ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a4505050565b600042905090565b600f60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000610ebe612dd0565b6001546000540303905090565b600e6020528060005260406000206000915090505481565b600f60149054906101000a900460ff1681565b60106020528060005260406000206000915090505481565b60136020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b60098054610f4a90614a08565b80601f0160208091040260200160405190810160405280929190818152602001828054610f7690614a08565b8015610fc35780601f10610f9857610100808354040283529160200191610fc3565b820191906000526020600020905b815481529060010190602001808311610fa657829003601f168201915b505050505081565b6000610fd682612dd5565b90508373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161461103d576040517fa114810000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008061104984612ea3565b9150915061105f818761105a612dc8565b612eca565b6110ab576110748661106f612dc8565b6127bb565b6110aa576040517f59c896be00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161415611112576040517fea553b3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61111f8686866001612f0e565b801561112a57600082555b600560008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600081546001900391905081905550600560008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008154600101919050819055506111f8856111d4888887612f28565b7c020000000000000000000000000000000000000000000000000000000017612f50565b600460008681526020019081526020016000208190555060007c02000000000000000000000000000000000000000000000000000000008416141561128057600060018501905060006004600083815260200190815260200160002054141561127e57600054811461127d578360046000838152602001908152602001600020819055505b5b505b838573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a46112e88686866001612f7b565b505050505050565b6112f8612f81565b600f60149054906101000a900460ff161561133f576040517f67fc29a400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80600f60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506001600f60146101000a81548160ff02191690831515021790555050565b61263081565b6113ac612f81565b81600a60006101000a81548160ff021916908360028111156113d1576113d0614430565b5b021790555080600b819055505050565b60008282905090506000811415611424576040517ff5ad9bf300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006004826114339190614a69565b1461146a576040517fde4285d100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61147333611be6565b8111156114ac576040517ff1bbe29900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000601060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490506004826114fd9190614ac9565b601160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008381526020019081526020016000208190555042601260003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002081905550601060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600081546001019190508190555060005b828110156116f357600085858381811061161357611612614afa565b5b9050602002013590503373ffffffffffffffffffffffffffffffffffffffff1661163c8261195a565b73ffffffffffffffffffffffffffffffffffffffff1614156116665761166181612fff565b611698565b6040517f47d4e58800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b423373ffffffffffffffffffffffffffffffffffffffff167f2ddeb9fdf97b8928a1720dc2febe475593debc796867772369b73353bed6b8ce836040516116df9190613efd565b60405180910390a3816001019150506115f6565b50423373ffffffffffffffffffffffffffffffffffffffff167f8384c640888323da22f28fab6b1650beb26ea1310d51f28f82676f66ddc3f6fa8460405161173b9190613efd565b60405180910390a350505050565b611751612f81565b611759611e0f565b73ffffffffffffffffffffffffffffffffffffffff166108fc479081150290604051600060405180830381858888f1935050505015801561179e573d6000803e3d6000fd5b50565b6117a9612f81565b6117b161300d565b565b6117bb612f81565b612630816117c7610eb4565b6117d19190614b29565b1115611809576040517f41eb528000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6118138282613070565b5050565b6118328383836040518060200160405280600081525061260e565b505050565b61183f612f81565b61184881612fff565b50565b611853612f81565b8060099080519060200190611869929190613b1a565b5050565b6060600083839050905060008167ffffffffffffffff81111561189357611892614137565b5b6040519080825280602002602001820160405280156118cc57816020015b6118b9613ba0565b8152602001906001900390816118b15790505b50905060005b828114611924576118fb8686838181106118ef576118ee614afa565b5b90506020020135612687565b82828151811061190e5761190d614afa565b5b60200260200101819052508060010190506118d2565b50809250505092915050565b6000600860149054906101000a900460ff16905090565b600a60009054906101000a900460ff1681565b600061196582612dd5565b9050919050565b600280600281111561198157611980614430565b5b600a60009054906101000a900460ff1660028111156119a3576119a2614430565b5b146119da576040517ff9dd843f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611a4e838380806020026020016040519081016040528093929190818152602001838360200280828437600081840152601f19601f82011690508083019250505050505050600b5433604051602001611a339190614bc7565b6040516020818303038152906040528051906020012061308e565b611a84576040517f106323b400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600e60003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020541415611afe576040517faf92324e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600e60003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490506000600e60003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550611b913382613070565b423373ffffffffffffffffffffffffffffffffffffffff167f14e5934ee1ceffb970cd4e24dfdb6dd75fc3e8abdf513018f9b783db67388abb83604051611bd89190613efd565b60405180910390a350505050565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611c4e576040517f8f4eb60400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054169050919050565b611ca7612f81565b611cb160006130a5565b565b611cbb612f81565b611cc361316b565b565b60606000806000611cd585611be6565b905060008167ffffffffffffffff811115611cf357611cf2614137565b5b604051908082528060200260200182016040528015611d215781602001602082028036833780820191505090505b509050611d2c613ba0565b6000611d36612dd0565b90505b838614611e0157611d49816131ce565b9150816040015115611d5a57611df6565b600073ffffffffffffffffffffffffffffffffffffffff16826000015173ffffffffffffffffffffffffffffffffffffffff1614611d9a57816000015194505b8773ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161415611df55780838780600101985081518110611de857611de7614afa565b5b6020026020010181815250505b5b806001019050611d39565b508195505050505050919050565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b606060038054611e4890614a08565b80601f0160208091040260200160405190810160405280929190818152602001828054611e7490614a08565b8015611ec15780601f10611e9657610100808354040283529160200191611ec1565b820191906000526020600020905b815481529060010190602001808311611ea457829003601f168201915b5050505050905090565b6060818310611f06576040517f32c1995a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080611f116131f9565b9050611f1b612dd0565b851015611f2d57611f2a612dd0565b94505b80841115611f39578093505b6000611f4487611be6565b905084861015611f67576000868603905081811015611f61578091505b50611f6c565b600090505b60008167ffffffffffffffff811115611f8857611f87614137565b5b604051908082528060200260200182016040528015611fb65781602001602082028036833780820191505090505b5090506000821415611fce57809450505050506120d8565b6000611fd988612687565b905060008160400151611fee57816000015190505b60008990505b8881141580156120045750848714155b156120ca57612012816131ce565b9250826040015115612023576120bf565b600073ffffffffffffffffffffffffffffffffffffffff16836000015173ffffffffffffffffffffffffffffffffffffffff161461206357826000015191505b8a73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156120be57808488806001019950815181106120b1576120b0614afa565b5b6020026020010181815250505b5b806001019050611ff4565b508583528296505050505050505b9392505050565b6120e7612dc8565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141561214c576040517fb06307db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060076000612159612dc8565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff16612206612dc8565b73ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c318360405161224b9190613cc0565b60405180910390a35050565b600f60149054906101000a900460ff1661229d576040517f9b115b9000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000601060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490506000805b82811015612494576000601260003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002054905062278d0081426123529190614be2565b101580156123bb5750601360003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002060009054906101000a900460ff16155b1561248857601160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000838152602001908152602001600020548361241c9190614b29565b92506001601360003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff0219169083151502179055505b816001019150506122e5565b5060008114156124d0576040517f4d201a1a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600f60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166340c10f1933846040518363ffffffff1660e01b815260040161252f929190614c16565b602060405180830381600087803b15801561254957600080fd5b505af115801561255d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125819190614c54565b9050806125ba576040517f4737a44500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b423373ffffffffffffffffffffffffffffffffffffffff167fda4c6a5ee0b2d3f2479a401278b140b9fdf84859a014aea79816e9638345059a846040516126019190613efd565b60405180910390a3505050565b612619848484610fcb565b60008373ffffffffffffffffffffffffffffffffffffffff163b1461267b5761264484848484613202565b61267a576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b50505050565b600c5481565b61268f613ba0565b612697613ba0565b61269f612dd0565b8310806126b357506126af6131f9565b8310155b156126c157809150506126ec565b6126ca836131ce565b90508060400151156126df57809150506126ec565b6126e883613362565b9150505b919050565b60606126fc82612d69565b612732576040517fa14c4b5000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061273c613382565b905060008151141561275d5760405180602001604052806000815250612788565b8061276784613414565b604051602001612778929190614cbd565b6040516020818303038152906040525b915050919050565b600b5481565b6012602052816000526040600020602052806000526040600020600091509150505481565b6000600760008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b600180600281111561286457612863614430565b5b600a60009054906101000a900460ff16600281111561288657612885614430565b5b146128bd576040517ff9dd843f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612931838380806020026020016040519081016040528093929190818152602001838360200280828437600081840152601f19601f82011690508083019250505050505050600b54336040516020016129169190614bc7565b6040516020818303038152906040528051906020012061308e565b612967576040517f106323b400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612630612972610eb4565b106129a9576040517f41eb528000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610378600c54106129e6576040517f0748c45200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6703d48c89a60200003414612a27576040517f25acab5d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d60003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff1615612aab576040517fed554ed900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6004600c5401600c819055506001600d60003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff021916908315150217905550612b1a336004613070565b423373ffffffffffffffffffffffffffffffffffffffff167f4c4aacb77138163adee65ce2fc6ebc1c7111049703ca6a69485495b46c93935860405160405180910390a3505050565b612b6b612f81565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415612bdb576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612bd290614d53565b60405180910390fd5b612be4816130a5565b50565b612bef612f81565b6002806002811115612c0457612c03614430565b5b600a60009054906101000a900460ff166002811115612c2657612c25614430565b5b14612c5d576040517ff9dd843f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000858590509050838390508114612ca1576040517f049c97cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015612d3b57848482818110612cbf57612cbe614afa565b5b90506020020135600e6000898985818110612cdd57612cdc614afa565b5b9050602002016020810190612cf29190613d39565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550806001019050612ca4565b50505050505050565b6011602052816000526040600020602052806000526040600020600091509150505481565b600081612d74612dd0565b11158015612d83575060005482105b8015612dc1575060007c0100000000000000000000000000000000000000000000000000000000600460008581526020019081526020016000205416145b9050919050565b600033905090565b600090565b60008082905080612de4612dd0565b11612e6c57600054811015612e6b5760006004600083815260200190815260200160002054905060007c010000000000000000000000000000000000000000000000000000000082161415612e69575b6000811415612e5f576004600083600190039350838152602001908152602001600020549050612e34565b8092505050612e9e565b505b5b6040517fdf2d9b4200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b919050565b60008060006006600085815260200190815260200160002090508092508254915050915091565b600073ffffffffffffffffffffffffffffffffffffffff8316925073ffffffffffffffffffffffffffffffffffffffff821691508382148383141790509392505050565b612f16613464565b612f22848484846134ae565b50505050565b60008060e883901c905060e8612f3f8686846134b4565b62ffffff16901b9150509392505050565b600073ffffffffffffffffffffffffffffffffffffffff83169250814260a01b178317905092915050565b50505050565b612f896134bd565b73ffffffffffffffffffffffffffffffffffffffff16612fa7611e0f565b73ffffffffffffffffffffffffffffffffffffffff1614612ffd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612ff490614dbf565b60405180910390fd5b565b61300a8160006134c5565b50565b613015613719565b6000600860146101000a81548160ff0219169083151502179055507f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa6130596134bd565b6040516130669190613e93565b60405180910390a1565b61308a828260405180602001604052806000815250613762565b5050565b60008261309b85846137ff565b1490509392505050565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905081600860006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b613173613464565b6001600860146101000a81548160ff0219169083151502179055507f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586131b76134bd565b6040516131c49190613e93565b60405180910390a1565b6131d6613ba0565b6131f26004600084815260200190815260200160002054613855565b9050919050565b60008054905090565b60008373ffffffffffffffffffffffffffffffffffffffff1663150b7a02613228612dc8565b8786866040518563ffffffff1660e01b815260040161324a9493929190614e34565b602060405180830381600087803b15801561326457600080fd5b505af192505050801561329557506040513d601f19601f820116820180604052508101906132929190614e95565b60015b61330f573d80600081146132c5576040519150601f19603f3d011682016040523d82523d6000602084013e6132ca565b606091505b50600081511415613307576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805181602001fd5b63150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614915050949350505050565b61336a613ba0565b61337b61337683612dd5565b613855565b9050919050565b60606009805461339190614a08565b80601f01602080910402602001604051908101604052809291908181526020018280546133bd90614a08565b801561340a5780601f106133df5761010080835404028352916020019161340a565b820191906000526020600020905b8154815290600101906020018083116133ed57829003601f168201915b5050505050905090565b606060806040510190508060405280825b60011561345057600183039250600a81066030018353600a810490508061344b57613450565b613425565b508181036020830392508083525050919050565b61346c611930565b156134ac576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016134a390614f0e565b60405180910390fd5b565b50505050565b60009392505050565b600033905090565b60006134d083612dd5565b905060008190506000806134e386612ea3565b91509150841561354c576134ff81846134fa612dc8565b612eca565b61354b576135148361350f612dc8565b6127bb565b61354a576040517f59c896be00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b5b61355a836000886001612f0e565b801561356557600082555b600160806001901b03600560008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000828254019250508190555061360d836135ca85600088612f28565b7c02000000000000000000000000000000000000000000000000000000007c01000000000000000000000000000000000000000000000000000000001717612f50565b600460008881526020019081526020016000208190555060007c020000000000000000000000000000000000000000000000000000000085161415613695576000600187019050600060046000838152602001908152602001600020541415613693576000548114613692578460046000838152602001908152602001600020819055505b5b505b85600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a46136ff836000886001612f7b565b600160008154809291906001019190505550505050505050565b613721611930565b613760576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161375790614f7a565b60405180910390fd5b565b61376c838361390b565b60008373ffffffffffffffffffffffffffffffffffffffff163b146137fa57600080549050600083820390505b6137ac6000868380600101945086613202565b6137e2576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8181106137995781600054146137f757600080fd5b50505b505050565b60008082905060005b845181101561384a576138358286838151811061382857613827614afa565b5b6020026020010151613ac8565b9150808061384290614f9a565b915050613808565b508091505092915050565b61385d613ba0565b81816000019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff168152505060a082901c816020019067ffffffffffffffff16908167ffffffffffffffff168152505060007c01000000000000000000000000000000000000000000000000000000008316141581604001901515908115158152505060e882901c816060019062ffffff16908162ffffff1681525050919050565b600080549050600082141561394c576040517fb562e8dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6139596000848385612f0e565b600160406001901b178202600560008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055506139d0836139c16000866000612f28565b6139ca85613af3565b17612f50565b6004600083815260200190815260200160002081905550600080838301905073ffffffffffffffffffffffffffffffffffffffff85169150828260007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600080a4600183015b818114613a7157808360007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600080a4600181019050613a36565b506000821415613aad576040517f2e07630000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806000819055505050613ac36000848385612f7b565b505050565b6000818310613ae057613adb8284613b03565b613aeb565b613aea8383613b03565b5b905092915050565b60006001821460e11b9050919050565b600082600052816020526040600020905092915050565b828054613b2690614a08565b90600052602060002090601f016020900481019282613b485760008555613b8f565b82601f10613b6157805160ff1916838001178555613b8f565b82800160010185558215613b8f579182015b82811115613b8e578251825591602001919060010190613b73565b5b509050613b9c9190613bef565b5090565b6040518060800160405280600073ffffffffffffffffffffffffffffffffffffffff168152602001600067ffffffffffffffff168152602001600015158152602001600062ffffff1681525090565b5b80821115613c08576000816000905550600101613bf0565b5090565b6000604051905090565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b613c5581613c20565b8114613c6057600080fd5b50565b600081359050613c7281613c4c565b92915050565b600060208284031215613c8e57613c8d613c16565b5b6000613c9c84828501613c63565b91505092915050565b60008115159050919050565b613cba81613ca5565b82525050565b6000602082019050613cd56000830184613cb1565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000613d0682613cdb565b9050919050565b613d1681613cfb565b8114613d2157600080fd5b50565b600081359050613d3381613d0d565b92915050565b600060208284031215613d4f57613d4e613c16565b5b6000613d5d84828501613d24565b91505092915050565b600081519050919050565b600082825260208201905092915050565b60005b83811015613da0578082015181840152602081019050613d85565b83811115613daf576000848401525b50505050565b6000601f19601f8301169050919050565b6000613dd182613d66565b613ddb8185613d71565b9350613deb818560208601613d82565b613df481613db5565b840191505092915050565b60006020820190508181036000830152613e198184613dc6565b905092915050565b6000819050919050565b613e3481613e21565b8114613e3f57600080fd5b50565b600081359050613e5181613e2b565b92915050565b600060208284031215613e6d57613e6c613c16565b5b6000613e7b84828501613e42565b91505092915050565b613e8d81613cfb565b82525050565b6000602082019050613ea86000830184613e84565b92915050565b60008060408385031215613ec557613ec4613c16565b5b6000613ed385828601613d24565b9250506020613ee485828601613e42565b9150509250929050565b613ef781613e21565b82525050565b6000602082019050613f126000830184613eee565b92915050565b6000819050919050565b6000613f3d613f38613f3384613cdb565b613f18565b613cdb565b9050919050565b6000613f4f82613f22565b9050919050565b6000613f6182613f44565b9050919050565b613f7181613f56565b82525050565b6000602082019050613f8c6000830184613f68565b92915050565b600080600060608486031215613fab57613faa613c16565b5b6000613fb986828701613d24565b9350506020613fca86828701613d24565b9250506040613fdb86828701613e42565b9150509250925092565b60038110613ff257600080fd5b50565b60008135905061400481613fe5565b92915050565b6000819050919050565b61401d8161400a565b811461402857600080fd5b50565b60008135905061403a81614014565b92915050565b6000806040838503121561405757614056613c16565b5b600061406585828601613ff5565b92505060206140768582860161402b565b9150509250929050565b600080fd5b600080fd5b600080fd5b60008083601f8401126140a5576140a4614080565b5b8235905067ffffffffffffffff8111156140c2576140c1614085565b5b6020830191508360208202830111156140de576140dd61408a565b5b9250929050565b600080602083850312156140fc576140fb613c16565b5b600083013567ffffffffffffffff81111561411a57614119613c1b565b5b6141268582860161408f565b92509250509250929050565b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61416f82613db5565b810181811067ffffffffffffffff8211171561418e5761418d614137565b5b80604052505050565b60006141a1613c0c565b90506141ad8282614166565b919050565b600067ffffffffffffffff8211156141cd576141cc614137565b5b6141d682613db5565b9050602081019050919050565b82818337600083830152505050565b6000614205614200846141b2565b614197565b90508281526020810184848401111561422157614220614132565b5b61422c8482856141e3565b509392505050565b600082601f83011261424957614248614080565b5b81356142598482602086016141f2565b91505092915050565b60006020828403121561427857614277613c16565b5b600082013567ffffffffffffffff81111561429657614295613c1b565b5b6142a284828501614234565b91505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6142e081613cfb565b82525050565b600067ffffffffffffffff82169050919050565b614303816142e6565b82525050565b61431281613ca5565b82525050565b600062ffffff82169050919050565b61433081614318565b82525050565b60808201600082015161434c60008501826142d7565b50602082015161435f60208501826142fa565b5060408201516143726040850182614309565b5060608201516143856060850182614327565b50505050565b60006143978383614336565b60808301905092915050565b6000602082019050919050565b60006143bb826142ab565b6143c581856142b6565b93506143d0836142c7565b8060005b838110156144015781516143e8888261438b565b97506143f3836143a3565b9250506001810190506143d4565b5085935050505092915050565b6000602082019050818103600083015261442881846143b0565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600381106144705761446f614430565b5b50565b60008190506144818261445f565b919050565b600061449182614473565b9050919050565b6144a181614486565b82525050565b60006020820190506144bc6000830184614498565b92915050565b60008083601f8401126144d8576144d7614080565b5b8235905067ffffffffffffffff8111156144f5576144f4614085565b5b6020830191508360208202830111156145115761451061408a565b5b9250929050565b6000806020838503121561452f5761452e613c16565b5b600083013567ffffffffffffffff81111561454d5761454c613c1b565b5b614559858286016144c2565b92509250509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61459a81613e21565b82525050565b60006145ac8383614591565b60208301905092915050565b6000602082019050919050565b60006145d082614565565b6145da8185614570565b93506145e583614581565b8060005b838110156146165781516145fd88826145a0565b9750614608836145b8565b9250506001810190506145e9565b5085935050505092915050565b6000602082019050818103600083015261463d81846145c5565b905092915050565b60008060006060848603121561465e5761465d613c16565b5b600061466c86828701613d24565b935050602061467d86828701613e42565b925050604061468e86828701613e42565b9150509250925092565b6146a181613ca5565b81146146ac57600080fd5b50565b6000813590506146be81614698565b92915050565b600080604083850312156146db576146da613c16565b5b60006146e985828601613d24565b92505060206146fa858286016146af565b9150509250929050565b600067ffffffffffffffff82111561471f5761471e614137565b5b61472882613db5565b9050602081019050919050565b600061474861474384614704565b614197565b90508281526020810184848401111561476457614763614132565b5b61476f8482856141e3565b509392505050565b600082601f83011261478c5761478b614080565b5b813561479c848260208601614735565b91505092915050565b600080600080608085870312156147bf576147be613c16565b5b60006147cd87828801613d24565b94505060206147de87828801613d24565b93505060406147ef87828801613e42565b925050606085013567ffffffffffffffff8111156148105761480f613c1b565b5b61481c87828801614777565b91505092959194509250565b60808201600082015161483e60008501826142d7565b50602082015161485160208501826142fa565b5060408201516148646040850182614309565b5060608201516148776060850182614327565b50505050565b60006080820190506148926000830184614828565b92915050565b6148a18161400a565b82525050565b60006020820190506148bc6000830184614898565b92915050565b600080604083850312156148d9576148d8613c16565b5b60006148e785828601613d24565b92505060206148f885828601613d24565b9150509250929050565b60008083601f84011261491857614917614080565b5b8235905067ffffffffffffffff81111561493557614934614085565b5b6020830191508360208202830111156149515761495061408a565b5b9250929050565b6000806000806040858703121561497257614971613c16565b5b600085013567ffffffffffffffff8111156149905761498f613c1b565b5b61499c87828801614902565b9450945050602085013567ffffffffffffffff8111156149bf576149be613c1b565b5b6149cb8782880161408f565b925092505092959194509250565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60006002820490506001821680614a2057607f821691505b60208210811415614a3457614a336149d9565b5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000614a7482613e21565b9150614a7f83613e21565b925082614a8f57614a8e614a3a565b5b828206905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000614ad482613e21565b9150614adf83613e21565b925082614aef57614aee614a3a565b5b828204905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6000614b3482613e21565b9150614b3f83613e21565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115614b7457614b73614a9a565b5b828201905092915050565b60008160601b9050919050565b6000614b9782614b7f565b9050919050565b6000614ba982614b8c565b9050919050565b614bc1614bbc82613cfb565b614b9e565b82525050565b6000614bd38284614bb0565b60148201915081905092915050565b6000614bed82613e21565b9150614bf883613e21565b925082821015614c0b57614c0a614a9a565b5b828203905092915050565b6000604082019050614c2b6000830185613e84565b614c386020830184613eee565b9392505050565b600081519050614c4e81614698565b92915050565b600060208284031215614c6a57614c69613c16565b5b6000614c7884828501614c3f565b91505092915050565b600081905092915050565b6000614c9782613d66565b614ca18185614c81565b9350614cb1818560208601613d82565b80840191505092915050565b6000614cc98285614c8c565b9150614cd58284614c8c565b91508190509392505050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b6000614d3d602683613d71565b9150614d4882614ce1565b604082019050919050565b60006020820190508181036000830152614d6c81614d30565b9050919050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b6000614da9602083613d71565b9150614db482614d73565b602082019050919050565b60006020820190508181036000830152614dd881614d9c565b9050919050565b600081519050919050565b600082825260208201905092915050565b6000614e0682614ddf565b614e108185614dea565b9350614e20818560208601613d82565b614e2981613db5565b840191505092915050565b6000608082019050614e496000830187613e84565b614e566020830186613e84565b614e636040830185613eee565b8181036060830152614e758184614dfb565b905095945050505050565b600081519050614e8f81613c4c565b92915050565b600060208284031215614eab57614eaa613c16565b5b6000614eb984828501614e80565b91505092915050565b7f5061757361626c653a2070617573656400000000000000000000000000000000600082015250565b6000614ef8601083613d71565b9150614f0382614ec2565b602082019050919050565b60006020820190508181036000830152614f2781614eeb565b9050919050565b7f5061757361626c653a206e6f7420706175736564000000000000000000000000600082015250565b6000614f64601483613d71565b9150614f6f82614f2e565b602082019050919050565b60006020820190508181036000830152614f9381614f57565b9050919050565b6000614fa582613e21565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415614fd857614fd7614a9a565b5b60018201905091905056fea2646970667358221220a0167164e789bc96aacef69a578ac620dee7bca95f30484bce3562c83c57dfb864736f6c6343000809003300000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000043697066733a2f2f626166796265696772723271797479327575326169346a636e3466346e6e656e67777963723573346e6a646c6770706e706d717364717166766a712f0000000000000000000000000000000000000000000000000000000000

Deployed Bytecode

0x6080604052600436106102ae5760003560e01c80635bbb217711610175578063a22cb465116100dc578063d4db554711610095578063edc0c72c1161006f578063edc0c72c14610ad4578063f2fde38b14610af0578063f797d7bc14610b19578063fb88f0a414610b42576102ae565b8063d4db554714610a2f578063de16bc0f14610a5a578063e985e9c514610a97576102ae565b8063a22cb46514610921578063aaf8ba8e1461094a578063b88d4fde14610961578063b8df93eb1461098a578063c23dc68f146109b5578063c87b56dd146109f2576102ae565b8063715018a61161012e578063715018a6146108235780638456cb591461083a5780638462151c146108515780638da5cb5b1461088e57806395d89b41146108b957806399a2557a146108e4576102ae565b80635bbb2177146106ed5780635c975abb1461072a5780635d3aa87e146107555780636352211e146107805780636f77197d146107bd57806370a08231146107e6576102ae565b806322e0ab9c116102195780633ccfd60b116101d25780633ccfd60b1461061b5780633f4ba83a1461063257806340c10f191461064957806342842e0e1461067257806342966c681461069b57806355f804b3146106c4576102ae565b806322e0ab9c1461052157806323b872dd1461054c57806325b3ec381461057557806332cb6b0c1461059e57806336372ac5146105c957806336dab767146105f2576102ae565b80631302a66f1161026b5780631302a66f146103e957806318160ddd14610414578063192051cf1461043f5780631f6bebff1461047c5780631f7dcafe146104a757806321ea9e20146104e4576102ae565b806301ffc9a7146102b357806303ad62bb146102f057806306fdde031461032d578063081812fc14610358578063095ea7b3146103955780630f28c97d146103be575b600080fd5b3480156102bf57600080fd5b506102da60048036038101906102d59190613c78565b610b7f565b6040516102e79190613cc0565b60405180910390f35b3480156102fc57600080fd5b5061031760048036038101906103129190613d39565b610c11565b6040516103249190613cc0565b60405180910390f35b34801561033957600080fd5b50610342610c31565b60405161034f9190613dff565b60405180910390f35b34801561036457600080fd5b5061037f600480360381019061037a9190613e57565b610cc3565b60405161038c9190613e93565b60405180910390f35b3480156103a157600080fd5b506103bc60048036038101906103b79190613eae565b610d42565b005b3480156103ca57600080fd5b506103d3610e86565b6040516103e09190613efd565b60405180910390f35b3480156103f557600080fd5b506103fe610e8e565b60405161040b9190613f77565b60405180910390f35b34801561042057600080fd5b50610429610eb4565b6040516104369190613efd565b60405180910390f35b34801561044b57600080fd5b5061046660048036038101906104619190613d39565b610ecb565b6040516104739190613efd565b60405180910390f35b34801561048857600080fd5b50610491610ee3565b60405161049e9190613cc0565b60405180910390f35b3480156104b357600080fd5b506104ce60048036038101906104c99190613d39565b610ef6565b6040516104db9190613efd565b60405180910390f35b3480156104f057600080fd5b5061050b60048036038101906105069190613eae565b610f0e565b6040516105189190613cc0565b60405180910390f35b34801561052d57600080fd5b50610536610f3d565b6040516105439190613dff565b60405180910390f35b34801561055857600080fd5b50610573600480360381019061056e9190613f92565b610fcb565b005b34801561058157600080fd5b5061059c60048036038101906105979190613d39565b6112f0565b005b3480156105aa57600080fd5b506105b361139e565b6040516105c09190613efd565b60405180910390f35b3480156105d557600080fd5b506105f060048036038101906105eb9190614040565b6113a4565b005b3480156105fe57600080fd5b50610619600480360381019061061491906140e5565b6113e1565b005b34801561062757600080fd5b50610630611749565b005b34801561063e57600080fd5b506106476117a1565b005b34801561065557600080fd5b50610670600480360381019061066b9190613eae565b6117b3565b005b34801561067e57600080fd5b5061069960048036038101906106949190613f92565b611817565b005b3480156106a757600080fd5b506106c260048036038101906106bd9190613e57565b611837565b005b3480156106d057600080fd5b506106eb60048036038101906106e69190614262565b61184b565b005b3480156106f957600080fd5b50610714600480360381019061070f91906140e5565b61186d565b604051610721919061440e565b60405180910390f35b34801561073657600080fd5b5061073f611930565b60405161074c9190613cc0565b60405180910390f35b34801561076157600080fd5b5061076a611947565b60405161077791906144a7565b60405180910390f35b34801561078c57600080fd5b506107a760048036038101906107a29190613e57565b61195a565b6040516107b49190613e93565b60405180910390f35b3480156107c957600080fd5b506107e460048036038101906107df9190614518565b61196c565b005b3480156107f257600080fd5b5061080d60048036038101906108089190613d39565b611be6565b60405161081a9190613efd565b60405180910390f35b34801561082f57600080fd5b50610838611c9f565b005b34801561084657600080fd5b5061084f611cb3565b005b34801561085d57600080fd5b5061087860048036038101906108739190613d39565b611cc5565b6040516108859190614623565b60405180910390f35b34801561089a57600080fd5b506108a3611e0f565b6040516108b09190613e93565b60405180910390f35b3480156108c557600080fd5b506108ce611e39565b6040516108db9190613dff565b60405180910390f35b3480156108f057600080fd5b5061090b60048036038101906109069190614645565b611ecb565b6040516109189190614623565b60405180910390f35b34801561092d57600080fd5b50610948600480360381019061094391906146c4565b6120df565b005b34801561095657600080fd5b5061095f612257565b005b34801561096d57600080fd5b50610988600480360381019061098391906147a5565b61260e565b005b34801561099657600080fd5b5061099f612681565b6040516109ac9190613efd565b60405180910390f35b3480156109c157600080fd5b506109dc60048036038101906109d79190613e57565b612687565b6040516109e9919061487d565b60405180910390f35b3480156109fe57600080fd5b50610a196004803603810190610a149190613e57565b6126f1565b604051610a269190613dff565b60405180910390f35b348015610a3b57600080fd5b50610a44612790565b604051610a5191906148a7565b60405180910390f35b348015610a6657600080fd5b50610a816004803603810190610a7c9190613eae565b612796565b604051610a8e9190613efd565b60405180910390f35b348015610aa357600080fd5b50610abe6004803603810190610ab991906148c2565b6127bb565b604051610acb9190613cc0565b60405180910390f35b610aee6004803603810190610ae99190614518565b61284f565b005b348015610afc57600080fd5b50610b176004803603810190610b129190613d39565b612b63565b005b348015610b2557600080fd5b50610b406004803603810190610b3b9190614958565b612be7565b005b348015610b4e57600080fd5b50610b696004803603810190610b649190613eae565b612d44565b604051610b769190613efd565b60405180910390f35b60006301ffc9a760e01b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480610bda57506380ac58cd60e01b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b80610c0a5750635b5e139f60e01b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b9050919050565b600d6020528060005260406000206000915054906101000a900460ff1681565b606060028054610c4090614a08565b80601f0160208091040260200160405190810160405280929190818152602001828054610c6c90614a08565b8015610cb95780601f10610c8e57610100808354040283529160200191610cb9565b820191906000526020600020905b815481529060010190602001808311610c9c57829003601f168201915b5050505050905090565b6000610cce82612d69565b610d04576040517fcf4700e400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6006600083815260200190815260200160002060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b6000610d4d8261195a565b90508073ffffffffffffffffffffffffffffffffffffffff16610d6e612dc8565b73ffffffffffffffffffffffffffffffffffffffff1614610dd157610d9a81610d95612dc8565b6127bb565b610dd0576040517fcfb3b94200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b826006600084815260200190815260200160002060000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550818373ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a4505050565b600042905090565b600f60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000610ebe612dd0565b6001546000540303905090565b600e6020528060005260406000206000915090505481565b600f60149054906101000a900460ff1681565b60106020528060005260406000206000915090505481565b60136020528160005260406000206020528060005260406000206000915091509054906101000a900460ff1681565b60098054610f4a90614a08565b80601f0160208091040260200160405190810160405280929190818152602001828054610f7690614a08565b8015610fc35780601f10610f9857610100808354040283529160200191610fc3565b820191906000526020600020905b815481529060010190602001808311610fa657829003601f168201915b505050505081565b6000610fd682612dd5565b90508373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161461103d576040517fa114810000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008061104984612ea3565b9150915061105f818761105a612dc8565b612eca565b6110ab576110748661106f612dc8565b6127bb565b6110aa576040517f59c896be00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161415611112576040517fea553b3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61111f8686866001612f0e565b801561112a57600082555b600560008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600081546001900391905081905550600560008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008154600101919050819055506111f8856111d4888887612f28565b7c020000000000000000000000000000000000000000000000000000000017612f50565b600460008681526020019081526020016000208190555060007c02000000000000000000000000000000000000000000000000000000008416141561128057600060018501905060006004600083815260200190815260200160002054141561127e57600054811461127d578360046000838152602001908152602001600020819055505b5b505b838573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a46112e88686866001612f7b565b505050505050565b6112f8612f81565b600f60149054906101000a900460ff161561133f576040517f67fc29a400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80600f60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506001600f60146101000a81548160ff02191690831515021790555050565b61263081565b6113ac612f81565b81600a60006101000a81548160ff021916908360028111156113d1576113d0614430565b5b021790555080600b819055505050565b60008282905090506000811415611424576040517ff5ad9bf300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006004826114339190614a69565b1461146a576040517fde4285d100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61147333611be6565b8111156114ac576040517ff1bbe29900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000601060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490506004826114fd9190614ac9565b601160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008381526020019081526020016000208190555042601260003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002081905550601060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600081546001019190508190555060005b828110156116f357600085858381811061161357611612614afa565b5b9050602002013590503373ffffffffffffffffffffffffffffffffffffffff1661163c8261195a565b73ffffffffffffffffffffffffffffffffffffffff1614156116665761166181612fff565b611698565b6040517f47d4e58800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b423373ffffffffffffffffffffffffffffffffffffffff167f2ddeb9fdf97b8928a1720dc2febe475593debc796867772369b73353bed6b8ce836040516116df9190613efd565b60405180910390a3816001019150506115f6565b50423373ffffffffffffffffffffffffffffffffffffffff167f8384c640888323da22f28fab6b1650beb26ea1310d51f28f82676f66ddc3f6fa8460405161173b9190613efd565b60405180910390a350505050565b611751612f81565b611759611e0f565b73ffffffffffffffffffffffffffffffffffffffff166108fc479081150290604051600060405180830381858888f1935050505015801561179e573d6000803e3d6000fd5b50565b6117a9612f81565b6117b161300d565b565b6117bb612f81565b612630816117c7610eb4565b6117d19190614b29565b1115611809576040517f41eb528000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6118138282613070565b5050565b6118328383836040518060200160405280600081525061260e565b505050565b61183f612f81565b61184881612fff565b50565b611853612f81565b8060099080519060200190611869929190613b1a565b5050565b6060600083839050905060008167ffffffffffffffff81111561189357611892614137565b5b6040519080825280602002602001820160405280156118cc57816020015b6118b9613ba0565b8152602001906001900390816118b15790505b50905060005b828114611924576118fb8686838181106118ef576118ee614afa565b5b90506020020135612687565b82828151811061190e5761190d614afa565b5b60200260200101819052508060010190506118d2565b50809250505092915050565b6000600860149054906101000a900460ff16905090565b600a60009054906101000a900460ff1681565b600061196582612dd5565b9050919050565b600280600281111561198157611980614430565b5b600a60009054906101000a900460ff1660028111156119a3576119a2614430565b5b146119da576040517ff9dd843f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611a4e838380806020026020016040519081016040528093929190818152602001838360200280828437600081840152601f19601f82011690508083019250505050505050600b5433604051602001611a339190614bc7565b6040516020818303038152906040528051906020012061308e565b611a84576040517f106323b400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600e60003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020541415611afe576040517faf92324e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600e60003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490506000600e60003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550611b913382613070565b423373ffffffffffffffffffffffffffffffffffffffff167f14e5934ee1ceffb970cd4e24dfdb6dd75fc3e8abdf513018f9b783db67388abb83604051611bd89190613efd565b60405180910390a350505050565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611c4e576040517f8f4eb60400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054169050919050565b611ca7612f81565b611cb160006130a5565b565b611cbb612f81565b611cc361316b565b565b60606000806000611cd585611be6565b905060008167ffffffffffffffff811115611cf357611cf2614137565b5b604051908082528060200260200182016040528015611d215781602001602082028036833780820191505090505b509050611d2c613ba0565b6000611d36612dd0565b90505b838614611e0157611d49816131ce565b9150816040015115611d5a57611df6565b600073ffffffffffffffffffffffffffffffffffffffff16826000015173ffffffffffffffffffffffffffffffffffffffff1614611d9a57816000015194505b8773ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161415611df55780838780600101985081518110611de857611de7614afa565b5b6020026020010181815250505b5b806001019050611d39565b508195505050505050919050565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b606060038054611e4890614a08565b80601f0160208091040260200160405190810160405280929190818152602001828054611e7490614a08565b8015611ec15780601f10611e9657610100808354040283529160200191611ec1565b820191906000526020600020905b815481529060010190602001808311611ea457829003601f168201915b5050505050905090565b6060818310611f06576040517f32c1995a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080611f116131f9565b9050611f1b612dd0565b851015611f2d57611f2a612dd0565b94505b80841115611f39578093505b6000611f4487611be6565b905084861015611f67576000868603905081811015611f61578091505b50611f6c565b600090505b60008167ffffffffffffffff811115611f8857611f87614137565b5b604051908082528060200260200182016040528015611fb65781602001602082028036833780820191505090505b5090506000821415611fce57809450505050506120d8565b6000611fd988612687565b905060008160400151611fee57816000015190505b60008990505b8881141580156120045750848714155b156120ca57612012816131ce565b9250826040015115612023576120bf565b600073ffffffffffffffffffffffffffffffffffffffff16836000015173ffffffffffffffffffffffffffffffffffffffff161461206357826000015191505b8a73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156120be57808488806001019950815181106120b1576120b0614afa565b5b6020026020010181815250505b5b806001019050611ff4565b508583528296505050505050505b9392505050565b6120e7612dc8565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141561214c576040517fb06307db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060076000612159612dc8565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff16612206612dc8565b73ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c318360405161224b9190613cc0565b60405180910390a35050565b600f60149054906101000a900460ff1661229d576040517f9b115b9000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000601060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490506000805b82811015612494576000601260003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002054905062278d0081426123529190614be2565b101580156123bb5750601360003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002060009054906101000a900460ff16155b1561248857601160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000838152602001908152602001600020548361241c9190614b29565b92506001601360003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600084815260200190815260200160002060006101000a81548160ff0219169083151502179055505b816001019150506122e5565b5060008114156124d0576040517f4d201a1a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600f60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166340c10f1933846040518363ffffffff1660e01b815260040161252f929190614c16565b602060405180830381600087803b15801561254957600080fd5b505af115801561255d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125819190614c54565b9050806125ba576040517f4737a44500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b423373ffffffffffffffffffffffffffffffffffffffff167fda4c6a5ee0b2d3f2479a401278b140b9fdf84859a014aea79816e9638345059a846040516126019190613efd565b60405180910390a3505050565b612619848484610fcb565b60008373ffffffffffffffffffffffffffffffffffffffff163b1461267b5761264484848484613202565b61267a576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b50505050565b600c5481565b61268f613ba0565b612697613ba0565b61269f612dd0565b8310806126b357506126af6131f9565b8310155b156126c157809150506126ec565b6126ca836131ce565b90508060400151156126df57809150506126ec565b6126e883613362565b9150505b919050565b60606126fc82612d69565b612732576040517fa14c4b5000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061273c613382565b905060008151141561275d5760405180602001604052806000815250612788565b8061276784613414565b604051602001612778929190614cbd565b6040516020818303038152906040525b915050919050565b600b5481565b6012602052816000526040600020602052806000526040600020600091509150505481565b6000600760008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b600180600281111561286457612863614430565b5b600a60009054906101000a900460ff16600281111561288657612885614430565b5b146128bd576040517ff9dd843f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612931838380806020026020016040519081016040528093929190818152602001838360200280828437600081840152601f19601f82011690508083019250505050505050600b54336040516020016129169190614bc7565b6040516020818303038152906040528051906020012061308e565b612967576040517f106323b400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612630612972610eb4565b106129a9576040517f41eb528000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610378600c54106129e6576040517f0748c45200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6703d48c89a60200003414612a27576040517f25acab5d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d60003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff1615612aab576040517fed554ed900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6004600c5401600c819055506001600d60003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff021916908315150217905550612b1a336004613070565b423373ffffffffffffffffffffffffffffffffffffffff167f4c4aacb77138163adee65ce2fc6ebc1c7111049703ca6a69485495b46c93935860405160405180910390a3505050565b612b6b612f81565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415612bdb576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612bd290614d53565b60405180910390fd5b612be4816130a5565b50565b612bef612f81565b6002806002811115612c0457612c03614430565b5b600a60009054906101000a900460ff166002811115612c2657612c25614430565b5b14612c5d576040517ff9dd843f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000858590509050838390508114612ca1576040517f049c97cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015612d3b57848482818110612cbf57612cbe614afa565b5b90506020020135600e6000898985818110612cdd57612cdc614afa565b5b9050602002016020810190612cf29190613d39565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550806001019050612ca4565b50505050505050565b6011602052816000526040600020602052806000526040600020600091509150505481565b600081612d74612dd0565b11158015612d83575060005482105b8015612dc1575060007c0100000000000000000000000000000000000000000000000000000000600460008581526020019081526020016000205416145b9050919050565b600033905090565b600090565b60008082905080612de4612dd0565b11612e6c57600054811015612e6b5760006004600083815260200190815260200160002054905060007c010000000000000000000000000000000000000000000000000000000082161415612e69575b6000811415612e5f576004600083600190039350838152602001908152602001600020549050612e34565b8092505050612e9e565b505b5b6040517fdf2d9b4200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b919050565b60008060006006600085815260200190815260200160002090508092508254915050915091565b600073ffffffffffffffffffffffffffffffffffffffff8316925073ffffffffffffffffffffffffffffffffffffffff821691508382148383141790509392505050565b612f16613464565b612f22848484846134ae565b50505050565b60008060e883901c905060e8612f3f8686846134b4565b62ffffff16901b9150509392505050565b600073ffffffffffffffffffffffffffffffffffffffff83169250814260a01b178317905092915050565b50505050565b612f896134bd565b73ffffffffffffffffffffffffffffffffffffffff16612fa7611e0f565b73ffffffffffffffffffffffffffffffffffffffff1614612ffd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612ff490614dbf565b60405180910390fd5b565b61300a8160006134c5565b50565b613015613719565b6000600860146101000a81548160ff0219169083151502179055507f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa6130596134bd565b6040516130669190613e93565b60405180910390a1565b61308a828260405180602001604052806000815250613762565b5050565b60008261309b85846137ff565b1490509392505050565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905081600860006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b613173613464565b6001600860146101000a81548160ff0219169083151502179055507f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586131b76134bd565b6040516131c49190613e93565b60405180910390a1565b6131d6613ba0565b6131f26004600084815260200190815260200160002054613855565b9050919050565b60008054905090565b60008373ffffffffffffffffffffffffffffffffffffffff1663150b7a02613228612dc8565b8786866040518563ffffffff1660e01b815260040161324a9493929190614e34565b602060405180830381600087803b15801561326457600080fd5b505af192505050801561329557506040513d601f19601f820116820180604052508101906132929190614e95565b60015b61330f573d80600081146132c5576040519150601f19603f3d011682016040523d82523d6000602084013e6132ca565b606091505b50600081511415613307576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805181602001fd5b63150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614915050949350505050565b61336a613ba0565b61337b61337683612dd5565b613855565b9050919050565b60606009805461339190614a08565b80601f01602080910402602001604051908101604052809291908181526020018280546133bd90614a08565b801561340a5780601f106133df5761010080835404028352916020019161340a565b820191906000526020600020905b8154815290600101906020018083116133ed57829003601f168201915b5050505050905090565b606060806040510190508060405280825b60011561345057600183039250600a81066030018353600a810490508061344b57613450565b613425565b508181036020830392508083525050919050565b61346c611930565b156134ac576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016134a390614f0e565b60405180910390fd5b565b50505050565b60009392505050565b600033905090565b60006134d083612dd5565b905060008190506000806134e386612ea3565b91509150841561354c576134ff81846134fa612dc8565b612eca565b61354b576135148361350f612dc8565b6127bb565b61354a576040517f59c896be00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b5b61355a836000886001612f0e565b801561356557600082555b600160806001901b03600560008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000828254019250508190555061360d836135ca85600088612f28565b7c02000000000000000000000000000000000000000000000000000000007c01000000000000000000000000000000000000000000000000000000001717612f50565b600460008881526020019081526020016000208190555060007c020000000000000000000000000000000000000000000000000000000085161415613695576000600187019050600060046000838152602001908152602001600020541415613693576000548114613692578460046000838152602001908152602001600020819055505b5b505b85600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a46136ff836000886001612f7b565b600160008154809291906001019190505550505050505050565b613721611930565b613760576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161375790614f7a565b60405180910390fd5b565b61376c838361390b565b60008373ffffffffffffffffffffffffffffffffffffffff163b146137fa57600080549050600083820390505b6137ac6000868380600101945086613202565b6137e2576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8181106137995781600054146137f757600080fd5b50505b505050565b60008082905060005b845181101561384a576138358286838151811061382857613827614afa565b5b6020026020010151613ac8565b9150808061384290614f9a565b915050613808565b508091505092915050565b61385d613ba0565b81816000019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff168152505060a082901c816020019067ffffffffffffffff16908167ffffffffffffffff168152505060007c01000000000000000000000000000000000000000000000000000000008316141581604001901515908115158152505060e882901c816060019062ffffff16908162ffffff1681525050919050565b600080549050600082141561394c576040517fb562e8dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6139596000848385612f0e565b600160406001901b178202600560008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055506139d0836139c16000866000612f28565b6139ca85613af3565b17612f50565b6004600083815260200190815260200160002081905550600080838301905073ffffffffffffffffffffffffffffffffffffffff85169150828260007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600080a4600183015b818114613a7157808360007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600080a4600181019050613a36565b506000821415613aad576040517f2e07630000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806000819055505050613ac36000848385612f7b565b505050565b6000818310613ae057613adb8284613b03565b613aeb565b613aea8383613b03565b5b905092915050565b60006001821460e11b9050919050565b600082600052816020526040600020905092915050565b828054613b2690614a08565b90600052602060002090601f016020900481019282613b485760008555613b8f565b82601f10613b6157805160ff1916838001178555613b8f565b82800160010185558215613b8f579182015b82811115613b8e578251825591602001919060010190613b73565b5b509050613b9c9190613bef565b5090565b6040518060800160405280600073ffffffffffffffffffffffffffffffffffffffff168152602001600067ffffffffffffffff168152602001600015158152602001600062ffffff1681525090565b5b80821115613c08576000816000905550600101613bf0565b5090565b6000604051905090565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b613c5581613c20565b8114613c6057600080fd5b50565b600081359050613c7281613c4c565b92915050565b600060208284031215613c8e57613c8d613c16565b5b6000613c9c84828501613c63565b91505092915050565b60008115159050919050565b613cba81613ca5565b82525050565b6000602082019050613cd56000830184613cb1565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000613d0682613cdb565b9050919050565b613d1681613cfb565b8114613d2157600080fd5b50565b600081359050613d3381613d0d565b92915050565b600060208284031215613d4f57613d4e613c16565b5b6000613d5d84828501613d24565b91505092915050565b600081519050919050565b600082825260208201905092915050565b60005b83811015613da0578082015181840152602081019050613d85565b83811115613daf576000848401525b50505050565b6000601f19601f8301169050919050565b6000613dd182613d66565b613ddb8185613d71565b9350613deb818560208601613d82565b613df481613db5565b840191505092915050565b60006020820190508181036000830152613e198184613dc6565b905092915050565b6000819050919050565b613e3481613e21565b8114613e3f57600080fd5b50565b600081359050613e5181613e2b565b92915050565b600060208284031215613e6d57613e6c613c16565b5b6000613e7b84828501613e42565b91505092915050565b613e8d81613cfb565b82525050565b6000602082019050613ea86000830184613e84565b92915050565b60008060408385031215613ec557613ec4613c16565b5b6000613ed385828601613d24565b9250506020613ee485828601613e42565b9150509250929050565b613ef781613e21565b82525050565b6000602082019050613f126000830184613eee565b92915050565b6000819050919050565b6000613f3d613f38613f3384613cdb565b613f18565b613cdb565b9050919050565b6000613f4f82613f22565b9050919050565b6000613f6182613f44565b9050919050565b613f7181613f56565b82525050565b6000602082019050613f8c6000830184613f68565b92915050565b600080600060608486031215613fab57613faa613c16565b5b6000613fb986828701613d24565b9350506020613fca86828701613d24565b9250506040613fdb86828701613e42565b9150509250925092565b60038110613ff257600080fd5b50565b60008135905061400481613fe5565b92915050565b6000819050919050565b61401d8161400a565b811461402857600080fd5b50565b60008135905061403a81614014565b92915050565b6000806040838503121561405757614056613c16565b5b600061406585828601613ff5565b92505060206140768582860161402b565b9150509250929050565b600080fd5b600080fd5b600080fd5b60008083601f8401126140a5576140a4614080565b5b8235905067ffffffffffffffff8111156140c2576140c1614085565b5b6020830191508360208202830111156140de576140dd61408a565b5b9250929050565b600080602083850312156140fc576140fb613c16565b5b600083013567ffffffffffffffff81111561411a57614119613c1b565b5b6141268582860161408f565b92509250509250929050565b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61416f82613db5565b810181811067ffffffffffffffff8211171561418e5761418d614137565b5b80604052505050565b60006141a1613c0c565b90506141ad8282614166565b919050565b600067ffffffffffffffff8211156141cd576141cc614137565b5b6141d682613db5565b9050602081019050919050565b82818337600083830152505050565b6000614205614200846141b2565b614197565b90508281526020810184848401111561422157614220614132565b5b61422c8482856141e3565b509392505050565b600082601f83011261424957614248614080565b5b81356142598482602086016141f2565b91505092915050565b60006020828403121561427857614277613c16565b5b600082013567ffffffffffffffff81111561429657614295613c1b565b5b6142a284828501614234565b91505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6142e081613cfb565b82525050565b600067ffffffffffffffff82169050919050565b614303816142e6565b82525050565b61431281613ca5565b82525050565b600062ffffff82169050919050565b61433081614318565b82525050565b60808201600082015161434c60008501826142d7565b50602082015161435f60208501826142fa565b5060408201516143726040850182614309565b5060608201516143856060850182614327565b50505050565b60006143978383614336565b60808301905092915050565b6000602082019050919050565b60006143bb826142ab565b6143c581856142b6565b93506143d0836142c7565b8060005b838110156144015781516143e8888261438b565b97506143f3836143a3565b9250506001810190506143d4565b5085935050505092915050565b6000602082019050818103600083015261442881846143b0565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600381106144705761446f614430565b5b50565b60008190506144818261445f565b919050565b600061449182614473565b9050919050565b6144a181614486565b82525050565b60006020820190506144bc6000830184614498565b92915050565b60008083601f8401126144d8576144d7614080565b5b8235905067ffffffffffffffff8111156144f5576144f4614085565b5b6020830191508360208202830111156145115761451061408a565b5b9250929050565b6000806020838503121561452f5761452e613c16565b5b600083013567ffffffffffffffff81111561454d5761454c613c1b565b5b614559858286016144c2565b92509250509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61459a81613e21565b82525050565b60006145ac8383614591565b60208301905092915050565b6000602082019050919050565b60006145d082614565565b6145da8185614570565b93506145e583614581565b8060005b838110156146165781516145fd88826145a0565b9750614608836145b8565b9250506001810190506145e9565b5085935050505092915050565b6000602082019050818103600083015261463d81846145c5565b905092915050565b60008060006060848603121561465e5761465d613c16565b5b600061466c86828701613d24565b935050602061467d86828701613e42565b925050604061468e86828701613e42565b9150509250925092565b6146a181613ca5565b81146146ac57600080fd5b50565b6000813590506146be81614698565b92915050565b600080604083850312156146db576146da613c16565b5b60006146e985828601613d24565b92505060206146fa858286016146af565b9150509250929050565b600067ffffffffffffffff82111561471f5761471e614137565b5b61472882613db5565b9050602081019050919050565b600061474861474384614704565b614197565b90508281526020810184848401111561476457614763614132565b5b61476f8482856141e3565b509392505050565b600082601f83011261478c5761478b614080565b5b813561479c848260208601614735565b91505092915050565b600080600080608085870312156147bf576147be613c16565b5b60006147cd87828801613d24565b94505060206147de87828801613d24565b93505060406147ef87828801613e42565b925050606085013567ffffffffffffffff8111156148105761480f613c1b565b5b61481c87828801614777565b91505092959194509250565b60808201600082015161483e60008501826142d7565b50602082015161485160208501826142fa565b5060408201516148646040850182614309565b5060608201516148776060850182614327565b50505050565b60006080820190506148926000830184614828565b92915050565b6148a18161400a565b82525050565b60006020820190506148bc6000830184614898565b92915050565b600080604083850312156148d9576148d8613c16565b5b60006148e785828601613d24565b92505060206148f885828601613d24565b9150509250929050565b60008083601f84011261491857614917614080565b5b8235905067ffffffffffffffff81111561493557614934614085565b5b6020830191508360208202830111156149515761495061408a565b5b9250929050565b6000806000806040858703121561497257614971613c16565b5b600085013567ffffffffffffffff8111156149905761498f613c1b565b5b61499c87828801614902565b9450945050602085013567ffffffffffffffff8111156149bf576149be613c1b565b5b6149cb8782880161408f565b925092505092959194509250565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60006002820490506001821680614a2057607f821691505b60208210811415614a3457614a336149d9565b5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000614a7482613e21565b9150614a7f83613e21565b925082614a8f57614a8e614a3a565b5b828206905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000614ad482613e21565b9150614adf83613e21565b925082614aef57614aee614a3a565b5b828204905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6000614b3482613e21565b9150614b3f83613e21565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115614b7457614b73614a9a565b5b828201905092915050565b60008160601b9050919050565b6000614b9782614b7f565b9050919050565b6000614ba982614b8c565b9050919050565b614bc1614bbc82613cfb565b614b9e565b82525050565b6000614bd38284614bb0565b60148201915081905092915050565b6000614bed82613e21565b9150614bf883613e21565b925082821015614c0b57614c0a614a9a565b5b828203905092915050565b6000604082019050614c2b6000830185613e84565b614c386020830184613eee565b9392505050565b600081519050614c4e81614698565b92915050565b600060208284031215614c6a57614c69613c16565b5b6000614c7884828501614c3f565b91505092915050565b600081905092915050565b6000614c9782613d66565b614ca18185614c81565b9350614cb1818560208601613d82565b80840191505092915050565b6000614cc98285614c8c565b9150614cd58284614c8c565b91508190509392505050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b6000614d3d602683613d71565b9150614d4882614ce1565b604082019050919050565b60006020820190508181036000830152614d6c81614d30565b9050919050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b6000614da9602083613d71565b9150614db482614d73565b602082019050919050565b60006020820190508181036000830152614dd881614d9c565b9050919050565b600081519050919050565b600082825260208201905092915050565b6000614e0682614ddf565b614e108185614dea565b9350614e20818560208601613d82565b614e2981613db5565b840191505092915050565b6000608082019050614e496000830187613e84565b614e566020830186613e84565b614e636040830185613eee565b8181036060830152614e758184614dfb565b905095945050505050565b600081519050614e8f81613c4c565b92915050565b600060208284031215614eab57614eaa613c16565b5b6000614eb984828501614e80565b91505092915050565b7f5061757361626c653a2070617573656400000000000000000000000000000000600082015250565b6000614ef8601083613d71565b9150614f0382614ec2565b602082019050919050565b60006020820190508181036000830152614f2781614eeb565b9050919050565b7f5061757361626c653a206e6f7420706175736564000000000000000000000000600082015250565b6000614f64601483613d71565b9150614f6f82614f2e565b602082019050919050565b60006020820190508181036000830152614f9381614f57565b9050919050565b6000614fa582613e21565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415614fd857614fd7614a9a565b5b60018201905091905056fea2646970667358221220a0167164e789bc96aacef69a578ac620dee7bca95f30484bce3562c83c57dfb864736f6c63430008090033

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

00000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000043697066733a2f2f626166796265696772723271797479327575326169346a636e3466346e6e656e67777963723573346e6a646c6770706e706d717364717166766a712f0000000000000000000000000000000000000000000000000000000000

-----Decoded View---------------
Arg [0] : myBaseURI_ (string): ipfs://bafybeigrr2qyty2uu2ai4jcn4f4nnengwycr5s4njdlgppnpmqsdqqfvjq/

-----Encoded View---------------
5 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000020
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000043
Arg [2] : 697066733a2f2f626166796265696772723271797479327575326169346a636e
Arg [3] : 3466346e6e656e67777963723573346e6a646c6770706e706d71736471716676
Arg [4] : 6a712f0000000000000000000000000000000000000000000000000000000000


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  ]
[ 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.