Sepolia Testnet

Contract

0x218a56135774A6fd1a2f20Bc4783793E039D71bE

Overview

ETH Balance

0.52286 ETH

Multichain Info

N/A
Transaction Hash
Method
Block
From
To
Safe Transfer Fr...66646052024-09-10 3:53:1247 hrs ago1725940392IN
0x218a5613...E039D71bE
0 ETH0.00101427.9088275
Safe Transfer Fr...66645832024-09-10 3:46:4847 hrs ago1725940008IN
0x218a5613...E039D71bE
0 ETH0.000826257.43457151
Safe Transfer Fr...66638952024-09-10 0:53:002 days ago1725929580IN
0x218a5613...E039D71bE
0 ETH0.000642323.1096083
Safe Transfer Fr...66638372024-09-10 0:39:362 days ago1725928776IN
0x218a5613...E039D71bE
0 ETH0.000359431.7400694
Safe Transfer Fr...66637422024-09-10 0:16:482 days ago1725927408IN
0x218a5613...E039D71bE
0 ETH0.000367461.77897639
Safe Transfer Fr...66637372024-09-10 0:15:242 days ago1725927324IN
0x218a5613...E039D71bE
0 ETH0.000368721.80946517
Safe Transfer Fr...66636502024-09-09 23:52:002 days ago1725925920IN
0x218a5613...E039D71bE
0 ETH0.000081931.62177504
Safe Transfer Fr...66636492024-09-09 23:51:362 days ago1725925896IN
0x218a5613...E039D71bE
0 ETH0.000082041.62427899
Set Gender And D...66593252024-09-09 5:21:482 days ago1725859308IN
0x218a5613...E039D71bE
0 ETH0.000081282.59759699
Safe Transfer Fr...66519382024-09-07 23:35:364 days ago1725752136IN
0x218a5613...E039D71bE
0 ETH0.00031331.51676479
Safe Transfer Fr...66518292024-09-07 23:09:484 days ago1725750588IN
0x218a5613...E039D71bE
0 ETH0.000115830.903242
Safe Transfer Fr...66510302024-09-07 19:55:004 days ago1725738900IN
0x218a5613...E039D71bE
0 ETH0.000240690.40783332
Safe Transfer Fr...66496982024-09-07 14:30:124 days ago1725719412IN
0x218a5613...E039D71bE
0 ETH0.000548214.93226419
Safe Transfer Fr...66496962024-09-07 14:29:484 days ago1725719388IN
0x218a5613...E039D71bE
0 ETH0.000526724.73893085
Safe Transfer Fr...66493022024-09-07 12:55:004 days ago1725713700IN
0x218a5613...E039D71bE
0 ETH0.001037249.33199187
Safe Transfer Fr...66493012024-09-07 12:54:364 days ago1725713676IN
0x218a5613...E039D71bE
0 ETH0.001022089.19559192
Safe Transfer Fr...66492242024-09-07 12:36:124 days ago1725712572IN
0x218a5613...E039D71bE
0 ETH0.001617147.82888136
Safe Transfer Fr...66491232024-09-07 12:11:364 days ago1725711096IN
0x218a5613...E039D71bE
0 ETH0.000533424.79918098
Safe Transfer Fr...66427702024-09-06 10:50:125 days ago1725619812IN
0x218a5613...E039D71bE
0 ETH0.0015995214.39078942
Safe Transfer Fr...66427332024-09-06 10:41:365 days ago1725619296IN
0x218a5613...E039D71bE
0 ETH0.0035601217.23421374
Safe Transfer Fr...66425652024-09-06 10:00:485 days ago1725616848IN
0x218a5613...E039D71bE
0 ETH0.0087069314.75257369
Safe Transfer Fr...66406062024-09-06 2:04:366 days ago1725588276IN
0x218a5613...E039D71bE
0 ETH0.000801613.88053335
Safe Transfer Fr...66388742024-09-05 19:02:006 days ago1725562920IN
0x218a5613...E039D71bE
0 ETH0.00213268.44772581
Set Gender And D...66159632024-09-02 1:35:2410 days ago1725240924IN
0x218a5613...E039D71bE
0 ETH0.000049121.56949123
Set Gender And D...66159622024-09-02 1:35:1210 days ago1725240912IN
0x218a5613...E039D71bE
0 ETH0.000049241.57434841
View all transactions

Latest 25 internal transactions (View All)

Advanced mode:
Parent Transaction Hash Block From To
65999682024-08-30 11:54:1212 days ago1725018852
0x218a5613...E039D71bE
0.00013 ETH
65872282024-08-28 11:35:2414 days ago1724844924
0x218a5613...E039D71bE
0.00013 ETH
64554442024-08-07 16:47:2435 days ago1723049244
0x218a5613...E039D71bE
0.00013 ETH
64554402024-08-07 16:46:3635 days ago1723049196
0x218a5613...E039D71bE
0.00013 ETH
64554382024-08-07 16:46:0035 days ago1723049160
0x218a5613...E039D71bE
0.00013 ETH
64554362024-08-07 16:45:3635 days ago1723049136
0x218a5613...E039D71bE
0.00013 ETH
64552982024-08-07 16:15:0035 days ago1723047300
0x218a5613...E039D71bE
0.00013 ETH
64552962024-08-07 16:14:3635 days ago1723047276
0x218a5613...E039D71bE
0.00013 ETH
64552922024-08-07 16:13:3635 days ago1723047216
0x218a5613...E039D71bE
0.00013 ETH
64552832024-08-07 16:11:4835 days ago1723047108
0x218a5613...E039D71bE
0.00013 ETH
64552822024-08-07 16:11:2435 days ago1723047084
0x218a5613...E039D71bE
0.00013 ETH
64552812024-08-07 16:11:0035 days ago1723047060
0x218a5613...E039D71bE
0.00013 ETH
64552792024-08-07 16:10:3635 days ago1723047036
0x218a5613...E039D71bE
0.00013 ETH
64552752024-08-07 16:09:2435 days ago1723046964
0x218a5613...E039D71bE
0.00013 ETH
64552732024-08-07 16:09:0035 days ago1723046940
0x218a5613...E039D71bE
0.00013 ETH
64552712024-08-07 16:08:3635 days ago1723046916
0x218a5613...E039D71bE
0.00013 ETH
64552662024-08-07 16:07:3635 days ago1723046856
0x218a5613...E039D71bE
0.00013 ETH
64552642024-08-07 16:07:1235 days ago1723046832
0x218a5613...E039D71bE
0.00013 ETH
64552612024-08-07 16:06:3635 days ago1723046796
0x218a5613...E039D71bE
0.00013 ETH
64552572024-08-07 16:05:4835 days ago1723046748
0x218a5613...E039D71bE
0.00013 ETH
64552552024-08-07 16:05:2435 days ago1723046724
0x218a5613...E039D71bE
0.00013 ETH
64552422024-08-07 16:02:3635 days ago1723046556
0x218a5613...E039D71bE
0.00013 ETH
64552392024-08-07 16:02:0035 days ago1723046520
0x218a5613...E039D71bE
0.00013 ETH
64552262024-08-07 15:59:0035 days ago1723046340
0x218a5613...E039D71bE
0.00013 ETH
64552142024-08-07 15:56:1235 days ago1723046172
0x218a5613...E039D71bE
0.00013 ETH
View All Internal Transactions
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
Skelephunks

Compiler Version
v0.8.17+commit.8df45f5f

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity Standard Json-Input format)

File 1 of 18 : Skelephunks.sol
// SPDX-License-Identifier: Unlicense
// Creator: 0xYeety/YEETY.eth - Co-Founder/CTO, Virtue Labs

pragma solidity ^0.8.17;

//import "./ERC721Y_A.sol";
import "./ERC721Y.sol";
import "lib/openzeppelin-contracts/contracts/access/Ownable.sol";
import "lib/openzeppelin-contracts/contracts/utils/Strings.sol";
import "lib/openzeppelin-contracts/contracts/utils/cryptography/MerkleProof.sol";
import "lib/openzeppelin-contracts/contracts/token/ERC20/IERC20.sol";
import "lib/operator-filter-registry/src/DefaultOperatorFilterer.sol";

contract Skelephunks is ERC721Y, Ownable, DefaultOperatorFilterer {
    using Address for address;
    using Strings for uint256;
    string public PROVENANCE;
    bool provenanceSet;

    mapping(address => uint256) public numMinted;

    mapping(uint256 => string) private _gdToPath;

    /*************************************************************************/
    /*** PAYMENT VARIABLES (Start) *******************************************/
    address[] public payees;
    mapping(address => uint256) private paymentInfo;
    uint256 totalReceived = 0;
    mapping(address => uint256) amountsWithdrawn;

    modifier onlyPayee() {
        _isPayee();
        _;
    }
    function _isPayee() internal view virtual {
        require(paymentInfo[msg.sender] > 0, "not a payee");
    }
    /*** PAYMENT VARIABLES (End) *******************************************/
    /***********************************************************************/

//    uint256 public mintPrice = 0.0013 ether;
    uint256 public mintPrice = 0.00013 ether;
    uint256 private maxPaidTokens = 10;

    enum MintStatus {
        PreMint,
        Phunks,
        AllowList,
        Public,
        PublicExtended,
        ReserveOnly,
        Finished
    }

    MintStatus public mintStatus = MintStatus.PreMint;
    bool public paused = false;

    uint256 public maxPossibleSupply = 9999;
    uint256 public maxMintableSupply = 6666;
    uint256 public numMintedRegular = 0;
    uint256 public maxReserveSupply = 3333;
    uint256 public numMintedReserve = 0;
    uint256 private _maxMintsPerWallet;

    string collectionDescription = "Skelephunks is a universal, adaptive PFP for the Ethereum community.";
    string collectionImg = "";
    string externalLink = "https://skelephunks.com";

    mapping(uint256 => uint256) private _genderDirection;

//    ERC721Proto phunksContract = ERC721Proto(0x0000000000000000000000000000000000000000);
//    bytes32 public phunksMerkleRoot = 0x3f4500794b717c7e25c0cfe9ee3f5bd58ae0af57ef2038de6847879660d0c9f1;
    bytes32 public phunksMerkleRoot = 0xf0f7a55aec9ad32ed76282ecb785ebe960e8086dcccaf5936a0dfccb19733684;
    uint256 public phunksClaimsMade;
    uint256 public maxPhunkClaims = 333;
    mapping(address => bool) public phunkListClaimed;

//    bytes32 public merkleRoot = 0x3f4500794b717c7e25c0cfe9ee3f5bd58ae0af57ef2038de6847879660d0c9f1;
    bytes32 public merkleRoot = 0x106cfb7a584f43d49565772c75a9e5e49c925b021a541f1975516ca4792a24b4;
    uint256 public allowlistClaimsMade;
    uint256 public maxAllowlistClaims = 1000;
    mapping(address => bool) public allowlistClaimed;

    mapping(address => uint256) private _mintClaimsMade;
    mapping(address => uint256) private _otherClaimsMade;

    mapping(address => bool) private _reserveAuths;
    address public keysContract;


    uint256 public keyRedemptionAmt = 3;


    modifier onlyReserveAuth() {
        require(getReserveAuthStatus(msg.sender), "ra");
        _;
    }


    bool royaltySwitch = true;
    modifier onlyAllowedOperator(address from) virtual override {
        if (royaltySwitch) {
            if (from != msg.sender) {
                _checkFilterOperator(msg.sender);
            }
        }
        _;
    }
    modifier onlyAllowedOperatorApproval(address operator) virtual override {
        if (royaltySwitch) {
            _checkFilterOperator(operator);
        }
        _;
    }


    constructor (
        string memory name_,
        string memory symbol_,
//        uint256 maxPossibleSupply_,
        uint256 maxMintsPerWallet_,
        address[] memory payees_,
        uint256[] memory basisPoints_
    ) ERC721Y(name_, symbol_, maxPossibleSupply) {
//        maxPossibleSupply = maxPossibleSupply_;
        _maxMintsPerWallet = maxMintsPerWallet_;

        require(payees_.length == basisPoints_.length, "l");
        payees = payees_;
        for (uint256 i = 0; i < payees_.length; i++) {
            paymentInfo[payees_[i]] = basisPoints_[i];
        }

        _gdToPath[0] = "phunk/male";
        _gdToPath[1] = "phunk/female";
        _gdToPath[2] = "punk/male";
        _gdToPath[3] = "punk/female";
    }

    function flipPaused() public onlyOwner {
        paused = !paused;
    }

    function setMintStatus(MintStatus newMintStatus) public onlyOwner {
        require(newMintStatus != MintStatus.PreMint && mintStatus != MintStatus.Finished, "ms");
        mintStatus = newMintStatus;
    }

    function min(uint256 x, uint256 y) private pure returns (uint256) {
        if (x < y) {
            return x;
        }

        return y;
    }

    function totalClaimsMade(address minter) public view returns (uint256) {
        return _mintClaimsMade[minter] + _otherClaimsMade[minter];
    }

    function phunkClaimsRemain() public view returns (bool) {
        return (phunksClaimsMade < maxPhunkClaims);
    }

    function eligibleForPhunk(
        address minter,
        bytes32[] calldata _proof
    ) public view returns (bool) {
        return ((!(phunkListClaimed[minter])) && MerkleProof.verify(
            _proof, phunksMerkleRoot, keccak256(abi.encodePacked(minter))
        ) && phunkClaimsRemain());
    }

//    function eligibleForPhunk(address minter) private view returns (bool) {
//        return (((!(phunkListClaimed[minter])) && (phunksContract.balanceOf(minter) > 0)) && phunkClaimsRemain());
//    }

    function allowlistClaimsRemain() public view returns (bool) {
        return (allowlistClaimsMade < maxAllowlistClaims);
    }

//    function eligibleForAllowlist(
//        address minter,
//        bytes32[] calldata _proof
//    ) public view returns (bool) {
//        return ((!(allowlistClaimed[minter])) && MerkleProof.verify(
//            _proof, merkleRoot, keccak256(abi.encodePacked(minter))
//        ) && allowlistClaimsRemain());
//    }
    function eligibleForAllowlist(
        address minter,
        bytes32[] calldata _proof
    ) public view returns (bool) {
        return (MerkleProof.verify(
            _proof, merkleRoot, keccak256(abi.encodePacked(minter))
        ) && allowlistClaimsRemain());
    }

    //////////

    function maxMintsInternal(
        address wallet,
        bytes32[] calldata _phunkProof,
        bytes32[] calldata _alProof
    ) private view returns (uint256) {
        if (mintStatus == MintStatus.PreMint) {
            return 0;
        }
        else if (mintStatus == MintStatus.Phunks) {
            return (eligibleForPhunk(wallet, _phunkProof) ? 1 : 0);
        }
        else if (mintStatus == MintStatus.AllowList) {
            if (eligibleForAllowlist(wallet, _alProof)) {
                return min(_maxMintsPerWallet - numMinted[wallet], maxMintableSupply - numMintedRegular);
            }
            else if (eligibleForPhunk(wallet, _phunkProof)) { return 1; }
            else { return 0; }
        }
        else if (mintStatus == MintStatus.Public) {
            return min(_maxMintsPerWallet - numMinted[wallet], maxMintableSupply - numMintedRegular);
        }
        else if (mintStatus == MintStatus.PublicExtended) {
            return (maxMintableSupply - numMintedRegular);
        }

        return 0;
    }

    function maxMintsPerWallet(
        address wallet,
        bytes32[] calldata _phunkProof,
        bytes32[] calldata _alProof
    ) public view returns (uint256) {
        return min(100, maxMintsInternal(wallet, _phunkProof, _alProof));
    }

    function walletCanMint(
        address wallet,
        bytes32[] calldata _phunkProof,
        bytes32[] calldata _alProof
    ) public view returns (bool) {
//        if (numMinted[wallet] == maxMintsPerWallet(wallet, _phunkProof, _alProof)) {
//            return false;
//        }
//
//        if (mintStatus == MintStatus.PreMint) {
//            return false;
//        }
//        else if (mintStatus == MintStatus.Phunks) {
//            return eligibleForPhunk(wallet, _phunkProof);
//        }
//        else if (mintStatus == MintStatus.AllowList) {
//            return (eligibleForPhunk(wallet, _phunkProof) || eligibleForAllowlist(wallet, _alProof));
//        }
//        else {
//            return true;
//        }

        return (maxMintsPerWallet(wallet, _phunkProof, _alProof) > 0);
    }

    function _generalGetNumFree(
        address wallet,
        uint256 quantity,
        bytes32[] calldata _phunkProof,
        bytes32[] calldata _alProof
    ) private view returns (uint256) {
        uint256 toReturn;

//        if ((quantity + numMinted[wallet]) == _maxMintsPerWallet) {
//        if ((quantity + numMinted[wallet]) == maxMintsPerWallet(wallet, _phunkProof, _alProof)) {
        if (quantity == maxMintsPerWallet(wallet, _phunkProof, _alProof)) {
//            toReturn = min(quantity, 3);
//
//            toReturn -= min(_mintClaimsMade[wallet], toReturn);

//            if (quantity <= 3) {
//
//            }
//            else {
//
//            }

            toReturn = 3 - _mintClaimsMade[wallet];
            toReturn = min(toReturn, quantity);
        }
        else {
            toReturn = (eligibleForPhunk(wallet, _phunkProof) ? 1 : 0) +
                ((eligibleForAllowlist(wallet, _alProof) && (!(allowlistClaimed[wallet]))) ? 1 : 0);
            toReturn = min(toReturn, quantity);
        }

        return toReturn;
    }

    function getNumFree(
        address wallet,
        uint256 quantity,
        bytes32[] calldata _phunkProof,
        bytes32[] calldata _alProof
    ) public view returns (uint256) {
        if (mintStatus == MintStatus.PreMint) {
            return 0;
        }
        else if (mintStatus == MintStatus.Phunks) {
            return (eligibleForPhunk(wallet, _phunkProof) ? 1 : 0);
        }
        else if (mintStatus == MintStatus.AllowList) {
            if (eligibleForAllowlist(wallet, _alProof)) {
                return _generalGetNumFree(wallet, quantity, _phunkProof, _alProof);
            }
            else if (eligibleForPhunk(wallet, _phunkProof)) { return 1; }
            else { return 0; }
        }
        else if (mintStatus == MintStatus.Public) {
            return _generalGetNumFree(wallet, quantity, _phunkProof, _alProof);
        }
        else if (mintStatus == MintStatus.PublicExtended) {
            return _generalGetNumFree(wallet, quantity, _phunkProof, _alProof);
        }

        return 0;
    }

    function getMintCost(
        address wallet,
        uint256 quantity,
        bytes32[] calldata _phunkProof,
        bytes32[] calldata _alProof
    ) public view returns (uint256) {
        uint256 numFree = getNumFree(wallet, quantity, _phunkProof, _alProof);

        return mintPrice*(quantity - numFree);
    }

    //////////

    function _mintMain(address _to, uint256 _quantity, uint256 _numFree, uint256 _gd, bool isReserve) private {
        require(!paused, "p");
//        require(
//            numMinted[_to] + _quantity <= maxMintsPerWallet &&
//            numMintedRegular + _quantity <= maxPossibleSupply, "mmpw/mps");
        require(_gd < 4, "v");

        uint256 curIndex = numMintedRegular;

//        _safeMint(_to, _quantity);
        _mintRandom(_to, _quantity);

        numMinted[_to] += _quantity;

        uint256 accumulator = 0;
        uint256 curBlock = curIndex/128;
        //        uint256 curSlot = curIndex%128;

        for (uint256 i = curIndex; i < curIndex + _quantity; i++) {
            uint256 newBlock = i/128;

            if (newBlock != curBlock) {
                _genderDirection[curBlock] += accumulator;
                accumulator = 0;
                curBlock = newBlock;
            }

            accumulator += (_gd << ((i%128)*2)); // i%128 is the slot to update
        }

        _genderDirection[curBlock] += accumulator;

        if (isReserve) {
            numMintedReserve += _quantity;
        }
        else {
//            numMintedRegular += _quantity;
            numMintedRegular += _quantity - _numFree;
            numMintedReserve += _numFree;
        }

        if (numMintedRegular == maxMintableSupply) {
            mintStatus = MintStatus.ReserveOnly;
        }

        if (mintStatus == MintStatus.ReserveOnly) {
            if (numMintedReserve == maxReserveSupply) {
                mintStatus = MintStatus.Finished;
            }
        }
    }

    function mint(
        uint256 _quantity,
        uint256 genderDirection,
        bytes32[] calldata _phunkProof,
        bytes32[] calldata _alProof
    ) public payable {
//        require(!((msg.sender).isContract()));
        require(msg.sender == tx.origin);
        uint256 numFree = getNumFree(msg.sender, _quantity, _phunkProof, _alProof);
        require(msg.value == getMintCost(msg.sender, _quantity, _phunkProof, _alProof), "poor");
//        require(
//            numMinted[msg.sender] + _quantity <= maxMintsPerWallet(msg.sender, _phunkProof, _alProof) &&
//            numMintedRegular + _quantity <= maxMintableSupply, "mmpw/mps");
//        require(
//            _quantity <= maxMintsPerWallet(msg.sender, _phunkProof, _alProof) &&
//            numMintedRegular + _quantity <= maxMintableSupply, "mmpw/mps");
        require(_quantity <= maxMintsPerWallet(msg.sender, _phunkProof, _alProof), "mmpw");
        require(numMintedRegular + (_quantity - numFree) <= maxMintableSupply, "mms");
        require(numMintedReserve + numFree <= maxReserveSupply, "mrs");


//        require()


        uint256 numFreeCopy = numFree;
        if (numFreeCopy > 0) {
            if (eligibleForPhunk(msg.sender, _phunkProof)) {
                phunkListClaimed[msg.sender] = true;
                _mintClaimsMade[msg.sender] += 1;
                numFreeCopy -= 1;
            }
        }
        if (numFreeCopy > 0) {
            if (eligibleForAllowlist(msg.sender, _alProof)) {
                allowlistClaimed[msg.sender] = true;
                _mintClaimsMade[msg.sender] += 1;
                numFreeCopy -= 1;
            }
        }
        _mintClaimsMade[msg.sender] += numFreeCopy;


        totalReceived += msg.value;
        _mintMain(msg.sender, _quantity, numFree, genderDirection, false);

//        for (uint256 i = 0; i < _quantity; i++) {
//            SkeleKeysProto(keysContract).tryToAllocateRandomKey(msg.sender);
//        }
//


//        for (uint256 i = 0; i < _quantity; i++) {
////            if (SkeleKeysProto(keysContract).balanceOf(keysContract) > 0) {
//            if (SkeleKeysProto(keysContract).hasUnallocatedKeys()) {
////                SkeleKeysProto(keysContract).allocateRandomKey(msg.sender);
//                SkeleKeysProto(keysContract).tryToAllocateRandomKey(msg.sender);
//            }
//        }


//        revert("end of mint function");
    }

    function mintReserve(
        address _to,
        uint256 _quantity,
        uint256 genderDirection
    ) public onlyReserveAuth {
        _mintReserve(_to, _quantity, genderDirection);
    }

    function redeemKeyForSkelephunks(
        uint256 keyId,
        uint256 genderDirection
    ) public {
        require(msg.sender == tx.origin, "no contracts fam");
//        _mintMain(msg.sender, keyRedemptionAmt, 0, genderDirection, true);
//        _otherClaimsMade
        _mintReserve(msg.sender, keyRedemptionAmt, genderDirection);
        SkeleKeysProto(keysContract).redeemKey(keyId);
    }

    function _mintReserve(
        address _to,
        uint256 _quantity,
        uint256 genderDirection
    ) private {
        _mintMain(_to, _quantity, 0, genderDirection, true);
        _otherClaimsMade[_to] += _quantity;
    }

    //////////

    function setMintPrice(uint256 _mintPrice) public onlyOwner {
        mintPrice = _mintPrice;
    }

    function setMaxMintsPerWallet(uint256 __maxMintsPerWallet) public onlyOwner {
        _maxMintsPerWallet = __maxMintsPerWallet;
    }

    function setPhunksMerkleRoot(bytes32 _newPhunksMerkleRoot) public onlyOwner {
        phunksMerkleRoot = _newPhunksMerkleRoot;
    }

    function setAllowlistMerkleRoot(bytes32 _newAllowlistMerkleRoot) public onlyOwner {
        merkleRoot = _newAllowlistMerkleRoot;
    }

    //////////

    //    function getGenderAndDirection(uint256 tokenId) private view returns (uint256) {
    function getGenderAndDirection(uint256 tokenId) public view returns (uint256) {
        uint256 curBlock = tokenId/128;
        uint256 curSlot = tokenId%128;

        return (_genderDirection[curBlock] >> (curSlot*2))%4;
    }

    function setGenderAndDirection(uint256 tokenId, uint256 gender, uint256 direction) public {
        require(msg.sender == ownerOf(tokenId), "o");
        require(gender < 2 && direction < 2, "v");

        uint256 toSet = direction*2 + gender;

        uint256 curGenderDirection = getGenderAndDirection(tokenId);

        uint256 curBlock = tokenId/128;
        uint256 curSlot = tokenId%128;

        _genderDirection[curBlock] -= (curGenderDirection << (curSlot*2));
        _genderDirection[curBlock] += (toSet << (curSlot*2));
    }

    //////////

    function setKeysContract(address keysAddr) public onlyOwner {
        setReserveAuthStatus(keysContract, false);
        keysContract = keysAddr;
        setReserveAuthStatus(keysContract, true);
    }

    function setReserveAuthStatus(address addr, bool isAuthorized) public onlyOwner {
        _reserveAuths[addr] = isAuthorized;
    }

    function getReserveAuthStatus(address addr) public view returns (bool) {
        return _reserveAuths[addr];
    }

    function setKeyRedemptionAmt(uint256 _newAmt) public onlyOwner {
        keyRedemptionAmt = _newAmt;
    }

    //////////

    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        require(_exists(tokenId), "z");

        if (bytes(_basedURI).length > 0) {
            return string(
                abi.encodePacked(
                    _basedURI, "/", _gdToPath[getGenderAndDirection(tokenId)], "/",
                    tokenId.toString()));
        }
        else {
            return _preRevealURI;
        }
    }

    function setPreRevealURI(string memory preRevealURI_) public onlyOwner {
        _setPreRevealURI(preRevealURI_);
    }

    function setBasedURI(string memory basedURI_) public onlyOwner {
        _setBasedURI(basedURI_);
    }

    function setProvenanceHash(string memory provenanceHash) public onlyOwner {
        require(!provenanceSet);
        PROVENANCE = provenanceHash;
        provenanceSet = true;
    }

    //////////

    function setApprovalForAll(
        address operator,
        bool approved
    ) public override onlyAllowedOperatorApproval(operator) {
        super.setApprovalForAll(operator, approved);
    }

    function approve(
        address operator,
        uint256 tokenId
    ) public override onlyAllowedOperatorApproval(operator) {
        super.approve(operator, tokenId);
    }

    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public override onlyAllowedOperator(from) {
        super.transferFrom(from, to, tokenId);
    }

    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public override onlyAllowedOperator(from) {
        super.safeTransferFrom(from, to, tokenId);
    }

    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory data
    ) public override onlyAllowedOperator(from) {
        super.safeTransferFrom(from, to, tokenId, data);
    }

    //////////

    function setCollectionDescription(string memory _collectionDescription) public onlyOwner {
        collectionDescription = _collectionDescription;
    }

    function setCollectionImg(string memory _collectionImg) public onlyOwner {
        collectionImg = _collectionImg;
    }

    function setExternalLink(string memory _externalLink) public onlyOwner {
        externalLink = _externalLink;
    }

    function contractURI() public view returns (string memory) {
        return string(
            abi.encodePacked(
                "data:application/json;utf8,{\"name\":\"", name(),"\",",
                "\"description\":\"", collectionDescription, "\",",
                "\"image\":\"", collectionImg, "\",",
                "\"external_link\":\"", externalLink, "\",",
                "\"seller_fee_basis_points\":666,\"fee_recipient\":\"",
                uint256(uint160(address(this))).toHexString(), "\"}"
            )
        );
    }

    function flipRoyaltySwitch() public onlyOwner {
        royaltySwitch = !royaltySwitch;
    }

    /*********************************************************************/
    /*** PAYMENT LOGIC (Start) *******************************************/
    receive() external payable {
        totalReceived += msg.value;
    }

    function withdraw() public onlyPayee {
        uint256 totalForPayee = (totalReceived/10000)*paymentInfo[msg.sender];
        uint256 toWithdraw = totalForPayee - amountsWithdrawn[msg.sender];
        amountsWithdrawn[msg.sender] = totalForPayee;
        (bool success, ) = payable(msg.sender).call{value: toWithdraw}("");
        require(success, "Payment failed!");
    }

    function emergencyWithdraw() external onlyOwner {
        uint256 toWithdraw = address(this).balance;
        (bool success, ) = payable(msg.sender).call{value: toWithdraw}("");
        require(success, "Payment failed!");
    }

    function withdrawTokens(address tokenAddress) external onlyPayee {
        for (uint256 i = 0; i < payees.length; i++) {
            IERC20(tokenAddress).transfer(
                payees[i],
                (IERC20(tokenAddress).balanceOf(address(this))/10000)*paymentInfo[payees[i]]
            );
        }
    }

    function emergencyWithdrawTokens(address tokenAddress) external onlyOwner {
        IERC20(tokenAddress).transfer(msg.sender, IERC20(tokenAddress).balanceOf(address(this)));
    }
    /*** PAYMENT LOGIC (End) *******************************************/
    /*******************************************************************/
}

////////////////////

abstract contract ERC721Proto {
    function balanceOf(address owner) public view virtual returns (uint256);
}

//////////

abstract contract SkeleKeysProto {
//    function allocateRandomKey(address to) public virtual;
//    function numUnallocated() public view virtual returns (uint256);
    function balanceOf(address owner) public view virtual returns (uint256);
    function hasUnallocatedKeys() public view virtual returns (bool);
    function allocateRandomKey(address to) external virtual;
    function tryToAllocateRandomKey(address to) public virtual;
    function redeemKey(uint256 keyId) public virtual;
}

////////////////////////////////////////

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

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

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

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

File 3 of 18 : IERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

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

    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

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

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

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

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

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

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

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

    /**
     * @dev Transfers `tokenId` token from `from` to `to`.
     *
     * WARNING: Note that the caller is responsible to confirm that the recipient is capable of receiving ERC721
     * or else they may be permanently lost. Usage of {safeTransferFrom} prevents loss, though the caller must
     * understand this adds an external call which potentially creates a reentrancy vulnerability.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

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

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

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

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

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

pragma solidity ^0.8.0;

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

File 6 of 18 : IERC721Enumerable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC721/extensions/IERC721Enumerable.sol)

pragma solidity ^0.8.0;

import "../IERC721.sol";

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

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

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

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

pragma solidity ^0.8.0;

import "../IERC721.sol";

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

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

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

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

pragma solidity ^0.8.1;

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

        return account.code.length > 0;
    }

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

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

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

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

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

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

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

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        (bool success, bytes memory returndata) = target.staticcall(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

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

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        (bool success, bytes memory returndata) = target.delegatecall(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling
     * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract.
     *
     * _Available since v4.8._
     */
    function verifyCallResultFromTarget(
        address target,
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        if (success) {
            if (returndata.length == 0) {
                // only check isContract if the call was successful and the return data is empty
                // otherwise we already know that it was a contract
                require(isContract(target), "Address: call to non-contract");
            }
            return returndata;
        } else {
            _revert(returndata, errorMessage);
        }
    }

    /**
     * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason or using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            _revert(returndata, errorMessage);
        }
    }

    function _revert(bytes memory returndata, string memory errorMessage) private pure {
        // Look for revert reason and bubble it up if present
        if (returndata.length > 0) {
            // The easiest way to bubble the revert reason is using memory via assembly
            /// @solidity memory-safe-assembly
            assembly {
                let returndata_size := mload(returndata)
                revert(add(32, returndata), returndata_size)
            }
        } else {
            revert(errorMessage);
        }
    }
}

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

pragma solidity ^0.8.0;

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

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

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

pragma solidity ^0.8.0;

import "./math/Math.sol";

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

    /**
     * @dev Converts a `uint256` to its ASCII `string` decimal representation.
     */
    function toString(uint256 value) internal pure returns (string memory) {
        unchecked {
            uint256 length = Math.log10(value) + 1;
            string memory buffer = new string(length);
            uint256 ptr;
            /// @solidity memory-safe-assembly
            assembly {
                ptr := add(buffer, add(32, length))
            }
            while (true) {
                ptr--;
                /// @solidity memory-safe-assembly
                assembly {
                    mstore8(ptr, byte(mod(value, 10), _SYMBOLS))
                }
                value /= 10;
                if (value == 0) break;
            }
            return buffer;
        }
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
     */
    function toHexString(uint256 value) internal pure returns (string memory) {
        unchecked {
            return toHexString(value, Math.log256(value) + 1);
        }
    }

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

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

File 11 of 18 : MerkleProof.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/MerkleProof.sol)

pragma solidity ^0.8.0;

/**
 * @dev These functions deal with verification of Merkle Tree proofs.
 *
 * The tree and the proofs can be generated using our
 * https://github.com/OpenZeppelin/merkle-tree[JavaScript library].
 * You will find a quickstart guide in the readme.
 *
 * 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.
 * OpenZeppelin's JavaScript library generates merkle trees that are safe
 * against this attack out of the box.
 */
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 simultaneously proven to be a part of a merkle tree defined by
     * `root`, according to `proof` and `proofFlags` as described in {processMultiProof}.
     *
     * CAUTION: Not all merkle trees admit multiproofs. See {processMultiProof} for details.
     *
     * _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}
     *
     * CAUTION: Not all merkle trees admit multiproofs. See {processMultiProof} for details.
     *
     * _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 sibling nodes in `proof`. The reconstruction
     * proceeds by incrementally reconstructing all inner nodes by combining a leaf/inner node with either another
     * leaf/inner node or a proof sibling node, depending on whether each `proofFlags` item is true or false
     * respectively.
     *
     * CAUTION: Not all merkle trees admit multiproofs. To use multiproofs, it is sufficient to ensure that: 1) the tree
     * is complete (but not necessarily perfect), 2) the leaves to be proven are in the opposite order they are in the
     * tree (i.e., as seen from right to left starting at the deepest layer and continuing at the next layer).
     *
     * _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}.
     *
     * CAUTION: Not all merkle trees admit multiproofs. See {processMultiProof} for details.
     *
     * _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 12 of 18 : ERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol)

pragma solidity ^0.8.0;

import "./IERC165.sol";

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

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

pragma solidity ^0.8.0;

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

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

pragma solidity ^0.8.0;

/**
 * @dev Standard math utilities missing in the Solidity language.
 */
library Math {
    enum Rounding {
        Down, // Toward negative infinity
        Up, // Toward infinity
        Zero // Toward zero
    }

    /**
     * @dev Returns the largest of two numbers.
     */
    function max(uint256 a, uint256 b) internal pure returns (uint256) {
        return a > b ? a : b;
    }

    /**
     * @dev Returns the smallest of two numbers.
     */
    function min(uint256 a, uint256 b) internal pure returns (uint256) {
        return a < b ? a : b;
    }

    /**
     * @dev Returns the average of two numbers. The result is rounded towards
     * zero.
     */
    function average(uint256 a, uint256 b) internal pure returns (uint256) {
        // (a + b) / 2 can overflow.
        return (a & b) + (a ^ b) / 2;
    }

    /**
     * @dev Returns the ceiling of the division of two numbers.
     *
     * This differs from standard division with `/` in that it rounds up instead
     * of rounding down.
     */
    function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) {
        // (a + b - 1) / b can overflow on addition, so we distribute.
        return a == 0 ? 0 : (a - 1) / b + 1;
    }

    /**
     * @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or denominator == 0
     * @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv)
     * with further edits by Uniswap Labs also under MIT license.
     */
    function mulDiv(
        uint256 x,
        uint256 y,
        uint256 denominator
    ) internal pure returns (uint256 result) {
        unchecked {
            // 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use
            // use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256
            // variables such that product = prod1 * 2^256 + prod0.
            uint256 prod0; // Least significant 256 bits of the product
            uint256 prod1; // Most significant 256 bits of the product
            assembly {
                let mm := mulmod(x, y, not(0))
                prod0 := mul(x, y)
                prod1 := sub(sub(mm, prod0), lt(mm, prod0))
            }

            // Handle non-overflow cases, 256 by 256 division.
            if (prod1 == 0) {
                return prod0 / denominator;
            }

            // Make sure the result is less than 2^256. Also prevents denominator == 0.
            require(denominator > prod1);

            ///////////////////////////////////////////////
            // 512 by 256 division.
            ///////////////////////////////////////////////

            // Make division exact by subtracting the remainder from [prod1 prod0].
            uint256 remainder;
            assembly {
                // Compute remainder using mulmod.
                remainder := mulmod(x, y, denominator)

                // Subtract 256 bit number from 512 bit number.
                prod1 := sub(prod1, gt(remainder, prod0))
                prod0 := sub(prod0, remainder)
            }

            // Factor powers of two out of denominator and compute largest power of two divisor of denominator. Always >= 1.
            // See https://cs.stackexchange.com/q/138556/92363.

            // Does not overflow because the denominator cannot be zero at this stage in the function.
            uint256 twos = denominator & (~denominator + 1);
            assembly {
                // Divide denominator by twos.
                denominator := div(denominator, twos)

                // Divide [prod1 prod0] by twos.
                prod0 := div(prod0, twos)

                // Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one.
                twos := add(div(sub(0, twos), twos), 1)
            }

            // Shift in bits from prod1 into prod0.
            prod0 |= prod1 * twos;

            // Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such
            // that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for
            // four bits. That is, denominator * inv = 1 mod 2^4.
            uint256 inverse = (3 * denominator) ^ 2;

            // Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also works
            // in modular arithmetic, doubling the correct bits in each step.
            inverse *= 2 - denominator * inverse; // inverse mod 2^8
            inverse *= 2 - denominator * inverse; // inverse mod 2^16
            inverse *= 2 - denominator * inverse; // inverse mod 2^32
            inverse *= 2 - denominator * inverse; // inverse mod 2^64
            inverse *= 2 - denominator * inverse; // inverse mod 2^128
            inverse *= 2 - denominator * inverse; // inverse mod 2^256

            // Because the division is now exact we can divide by multiplying with the modular inverse of denominator.
            // This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is
            // less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1
            // is no longer required.
            result = prod0 * inverse;
            return result;
        }
    }

    /**
     * @notice Calculates x * y / denominator with full precision, following the selected rounding direction.
     */
    function mulDiv(
        uint256 x,
        uint256 y,
        uint256 denominator,
        Rounding rounding
    ) internal pure returns (uint256) {
        uint256 result = mulDiv(x, y, denominator);
        if (rounding == Rounding.Up && mulmod(x, y, denominator) > 0) {
            result += 1;
        }
        return result;
    }

    /**
     * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded down.
     *
     * Inspired by Henry S. Warren, Jr.'s "Hacker's Delight" (Chapter 11).
     */
    function sqrt(uint256 a) internal pure returns (uint256) {
        if (a == 0) {
            return 0;
        }

        // For our first guess, we get the biggest power of 2 which is smaller than the square root of the target.
        //
        // We know that the "msb" (most significant bit) of our target number `a` is a power of 2 such that we have
        // `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`.
        //
        // This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)`
        // → `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))`
        // → `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)`
        //
        // Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit.
        uint256 result = 1 << (log2(a) >> 1);

        // At this point `result` is an estimation with one bit of precision. We know the true value is a uint128,
        // since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at
        // every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision
        // into the expected uint128 result.
        unchecked {
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            return min(result, a / result);
        }
    }

    /**
     * @notice Calculates sqrt(a), following the selected rounding direction.
     */
    function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = sqrt(a);
            return result + (rounding == Rounding.Up && result * result < a ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 2, rounded down, of a positive value.
     * Returns 0 if given 0.
     */
    function log2(uint256 value) internal pure returns (uint256) {
        uint256 result = 0;
        unchecked {
            if (value >> 128 > 0) {
                value >>= 128;
                result += 128;
            }
            if (value >> 64 > 0) {
                value >>= 64;
                result += 64;
            }
            if (value >> 32 > 0) {
                value >>= 32;
                result += 32;
            }
            if (value >> 16 > 0) {
                value >>= 16;
                result += 16;
            }
            if (value >> 8 > 0) {
                value >>= 8;
                result += 8;
            }
            if (value >> 4 > 0) {
                value >>= 4;
                result += 4;
            }
            if (value >> 2 > 0) {
                value >>= 2;
                result += 2;
            }
            if (value >> 1 > 0) {
                result += 1;
            }
        }
        return result;
    }

    /**
     * @dev Return the log in base 2, following the selected rounding direction, of a positive value.
     * Returns 0 if given 0.
     */
    function log2(uint256 value, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = log2(value);
            return result + (rounding == Rounding.Up && 1 << result < value ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 10, rounded down, of a positive value.
     * Returns 0 if given 0.
     */
    function log10(uint256 value) internal pure returns (uint256) {
        uint256 result = 0;
        unchecked {
            if (value >= 10**64) {
                value /= 10**64;
                result += 64;
            }
            if (value >= 10**32) {
                value /= 10**32;
                result += 32;
            }
            if (value >= 10**16) {
                value /= 10**16;
                result += 16;
            }
            if (value >= 10**8) {
                value /= 10**8;
                result += 8;
            }
            if (value >= 10**4) {
                value /= 10**4;
                result += 4;
            }
            if (value >= 10**2) {
                value /= 10**2;
                result += 2;
            }
            if (value >= 10**1) {
                result += 1;
            }
        }
        return result;
    }

    /**
     * @dev Return the log in base 10, following the selected rounding direction, of a positive value.
     * Returns 0 if given 0.
     */
    function log10(uint256 value, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = log10(value);
            return result + (rounding == Rounding.Up && 10**result < value ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 256, rounded down, of a positive value.
     * Returns 0 if given 0.
     *
     * Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string.
     */
    function log256(uint256 value) internal pure returns (uint256) {
        uint256 result = 0;
        unchecked {
            if (value >> 128 > 0) {
                value >>= 128;
                result += 16;
            }
            if (value >> 64 > 0) {
                value >>= 64;
                result += 8;
            }
            if (value >> 32 > 0) {
                value >>= 32;
                result += 4;
            }
            if (value >> 16 > 0) {
                value >>= 16;
                result += 2;
            }
            if (value >> 8 > 0) {
                result += 1;
            }
        }
        return result;
    }

    /**
     * @dev Return the log in base 10, following the selected rounding direction, of a positive value.
     * Returns 0 if given 0.
     */
    function log256(uint256 value, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = log256(value);
            return result + (rounding == Rounding.Up && 1 << (result * 8) < value ? 1 : 0);
        }
    }
}

File 15 of 18 : DefaultOperatorFilterer.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.13;

import {OperatorFilterer} from "./OperatorFilterer.sol";

/**
 * @title  DefaultOperatorFilterer
 * @notice Inherits from OperatorFilterer and automatically subscribes to the default OpenSea subscription.
 */
abstract contract DefaultOperatorFilterer is OperatorFilterer {
    address constant DEFAULT_SUBSCRIPTION = address(0x3cc6CddA760b79bAfa08dF41ECFA224f810dCeB6);

    constructor() OperatorFilterer(DEFAULT_SUBSCRIPTION, true) {}
}

File 16 of 18 : IOperatorFilterRegistry.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.13;

interface IOperatorFilterRegistry {
    function isOperatorAllowed(address registrant, address operator) external view returns (bool);
    function register(address registrant) external;
    function registerAndSubscribe(address registrant, address subscription) external;
    function registerAndCopyEntries(address registrant, address registrantToCopy) external;
    function unregister(address addr) external;
    function updateOperator(address registrant, address operator, bool filtered) external;
    function updateOperators(address registrant, address[] calldata operators, bool filtered) external;
    function updateCodeHash(address registrant, bytes32 codehash, bool filtered) external;
    function updateCodeHashes(address registrant, bytes32[] calldata codeHashes, bool filtered) external;
    function subscribe(address registrant, address registrantToSubscribe) external;
    function unsubscribe(address registrant, bool copyExistingEntries) external;
    function subscriptionOf(address addr) external returns (address registrant);
    function subscribers(address registrant) external returns (address[] memory);
    function subscriberAt(address registrant, uint256 index) external returns (address);
    function copyEntriesOf(address registrant, address registrantToCopy) external;
    function isOperatorFiltered(address registrant, address operator) external returns (bool);
    function isCodeHashOfFiltered(address registrant, address operatorWithCode) external returns (bool);
    function isCodeHashFiltered(address registrant, bytes32 codeHash) external returns (bool);
    function filteredOperators(address addr) external returns (address[] memory);
    function filteredCodeHashes(address addr) external returns (bytes32[] memory);
    function filteredOperatorAt(address registrant, uint256 index) external returns (address);
    function filteredCodeHashAt(address registrant, uint256 index) external returns (bytes32);
    function isRegistered(address addr) external returns (bool);
    function codeHashOf(address addr) external returns (bytes32);
}

File 17 of 18 : OperatorFilterer.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.13;

import {IOperatorFilterRegistry} from "./IOperatorFilterRegistry.sol";

/**
 * @title  OperatorFilterer
 * @notice Abstract contract whose constructor automatically registers and optionally subscribes to or copies another
 *         registrant's entries in the OperatorFilterRegistry.
 * @dev    This smart contract is meant to be inherited by token contracts so they can use the following:
 *         - `onlyAllowedOperator` modifier for `transferFrom` and `safeTransferFrom` methods.
 *         - `onlyAllowedOperatorApproval` modifier for `approve` and `setApprovalForAll` methods.
 */
abstract contract OperatorFilterer {
    error OperatorNotAllowed(address operator);

    IOperatorFilterRegistry public constant OPERATOR_FILTER_REGISTRY =
        IOperatorFilterRegistry(0x000000000000AAeB6D7670E522A718067333cd4E);

    constructor(address subscriptionOrRegistrantToCopy, bool subscribe) {
        // If an inheriting token contract is deployed to a network without the registry deployed, the modifier
        // will not revert, but the contract will need to be registered with the registry once it is deployed in
        // order for the modifier to filter addresses.
        if (address(OPERATOR_FILTER_REGISTRY).code.length > 0) {
            if (subscribe) {
                OPERATOR_FILTER_REGISTRY.registerAndSubscribe(address(this), subscriptionOrRegistrantToCopy);
            } else {
                if (subscriptionOrRegistrantToCopy != address(0)) {
                    OPERATOR_FILTER_REGISTRY.registerAndCopyEntries(address(this), subscriptionOrRegistrantToCopy);
                } else {
                    OPERATOR_FILTER_REGISTRY.register(address(this));
                }
            }
        }
    }

    modifier onlyAllowedOperator(address from) virtual {
        // Allow spending tokens from addresses with balance
        // Note that this still allows listings and marketplaces with escrow to transfer tokens if transferred
        // from an EOA.
        if (from != msg.sender) {
            _checkFilterOperator(msg.sender);
        }
        _;
    }

    modifier onlyAllowedOperatorApproval(address operator) virtual {
        _checkFilterOperator(operator);
        _;
    }

    function _checkFilterOperator(address operator) internal view virtual {
        // Check registry code length to facilitate testing in environments without a deployed registry.
        if (address(OPERATOR_FILTER_REGISTRY).code.length > 0) {
            if (!OPERATOR_FILTER_REGISTRY.isOperatorAllowed(address(this), operator)) {
                revert OperatorNotAllowed(operator);
            }
        }
    }
}

File 18 of 18 : ERC721Y.sol
// SPDX-License-Identifier: Unlicense
// Creator: 0xYeety/YEETY.eth - Co-Founder/CTO, Virtue Labs

pragma solidity ^0.8.17;

import "lib/openzeppelin-contracts/contracts/token/ERC721/IERC721.sol";
import "lib/openzeppelin-contracts/contracts/token/ERC721/IERC721Receiver.sol";
import "lib/openzeppelin-contracts/contracts/token/ERC721/extensions/IERC721Metadata.sol";
import "lib/openzeppelin-contracts/contracts/token/ERC721/extensions/IERC721Enumerable.sol";
import "lib/openzeppelin-contracts/contracts/utils/Address.sol";
import "lib/openzeppelin-contracts/contracts/utils/Context.sol";
import "lib/openzeppelin-contracts/contracts/utils/Strings.sol";
import "lib/openzeppelin-contracts/contracts/utils/introspection/ERC165.sol";

contract ERC721Y is Context, ERC165, IERC721, IERC721Metadata, IERC721Enumerable {
    using Address for address;
    using Strings for uint256;

    uint256 private currentIndex = 1;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Base URI
    string internal _basedURI;
    string internal _preRevealURI;

    mapping(uint => uint) private _availableTokens;
    uint256 private _numAvailableTokens;
    uint256 immutable _maxSupply;

    struct MintInfo {
        address minter;
        uint64 timeMinted;
    }
    mapping(uint256 => MintInfo) private _minters;
    mapping(uint256 => address) private _ownerships;
    mapping(address => uint256) private _balances;
    mapping(uint256 => MintInfo) private _mintOrdering;

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

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

    constructor(
        string memory name_,
        string memory symbol_,
        uint256 maxTokens_
    ) {
        _name = name_;
        _symbol = symbol_;
        _maxSupply = maxTokens_;
        _numAvailableTokens = maxTokens_;
    }

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

    /**
     * @dev See {IERC721Enumerable-tokenByIndex}.
     */
    function tokenByIndex(uint256 index) public view override returns (uint256) {
        require(index > 0, "i0");
        uint256 pseudoIndex = index - 1;
        uint256 supply = totalSupply();
        require(pseudoIndex < supply, "g");
        uint256 curIndex = 0;
        for (uint256 i = 0; i < _maxSupply; i++) {
            if (_ownerships[i] != address(0)) {
                if (curIndex == pseudoIndex) {
//                    return i;
                    return (i + 1);
                }
                curIndex++;
            }
        }
        revert("u");
    }

    /**
     * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}.
     * This read function is O(totalSupply). If calling from a separate contract, be sure to test gas first.
     * It may also degrade with extremely large collection sizes (e.g >> 10000), test for your use case.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) public view override returns (uint256) {
        require(index < balanceOf(owner), "b");
        uint256 curIndex = 0;
        for (uint256 i = 0; i < _maxSupply; i++) {
            if (_ownerships[i] == owner) {
                if (curIndex == index) {
//                    return i;
                    return (i + 1);
                }
                curIndex++;
            }
        }
        revert("u");
    }

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

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

    /**
     * @dev See {IERC721-ownerOf}.
     */
    function ownerOf(uint256 tokenId) public view override returns (address) {
        require(_exists(tokenId), "e");
//        return _ownerships[tokenId];
        return _ownerships[tokenId - 1];
    }

    /**
     * @dev gets the address that minted a token
    **/
    function minterOf(uint256 tokenId) public view returns (address) {
        require(_exists(tokenId), "e");
//        return _minters[tokenId].minter;
        return _minters[tokenId - 1].minter;
    }

    function mintedAt(uint256 tokenId) public view returns (uint64) {
        require(_exists(tokenId), "e");
//        return _minters[tokenId].timeMinted;
        return _minters[tokenId - 1].timeMinted;
    }

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

    //    function _setName(string memory name_) internal virtual {
    //        _name = name_;
    //    }

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

    //    function _setSymbol(string memory symbol_) internal virtual {
    //        _symbol = symbol_;
    //    }

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

        if (bytes(_basedURI).length > 0) {
            return string(abi.encodePacked(_basedURI, "/", tokenId.toString(), ".json"));
        }
        else {
            return _preRevealURI;
        }
    }

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

    /**
     * @dev Internal function to set the base URI for all token IDs. It is
     * automatically added as a prefix to the value returned in {tokenURI},
     * or to the token ID if {tokenURI} is empty.
     */
    function _setBasedURI(string memory basedURI_) internal virtual {
        _basedURI = basedURI_;
    }

    function preRevealURI() public view virtual returns (string memory) {
        return _preRevealURI;
    }

    function _setPreRevealURI(string memory preRevealURI_) internal virtual {
        _preRevealURI = preRevealURI_;
    }

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

        require(
            _msgSender() == owner || isApprovedForAll(owner, _msgSender()),
            "a"
        );

        _approve(to, tokenId, owner);
    }

    /**
     * @dev See {IERC721-getApproved}.
     */
    function getApproved(uint256 tokenId) public view override returns (address) {
        require(_exists(tokenId), "a");

//        return _tokenApprovals[tokenId];
        return _tokenApprovals[tokenId - 1];
    }

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

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

    function setApprovalForSelf(address operator, bool approved) internal {
        _operatorApprovals[address(this)][operator] = approved;
        emit ApprovalForAll(address(this), operator, approved);
    }

    //    /**
    //     * @dev Sets approval for all from an external contract
    //     *   - Meant for use when there are multiple collections an external contract needs to manage
    //     *   - Can only be called by "authorized" external contracts - set by the owner of this contract
    //    **/
    //    function externalSetApprovalForAll(address forWhom, address operator, bool approved) public {
    //        require(msg.sender == approvalRequestRegistry);
    //        require(operator != forWhom, "a");
    //
    //        _operatorApprovals[forWhom][operator] = approved;
    //        emit ApprovalForAll(forWhom, operator, approved);
    //    }

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

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

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

    /**
     * @dev See {IERC721-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) public virtual override {
        _transfer(from, to, tokenId);
        require(
            _checkOnERC721Received(from, to, tokenId, _data),
            "z"
        );
    }

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

//    function _safeMint(address to, uint256 quantity) internal {
//        _safeMint(to, quantity, "");
//    }
//
//    function _safeMint(
//        address to,
//        uint256 quantity,
//        bytes memory _data
//    ) internal {
//        //        require(!(to.isContract()));
//        _mint(to, quantity);
//        require(_checkOnERC721Received(address(0), to, currentIndex - 1, _data), "z");
//    }
//
//    function _mint(address to, uint256 quantity) internal {
//        uint256 startTokenId = currentIndex;
//        require(to != address(0), "0");
//        // We know if the first token in the batch doesn't exist, the other ones don't as well, because of serial ordering.
//        require(!_exists(startTokenId), "a");
//
//        _balances[to] = _balances[to] + quantity;
//        _ownerships[startTokenId] = to;
//        _minters[startTokenId] = to;
//
//        uint256 updatedIndex = startTokenId;
//
//        for (uint256 i = 0; i < quantity; i++) {
//            emit Transfer(address(0), to, updatedIndex);
//            updatedIndex++;
//        }
//
//        currentIndex = updatedIndex;
//    }

    /******************/

    function _mintIdWithoutBalanceUpdate(address to, uint256 tokenId) private {
        _ownerships[tokenId] = to;
        _minters[tokenId].minter = to;
        _minters[tokenId].timeMinted = uint64(block.timestamp);
//        emit Transfer(address(0), to, tokenId);
        emit Transfer(address(0), to, tokenId + 1);
    }

    function _mintRandom(address to, uint _quantity) internal virtual {
        require(to != address(0), "0");
        require(_quantity > 0, "1");

        uint updatedNumAvailableTokens = _numAvailableTokens;
        for (uint256 i; i < _quantity; i++) { // Do this ++ unchecked?
            uint256 tokenId = getRandomAvailableTokenId(to, updatedNumAvailableTokens);
            _mintIdWithoutBalanceUpdate(to, tokenId);
            updatedNumAvailableTokens--;
        }

        _numAvailableTokens = updatedNumAvailableTokens;
        _balances[to] += _quantity;

        _mintOrdering[currentIndex].minter = to;
        _mintOrdering[currentIndex].timeMinted = uint64(block.timestamp);
        currentIndex += _quantity;
    }

    function getRandomAvailableTokenId(
        address to,
        uint updatedNumAvailableTokens
    ) internal returns (uint256) {
        uint256 randomNum = uint256(
            keccak256(
                abi.encode(
                    to,
                    tx.gasprice,
                    block.number,
                    block.timestamp,
                    block.difficulty,
                    blockhash(block.number - 1),
                    address(this),
                    updatedNumAvailableTokens
                )
            )
        );
        uint256 randomIndex = randomNum % updatedNumAvailableTokens;
        return getAvailableTokenAtIndex(randomIndex, updatedNumAvailableTokens);
    }

    // Implements https://en.wikipedia.org/wiki/Fisher%E2%80%93Yates_shuffle. Code taken from CryptoPhunksV2
    function getAvailableTokenAtIndex(
        uint256 indexToUse,
        uint256 updatedNumAvailableTokens
    ) internal returns (uint256) {
        uint256 valAtIndex = _availableTokens[indexToUse];
        uint256 result;
        if (valAtIndex == 0) {
            // This means the index itself is still an available token
            result = indexToUse;
        } else {
            // This means the index itself is not an available token, but the val at that index is.
            result = valAtIndex;
        }

        uint256 lastIndex = updatedNumAvailableTokens - 1;
        if (indexToUse != lastIndex) {
            // Replace the value at indexToUse, now that it's been used.
            // Replace it with the data from the last index in the array, since we are going to decrease the array size afterwards.
            uint256 lastValInArray = _availableTokens[lastIndex];
            if (lastValInArray == 0) {
                // This means the index itself is still an available token
                _availableTokens[indexToUse] = lastIndex;
            } else {
                // This means the index itself is not an available token, but the val at that index is.
                _availableTokens[indexToUse] = lastValInArray;
                // Gas refund courtsey of @dievardump
                delete _availableTokens[lastIndex];
            }
        }

        return result;
    }

    function getMintOrderInfoByIndex(uint256 index) private view returns (MintInfo memory) {
        if (index > totalSupply()) {
            return _mintOrdering[0];
        }

        for (uint256 i = index; i > 0; i--) {
            if (_mintOrdering[i].minter != address(0)) {
                return _mintOrdering[i];
            }
        }

        return _mintOrdering[0];

//        revert("u");
    }

    function getMinterByOrderIndex(uint256 index) public view returns (address) {
        MintInfo memory info = getMintOrderInfoByIndex(index);
        return info.minter;
    }

    function getMintTimeByOrderIndex(uint256 index) public view returns (uint64) {
        MintInfo memory info = getMintOrderInfoByIndex(index);
        return info.timeMinted;
    }

    /******************/

    function _transfer(
        address from,
        address to,
        uint256 tokenId
    ) private {
        address prevOwnership = ownerOf(tokenId);

        bool isApprovedOrOwner = (_msgSender() == prevOwnership ||
        getApproved(tokenId) == _msgSender() ||
        isApprovedForAll(prevOwnership, _msgSender()));

        require(isApprovedOrOwner, "a");
        require(prevOwnership == from, "o");
        require(to != address(0), "0");

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

        _balances[from] -= 1;
        _balances[to] += 1;
//        _ownerships[tokenId] = to;
        _ownerships[tokenId - 1] = to;

//        // If the ownership slot of tokenId+1 is not explicitly set, that means the transfer initiator owns it.
//        // Set the slot of tokenId+1 explicitly in storage to maintain correctness for ownerOf(tokenId+1) calls.
//        uint256 nextTokenId = tokenId + 1;
//        if (_ownerships[nextTokenId] == address(0)) {
//            if (_exists(nextTokenId)) {
//                _ownerships[nextTokenId] = prevOwnership;
//            }
//        }

        emit Transfer(from, to, tokenId);
    }

    function _approve(
        address to,
        uint256 tokenId,
        address owner
    ) private {
//        _tokenApprovals[tokenId] = to;
        _tokenApprovals[tokenId - 1] = to;
        emit Approval(owner, to, tokenId);
    }

    /******************/

    function _checkOnERC721Received(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) private returns (bool) {
        if (to.isContract()) {
            try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) {
                return retval == IERC721Receiver(to).onERC721Received.selector;
            } catch (bytes memory reason) {
                if (reason.length == 0) {
                    revert("z");
                } else {
                    assembly {
                        revert(add(32, reason), mload(reason))
                    }
                }
            }
        } else {
            return true;
        }
    }
}

////////////////////////////////////////

Settings
{
  "remappings": [
    "ds-test/=lib/operator-filter-registry/lib/forge-std/lib/ds-test/src/",
    "erc4626-tests/=lib/operator-filter-registry/lib/openzeppelin-contracts/lib/erc4626-tests/",
    "forge-std/=lib/operator-filter-registry/lib/forge-std/src/",
    "openzeppelin-contracts-upgradeable/=lib/operator-filter-registry/lib/openzeppelin-contracts-upgradeable/contracts/",
    "openzeppelin-contracts/=lib/operator-filter-registry/lib/openzeppelin-contracts/contracts/",
    "operator-filter-registry/=lib/operator-filter-registry/src/"
  ],
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "metadata": {
    "bytecodeHash": "ipfs"
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "evmVersion": "london",
  "libraries": {}
}

Contract ABI

[{"inputs":[{"internalType":"string","name":"name_","type":"string"},{"internalType":"string","name":"symbol_","type":"string"},{"internalType":"uint256","name":"maxMintsPerWallet_","type":"uint256"},{"internalType":"address[]","name":"payees_","type":"address[]"},{"internalType":"uint256[]","name":"basisPoints_","type":"uint256[]"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"operator","type":"address"}],"name":"OperatorNotAllowed","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":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","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"},{"inputs":[],"name":"OPERATOR_FILTER_REGISTRY","outputs":[{"internalType":"contract IOperatorFilterRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PROVENANCE","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"allowlistClaimed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"allowlistClaimsMade","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"allowlistClaimsRemain","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"operator","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":[],"name":"basedURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"minter","type":"address"},{"internalType":"bytes32[]","name":"_proof","type":"bytes32[]"}],"name":"eligibleForAllowlist","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"minter","type":"address"},{"internalType":"bytes32[]","name":"_proof","type":"bytes32[]"}],"name":"eligibleForPhunk","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"emergencyWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"}],"name":"emergencyWithdrawTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"flipPaused","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"flipRoyaltySwitch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getGenderAndDirection","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"uint256","name":"quantity","type":"uint256"},{"internalType":"bytes32[]","name":"_phunkProof","type":"bytes32[]"},{"internalType":"bytes32[]","name":"_alProof","type":"bytes32[]"}],"name":"getMintCost","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getMintTimeByOrderIndex","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getMinterByOrderIndex","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"uint256","name":"quantity","type":"uint256"},{"internalType":"bytes32[]","name":"_phunkProof","type":"bytes32[]"},{"internalType":"bytes32[]","name":"_alProof","type":"bytes32[]"}],"name":"getNumFree","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"getReserveAuthStatus","outputs":[{"internalType":"bool","name":"","type":"bool"}],"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":[],"name":"keyRedemptionAmt","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"keysContract","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxAllowlistClaims","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxMintableSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"bytes32[]","name":"_phunkProof","type":"bytes32[]"},{"internalType":"bytes32[]","name":"_alProof","type":"bytes32[]"}],"name":"maxMintsPerWallet","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxPhunkClaims","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxPossibleSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxReserveSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"merkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_quantity","type":"uint256"},{"internalType":"uint256","name":"genderDirection","type":"uint256"},{"internalType":"bytes32[]","name":"_phunkProof","type":"bytes32[]"},{"internalType":"bytes32[]","name":"_alProof","type":"bytes32[]"}],"name":"mint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"mintPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_quantity","type":"uint256"},{"internalType":"uint256","name":"genderDirection","type":"uint256"}],"name":"mintReserve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"mintStatus","outputs":[{"internalType":"enum Skelephunks.MintStatus","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"mintedAt","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"minterOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"numMinted","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"numMintedRegular","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"numMintedReserve","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"payees","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"phunkClaimsRemain","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"phunkListClaimed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"phunksClaimsMade","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"phunksMerkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"preRevealURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"keyId","type":"uint256"},{"internalType":"uint256","name":"genderDirection","type":"uint256"}],"name":"redeemKeyForSkelephunks","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":"bytes32","name":"_newAllowlistMerkleRoot","type":"bytes32"}],"name":"setAllowlistMerkleRoot","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":"basedURI_","type":"string"}],"name":"setBasedURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_collectionDescription","type":"string"}],"name":"setCollectionDescription","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_collectionImg","type":"string"}],"name":"setCollectionImg","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_externalLink","type":"string"}],"name":"setExternalLink","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"gender","type":"uint256"},{"internalType":"uint256","name":"direction","type":"uint256"}],"name":"setGenderAndDirection","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newAmt","type":"uint256"}],"name":"setKeyRedemptionAmt","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"keysAddr","type":"address"}],"name":"setKeysContract","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"__maxMintsPerWallet","type":"uint256"}],"name":"setMaxMintsPerWallet","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_mintPrice","type":"uint256"}],"name":"setMintPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum Skelephunks.MintStatus","name":"newMintStatus","type":"uint8"}],"name":"setMintStatus","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_newPhunksMerkleRoot","type":"bytes32"}],"name":"setPhunksMerkleRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"preRevealURI_","type":"string"}],"name":"setPreRevealURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"provenanceHash","type":"string"}],"name":"setProvenanceHash","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"bool","name":"isAuthorized","type":"bool"}],"name":"setReserveAuthStatus","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":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"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":"minter","type":"address"}],"name":"totalClaimsMade","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":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"bytes32[]","name":"_phunkProof","type":"bytes32[]"},{"internalType":"bytes32[]","name":"_alProof","type":"bytes32[]"}],"name":"walletCanMint","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"}],"name":"withdrawTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]

60016000908155601481905565763bfbd22000601655600a6017556018805461ffff1916905561270f601955611a0a601a55601b819055610d05601c55601d55610120604052604460a08181529062004ea260c039601f90620000639082620006c8565b5060408051602080820190925260008152620000809082620006c8565b5060408051808201909152601781527f68747470733a2f2f736b656c657068756e6b732e636f6d0000000000000000006020820152602190620000c49082620006c8565b507ff0f7a55aec9ad32ed76282ecb785ebe960e8086dcccaf5936a0dfccb1973368460235561014d6025557f106cfb7a584f43d49565772c75a9e5e49c925b021a541f1975516ca4792a24b46027556103e86029556003602f556030805460ff191660011790553480156200013857600080fd5b5060405162004ee638038062004ee68339810160408190526200015b91620008ed565b733cc6cdda760b79bafa08df41ecfa224f810dceb6600186866019548260019081620001889190620006c8565b506002620001978382620006c8565b50608081905260065550620001ae90503362000550565b6daaeb6d7670e522a718067333cd4e3b15620002f35780156200024157604051633e9f1edf60e11b81523060048201526001600160a01b03831660248201526daaeb6d7670e522a718067333cd4e90637d3e3dbe906044015b600060405180830381600087803b1580156200022257600080fd5b505af115801562000237573d6000803e3d6000fd5b50505050620002f3565b6001600160a01b03821615620002925760405163a0af290360e01b81523060048201526001600160a01b03831660248201526daaeb6d7670e522a718067333cd4e9063a0af29039060440162000207565b604051632210724360e11b81523060048201526daaeb6d7670e522a718067333cd4e90634420e48690602401600060405180830381600087803b158015620002d957600080fd5b505af1158015620002ee573d6000803e3d6000fd5b505050505b5050601e8390558051825114620003345760405162461bcd60e51b81526020600482015260016024820152601b60fa1b604482015260640160405180910390fd5b815162000349906012906020850190620005a2565b5060005b8251811015620003cf578181815181106200036c576200036c62000a20565b6020026020010151601360008584815181106200038d576200038d62000a20565b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055508080620003c69062000a36565b9150506200034d565b5060408051808201909152600a8152697068756e6b2f6d616c6560b01b60208083019190915260008052601190527f4ad3b33220dddc71b994a52d72c06b10862965f7d926534c05c00fb7e819e7b7906200042b9082620006c8565b5060408051808201909152600c81526b7068756e6b2f66656d616c6560a01b6020808301919091526001600052601190527f17bc176d2408558f6e4111feebc3cab4e16b63e967be91cde721f4c8a488b552906200048a9082620006c8565b5060408051808201909152600981526870756e6b2f6d616c6560b81b6020808301919091526002600052601190527f08037d7b151cc412d25674a4e66b334d9ae9d2e5517a7feaae5cdb828bf1c62890620004e69082620006c8565b5060408051808201909152600b81526a70756e6b2f66656d616c6560a81b6020808301919091526003600052601190527f9bfbaa59f8e10e7868f8b402de9d605a390c45ddaebd8c9de3c6f31e733c87ff90620005449082620006c8565b50505050505062000a5e565b600d80546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b828054828255906000526020600020908101928215620005fa579160200282015b82811115620005fa57825182546001600160a01b0319166001600160a01b03909116178255602090920191600190910190620005c3565b50620006089291506200060c565b5090565b5b808211156200060857600081556001016200060d565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200064e57607f821691505b6020821081036200066f57634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620006c357600081815260208120601f850160051c810160208610156200069e5750805b601f850160051c820191505b81811015620006bf57828155600101620006aa565b5050505b505050565b81516001600160401b03811115620006e457620006e462000623565b620006fc81620006f5845462000639565b8462000675565b602080601f8311600181146200073457600084156200071b5750858301515b600019600386901b1c1916600185901b178555620006bf565b600085815260208120601f198616915b82811015620007655788860151825594840194600190910190840162000744565b5085821015620007845787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b604051601f8201601f191681016001600160401b0381118282101715620007bf57620007bf62000623565b604052919050565b600082601f830112620007d957600080fd5b81516001600160401b03811115620007f557620007f562000623565b60206200080b601f8301601f1916820162000794565b82815285828487010111156200082057600080fd5b60005b838110156200084057858101830151828201840152820162000823565b506000928101909101919091529392505050565b60006001600160401b0382111562000870576200087062000623565b5060051b60200190565b600082601f8301126200088c57600080fd5b81516020620008a56200089f8362000854565b62000794565b82815260059290921b84018101918181019086841115620008c557600080fd5b8286015b84811015620008e25780518352918301918301620008c9565b509695505050505050565b600080600080600060a086880312156200090657600080fd5b85516001600160401b03808211156200091e57600080fd5b6200092c89838a01620007c7565b96506020915081880151818111156200094457600080fd5b620009528a828b01620007c7565b965050604088015194506060880151818111156200096f57600080fd5b8801601f81018a136200098157600080fd5b8051620009926200089f8262000854565b81815260059190911b8201840190848101908c831115620009b257600080fd5b928501925b82841015620009e95783516001600160a01b0381168114620009d95760008081fd5b82529285019290850190620009b7565b60808c015190975094505050508082111562000a0457600080fd5b5062000a13888289016200087a565b9150509295509295909350565b634e487b7160e01b600052603260045260246000fd5b60006001820162000a5757634e487b7160e01b600052601160045260246000fd5b5060010190565b60805161441a62000a88600039600081816110d8015281816112fb01526117a3015261441a6000f3fe6080604052600436106104985760003560e01c8063715018a611610260578063b81440bb11610144578063db2e21bc116100c1578063f1b0aa1511610085578063f1b0aa1514610df9578063f2eb817214610e19578063f2fde38b14610e39578063f4a0a52814610e59578063f8cf016314610e79578063f95df41414610eb257600080fd5b8063db2e21bc14610d4d578063df87694914610d62578063e8a3d48514610d7b578063e985e9c514610d90578063ede029fc14610dd957600080fd5b8063c87b56dd11610108578063c87b56dd14610cc9578063ce8539b114610ce9578063cffb47cf14610cfe578063d831f62314610d14578063daf5085914610d2d57600080fd5b8063b81440bb14610c28578063b88d4fde14610c3e578063bb42436914610c5e578063c1d5f48c14610c71578063c48f653114610c9157600080fd5b80638ca1f0cf116101dd5780639da3f8fd116101a15780639da3f8fd14610b615780639e942ace14610b88578063a22cb46514610ba8578063aff8cfa114610bc8578063b2af127c14610be8578063b6d04a0b14610c0857600080fd5b80638ca1f0cf14610ace5780638da5cb5b14610aee5780639471302e14610b0c57806395d89b4114610b2c578063963c354614610b4157600080fd5b80637e12dc11116102245780637e12dc1114610a1e578063814c8c5514610a3e5780638305778a14610a5e578063881e68c614610a8e5780638ac06d3914610aae57600080fd5b8063715018a614610994578063740ac6f6146109a9578063741fd872146109c957806379b6ed36146109e95780637ccd7887146109fe57600080fd5b8063333171bb1161038757806349ee537d1161030457806363037b0c116102c857806363037b0c146108f35780636352211e146109135780636373a6b1146109335780636817c76c146109485780636b90fa851461095e57806370a082311461097457600080fd5b806349ee537d146108685780634f6ccce71461087e5780635b2ca0841461089e5780635c975abb146108be5780636095049a146108dd57600080fd5b806341f434341161034b57806341f43434146107d057806342842e0e146107f257806344dd599b146108125780634811ea441461083257806349df728c1461084857600080fd5b8063333171bb14610764578063386b7691146107795780633ccfd60b1461078f5780633cf01344146107a457806341422eed146107ba57600080fd5b80631a05dc87116104155780632eb4a7ab116103d95780632eb4a7ab146106c85780632f745c59146106de57806330359e5f146106fe578063303a67d01461071e57806330b42ec21461073457600080fd5b80631a05dc871461061b5780631f9179211461063b57806320fc7eb21461065b57806323b872dd146106885780632a85db55146106a857600080fd5b8063095ea7b31161045c578063095ea7b31461058f57806310969523146105b157806313ea7b04146105d157806318160ddd146105e65780631931225b146105fb57600080fd5b806301ffc9a7146104bc57806304a6c8c9146104f15780630519ef1f1461051557806306fdde0314610535578063081812fc1461055757600080fd5b366104b75734601460008282546104af91906138f1565b925050819055005b600080fd5b3480156104c857600080fd5b506104dc6104d736600461391a565b610ed2565b60405190151581526020015b60405180910390f35b3480156104fd57600080fd5b50610507601a5481565b6040519081526020016104e8565b34801561052157600080fd5b50610507610530366004613999565b610f3f565b34801561054157600080fd5b5061054a610f77565b6040516104e89190613a72565b34801561056357600080fd5b50610577610572366004613a85565b611009565b6040516001600160a01b0390911681526020016104e8565b34801561059b57600080fd5b506105af6105aa366004613a9e565b611068565b005b3480156105bd57600080fd5b506105af6105cc366004613b53565b61108d565b3480156105dd57600080fd5b5061054a6110c2565b3480156105f257600080fd5b506105076110d1565b34801561060757600080fd5b506105af610616366004613b9b565b611106565b34801561062757600080fd5b506104dc610636366004613bc7565b611238565b34801561064757600080fd5b506105af610656366004613b53565b611255565b34801561066757600080fd5b50610507610676366004613c47565b60106020526000908152604090205481565b34801561069457600080fd5b506105af6106a3366004613c62565b61126d565b3480156106b457600080fd5b506105af6106c3366004613b53565b6112a4565b3480156106d457600080fd5b5061050760275481565b3480156106ea57600080fd5b506105076106f9366004613a9e565b6112b8565b34801561070a57600080fd5b506105af610719366004613c9e565b6113aa565b34801561072a57600080fd5b50610507601b5481565b34801561074057600080fd5b506104dc61074f366004613c47565b602a6020526000908152604090205460ff1681565b34801561077057600080fd5b506105af6113f9565b34801561078557600080fd5b5061050760195481565b34801561079b57600080fd5b506105af61141e565b3480156107b057600080fd5b5061050760295481565b3480156107c657600080fd5b5061050760255481565b3480156107dc57600080fd5b506105776daaeb6d7670e522a718067333cd4e81565b3480156107fe57600080fd5b506105af61080d366004613c62565b611508565b34801561081e57600080fd5b5061050761082d366004613a85565b611539565b34801561083e57600080fd5b5061050760285481565b34801561085457600080fd5b506105af610863366004613c47565b611587565b34801561087457600080fd5b5061050760245481565b34801561088a57600080fd5b50610507610899366004613a85565b611719565b3480156108aa57600080fd5b506105af6108b9366004613cd1565b611818565b3480156108ca57600080fd5b506018546104dc90610100900460ff1681565b3480156108e957600080fd5b50610507601d5481565b3480156108ff57600080fd5b5061057761090e366004613a85565b6118c9565b34801561091f57600080fd5b5061057761092e366004613a85565b6118f3565b34801561093f57600080fd5b5061054a611929565b34801561095457600080fd5b5061050760165481565b34801561096a57600080fd5b5061050760235481565b34801561098057600080fd5b5061050761098f366004613c47565b6119b7565b3480156109a057600080fd5b506105af6119fb565b3480156109b557600080fd5b506104dc6109c4366004613cf3565b611a0f565b3480156109d557600080fd5b50602e54610577906001600160a01b031681565b3480156109f557600080fd5b5061054a611ac0565b348015610a0a57600080fd5b506105af610a19366004613a85565b611acf565b348015610a2a57600080fd5b506104dc610a39366004613cf3565b611adc565b348015610a4a57600080fd5b506105af610a59366004613d45565b611b51565b348015610a6a57600080fd5b506104dc610a79366004613c47565b60266020526000908152604090205460ff1681565b348015610a9a57600080fd5b50610577610aa9366004613a85565b611bea565b348015610aba57600080fd5b506105af610ac9366004613c47565b611bfe565b348015610ada57600080fd5b506105af610ae9366004613b53565b611c46565b348015610afa57600080fd5b50600d546001600160a01b0316610577565b348015610b1857600080fd5b506105af610b27366004613b53565b611c5a565b348015610b3857600080fd5b5061054a611c6e565b348015610b4d57600080fd5b506105af610b5c366004613a85565b611c7d565b348015610b6d57600080fd5b50601854610b7b9060ff1681565b6040516104e89190613d7c565b348015610b9457600080fd5b50610577610ba3366004613a85565b611c8a565b348015610bb457600080fd5b506105af610bc3366004613db2565b611cc0565b348015610bd457600080fd5b506105af610be3366004613db2565b611ce0565b348015610bf457600080fd5b506105af610c03366004613c47565b611d13565b348015610c1457600080fd5b50610507610c23366004613c47565b611dfc565b348015610c3457600080fd5b50610507602f5481565b348015610c4a57600080fd5b506105af610c59366004613de9565b611e2a565b6105af610c6c366004613e64565b611e63565b348015610c7d57600080fd5b506105af610c8c366004613a85565b6120b9565b348015610c9d57600080fd5b50610cb1610cac366004613a85565b6120c6565b6040516001600160401b0390911681526020016104e8565b348015610cd557600080fd5b5061054a610ce4366004613a85565b6120dd565b348015610cf557600080fd5b506105af612200565b348015610d0a57600080fd5b50610507601c5481565b348015610d2057600080fd5b50602954602854106104dc565b348015610d3957600080fd5b50610507610d48366004613999565b61221c565b348015610d5957600080fd5b506105af61234c565b348015610d6e57600080fd5b50602554602454106104dc565b348015610d8757600080fd5b5061054a6123e0565b348015610d9c57600080fd5b506104dc610dab366004613ea2565b6001600160a01b039182166000908152600c6020908152604080832093909416825291909152205460ff1690565b348015610de557600080fd5b506105af610df4366004613b53565b612421565b348015610e0557600080fd5b50610cb1610e14366004613a85565b612432565b348015610e2557600080fd5b50610507610e34366004613bc7565b61248f565b348015610e4557600080fd5b506105af610e54366004613c47565b6124a8565b348015610e6557600080fd5b506105af610e74366004613a85565b61251e565b348015610e8557600080fd5b506104dc610e94366004613c47565b6001600160a01b03166000908152602d602052604090205460ff1690565b348015610ebe57600080fd5b506105af610ecd366004613a85565b61252b565b60006001600160e01b031982166380ac58cd60e01b1480610f0357506001600160e01b03198216635b5e139f60e01b145b80610f1e57506001600160e01b0319821663780e9d6360e01b145b80610f3957506301ffc9a760e01b6001600160e01b03198316145b92915050565b600080610f5088888888888861221c565b9050610f5c8188613ed5565b601654610f699190613ee8565b9150505b9695505050505050565b606060018054610f8690613eff565b80601f0160208091040260200160405190810160405280929190818152602001828054610fb290613eff565b8015610fff5780601f10610fd457610100808354040283529160200191610fff565b820191906000526020600020905b815481529060010190602001808311610fe257829003601f168201915b5050505050905090565b600061101482612538565b6110395760405162461bcd60e51b815260040161103090613f33565b60405180910390fd5b600b6000611048600185613ed5565b81526020810191909152604001600020546001600160a01b031692915050565b603054829060ff161561107e5761107e8161257c565b6110888383612635565b505050565b6110956126b6565b600f5460ff16156110a557600080fd5b600e6110b18282613f94565b5050600f805460ff19166001179055565b606060038054610f8690613eff565b60006006547f00000000000000000000000000000000000000000000000000000000000000006111019190613ed5565b905090565b61110f836118f3565b6001600160a01b0316336001600160a01b03161461113f5760405162461bcd60e51b815260040161103090614053565b60028210801561114f5750600281105b61117f5760405162461bcd60e51b81526020600482015260016024820152603b60f91b6044820152606401611030565b60008261118d836002613ee8565b61119791906138f1565b905060006111a485611539565b905060006111b3608087614084565b905060006111c2608088614098565b90506111cf816002613ee8565b83901b6022600084815260200190815260200160002060008282546111f49190613ed5565b909155506112059050816002613ee8565b84901b60226000848152602001908152602001600020600082825461122a91906138f1565b909155505050505050505050565b600080611248878787878761248f565b1190505b95945050505050565b61125d6126b6565b60216112698282613f94565b5050565b603054839060ff1615611293576001600160a01b0381163314611293576112933361257c565b61129e848484612710565b50505050565b6112ac6126b6565b6112b58161271b565b50565b60006112c3836119b7565b82106112f55760405162461bcd60e51b81526020600482015260016024820152603160f91b6044820152606401611030565b6000805b7f000000000000000000000000000000000000000000000000000000000000000081101561137d576000818152600860205260409020546001600160a01b0380871691160361136b5783820361135d576113548160016138f1565b92505050610f39565b81611367816140ac565b9250505b80611375816140ac565b9150506112f9565b5060405162461bcd60e51b81526020600482015260016024820152607560f81b6044820152606401611030565b336000908152602d602052604090205460ff166113ee5760405162461bcd60e51b8152602060048201526002602482015261726160f01b6044820152606401611030565b611088838383612727565b6114016126b6565b6018805461ff001981166101009182900460ff1615909102179055565b611426612768565b336000908152601360205260408120546014546114469061271090614084565b6114509190613ee8565b336000908152601560205260408120549192509061146e9083613ed5565b33600081815260156020526040808220869055519293509183908381818185875af1925050503d80600081146114c0576040519150601f19603f3d011682016040523d82523d6000602084013e6114c5565b606091505b50509050806110885760405162461bcd60e51b815260206004820152600f60248201526e5061796d656e74206661696c65642160881b6044820152606401611030565b603054839060ff161561152e576001600160a01b038116331461152e5761152e3361257c565b61129e8484846127b2565b600080611547608084614084565b90506000611556608085614098565b90506004611565826002613ee8565b60008481526022602052604090205461157f92911c614098565b949350505050565b61158f612768565b60005b60125481101561126957816001600160a01b031663a9059cbb601283815481106115be576115be6140c5565b9060005260206000200160009054906101000a90046001600160a01b031660136000601286815481106115f3576115f36140c5565b60009182526020808320909101546001600160a01b03908116845290830193909352604091820190205490516370a0823160e01b8152306004820152909161271091908816906370a0823190602401602060405180830381865afa15801561165f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061168391906140db565b61168d9190614084565b6116979190613ee8565b6040516001600160e01b031960e085901b1681526001600160a01b03909216600483015260248201526044016020604051808303816000875af11580156116e2573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061170691906140f4565b5080611711816140ac565b915050611592565b600080821161174f5760405162461bcd60e51b8152602060048201526002602482015261069360f41b6044820152606401611030565b600061175c600184613ed5565b905060006117686110d1565b905080821061179d5760405162461bcd60e51b81526020600482015260016024820152606760f81b6044820152606401611030565b6000805b7f000000000000000000000000000000000000000000000000000000000000000081101561137d576000818152600860205260409020546001600160a01b031615611806578382036117f857610f6d8160016138f1565b81611802816140ac565b9250505b80611810816140ac565b9150506117a1565b33321461185a5760405162461bcd60e51b815260206004820152601060248201526f6e6f20636f6e7472616374732066616d60801b6044820152606401611030565b61186733602f5483612727565b602e546040516363aac3a360e01b8152600481018490526001600160a01b03909116906363aac3a390602401600060405180830381600087803b1580156118ad57600080fd5b505af11580156118c1573d6000803e3d6000fd5b505050505050565b601281815481106118d957600080fd5b6000918252602090912001546001600160a01b0316905081565b60006118fe82612538565b61191a5760405162461bcd60e51b815260040161103090614111565b60086000611048600185613ed5565b600e805461193690613eff565b80601f016020809104026020016040519081016040528092919081815260200182805461196290613eff565b80156119af5780601f10611984576101008083540402835291602001916119af565b820191906000526020600020905b81548152906001019060200180831161199257829003601f168201915b505050505081565b60006001600160a01b0382166119df5760405162461bcd60e51b81526004016110309061412c565b506001600160a01b031660009081526009602052604090205490565b611a036126b6565b611a0d60006127cd565b565b6001600160a01b03831660009081526026602052604081205460ff16158015611aaa5750611aaa838380806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506023546040516bffffffffffffffffffffffff1960608b901b16602082015290925060340190505b6040516020818303038152906040528051906020012061281f565b801561157f575060255460245410949350505050565b606060048054610f8690613eff565b611ad76126b6565b602f55565b6000611b3e838380806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506027546040516bffffffffffffffffffffffff1960608b901b1660208201529092506034019050611a8f565b801561157f57506029546028541061157f565b611b596126b6565b6000816006811115611b6d57611b6d613d66565b14158015611b925750600660185460ff166006811115611b8f57611b8f613d66565b14155b611bc35760405162461bcd60e51b81526020600482015260026024820152616d7360f01b6044820152606401611030565b6018805482919060ff19166001836006811115611be257611be2613d66565b021790555050565b600080611bf683612835565b519392505050565b611c066126b6565b602e54611c1d906001600160a01b03166000611ce0565b602e80546001600160a01b0319166001600160a01b0383169081179091556112b5906001611ce0565b611c4e6126b6565b60206112698282613f94565b611c626126b6565b601f6112698282613f94565b606060028054610f8690613eff565b611c856126b6565b601e55565b6000611c9582612538565b611cb15760405162461bcd60e51b815260040161103090614111565b60076000611048600185613ed5565b603054829060ff1615611cd657611cd68161257c565b611088838361298f565b611ce86126b6565b6001600160a01b03919091166000908152602d60205260409020805460ff1916911515919091179055565b611d1b6126b6565b6040516370a0823160e01b81523060048201526001600160a01b0382169063a9059cbb90339083906370a0823190602401602060405180830381865afa158015611d69573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d8d91906140db565b6040516001600160e01b031960e085901b1681526001600160a01b03909216600483015260248201526044016020604051808303816000875af1158015611dd8573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061126991906140f4565b6001600160a01b0381166000908152602c6020908152604080832054602b909252822054610f3991906138f1565b603054849060ff1615611e50576001600160a01b0381163314611e5057611e503361257c565b611e5c85858585612a23565b5050505050565b333214611e6f57600080fd5b6000611e7f33888787878761221c565b9050611e8f338887878787610f3f565b3414611ec65760405162461bcd60e51b8152600401611030906020808252600490820152633837b7b960e11b604082015260600190565b611ed3338686868661248f565b871115611f0b5760405162461bcd60e51b8152600401611030906020808252600490820152636d6d707760e01b604082015260600190565b601a54611f188289613ed5565b601b54611f2591906138f1565b1115611f595760405162461bcd60e51b81526020600482015260036024820152626d6d7360e81b6044820152606401611030565b601c5481601d54611f6a91906138f1565b1115611f9e5760405162461bcd60e51b81526020600482015260036024820152626d727360e81b6044820152606401611030565b80801561200157611fb0338787611a0f565b1561200157336000908152602660209081526040808320805460ff19166001908117909155602b9092528220805491929091611fed9084906138f1565b90915550611ffe9050600182613ed5565b90505b801561206357612012338585611adc565b1561206357336000908152602a60209081526040808320805460ff19166001908117909155602b909252822080549192909161204f9084906138f1565b909155506120609050600182613ed5565b90505b336000908152602b6020526040812080548392906120829084906138f1565b92505081905550346014600082825461209b91906138f1565b909155506120af90503389848a6000612a56565b5050505050505050565b6120c16126b6565b602355565b6000806120d283612835565b602001519392505050565b60606120e882612538565b6121045760405162461bcd60e51b815260040161103090614147565b60006003805461211390613eff565b905011156121695760036011600061212a85611539565b815260200190815260200160002061214184612c7a565b604051602001612153939291906141f1565b6040516020818303038152906040529050919050565b6004805461217690613eff565b80601f01602080910402602001604051908101604052809291908181526020018280546121a290613eff565b80156121ef5780601f106121c4576101008083540402835291602001916121ef565b820191906000526020600020905b8154815290600101906020018083116121d257829003601f168201915b50505050509050919050565b919050565b6122086126b6565b6030805460ff19811660ff90911615179055565b60008060185460ff16600681111561223657612236613d66565b0361224357506000610f6d565b600160185460ff16600681111561225c5761225c613d66565b036122845761226c878686611a0f565b61227757600061227a565b60015b60ff169050610f6d565b600260185460ff16600681111561229d5761229d613d66565b036122e7576122ad878484611adc565b156122c7576122c0878787878787612d0c565b9050610f6d565b6122d2878686611a0f565b156122df57506001610f6d565b506000610f6d565b600360185460ff16600681111561230057612300613d66565b03612313576122c0878787878787612d0c565b600460185460ff16600681111561232c5761232c613d66565b0361233f576122c0878787878787612d0c565b5060009695505050505050565b6123546126b6565b6040514790600090339083908381818185875af1925050503d8060008114612398576040519150601f19603f3d011682016040523d82523d6000602084013e61239d565b606091505b50509050806112695760405162461bcd60e51b815260206004820152600f60248201526e5061796d656e74206661696c65642160881b6044820152606401611030565b60606123ea610f77565b601f602060216123f930612dd7565b60405160200161240d959493929190614238565b604051602081830303815290604052905090565b6124296126b6565b6112b581612dee565b600061243d82612538565b6124595760405162461bcd60e51b815260040161103090614111565b60076000612468600185613ed5565b8152602081019190915260400160002054600160a01b90046001600160401b031692915050565b6000610f6d60646124a38888888888612dfa565b612f71565b6124b06126b6565b6001600160a01b0381166125155760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401611030565b6112b5816127cd565b6125266126b6565b601655565b6125336126b6565b602755565b60008160000361254a57506000919050565b600060088161255a600186613ed5565b81526020810191909152604001600020546001600160a01b0316141592915050565b6daaeb6d7670e522a718067333cd4e3b156112b557604051633185c44d60e21b81523060048201526001600160a01b03821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa1580156125e9573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061260d91906140f4565b6112b557604051633b79c77360e21b81526001600160a01b0382166004820152602401611030565b6000612640826118f3565b9050806001600160a01b0316836001600160a01b0316036126735760405162461bcd60e51b815260040161103090614053565b336001600160a01b038216148061268f575061268f8133610dab565b6126ab5760405162461bcd60e51b815260040161103090613f33565b611088838383612f88565b600d546001600160a01b03163314611a0d5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401611030565b611088838383612ffb565b60046112698282613f94565b61273683836000846001612a56565b6001600160a01b0383166000908152602c60205260408120805484929061275e9084906138f1565b9091555050505050565b33600090815260136020526040902054611a0d5760405162461bcd60e51b815260206004820152600b60248201526a6e6f74206120706179656560a81b6044820152606401611030565b61108883838360405180602001604052806000815250611e2a565b600d80546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60008261282c8584613195565b14949350505050565b60408051808201909152600080825260208201526128516110d1565b8211156128b757505060008052600a6020908152604080518082019091527f13da86008ba1c6922daee3e07db95305ef49ebced9f5467a0b8613fcc6b343e3546001600160a01b0381168252600160a01b90046001600160401b03169181019190915290565b815b801561292f576000818152600a60205260409020546001600160a01b03161561291d576000908152600a60209081526040918290208251808401909352546001600160a01b0381168352600160a01b90046001600160401b03169082015292915050565b8061292781614364565b9150506128b9565b50506000805250600a6020908152604080518082019091527f13da86008ba1c6922daee3e07db95305ef49ebced9f5467a0b8613fcc6b343e3546001600160a01b0381168252600160a01b90046001600160401b03169181019190915290565b336001600160a01b038316036129b75760405162461bcd60e51b815260040161103090613f33565b336000818152600c602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b612a2e848484612ffb565b612a3a848484846131e2565b61129e5760405162461bcd60e51b815260040161103090614147565b601854610100900460ff1615612a925760405162461bcd60e51b81526020600482015260016024820152600760fc1b6044820152606401611030565b60048210612ac65760405162461bcd60e51b81526020600482015260016024820152603b60f91b6044820152606401611030565b601b54612ad386866132e3565b6001600160a01b03861660009081526010602052604081208054879290612afb9084906138f1565b909155506000905080612b0f608084614084565b9050825b612b1d88856138f1565b811015612ba0576000612b31608083614084565b9050828114612b675760008381526022602052604081208054869290612b589084906138f1565b92505081905550600093508092505b612b72608083614098565b612b7d906002613ee8565b612b8a9088901b856138f1565b9350508080612b98906140ac565b915050612b13565b5060008181526022602052604081208054849290612bbf9084906138f1565b90915550508315612be75786601d6000828254612bdc91906138f1565b90915550612c219050565b612bf18688613ed5565b601b6000828254612c0291906138f1565b9250508190555085601d6000828254612c1b91906138f1565b90915550505b601a54601b5403612c3a576018805460ff191660051790555b600560185460ff166006811115612c5357612c53613d66565b036120af57601c54601d54036120af5750506018805460ff19166006179055505050505050565b60606000612c878361341b565b60010190506000816001600160401b03811115612ca657612ca6613ac8565b6040519080825280601f01601f191660200182016040528015612cd0576020820181803683370190505b5090508181016020015b600019016f181899199a1a9b1b9c1cb0b131b232b360811b600a86061a8153600a8504945084612cda57509392505050565b600080612d1c888787878761248f565b8703612d59576001600160a01b0388166000908152602b6020526040902054612d46906003613ed5565b9050612d528188612f71565b9050612dcc565b612d64888585611adc565b8015612d8957506001600160a01b0388166000908152602a602052604090205460ff16155b612d94576000612d97565b60015b612da2898888611a0f565b612dad576000612db0565b60015b612dba919061437b565b60ff169050612dc98188612f71565b90505b979650505050505050565b6060610f3982612de6846134f3565b60010161355d565b60036112698282613f94565b60008060185460ff166006811115612e1457612e14613d66565b03612e215750600061124c565b600160185460ff166006811115612e3a57612e3a613d66565b03612e6257612e4a868686611a0f565b612e55576000612e58565b60015b60ff16905061124c565b600260185460ff166006811115612e7b57612e7b613d66565b03612ef057612e8b868484611adc565b15612ed0576001600160a01b038616600090815260106020526040902054601e54612ec991612eb991613ed5565b601b54601a546124a39190613ed5565b905061124c565b612edb868686611a0f565b15612ee85750600161124c565b50600061124c565b600360185460ff166006811115612f0957612f09613d66565b03612f37576001600160a01b038616600090815260106020526040902054601e54612ec991612eb991613ed5565b600460185460ff166006811115612f5057612f50613d66565b03612f6557601b54601a54612ec99190613ed5565b50600095945050505050565b600081831015612f82575081610f39565b50919050565b82600b6000612f98600186613ed5565b815260208101919091526040908101600090812080546001600160a01b0319166001600160a01b039485161790559051849286811692908516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259190a4505050565b6000613006826118f3565b90506000336001600160a01b038316148061303157503361302684611009565b6001600160a01b0316145b8061304157506130418233610dab565b9050806130605760405162461bcd60e51b815260040161103090613f33565b846001600160a01b0316826001600160a01b0316146130915760405162461bcd60e51b815260040161103090614053565b6001600160a01b0384166130b75760405162461bcd60e51b81526004016110309061412c565b6130c360008484612f88565b6001600160a01b03851660009081526009602052604081208054600192906130ec908490613ed5565b90915550506001600160a01b038416600090815260096020526040812080546001929061311a9084906138f1565b9091555084905060086000613130600187613ed5565b815260208101919091526040908101600090812080546001600160a01b0319166001600160a01b039485161790559051859287811692908916917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9190a45050505050565b600081815b84518110156131da576131c6828683815181106131b9576131b96140c5565b60200260200101516136ff565b9150806131d2816140ac565b91505061319a565b509392505050565b60006001600160a01b0384163b156132d857604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290613226903390899088908890600401614394565b6020604051808303816000875af1925050508015613261575060408051601f3d908101601f1916820190925261325e918101906143c7565b60015b6132be573d80801561328f576040519150601f19603f3d011682016040523d82523d6000602084013e613294565b606091505b5080516000036132b65760405162461bcd60e51b815260040161103090614147565b805181602001fd5b6001600160e01b031916630a85bd0160e11b14905061157f565b506001949350505050565b6001600160a01b0382166133095760405162461bcd60e51b81526004016110309061412c565b6000811161333d5760405162461bcd60e51b81526020600482015260016024820152603160f81b6044820152606401611030565b60065460005b82811015613384576000613357858461372e565b905061336385826137b7565b8261336d81614364565b93505050808061337c906140ac565b915050613343565b5060068190556001600160a01b038316600090815260096020526040812080548492906133b29084906138f1565b9091555050600080548152600a602052604080822080546001600160a01b0319166001600160a01b038716179055815482528120805467ffffffffffffffff60a01b1916600160a01b426001600160401b0316021790558054839190819061275e9084906138f1565b60008072184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b831061345a5772184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b830492506040015b6d04ee2d6d415b85acef81000000008310613486576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc1000083106134a457662386f26fc10000830492506010015b6305f5e10083106134bc576305f5e100830492506008015b61271083106134d057612710830492506004015b606483106134e2576064830492506002015b600a8310610f395760010192915050565b600080608083901c1561350b5760809290921c916010015b604083901c156135205760409290921c916008015b602083901c156135355760209290921c916004015b601083901c1561354a5760109290921c916002015b600883901c15610f395760010192915050565b6060600061356c836002613ee8565b6135779060026138f1565b6001600160401b0381111561358e5761358e613ac8565b6040519080825280601f01601f1916602001820160405280156135b8576020820181803683370190505b509050600360fc1b816000815181106135d3576135d36140c5565b60200101906001600160f81b031916908160001a905350600f60fb1b81600181518110613602576136026140c5565b60200101906001600160f81b031916908160001a9053506000613626846002613ee8565b6136319060016138f1565b90505b60018111156136a9576f181899199a1a9b1b9c1cb0b131b232b360811b85600f1660108110613665576136656140c5565b1a60f81b82828151811061367b5761367b6140c5565b60200101906001600160f81b031916908160001a90535060049490941c936136a281614364565b9050613634565b5083156136f85760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401611030565b9392505050565b600081831061371b5760008281526020849052604090206136f8565b60008381526020839052604090206136f8565b600080833a434244613741600184613ed5565b604080516001600160a01b0390971660208801528601949094526060850192909252608084015260a08301524060c08201523060e082015261010081018490526101200160408051601f198184030181529190528051602090910120905060006137ab8483614098565b905061124c8185613853565b600081815260086020908152604080832080546001600160a01b0319166001600160a01b038716908117909155600790925290912080546001600160e01b031916909117600160a01b426001600160401b0316021790556138198160016138f1565b6040516001600160a01b038416906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b60008281526005602052604081205481818103613871575083613874565b50805b6000613881600186613ed5565b90508086146138d257600081815260056020526040812054908190036138b75760008781526005602052604090208290556138d0565b6000878152600560205260408082208390558382528120555b505b50949350505050565b634e487b7160e01b600052601160045260246000fd5b80820180821115610f3957610f396138db565b6001600160e01b0319811681146112b557600080fd5b60006020828403121561392c57600080fd5b81356136f881613904565b80356001600160a01b03811681146121fb57600080fd5b60008083601f84011261396057600080fd5b5081356001600160401b0381111561397757600080fd5b6020830191508360208260051b850101111561399257600080fd5b9250929050565b600080600080600080608087890312156139b257600080fd5b6139bb87613937565b95506020870135945060408701356001600160401b03808211156139de57600080fd5b6139ea8a838b0161394e565b90965094506060890135915080821115613a0357600080fd5b50613a1089828a0161394e565b979a9699509497509295939492505050565b60005b83811015613a3d578181015183820152602001613a25565b50506000910152565b60008151808452613a5e816020860160208601613a22565b601f01601f19169290920160200192915050565b6020815260006136f86020830184613a46565b600060208284031215613a9757600080fd5b5035919050565b60008060408385031215613ab157600080fd5b613aba83613937565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b60006001600160401b0380841115613af857613af8613ac8565b604051601f8501601f19908116603f01168101908282118183101715613b2057613b20613ac8565b81604052809350858152868686011115613b3957600080fd5b858560208301376000602087830101525050509392505050565b600060208284031215613b6557600080fd5b81356001600160401b03811115613b7b57600080fd5b8201601f81018413613b8c57600080fd5b61157f84823560208401613ade565b600080600060608486031215613bb057600080fd5b505081359360208301359350604090920135919050565b600080600080600060608688031215613bdf57600080fd5b613be886613937565b945060208601356001600160401b0380821115613c0457600080fd5b613c1089838a0161394e565b90965094506040880135915080821115613c2957600080fd5b50613c368882890161394e565b969995985093965092949392505050565b600060208284031215613c5957600080fd5b6136f882613937565b600080600060608486031215613c7757600080fd5b613c8084613937565b9250613c8e60208501613937565b9150604084013590509250925092565b600080600060608486031215613cb357600080fd5b613cbc84613937565b95602085013595506040909401359392505050565b60008060408385031215613ce457600080fd5b50508035926020909101359150565b600080600060408486031215613d0857600080fd5b613d1184613937565b925060208401356001600160401b03811115613d2c57600080fd5b613d388682870161394e565b9497909650939450505050565b600060208284031215613d5757600080fd5b8135600781106136f857600080fd5b634e487b7160e01b600052602160045260246000fd5b6020810160078310613d9e57634e487b7160e01b600052602160045260246000fd5b91905290565b80151581146112b557600080fd5b60008060408385031215613dc557600080fd5b613dce83613937565b91506020830135613dde81613da4565b809150509250929050565b60008060008060808587031215613dff57600080fd5b613e0885613937565b9350613e1660208601613937565b92506040850135915060608501356001600160401b03811115613e3857600080fd5b8501601f81018713613e4957600080fd5b613e5887823560208401613ade565b91505092959194509250565b60008060008060008060808789031215613e7d57600080fd5b863595506020870135945060408701356001600160401b03808211156139de57600080fd5b60008060408385031215613eb557600080fd5b613ebe83613937565b9150613ecc60208401613937565b90509250929050565b81810381811115610f3957610f396138db565b8082028115828204841417610f3957610f396138db565b600181811c90821680613f1357607f821691505b602082108103612f8257634e487b7160e01b600052602260045260246000fd5b6020808252600190820152606160f81b604082015260600190565b601f82111561108857600081815260208120601f850160051c81016020861015613f755750805b601f850160051c820191505b818110156118c157828155600101613f81565b81516001600160401b03811115613fad57613fad613ac8565b613fc181613fbb8454613eff565b84613f4e565b602080601f831160018114613ff65760008415613fde5750858301515b600019600386901b1c1916600185901b1785556118c1565b600085815260208120601f198616915b8281101561402557888601518255948401946001909101908401614006565b50858210156140435787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6020808252600190820152606f60f81b604082015260600190565b634e487b7160e01b600052601260045260246000fd5b6000826140935761409361406e565b500490565b6000826140a7576140a761406e565b500690565b6000600182016140be576140be6138db565b5060010190565b634e487b7160e01b600052603260045260246000fd5b6000602082840312156140ed57600080fd5b5051919050565b60006020828403121561410657600080fd5b81516136f881613da4565b6020808252600190820152606560f81b604082015260600190565b6020808252600190820152600360fc1b604082015260600190565b6020808252600190820152603d60f91b604082015260600190565b6000815461416f81613eff565b60018281168015614187576001811461419c576141cb565b60ff19841687528215158302870194506141cb565b8560005260208060002060005b858110156141c25781548a8201529084019082016141a9565b50505082870194505b5050505092915050565b600081516141e7818560208601613a22565b9290920192915050565b60006141fd8286614162565b602f60f81b8082526142126001830187614162565b915080825250835161422b816001840160208801613a22565b0160010195945050505050565b7f646174613a6170706c69636174696f6e2f6a736f6e3b757466382c7b226e616d81526332911d1160e11b60208201526000865161427d816024850160208b01613a22565b61088b60f21b60249184019182018190526e113232b9b1b934b83a34b7b7111d1160891b60268301526142b36035830189614162565b818152681134b6b0b3b2911d1160b91b600282015291506142d7600b830188614162565b818152701132bc3a32b93730b62fb634b735911d1160791b600282015291506143036013830187614162565b9081527f2273656c6c65725f6665655f62617369735f706f696e7473223a3636362c226660028201526e32b2afb932b1b4b834b2b73a111d1160891b60228201529050610f6961435660318301866141d5565b61227d60f01b815260020190565b600081614373576143736138db565b506000190190565b60ff8181168382160190811115610f3957610f396138db565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090610f6d90830184613a46565b6000602082840312156143d957600080fd5b81516136f88161390456fea2646970667358221220c9719f35d2d0b7c45d5834f39e0244387b9e9c236273d7b64a3c354665ad161064736f6c63430008110033536b656c657068756e6b73206973206120756e6976657273616c2c2061646170746976652050465020666f722074686520457468657265756d20636f6d6d756e6974792e00000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000000000000000000000000000000000000000000d00000000000000000000000000000000000000000000000000000000000001200000000000000000000000000000000000000000000000000000000000000180000000000000000000000000000000000000000000000000000000000000000b536b656c657068756e6b730000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000005534b454c45000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000066f3794178997a12779527b36a2f042e001625af0000000000000000000000001088a6585f9a1e2a47933c53c96a1832f25536c9000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000005dc0000000000000000000000000000000000000000000000000000000000002134

Deployed Bytecode

0x6080604052600436106104985760003560e01c8063715018a611610260578063b81440bb11610144578063db2e21bc116100c1578063f1b0aa1511610085578063f1b0aa1514610df9578063f2eb817214610e19578063f2fde38b14610e39578063f4a0a52814610e59578063f8cf016314610e79578063f95df41414610eb257600080fd5b8063db2e21bc14610d4d578063df87694914610d62578063e8a3d48514610d7b578063e985e9c514610d90578063ede029fc14610dd957600080fd5b8063c87b56dd11610108578063c87b56dd14610cc9578063ce8539b114610ce9578063cffb47cf14610cfe578063d831f62314610d14578063daf5085914610d2d57600080fd5b8063b81440bb14610c28578063b88d4fde14610c3e578063bb42436914610c5e578063c1d5f48c14610c71578063c48f653114610c9157600080fd5b80638ca1f0cf116101dd5780639da3f8fd116101a15780639da3f8fd14610b615780639e942ace14610b88578063a22cb46514610ba8578063aff8cfa114610bc8578063b2af127c14610be8578063b6d04a0b14610c0857600080fd5b80638ca1f0cf14610ace5780638da5cb5b14610aee5780639471302e14610b0c57806395d89b4114610b2c578063963c354614610b4157600080fd5b80637e12dc11116102245780637e12dc1114610a1e578063814c8c5514610a3e5780638305778a14610a5e578063881e68c614610a8e5780638ac06d3914610aae57600080fd5b8063715018a614610994578063740ac6f6146109a9578063741fd872146109c957806379b6ed36146109e95780637ccd7887146109fe57600080fd5b8063333171bb1161038757806349ee537d1161030457806363037b0c116102c857806363037b0c146108f35780636352211e146109135780636373a6b1146109335780636817c76c146109485780636b90fa851461095e57806370a082311461097457600080fd5b806349ee537d146108685780634f6ccce71461087e5780635b2ca0841461089e5780635c975abb146108be5780636095049a146108dd57600080fd5b806341f434341161034b57806341f43434146107d057806342842e0e146107f257806344dd599b146108125780634811ea441461083257806349df728c1461084857600080fd5b8063333171bb14610764578063386b7691146107795780633ccfd60b1461078f5780633cf01344146107a457806341422eed146107ba57600080fd5b80631a05dc87116104155780632eb4a7ab116103d95780632eb4a7ab146106c85780632f745c59146106de57806330359e5f146106fe578063303a67d01461071e57806330b42ec21461073457600080fd5b80631a05dc871461061b5780631f9179211461063b57806320fc7eb21461065b57806323b872dd146106885780632a85db55146106a857600080fd5b8063095ea7b31161045c578063095ea7b31461058f57806310969523146105b157806313ea7b04146105d157806318160ddd146105e65780631931225b146105fb57600080fd5b806301ffc9a7146104bc57806304a6c8c9146104f15780630519ef1f1461051557806306fdde0314610535578063081812fc1461055757600080fd5b366104b75734601460008282546104af91906138f1565b925050819055005b600080fd5b3480156104c857600080fd5b506104dc6104d736600461391a565b610ed2565b60405190151581526020015b60405180910390f35b3480156104fd57600080fd5b50610507601a5481565b6040519081526020016104e8565b34801561052157600080fd5b50610507610530366004613999565b610f3f565b34801561054157600080fd5b5061054a610f77565b6040516104e89190613a72565b34801561056357600080fd5b50610577610572366004613a85565b611009565b6040516001600160a01b0390911681526020016104e8565b34801561059b57600080fd5b506105af6105aa366004613a9e565b611068565b005b3480156105bd57600080fd5b506105af6105cc366004613b53565b61108d565b3480156105dd57600080fd5b5061054a6110c2565b3480156105f257600080fd5b506105076110d1565b34801561060757600080fd5b506105af610616366004613b9b565b611106565b34801561062757600080fd5b506104dc610636366004613bc7565b611238565b34801561064757600080fd5b506105af610656366004613b53565b611255565b34801561066757600080fd5b50610507610676366004613c47565b60106020526000908152604090205481565b34801561069457600080fd5b506105af6106a3366004613c62565b61126d565b3480156106b457600080fd5b506105af6106c3366004613b53565b6112a4565b3480156106d457600080fd5b5061050760275481565b3480156106ea57600080fd5b506105076106f9366004613a9e565b6112b8565b34801561070a57600080fd5b506105af610719366004613c9e565b6113aa565b34801561072a57600080fd5b50610507601b5481565b34801561074057600080fd5b506104dc61074f366004613c47565b602a6020526000908152604090205460ff1681565b34801561077057600080fd5b506105af6113f9565b34801561078557600080fd5b5061050760195481565b34801561079b57600080fd5b506105af61141e565b3480156107b057600080fd5b5061050760295481565b3480156107c657600080fd5b5061050760255481565b3480156107dc57600080fd5b506105776daaeb6d7670e522a718067333cd4e81565b3480156107fe57600080fd5b506105af61080d366004613c62565b611508565b34801561081e57600080fd5b5061050761082d366004613a85565b611539565b34801561083e57600080fd5b5061050760285481565b34801561085457600080fd5b506105af610863366004613c47565b611587565b34801561087457600080fd5b5061050760245481565b34801561088a57600080fd5b50610507610899366004613a85565b611719565b3480156108aa57600080fd5b506105af6108b9366004613cd1565b611818565b3480156108ca57600080fd5b506018546104dc90610100900460ff1681565b3480156108e957600080fd5b50610507601d5481565b3480156108ff57600080fd5b5061057761090e366004613a85565b6118c9565b34801561091f57600080fd5b5061057761092e366004613a85565b6118f3565b34801561093f57600080fd5b5061054a611929565b34801561095457600080fd5b5061050760165481565b34801561096a57600080fd5b5061050760235481565b34801561098057600080fd5b5061050761098f366004613c47565b6119b7565b3480156109a057600080fd5b506105af6119fb565b3480156109b557600080fd5b506104dc6109c4366004613cf3565b611a0f565b3480156109d557600080fd5b50602e54610577906001600160a01b031681565b3480156109f557600080fd5b5061054a611ac0565b348015610a0a57600080fd5b506105af610a19366004613a85565b611acf565b348015610a2a57600080fd5b506104dc610a39366004613cf3565b611adc565b348015610a4a57600080fd5b506105af610a59366004613d45565b611b51565b348015610a6a57600080fd5b506104dc610a79366004613c47565b60266020526000908152604090205460ff1681565b348015610a9a57600080fd5b50610577610aa9366004613a85565b611bea565b348015610aba57600080fd5b506105af610ac9366004613c47565b611bfe565b348015610ada57600080fd5b506105af610ae9366004613b53565b611c46565b348015610afa57600080fd5b50600d546001600160a01b0316610577565b348015610b1857600080fd5b506105af610b27366004613b53565b611c5a565b348015610b3857600080fd5b5061054a611c6e565b348015610b4d57600080fd5b506105af610b5c366004613a85565b611c7d565b348015610b6d57600080fd5b50601854610b7b9060ff1681565b6040516104e89190613d7c565b348015610b9457600080fd5b50610577610ba3366004613a85565b611c8a565b348015610bb457600080fd5b506105af610bc3366004613db2565b611cc0565b348015610bd457600080fd5b506105af610be3366004613db2565b611ce0565b348015610bf457600080fd5b506105af610c03366004613c47565b611d13565b348015610c1457600080fd5b50610507610c23366004613c47565b611dfc565b348015610c3457600080fd5b50610507602f5481565b348015610c4a57600080fd5b506105af610c59366004613de9565b611e2a565b6105af610c6c366004613e64565b611e63565b348015610c7d57600080fd5b506105af610c8c366004613a85565b6120b9565b348015610c9d57600080fd5b50610cb1610cac366004613a85565b6120c6565b6040516001600160401b0390911681526020016104e8565b348015610cd557600080fd5b5061054a610ce4366004613a85565b6120dd565b348015610cf557600080fd5b506105af612200565b348015610d0a57600080fd5b50610507601c5481565b348015610d2057600080fd5b50602954602854106104dc565b348015610d3957600080fd5b50610507610d48366004613999565b61221c565b348015610d5957600080fd5b506105af61234c565b348015610d6e57600080fd5b50602554602454106104dc565b348015610d8757600080fd5b5061054a6123e0565b348015610d9c57600080fd5b506104dc610dab366004613ea2565b6001600160a01b039182166000908152600c6020908152604080832093909416825291909152205460ff1690565b348015610de557600080fd5b506105af610df4366004613b53565b612421565b348015610e0557600080fd5b50610cb1610e14366004613a85565b612432565b348015610e2557600080fd5b50610507610e34366004613bc7565b61248f565b348015610e4557600080fd5b506105af610e54366004613c47565b6124a8565b348015610e6557600080fd5b506105af610e74366004613a85565b61251e565b348015610e8557600080fd5b506104dc610e94366004613c47565b6001600160a01b03166000908152602d602052604090205460ff1690565b348015610ebe57600080fd5b506105af610ecd366004613a85565b61252b565b60006001600160e01b031982166380ac58cd60e01b1480610f0357506001600160e01b03198216635b5e139f60e01b145b80610f1e57506001600160e01b0319821663780e9d6360e01b145b80610f3957506301ffc9a760e01b6001600160e01b03198316145b92915050565b600080610f5088888888888861221c565b9050610f5c8188613ed5565b601654610f699190613ee8565b9150505b9695505050505050565b606060018054610f8690613eff565b80601f0160208091040260200160405190810160405280929190818152602001828054610fb290613eff565b8015610fff5780601f10610fd457610100808354040283529160200191610fff565b820191906000526020600020905b815481529060010190602001808311610fe257829003601f168201915b5050505050905090565b600061101482612538565b6110395760405162461bcd60e51b815260040161103090613f33565b60405180910390fd5b600b6000611048600185613ed5565b81526020810191909152604001600020546001600160a01b031692915050565b603054829060ff161561107e5761107e8161257c565b6110888383612635565b505050565b6110956126b6565b600f5460ff16156110a557600080fd5b600e6110b18282613f94565b5050600f805460ff19166001179055565b606060038054610f8690613eff565b60006006547f000000000000000000000000000000000000000000000000000000000000270f6111019190613ed5565b905090565b61110f836118f3565b6001600160a01b0316336001600160a01b03161461113f5760405162461bcd60e51b815260040161103090614053565b60028210801561114f5750600281105b61117f5760405162461bcd60e51b81526020600482015260016024820152603b60f91b6044820152606401611030565b60008261118d836002613ee8565b61119791906138f1565b905060006111a485611539565b905060006111b3608087614084565b905060006111c2608088614098565b90506111cf816002613ee8565b83901b6022600084815260200190815260200160002060008282546111f49190613ed5565b909155506112059050816002613ee8565b84901b60226000848152602001908152602001600020600082825461122a91906138f1565b909155505050505050505050565b600080611248878787878761248f565b1190505b95945050505050565b61125d6126b6565b60216112698282613f94565b5050565b603054839060ff1615611293576001600160a01b0381163314611293576112933361257c565b61129e848484612710565b50505050565b6112ac6126b6565b6112b58161271b565b50565b60006112c3836119b7565b82106112f55760405162461bcd60e51b81526020600482015260016024820152603160f91b6044820152606401611030565b6000805b7f000000000000000000000000000000000000000000000000000000000000270f81101561137d576000818152600860205260409020546001600160a01b0380871691160361136b5783820361135d576113548160016138f1565b92505050610f39565b81611367816140ac565b9250505b80611375816140ac565b9150506112f9565b5060405162461bcd60e51b81526020600482015260016024820152607560f81b6044820152606401611030565b336000908152602d602052604090205460ff166113ee5760405162461bcd60e51b8152602060048201526002602482015261726160f01b6044820152606401611030565b611088838383612727565b6114016126b6565b6018805461ff001981166101009182900460ff1615909102179055565b611426612768565b336000908152601360205260408120546014546114469061271090614084565b6114509190613ee8565b336000908152601560205260408120549192509061146e9083613ed5565b33600081815260156020526040808220869055519293509183908381818185875af1925050503d80600081146114c0576040519150601f19603f3d011682016040523d82523d6000602084013e6114c5565b606091505b50509050806110885760405162461bcd60e51b815260206004820152600f60248201526e5061796d656e74206661696c65642160881b6044820152606401611030565b603054839060ff161561152e576001600160a01b038116331461152e5761152e3361257c565b61129e8484846127b2565b600080611547608084614084565b90506000611556608085614098565b90506004611565826002613ee8565b60008481526022602052604090205461157f92911c614098565b949350505050565b61158f612768565b60005b60125481101561126957816001600160a01b031663a9059cbb601283815481106115be576115be6140c5565b9060005260206000200160009054906101000a90046001600160a01b031660136000601286815481106115f3576115f36140c5565b60009182526020808320909101546001600160a01b03908116845290830193909352604091820190205490516370a0823160e01b8152306004820152909161271091908816906370a0823190602401602060405180830381865afa15801561165f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061168391906140db565b61168d9190614084565b6116979190613ee8565b6040516001600160e01b031960e085901b1681526001600160a01b03909216600483015260248201526044016020604051808303816000875af11580156116e2573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061170691906140f4565b5080611711816140ac565b915050611592565b600080821161174f5760405162461bcd60e51b8152602060048201526002602482015261069360f41b6044820152606401611030565b600061175c600184613ed5565b905060006117686110d1565b905080821061179d5760405162461bcd60e51b81526020600482015260016024820152606760f81b6044820152606401611030565b6000805b7f000000000000000000000000000000000000000000000000000000000000270f81101561137d576000818152600860205260409020546001600160a01b031615611806578382036117f857610f6d8160016138f1565b81611802816140ac565b9250505b80611810816140ac565b9150506117a1565b33321461185a5760405162461bcd60e51b815260206004820152601060248201526f6e6f20636f6e7472616374732066616d60801b6044820152606401611030565b61186733602f5483612727565b602e546040516363aac3a360e01b8152600481018490526001600160a01b03909116906363aac3a390602401600060405180830381600087803b1580156118ad57600080fd5b505af11580156118c1573d6000803e3d6000fd5b505050505050565b601281815481106118d957600080fd5b6000918252602090912001546001600160a01b0316905081565b60006118fe82612538565b61191a5760405162461bcd60e51b815260040161103090614111565b60086000611048600185613ed5565b600e805461193690613eff565b80601f016020809104026020016040519081016040528092919081815260200182805461196290613eff565b80156119af5780601f10611984576101008083540402835291602001916119af565b820191906000526020600020905b81548152906001019060200180831161199257829003601f168201915b505050505081565b60006001600160a01b0382166119df5760405162461bcd60e51b81526004016110309061412c565b506001600160a01b031660009081526009602052604090205490565b611a036126b6565b611a0d60006127cd565b565b6001600160a01b03831660009081526026602052604081205460ff16158015611aaa5750611aaa838380806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506023546040516bffffffffffffffffffffffff1960608b901b16602082015290925060340190505b6040516020818303038152906040528051906020012061281f565b801561157f575060255460245410949350505050565b606060048054610f8690613eff565b611ad76126b6565b602f55565b6000611b3e838380806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506027546040516bffffffffffffffffffffffff1960608b901b1660208201529092506034019050611a8f565b801561157f57506029546028541061157f565b611b596126b6565b6000816006811115611b6d57611b6d613d66565b14158015611b925750600660185460ff166006811115611b8f57611b8f613d66565b14155b611bc35760405162461bcd60e51b81526020600482015260026024820152616d7360f01b6044820152606401611030565b6018805482919060ff19166001836006811115611be257611be2613d66565b021790555050565b600080611bf683612835565b519392505050565b611c066126b6565b602e54611c1d906001600160a01b03166000611ce0565b602e80546001600160a01b0319166001600160a01b0383169081179091556112b5906001611ce0565b611c4e6126b6565b60206112698282613f94565b611c626126b6565b601f6112698282613f94565b606060028054610f8690613eff565b611c856126b6565b601e55565b6000611c9582612538565b611cb15760405162461bcd60e51b815260040161103090614111565b60076000611048600185613ed5565b603054829060ff1615611cd657611cd68161257c565b611088838361298f565b611ce86126b6565b6001600160a01b03919091166000908152602d60205260409020805460ff1916911515919091179055565b611d1b6126b6565b6040516370a0823160e01b81523060048201526001600160a01b0382169063a9059cbb90339083906370a0823190602401602060405180830381865afa158015611d69573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d8d91906140db565b6040516001600160e01b031960e085901b1681526001600160a01b03909216600483015260248201526044016020604051808303816000875af1158015611dd8573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061126991906140f4565b6001600160a01b0381166000908152602c6020908152604080832054602b909252822054610f3991906138f1565b603054849060ff1615611e50576001600160a01b0381163314611e5057611e503361257c565b611e5c85858585612a23565b5050505050565b333214611e6f57600080fd5b6000611e7f33888787878761221c565b9050611e8f338887878787610f3f565b3414611ec65760405162461bcd60e51b8152600401611030906020808252600490820152633837b7b960e11b604082015260600190565b611ed3338686868661248f565b871115611f0b5760405162461bcd60e51b8152600401611030906020808252600490820152636d6d707760e01b604082015260600190565b601a54611f188289613ed5565b601b54611f2591906138f1565b1115611f595760405162461bcd60e51b81526020600482015260036024820152626d6d7360e81b6044820152606401611030565b601c5481601d54611f6a91906138f1565b1115611f9e5760405162461bcd60e51b81526020600482015260036024820152626d727360e81b6044820152606401611030565b80801561200157611fb0338787611a0f565b1561200157336000908152602660209081526040808320805460ff19166001908117909155602b9092528220805491929091611fed9084906138f1565b90915550611ffe9050600182613ed5565b90505b801561206357612012338585611adc565b1561206357336000908152602a60209081526040808320805460ff19166001908117909155602b909252822080549192909161204f9084906138f1565b909155506120609050600182613ed5565b90505b336000908152602b6020526040812080548392906120829084906138f1565b92505081905550346014600082825461209b91906138f1565b909155506120af90503389848a6000612a56565b5050505050505050565b6120c16126b6565b602355565b6000806120d283612835565b602001519392505050565b60606120e882612538565b6121045760405162461bcd60e51b815260040161103090614147565b60006003805461211390613eff565b905011156121695760036011600061212a85611539565b815260200190815260200160002061214184612c7a565b604051602001612153939291906141f1565b6040516020818303038152906040529050919050565b6004805461217690613eff565b80601f01602080910402602001604051908101604052809291908181526020018280546121a290613eff565b80156121ef5780601f106121c4576101008083540402835291602001916121ef565b820191906000526020600020905b8154815290600101906020018083116121d257829003601f168201915b50505050509050919050565b919050565b6122086126b6565b6030805460ff19811660ff90911615179055565b60008060185460ff16600681111561223657612236613d66565b0361224357506000610f6d565b600160185460ff16600681111561225c5761225c613d66565b036122845761226c878686611a0f565b61227757600061227a565b60015b60ff169050610f6d565b600260185460ff16600681111561229d5761229d613d66565b036122e7576122ad878484611adc565b156122c7576122c0878787878787612d0c565b9050610f6d565b6122d2878686611a0f565b156122df57506001610f6d565b506000610f6d565b600360185460ff16600681111561230057612300613d66565b03612313576122c0878787878787612d0c565b600460185460ff16600681111561232c5761232c613d66565b0361233f576122c0878787878787612d0c565b5060009695505050505050565b6123546126b6565b6040514790600090339083908381818185875af1925050503d8060008114612398576040519150601f19603f3d011682016040523d82523d6000602084013e61239d565b606091505b50509050806112695760405162461bcd60e51b815260206004820152600f60248201526e5061796d656e74206661696c65642160881b6044820152606401611030565b60606123ea610f77565b601f602060216123f930612dd7565b60405160200161240d959493929190614238565b604051602081830303815290604052905090565b6124296126b6565b6112b581612dee565b600061243d82612538565b6124595760405162461bcd60e51b815260040161103090614111565b60076000612468600185613ed5565b8152602081019190915260400160002054600160a01b90046001600160401b031692915050565b6000610f6d60646124a38888888888612dfa565b612f71565b6124b06126b6565b6001600160a01b0381166125155760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401611030565b6112b5816127cd565b6125266126b6565b601655565b6125336126b6565b602755565b60008160000361254a57506000919050565b600060088161255a600186613ed5565b81526020810191909152604001600020546001600160a01b0316141592915050565b6daaeb6d7670e522a718067333cd4e3b156112b557604051633185c44d60e21b81523060048201526001600160a01b03821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa1580156125e9573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061260d91906140f4565b6112b557604051633b79c77360e21b81526001600160a01b0382166004820152602401611030565b6000612640826118f3565b9050806001600160a01b0316836001600160a01b0316036126735760405162461bcd60e51b815260040161103090614053565b336001600160a01b038216148061268f575061268f8133610dab565b6126ab5760405162461bcd60e51b815260040161103090613f33565b611088838383612f88565b600d546001600160a01b03163314611a0d5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401611030565b611088838383612ffb565b60046112698282613f94565b61273683836000846001612a56565b6001600160a01b0383166000908152602c60205260408120805484929061275e9084906138f1565b9091555050505050565b33600090815260136020526040902054611a0d5760405162461bcd60e51b815260206004820152600b60248201526a6e6f74206120706179656560a81b6044820152606401611030565b61108883838360405180602001604052806000815250611e2a565b600d80546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60008261282c8584613195565b14949350505050565b60408051808201909152600080825260208201526128516110d1565b8211156128b757505060008052600a6020908152604080518082019091527f13da86008ba1c6922daee3e07db95305ef49ebced9f5467a0b8613fcc6b343e3546001600160a01b0381168252600160a01b90046001600160401b03169181019190915290565b815b801561292f576000818152600a60205260409020546001600160a01b03161561291d576000908152600a60209081526040918290208251808401909352546001600160a01b0381168352600160a01b90046001600160401b03169082015292915050565b8061292781614364565b9150506128b9565b50506000805250600a6020908152604080518082019091527f13da86008ba1c6922daee3e07db95305ef49ebced9f5467a0b8613fcc6b343e3546001600160a01b0381168252600160a01b90046001600160401b03169181019190915290565b336001600160a01b038316036129b75760405162461bcd60e51b815260040161103090613f33565b336000818152600c602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b612a2e848484612ffb565b612a3a848484846131e2565b61129e5760405162461bcd60e51b815260040161103090614147565b601854610100900460ff1615612a925760405162461bcd60e51b81526020600482015260016024820152600760fc1b6044820152606401611030565b60048210612ac65760405162461bcd60e51b81526020600482015260016024820152603b60f91b6044820152606401611030565b601b54612ad386866132e3565b6001600160a01b03861660009081526010602052604081208054879290612afb9084906138f1565b909155506000905080612b0f608084614084565b9050825b612b1d88856138f1565b811015612ba0576000612b31608083614084565b9050828114612b675760008381526022602052604081208054869290612b589084906138f1565b92505081905550600093508092505b612b72608083614098565b612b7d906002613ee8565b612b8a9088901b856138f1565b9350508080612b98906140ac565b915050612b13565b5060008181526022602052604081208054849290612bbf9084906138f1565b90915550508315612be75786601d6000828254612bdc91906138f1565b90915550612c219050565b612bf18688613ed5565b601b6000828254612c0291906138f1565b9250508190555085601d6000828254612c1b91906138f1565b90915550505b601a54601b5403612c3a576018805460ff191660051790555b600560185460ff166006811115612c5357612c53613d66565b036120af57601c54601d54036120af5750506018805460ff19166006179055505050505050565b60606000612c878361341b565b60010190506000816001600160401b03811115612ca657612ca6613ac8565b6040519080825280601f01601f191660200182016040528015612cd0576020820181803683370190505b5090508181016020015b600019016f181899199a1a9b1b9c1cb0b131b232b360811b600a86061a8153600a8504945084612cda57509392505050565b600080612d1c888787878761248f565b8703612d59576001600160a01b0388166000908152602b6020526040902054612d46906003613ed5565b9050612d528188612f71565b9050612dcc565b612d64888585611adc565b8015612d8957506001600160a01b0388166000908152602a602052604090205460ff16155b612d94576000612d97565b60015b612da2898888611a0f565b612dad576000612db0565b60015b612dba919061437b565b60ff169050612dc98188612f71565b90505b979650505050505050565b6060610f3982612de6846134f3565b60010161355d565b60036112698282613f94565b60008060185460ff166006811115612e1457612e14613d66565b03612e215750600061124c565b600160185460ff166006811115612e3a57612e3a613d66565b03612e6257612e4a868686611a0f565b612e55576000612e58565b60015b60ff16905061124c565b600260185460ff166006811115612e7b57612e7b613d66565b03612ef057612e8b868484611adc565b15612ed0576001600160a01b038616600090815260106020526040902054601e54612ec991612eb991613ed5565b601b54601a546124a39190613ed5565b905061124c565b612edb868686611a0f565b15612ee85750600161124c565b50600061124c565b600360185460ff166006811115612f0957612f09613d66565b03612f37576001600160a01b038616600090815260106020526040902054601e54612ec991612eb991613ed5565b600460185460ff166006811115612f5057612f50613d66565b03612f6557601b54601a54612ec99190613ed5565b50600095945050505050565b600081831015612f82575081610f39565b50919050565b82600b6000612f98600186613ed5565b815260208101919091526040908101600090812080546001600160a01b0319166001600160a01b039485161790559051849286811692908516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259190a4505050565b6000613006826118f3565b90506000336001600160a01b038316148061303157503361302684611009565b6001600160a01b0316145b8061304157506130418233610dab565b9050806130605760405162461bcd60e51b815260040161103090613f33565b846001600160a01b0316826001600160a01b0316146130915760405162461bcd60e51b815260040161103090614053565b6001600160a01b0384166130b75760405162461bcd60e51b81526004016110309061412c565b6130c360008484612f88565b6001600160a01b03851660009081526009602052604081208054600192906130ec908490613ed5565b90915550506001600160a01b038416600090815260096020526040812080546001929061311a9084906138f1565b9091555084905060086000613130600187613ed5565b815260208101919091526040908101600090812080546001600160a01b0319166001600160a01b039485161790559051859287811692908916917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9190a45050505050565b600081815b84518110156131da576131c6828683815181106131b9576131b96140c5565b60200260200101516136ff565b9150806131d2816140ac565b91505061319a565b509392505050565b60006001600160a01b0384163b156132d857604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290613226903390899088908890600401614394565b6020604051808303816000875af1925050508015613261575060408051601f3d908101601f1916820190925261325e918101906143c7565b60015b6132be573d80801561328f576040519150601f19603f3d011682016040523d82523d6000602084013e613294565b606091505b5080516000036132b65760405162461bcd60e51b815260040161103090614147565b805181602001fd5b6001600160e01b031916630a85bd0160e11b14905061157f565b506001949350505050565b6001600160a01b0382166133095760405162461bcd60e51b81526004016110309061412c565b6000811161333d5760405162461bcd60e51b81526020600482015260016024820152603160f81b6044820152606401611030565b60065460005b82811015613384576000613357858461372e565b905061336385826137b7565b8261336d81614364565b93505050808061337c906140ac565b915050613343565b5060068190556001600160a01b038316600090815260096020526040812080548492906133b29084906138f1565b9091555050600080548152600a602052604080822080546001600160a01b0319166001600160a01b038716179055815482528120805467ffffffffffffffff60a01b1916600160a01b426001600160401b0316021790558054839190819061275e9084906138f1565b60008072184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b831061345a5772184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b830492506040015b6d04ee2d6d415b85acef81000000008310613486576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc1000083106134a457662386f26fc10000830492506010015b6305f5e10083106134bc576305f5e100830492506008015b61271083106134d057612710830492506004015b606483106134e2576064830492506002015b600a8310610f395760010192915050565b600080608083901c1561350b5760809290921c916010015b604083901c156135205760409290921c916008015b602083901c156135355760209290921c916004015b601083901c1561354a5760109290921c916002015b600883901c15610f395760010192915050565b6060600061356c836002613ee8565b6135779060026138f1565b6001600160401b0381111561358e5761358e613ac8565b6040519080825280601f01601f1916602001820160405280156135b8576020820181803683370190505b509050600360fc1b816000815181106135d3576135d36140c5565b60200101906001600160f81b031916908160001a905350600f60fb1b81600181518110613602576136026140c5565b60200101906001600160f81b031916908160001a9053506000613626846002613ee8565b6136319060016138f1565b90505b60018111156136a9576f181899199a1a9b1b9c1cb0b131b232b360811b85600f1660108110613665576136656140c5565b1a60f81b82828151811061367b5761367b6140c5565b60200101906001600160f81b031916908160001a90535060049490941c936136a281614364565b9050613634565b5083156136f85760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401611030565b9392505050565b600081831061371b5760008281526020849052604090206136f8565b60008381526020839052604090206136f8565b600080833a434244613741600184613ed5565b604080516001600160a01b0390971660208801528601949094526060850192909252608084015260a08301524060c08201523060e082015261010081018490526101200160408051601f198184030181529190528051602090910120905060006137ab8483614098565b905061124c8185613853565b600081815260086020908152604080832080546001600160a01b0319166001600160a01b038716908117909155600790925290912080546001600160e01b031916909117600160a01b426001600160401b0316021790556138198160016138f1565b6040516001600160a01b038416906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b60008281526005602052604081205481818103613871575083613874565b50805b6000613881600186613ed5565b90508086146138d257600081815260056020526040812054908190036138b75760008781526005602052604090208290556138d0565b6000878152600560205260408082208390558382528120555b505b50949350505050565b634e487b7160e01b600052601160045260246000fd5b80820180821115610f3957610f396138db565b6001600160e01b0319811681146112b557600080fd5b60006020828403121561392c57600080fd5b81356136f881613904565b80356001600160a01b03811681146121fb57600080fd5b60008083601f84011261396057600080fd5b5081356001600160401b0381111561397757600080fd5b6020830191508360208260051b850101111561399257600080fd5b9250929050565b600080600080600080608087890312156139b257600080fd5b6139bb87613937565b95506020870135945060408701356001600160401b03808211156139de57600080fd5b6139ea8a838b0161394e565b90965094506060890135915080821115613a0357600080fd5b50613a1089828a0161394e565b979a9699509497509295939492505050565b60005b83811015613a3d578181015183820152602001613a25565b50506000910152565b60008151808452613a5e816020860160208601613a22565b601f01601f19169290920160200192915050565b6020815260006136f86020830184613a46565b600060208284031215613a9757600080fd5b5035919050565b60008060408385031215613ab157600080fd5b613aba83613937565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b60006001600160401b0380841115613af857613af8613ac8565b604051601f8501601f19908116603f01168101908282118183101715613b2057613b20613ac8565b81604052809350858152868686011115613b3957600080fd5b858560208301376000602087830101525050509392505050565b600060208284031215613b6557600080fd5b81356001600160401b03811115613b7b57600080fd5b8201601f81018413613b8c57600080fd5b61157f84823560208401613ade565b600080600060608486031215613bb057600080fd5b505081359360208301359350604090920135919050565b600080600080600060608688031215613bdf57600080fd5b613be886613937565b945060208601356001600160401b0380821115613c0457600080fd5b613c1089838a0161394e565b90965094506040880135915080821115613c2957600080fd5b50613c368882890161394e565b969995985093965092949392505050565b600060208284031215613c5957600080fd5b6136f882613937565b600080600060608486031215613c7757600080fd5b613c8084613937565b9250613c8e60208501613937565b9150604084013590509250925092565b600080600060608486031215613cb357600080fd5b613cbc84613937565b95602085013595506040909401359392505050565b60008060408385031215613ce457600080fd5b50508035926020909101359150565b600080600060408486031215613d0857600080fd5b613d1184613937565b925060208401356001600160401b03811115613d2c57600080fd5b613d388682870161394e565b9497909650939450505050565b600060208284031215613d5757600080fd5b8135600781106136f857600080fd5b634e487b7160e01b600052602160045260246000fd5b6020810160078310613d9e57634e487b7160e01b600052602160045260246000fd5b91905290565b80151581146112b557600080fd5b60008060408385031215613dc557600080fd5b613dce83613937565b91506020830135613dde81613da4565b809150509250929050565b60008060008060808587031215613dff57600080fd5b613e0885613937565b9350613e1660208601613937565b92506040850135915060608501356001600160401b03811115613e3857600080fd5b8501601f81018713613e4957600080fd5b613e5887823560208401613ade565b91505092959194509250565b60008060008060008060808789031215613e7d57600080fd5b863595506020870135945060408701356001600160401b03808211156139de57600080fd5b60008060408385031215613eb557600080fd5b613ebe83613937565b9150613ecc60208401613937565b90509250929050565b81810381811115610f3957610f396138db565b8082028115828204841417610f3957610f396138db565b600181811c90821680613f1357607f821691505b602082108103612f8257634e487b7160e01b600052602260045260246000fd5b6020808252600190820152606160f81b604082015260600190565b601f82111561108857600081815260208120601f850160051c81016020861015613f755750805b601f850160051c820191505b818110156118c157828155600101613f81565b81516001600160401b03811115613fad57613fad613ac8565b613fc181613fbb8454613eff565b84613f4e565b602080601f831160018114613ff65760008415613fde5750858301515b600019600386901b1c1916600185901b1785556118c1565b600085815260208120601f198616915b8281101561402557888601518255948401946001909101908401614006565b50858210156140435787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6020808252600190820152606f60f81b604082015260600190565b634e487b7160e01b600052601260045260246000fd5b6000826140935761409361406e565b500490565b6000826140a7576140a761406e565b500690565b6000600182016140be576140be6138db565b5060010190565b634e487b7160e01b600052603260045260246000fd5b6000602082840312156140ed57600080fd5b5051919050565b60006020828403121561410657600080fd5b81516136f881613da4565b6020808252600190820152606560f81b604082015260600190565b6020808252600190820152600360fc1b604082015260600190565b6020808252600190820152603d60f91b604082015260600190565b6000815461416f81613eff565b60018281168015614187576001811461419c576141cb565b60ff19841687528215158302870194506141cb565b8560005260208060002060005b858110156141c25781548a8201529084019082016141a9565b50505082870194505b5050505092915050565b600081516141e7818560208601613a22565b9290920192915050565b60006141fd8286614162565b602f60f81b8082526142126001830187614162565b915080825250835161422b816001840160208801613a22565b0160010195945050505050565b7f646174613a6170706c69636174696f6e2f6a736f6e3b757466382c7b226e616d81526332911d1160e11b60208201526000865161427d816024850160208b01613a22565b61088b60f21b60249184019182018190526e113232b9b1b934b83a34b7b7111d1160891b60268301526142b36035830189614162565b818152681134b6b0b3b2911d1160b91b600282015291506142d7600b830188614162565b818152701132bc3a32b93730b62fb634b735911d1160791b600282015291506143036013830187614162565b9081527f2273656c6c65725f6665655f62617369735f706f696e7473223a3636362c226660028201526e32b2afb932b1b4b834b2b73a111d1160891b60228201529050610f6961435660318301866141d5565b61227d60f01b815260020190565b600081614373576143736138db565b506000190190565b60ff8181168382160190811115610f3957610f396138db565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090610f6d90830184613a46565b6000602082840312156143d957600080fd5b81516136f88161390456fea2646970667358221220c9719f35d2d0b7c45d5834f39e0244387b9e9c236273d7b64a3c354665ad161064736f6c63430008110033

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

00000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000000000000000000000000000000000000000000d00000000000000000000000000000000000000000000000000000000000001200000000000000000000000000000000000000000000000000000000000000180000000000000000000000000000000000000000000000000000000000000000b536b656c657068756e6b730000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000005534b454c45000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000066f3794178997a12779527b36a2f042e001625af0000000000000000000000001088a6585f9a1e2a47933c53c96a1832f25536c9000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000005dc0000000000000000000000000000000000000000000000000000000000002134

-----Decoded View---------------
Arg [0] : name_ (string): Skelephunks
Arg [1] : symbol_ (string): SKELE
Arg [2] : maxMintsPerWallet_ (uint256): 13
Arg [3] : payees_ (address[]): 0x66F3794178997a12779527B36a2F042e001625aF,0x1088a6585F9a1E2a47933c53C96A1832f25536c9
Arg [4] : basisPoints_ (uint256[]): 1500,8500

-----Encoded View---------------
15 Constructor Arguments found :
Arg [0] : 00000000000000000000000000000000000000000000000000000000000000a0
Arg [1] : 00000000000000000000000000000000000000000000000000000000000000e0
Arg [2] : 000000000000000000000000000000000000000000000000000000000000000d
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000120
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000180
Arg [5] : 000000000000000000000000000000000000000000000000000000000000000b
Arg [6] : 536b656c657068756e6b73000000000000000000000000000000000000000000
Arg [7] : 0000000000000000000000000000000000000000000000000000000000000005
Arg [8] : 534b454c45000000000000000000000000000000000000000000000000000000
Arg [9] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [10] : 00000000000000000000000066f3794178997a12779527b36a2f042e001625af
Arg [11] : 0000000000000000000000001088a6585f9a1e2a47933c53c96a1832f25536c9
Arg [12] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [13] : 00000000000000000000000000000000000000000000000000000000000005dc
Arg [14] : 0000000000000000000000000000000000000000000000000000000000002134


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

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

Validator Index Block Amount
View All Withdrawals

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

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