编译器
0.8.19+commit.7dd6d404
文件 1 的 8:Context.sol
pragma solidity ^0.8.0;
abstract contract Context {
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes calldata) {
return msg.data;
}
}
文件 2 的 8:IERC165.sol
pragma solidity ^0.8.0;
interface IERC165 {
function supportsInterface(bytes4 interfaceId) external view returns (bool);
}
文件 3 的 8:IERC20.sol
pragma solidity ^0.8.0;
interface IERC20 {
event Transfer(address indexed from, address indexed to, uint256 value);
event Approval(address indexed owner, address indexed spender, uint256 value);
function totalSupply() external view returns (uint256);
function balanceOf(address account) external view returns (uint256);
function transfer(address to, uint256 amount) external returns (bool);
function allowance(address owner, address spender) external view returns (uint256);
function approve(address spender, uint256 amount) external returns (bool);
function transferFrom(
address from,
address to,
uint256 amount
) external returns (bool);
}
文件 4 的 8:IERC721.sol
pragma solidity ^0.8.0;
import "../../utils/introspection/IERC165.sol";
interface IERC721 is IERC165 {
event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);
event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);
event ApprovalForAll(address indexed owner, address indexed operator, bool approved);
function balanceOf(address owner) external view returns (uint256 balance);
function ownerOf(uint256 tokenId) external view returns (address owner);
function safeTransferFrom(
address from,
address to,
uint256 tokenId,
bytes calldata data
) external;
function safeTransferFrom(
address from,
address to,
uint256 tokenId
) external;
function transferFrom(
address from,
address to,
uint256 tokenId
) external;
function approve(address to, uint256 tokenId) external;
function setApprovalForAll(address operator, bool _approved) external;
function getApproved(uint256 tokenId) external view returns (address operator);
function isApprovedForAll(address owner, address operator) external view returns (bool);
}
文件 5 的 8:INexusGaming.sol
pragma solidity ^0.8.13;
import { IERC721 } from "openzeppelin/contracts/token/ERC721/IERC721.sol";
interface INexusGaming is IERC721 {
function mint(address to, uint256 amount) external;
}
文件 6 的 8:MerkleProof.sol
pragma solidity ^0.8.0;
library MerkleProof {
function verify(
bytes32[] memory proof,
bytes32 root,
bytes32 leaf
) internal pure returns (bool) {
return processProof(proof, leaf) == root;
}
function verifyCalldata(
bytes32[] calldata proof,
bytes32 root,
bytes32 leaf
) internal pure returns (bool) {
return processProofCalldata(proof, leaf) == root;
}
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;
}
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;
}
function multiProofVerify(
bytes32[] memory proof,
bool[] memory proofFlags,
bytes32 root,
bytes32[] memory leaves
) internal pure returns (bool) {
return processMultiProof(proof, proofFlags, leaves) == root;
}
function multiProofVerifyCalldata(
bytes32[] calldata proof,
bool[] calldata proofFlags,
bytes32 root,
bytes32[] memory leaves
) internal pure returns (bool) {
return processMultiProofCalldata(proof, proofFlags, leaves) == root;
}
function processMultiProof(
bytes32[] memory proof,
bool[] memory proofFlags,
bytes32[] memory leaves
) internal pure returns (bytes32 merkleRoot) {
uint256 leavesLen = leaves.length;
uint256 totalHashes = proofFlags.length;
require(leavesLen + proof.length - 1 == totalHashes, "MerkleProof: invalid multiproof");
bytes32[] memory hashes = new bytes32[](totalHashes);
uint256 leafPos = 0;
uint256 hashPos = 0;
uint256 proofPos = 0;
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 processMultiProofCalldata(
bytes32[] calldata proof,
bool[] calldata proofFlags,
bytes32[] memory leaves
) internal pure returns (bytes32 merkleRoot) {
uint256 leavesLen = leaves.length;
uint256 totalHashes = proofFlags.length;
require(leavesLen + proof.length - 1 == totalHashes, "MerkleProof: invalid multiproof");
bytes32[] memory hashes = new bytes32[](totalHashes);
uint256 leafPos = 0;
uint256 hashPos = 0;
uint256 proofPos = 0;
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) {
assembly {
mstore(0x00, a)
mstore(0x20, b)
value := keccak256(0x00, 0x40)
}
}
}
文件 7 的 8:Ownable.sol
pragma solidity ^0.8.0;
import "../utils/Context.sol";
abstract contract Ownable is Context {
address private _owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
constructor() {
_transferOwnership(_msgSender());
}
modifier onlyOwner() {
_checkOwner();
_;
}
function owner() public view virtual returns (address) {
return _owner;
}
function _checkOwner() internal view virtual {
require(owner() == _msgSender(), "Ownable: caller is not the owner");
}
function renounceOwnership() public virtual onlyOwner {
_transferOwnership(address(0));
}
function transferOwnership(address newOwner) public virtual onlyOwner {
require(newOwner != address(0), "Ownable: new owner is the zero address");
_transferOwnership(newOwner);
}
function _transferOwnership(address newOwner) internal virtual {
address oldOwner = _owner;
_owner = newOwner;
emit OwnershipTransferred(oldOwner, newOwner);
}
}
文件 8 的 8:Preseller.sol
pragma solidity ^0.8.13;
import { IERC20 } from "openzeppelin/contracts/token/ERC20/IERC20.sol";
import { Ownable } from "openzeppelin/contracts/access/Ownable.sol";
import { MerkleProof } from "openzeppelin/contracts/utils/cryptography/MerkleProof.sol";
import { INexusGaming } from "./interface/INexusGaming.sol";
contract Preseller is Ownable {
struct MintInfo {
uint48 startTime;
uint48 endTime;
uint48 claimTime;
bytes32 merkleRoot;
uint256 maxPurchased;
uint256 totalPurchased;
uint256[] prices;
}
INexusGaming public immutable nft;
uint256 public nextMintId;
mapping(uint256 => MintInfo) public mintInfos;
mapping(uint256 => mapping(address => mapping(uint256 => uint256))) public numberPurchased;
IERC20 public immutable usdc;
uint256 internal constant TRANCHE_COUNT = 5;
constructor(address _owner, address _nft, address _usdc) {
if (_owner == address(0) || _nft == address(0) || _usdc == address(0)) revert Preseller__ZeroAddressInvalid();
_transferOwnership(_owner);
nft = INexusGaming(_nft);
usdc = IERC20(_usdc);
}
function purchasePresale(
uint256 mintId,
uint256[] calldata amounts,
uint256[] calldata allocations,
bytes32[] calldata proof
) external {
MintInfo storage info = mintInfos[mintId];
if (block.timestamp < info.startTime || block.timestamp >= info.endTime)
revert Preseller__NotTimeForPresalePurchases();
if (amounts.length != allocations.length) revert Preseller__ArrayLengthMismatch();
if (amounts.length != TRANCHE_COUNT) revert Preseller__ArrayLengthInvalid();
if (!_verifyMerkleProof(allocations, info.merkleRoot, proof)) revert Preseller__ProofInvalid();
uint256 cost;
uint256 amount;
uint256[] memory cachedPrices = info.prices;
for (uint256 i; i < TRANCHE_COUNT; ) {
if (amounts[i] + numberPurchased[mintId][msg.sender][i] > allocations[i])
revert Preseller__ExceedsMaxAllocation();
cost += amounts[i] * cachedPrices[i];
amount += amounts[i];
numberPurchased[mintId][msg.sender][i] += amounts[i];
unchecked {
++i;
}
}
if (info.totalPurchased + amount > info.maxPurchased) revert Preseller__ExceedsMaxSupply();
if (amount == 0) revert Preseller__ZeroAmount();
info.totalPurchased += amount;
if (!usdc.transferFrom(msg.sender, address(this), cost)) {
revert Preseller__USDCTransferFailed();
}
emit PresalePurchase(msg.sender, amount);
}
function claimPresale(address user, uint256 mintId) external {
_claimPresale(user, mintId);
}
function claimPresaleBatch(address[] calldata users, uint256[] calldata mintIds) external {
if (users.length != mintIds.length) revert Preseller__ArrayLengthMismatch();
for (uint256 i; i < users.length; ) {
_claimPresale(users[i], mintIds[i]);
unchecked {
++i;
}
}
}
function _claimPresale(address user, uint256 mintId) internal {
uint256 amount;
MintInfo memory info = mintInfos[mintId];
if (block.timestamp < info.claimTime) revert Preseller__NotTimeForClaim();
for (uint256 i; i < TRANCHE_COUNT; ) {
amount += numberPurchased[mintId][user][i];
numberPurchased[mintId][user][i] = 0;
unchecked {
++i;
}
}
if (amount == 0) revert Preseller__ZeroAmount();
nft.mint(user, amount);
}
function setupMintPhase(
uint48 _startTime,
uint48 _endTime,
uint48 _claimTime,
bytes32 _merkleRoot,
uint256 _maxPurchased,
uint256[] calldata _prices
) external onlyOwner returns (uint256) {
if (_startTime >= _endTime || _startTime <= block.timestamp || _claimTime <= _endTime)
revert Preseller__MintTimesInvalid();
if (_merkleRoot == bytes32(0)) revert Preseller__ZeroRootInvalid();
if (_prices.length != TRANCHE_COUNT) revert Preseller__ArrayLengthInvalid();
uint256 mintId = nextMintId;
mintInfos[mintId] = MintInfo({
startTime: _startTime,
endTime: _endTime,
claimTime: _claimTime,
merkleRoot: _merkleRoot,
maxPurchased: _maxPurchased,
totalPurchased: 0,
prices: _prices
});
unchecked {
++nextMintId;
}
emit NewMintPhaseCreated(mintId);
return mintId;
}
function updatePrices(uint256 mintId, uint256[] calldata _prices) external onlyOwner {
if (mintId >= nextMintId) revert Preseller__MintIdInvalid();
if (_prices.length != TRANCHE_COUNT) revert Preseller__ArrayLengthInvalid();
mintInfos[mintId].prices = _prices;
emit PricesUpdated(mintId);
}
function updateMintStartTime(uint256 mintId, uint48 _startTime) external onlyOwner {
if (mintId >= nextMintId) revert Preseller__MintIdInvalid();
if (_startTime >= mintInfos[mintId].endTime || _startTime <= block.timestamp) {
revert Preseller__MintTimesInvalid();
}
emit StartTimeUpdated(mintId, _startTime, mintInfos[mintId].startTime);
mintInfos[mintId].startTime = _startTime;
}
function updateMintEndTime(uint256 mintId, uint48 _endTime) external onlyOwner {
if (mintId >= nextMintId) revert Preseller__MintIdInvalid();
if (mintInfos[mintId].startTime >= _endTime || mintInfos[mintId].claimTime <= _endTime) {
revert Preseller__MintTimesInvalid();
}
emit EndTimeUpdated(mintId, _endTime, mintInfos[mintId].endTime);
mintInfos[mintId].endTime = _endTime;
}
function updateMintClaimTime(uint256 mintId, uint48 _claimTime) external onlyOwner {
if (mintId >= nextMintId) revert Preseller__MintIdInvalid();
if (_claimTime <= mintInfos[mintId].endTime) {
revert Preseller__MintTimesInvalid();
}
emit ClaimTimeUpdated(mintId, _claimTime, mintInfos[mintId].claimTime);
mintInfos[mintId].claimTime = _claimTime;
}
function updateMintMerkleRoot(uint256 mintId, bytes32 _merkleRoot) external onlyOwner {
if (mintId >= nextMintId) revert Preseller__MintIdInvalid();
emit MerkleRootUpdated(mintId, _merkleRoot, mintInfos[mintId].merkleRoot);
mintInfos[mintId].merkleRoot = _merkleRoot;
}
function updateMintMaxPurchased(uint256 mintId, uint256 _maxPurchased) external onlyOwner {
if (mintId >= nextMintId) revert Preseller__MintIdInvalid();
if (_maxPurchased < mintInfos[mintId].totalPurchased) revert Preseller__MaxPurchasedInvalid();
emit MaxPurchasedUpdated(mintId, _maxPurchased, mintInfos[mintId].maxPurchased);
mintInfos[mintId].maxPurchased = _maxPurchased;
}
function withdraw() external onlyOwner {
uint256 balance = usdc.balanceOf(address(this));
usdc.transfer(owner(), balance);
emit Withdrawal(balance);
}
function _verifyMerkleProof(
uint256[] calldata _allocations,
bytes32 _merkleRoot,
bytes32[] calldata _proof
) private view returns (bool) {
bytes32 leaf = keccak256(abi.encode(msg.sender, _allocations));
return MerkleProof.verifyCalldata(_proof, _merkleRoot, leaf);
}
function getMintInfo(uint256 mintId) external view returns (MintInfo memory) {
return mintInfos[mintId];
}
function isMintActive(uint256 mintId) external view returns (bool) {
MintInfo storage info = mintInfos[mintId];
return (block.timestamp >= info.startTime) && (block.timestamp < info.endTime);
}
function getUserPurchasesPerMintId(uint256 mintId, address user) external view returns (uint256[] memory) {
uint256[] memory amounts = new uint256[](5);
for (uint256 i; i < TRANCHE_COUNT; ) {
amounts[i] = numberPurchased[mintId][user][i];
unchecked {
++i;
}
}
return amounts;
}
event PricesUpdated(uint256 indexed mintId);
event StartTimeUpdated(uint256 indexed mintId, uint48 startTime, uint48 oldStartTime);
event EndTimeUpdated(uint256 indexed mintId, uint48 endTime, uint48 oldEndTime);
event ClaimTimeUpdated(uint256 indexed mintId, uint48 claimTime, uint48 oldClaimTime);
event MerkleRootUpdated(uint256 indexed mintId, bytes32 merkleRoot, bytes32 oldMerkleRoot);
event MaxPurchasedUpdated(uint256 indexed mintId, uint256 supply, uint256 oldSupply);
event NewMintPhaseCreated(uint256 indexed mintId);
event Withdrawal(uint256 balance);
event PresalePurchase(address indexed purchaser, uint256 indexed amount);
error Preseller__ZeroAddressInvalid();
error Preseller__ZeroRootInvalid();
error Preseller__ZeroAmount();
error Preseller__ArrayLengthMismatch();
error Preseller__ArrayLengthInvalid();
error Preseller__ProofInvalid();
error Preseller__MintTimesInvalid();
error Preseller__MintIdInvalid();
error Preseller__MaxPurchasedInvalid();
error Preseller__USDCTransferFailed();
error Preseller__ExceedsMaxSupply();
error Preseller__ExceedsMaxAllocation();
error Preseller__NotTimeForClaim();
error Preseller__NotTimeForPresalePurchases();
}
{
"compilationTarget": {
"src/Preseller.sol": "Preseller"
},
"evmVersion": "paris",
"libraries": {},
"metadata": {
"bytecodeHash": "ipfs"
},
"optimizer": {
"enabled": true,
"runs": 200
},
"remappings": [
":ERC721A/=lib/ERC721A/contracts/",
":ds-test/=lib/forge-std/lib/ds-test/src/",
":erc4626-tests/=lib/operator-filter-registry/lib/openzeppelin-contracts/lib/erc4626-tests/",
":erc721a/=lib/ERC721A/contracts/",
":forge-std/=lib/forge-std/src/",
":murky/=lib/murky/src/",
":openzeppelin-contracts-upgradeable/=lib/operator-filter-registry/lib/openzeppelin-contracts-upgradeable/",
":openzeppelin-contracts/=lib/openzeppelin-contracts/",
":openzeppelin/=lib/openzeppelin-contracts/",
":operator-filter-registry/=lib/operator-filter-registry/src/",
":solady/=lib/solady/src/"
]
}
[{"inputs":[{"internalType":"address","name":"_owner","type":"address"},{"internalType":"address","name":"_nft","type":"address"},{"internalType":"address","name":"_usdc","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"Preseller__ArrayLengthInvalid","type":"error"},{"inputs":[],"name":"Preseller__ArrayLengthMismatch","type":"error"},{"inputs":[],"name":"Preseller__ExceedsMaxAllocation","type":"error"},{"inputs":[],"name":"Preseller__ExceedsMaxSupply","type":"error"},{"inputs":[],"name":"Preseller__MaxPurchasedInvalid","type":"error"},{"inputs":[],"name":"Preseller__MintIdInvalid","type":"error"},{"inputs":[],"name":"Preseller__MintTimesInvalid","type":"error"},{"inputs":[],"name":"Preseller__NotTimeForClaim","type":"error"},{"inputs":[],"name":"Preseller__NotTimeForPresalePurchases","type":"error"},{"inputs":[],"name":"Preseller__ProofInvalid","type":"error"},{"inputs":[],"name":"Preseller__USDCTransferFailed","type":"error"},{"inputs":[],"name":"Preseller__ZeroAddressInvalid","type":"error"},{"inputs":[],"name":"Preseller__ZeroAmount","type":"error"},{"inputs":[],"name":"Preseller__ZeroRootInvalid","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"mintId","type":"uint256"},{"indexed":false,"internalType":"uint48","name":"claimTime","type":"uint48"},{"indexed":false,"internalType":"uint48","name":"oldClaimTime","type":"uint48"}],"name":"ClaimTimeUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"mintId","type":"uint256"},{"indexed":false,"internalType":"uint48","name":"endTime","type":"uint48"},{"indexed":false,"internalType":"uint48","name":"oldEndTime","type":"uint48"}],"name":"EndTimeUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"mintId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"supply","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"oldSupply","type":"uint256"}],"name":"MaxPurchasedUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"mintId","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"merkleRoot","type":"bytes32"},{"indexed":false,"internalType":"bytes32","name":"oldMerkleRoot","type":"bytes32"}],"name":"MerkleRootUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"mintId","type":"uint256"}],"name":"NewMintPhaseCreated","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":"purchaser","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"PresalePurchase","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"mintId","type":"uint256"}],"name":"PricesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"mintId","type":"uint256"},{"indexed":false,"internalType":"uint48","name":"startTime","type":"uint48"},{"indexed":false,"internalType":"uint48","name":"oldStartTime","type":"uint48"}],"name":"StartTimeUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"balance","type":"uint256"}],"name":"Withdrawal","type":"event"},{"inputs":[{"internalType":"address","name":"user","type":"address"},{"internalType":"uint256","name":"mintId","type":"uint256"}],"name":"claimPresale","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"users","type":"address[]"},{"internalType":"uint256[]","name":"mintIds","type":"uint256[]"}],"name":"claimPresaleBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"mintId","type":"uint256"}],"name":"getMintInfo","outputs":[{"components":[{"internalType":"uint48","name":"startTime","type":"uint48"},{"internalType":"uint48","name":"endTime","type":"uint48"},{"internalType":"uint48","name":"claimTime","type":"uint48"},{"internalType":"bytes32","name":"merkleRoot","type":"bytes32"},{"internalType":"uint256","name":"maxPurchased","type":"uint256"},{"internalType":"uint256","name":"totalPurchased","type":"uint256"},{"internalType":"uint256[]","name":"prices","type":"uint256[]"}],"internalType":"struct Preseller.MintInfo","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"mintId","type":"uint256"},{"internalType":"address","name":"user","type":"address"}],"name":"getUserPurchasesPerMintId","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"mintId","type":"uint256"}],"name":"isMintActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"mintInfos","outputs":[{"internalType":"uint48","name":"startTime","type":"uint48"},{"internalType":"uint48","name":"endTime","type":"uint48"},{"internalType":"uint48","name":"claimTime","type":"uint48"},{"internalType":"bytes32","name":"merkleRoot","type":"bytes32"},{"internalType":"uint256","name":"maxPurchased","type":"uint256"},{"internalType":"uint256","name":"totalPurchased","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"nextMintId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"nft","outputs":[{"internalType":"contract INexusGaming","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"numberPurchased","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":"mintId","type":"uint256"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"uint256[]","name":"allocations","type":"uint256[]"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"purchasePresale","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint48","name":"_startTime","type":"uint48"},{"internalType":"uint48","name":"_endTime","type":"uint48"},{"internalType":"uint48","name":"_claimTime","type":"uint48"},{"internalType":"bytes32","name":"_merkleRoot","type":"bytes32"},{"internalType":"uint256","name":"_maxPurchased","type":"uint256"},{"internalType":"uint256[]","name":"_prices","type":"uint256[]"}],"name":"setupMintPhase","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"mintId","type":"uint256"},{"internalType":"uint48","name":"_claimTime","type":"uint48"}],"name":"updateMintClaimTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"mintId","type":"uint256"},{"internalType":"uint48","name":"_endTime","type":"uint48"}],"name":"updateMintEndTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"mintId","type":"uint256"},{"internalType":"uint256","name":"_maxPurchased","type":"uint256"}],"name":"updateMintMaxPurchased","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"mintId","type":"uint256"},{"internalType":"bytes32","name":"_merkleRoot","type":"bytes32"}],"name":"updateMintMerkleRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"mintId","type":"uint256"},{"internalType":"uint48","name":"_startTime","type":"uint48"}],"name":"updateMintStartTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"mintId","type":"uint256"},{"internalType":"uint256[]","name":"_prices","type":"uint256[]"}],"name":"updatePrices","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"usdc","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]