More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 114 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Claim | 19618686 | 271 days ago | IN | 0 ETH | 0.00354741 | ||||
Claim | 18009848 | 497 days ago | IN | 0 ETH | 0.00166696 | ||||
Claim | 17843587 | 520 days ago | IN | 0 ETH | 0.00418189 | ||||
Claim | 17815514 | 524 days ago | IN | 0 ETH | 0.00531861 | ||||
Claim | 17740412 | 534 days ago | IN | 0 ETH | 0.00236705 | ||||
Claim | 17708096 | 539 days ago | IN | 0 ETH | 0.00076573 | ||||
Claim | 17708093 | 539 days ago | IN | 0 ETH | 0.00174432 | ||||
Claim | 17656549 | 546 days ago | IN | 0 ETH | 0.00166822 | ||||
Claim | 17650543 | 547 days ago | IN | 0 ETH | 0.00471978 | ||||
Claim | 17634289 | 549 days ago | IN | 0 ETH | 0.00680655 | ||||
Claim | 17634287 | 549 days ago | IN | 0 ETH | 0.00777408 | ||||
Claim | 17612597 | 552 days ago | IN | 0 ETH | 0.00192291 | ||||
Claim | 17608917 | 553 days ago | IN | 0 ETH | 0.00131294 | ||||
Claim | 17600906 | 554 days ago | IN | 0 ETH | 0.00201603 | ||||
Claim | 17595552 | 555 days ago | IN | 0 ETH | 0.00073732 | ||||
Claim | 17595550 | 555 days ago | IN | 0 ETH | 0.00152082 | ||||
Claim | 17592037 | 555 days ago | IN | 0 ETH | 0.0046558 | ||||
Claim | 17588974 | 556 days ago | IN | 0 ETH | 0.0031713 | ||||
Claim | 17579046 | 557 days ago | IN | 0 ETH | 0.00273397 | ||||
Claim | 17576527 | 557 days ago | IN | 0 ETH | 0.00273408 | ||||
Claim | 17570423 | 558 days ago | IN | 0 ETH | 0.00164142 | ||||
Claim | 17569031 | 558 days ago | IN | 0 ETH | 0.0031955 | ||||
Claim | 17568956 | 558 days ago | IN | 0 ETH | 0.00081684 | ||||
Claim | 17568952 | 558 days ago | IN | 0 ETH | 0.00257533 | ||||
Claim | 17568044 | 559 days ago | IN | 0 ETH | 0.0019522 |
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Name:
ThePirateBay
Compiler Version
v0.8.19+commit.7dd6d404
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.4; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/security/Pausable.sol"; import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; interface ICryptoPirates { function types(uint256) external view returns (uint256); function TYPE_COMMON() external view returns (uint256); function TYPE_RARE() external view returns (uint256); function TYPE_EPIC() external view returns (uint256); function TYPE_LEGENDARY() external view returns (uint256); } contract ThePirateBay is Ownable, IERC721Receiver, Pausable, ReentrancyGuard { // whether or not rescue is enabled bool public rescueEnabled = false; // address of the NFT contract IERC721 public nftAddress; // address of the ERC20 token IERC20 public tokenAddress; uint256 public constant amountPerNFT = 10_000_000 ether; // amount of tokens per NFT uint256 public constant totalLockTime = 10 days; // how long the lock is uint256 public constant totalReward = 2_000_000_000 ether; // total reward for the pool (2 billion tokens) uint256 public constant COMMON_MULTIPLIER = 100; // 1 uint256 public constant RARE_MULTIPLIER = 125; // 1.25 uint256 public constant EPIC_MULTIPLIER = 200; // 2 uint256 public constant LEGENDARY_MULTIPLIER = 500; // 5 bool public depositStarted = true; // whether or not depositing has started uint256 public lockStartTime = 1686650400; // Tuesday, June 13, 2023 10:00:00 AM uint256 public totalStaked; // total amount of tokens staked uint256 public totalNFTsStaked; // total amount of NFTs staked uint256 public totalMultipliers; // total amount of multipliers struct Stake { uint256 amount; // amount of tokens staked uint256[] nftIds; // array of NFTs staked bool claimed; // whether the user has claimed their reward } mapping(uint256 => bool) private nftIdsStaked; // whether or not an NFT has been staked mapping(address => Stake) public stakes; // stake of an account event Staked(address indexed user, uint256 amount, uint256[] nftIds); event Claimed(address indexed user, uint256 amount); constructor(address _nftAddress, address _tokenAddress) { nftAddress = IERC721(_nftAddress); tokenAddress = IERC20(_tokenAddress); } modifier whenDepositOn() { require(depositStarted, "Cannot stake before deposit started"); require(lockStartTime > block.timestamp, "Cannot stake after lock started"); _; } modifier whenLockOver() { require(lockStartTime + totalLockTime < block.timestamp, "Cannot claim during lock time"); _; } modifier whenRescueEnabled() { require(rescueEnabled, "Rescue is not enabled"); _; } /// @dev allows user to stake tokens and NFTs /// @param _nftIds ids of the NFTs to stake function stake(uint256[] calldata _nftIds) external whenNotPaused whenDepositOn nonReentrant { require(_nftIds.length > 0, "Cannot stake 0 NFTs"); uint256 totalAmount = amountPerNFT * _nftIds.length; Stake storage _stake = stakes[_msgSender()]; // transfer tokens to contract tokenAddress.transferFrom(_msgSender(), address(this), totalAmount); // transfer NFTs to contract for (uint256 i = 0; i < _nftIds.length; i++) { require(!nftIdsStaked[_nftIds[i]], "Cannot stake the same NFT twice"); nftAddress.transferFrom(_msgSender(), address(this), _nftIds[i]); _stake.nftIds.push(_nftIds[i]); nftIdsStaked[_nftIds[i]] = true; totalMultipliers += nftMultiplier(_nftIds[i]); } // update stake _stake.amount += totalAmount; // update totals totalStaked += totalAmount; totalNFTsStaked += _nftIds.length; emit Staked(_msgSender(), totalAmount, _nftIds); } /// @dev allows user to claim tokens and NFTs function claim() external whenNotPaused whenLockOver nonReentrant { Stake memory _stake = stakes[_msgSender()]; require(_stake.amount > 0, "Cannot claim before staking"); require(!_stake.claimed, "Cannot claim twice"); _stake.claimed = true; // transfer NFTs to user for (uint256 i = 0; i < _stake.nftIds.length; i++) { nftAddress.transferFrom(address(this), _msgSender(), _stake.nftIds[i]); } uint256 totalAmount = _stake.amount + earned(_msgSender()); // transfer tokens to user require(IERC20(tokenAddress).transfer(_msgSender(), totalAmount), "Cannot transfer tokens to user"); emit Claimed(_msgSender(), totalAmount); } /// @dev returns the amount of tokens earned /// @param account address of the account function earned(address account) public view returns (uint256 _earned) { uint256 multiplier = totalMultiplier(account); return multiplier * totalReward / totalMultipliers; } /// @dev returns the multiplier for an NFT /// @param nftId id of the NFT function nftMultiplier(uint256 nftId) public view returns (uint256 multiplier) { ICryptoPirates cryptoPirates = ICryptoPirates(address(nftAddress)); uint256 nftType = cryptoPirates.types(nftId); if (nftType == cryptoPirates.TYPE_COMMON()) { return COMMON_MULTIPLIER; } else if (nftType == cryptoPirates.TYPE_RARE()) { return RARE_MULTIPLIER; } else if (nftType == cryptoPirates.TYPE_EPIC()) { return EPIC_MULTIPLIER; } else if (nftType == cryptoPirates.TYPE_LEGENDARY()) { return LEGENDARY_MULTIPLIER; } return COMMON_MULTIPLIER; } /// @dev returns the total multiplier for an account /// @param account address of the account function totalMultiplier(address account) public view returns (uint256 multiplier) { Stake memory _stake = stakes[account]; for (uint256 i = 0; i < _stake.nftIds.length; i++) { multiplier += nftMultiplier(_stake.nftIds[i]); } return multiplier; } /// @dev returns the NFTs staked by an account /// @param account address of the account function userNFTs(address account) public view returns (uint256[] memory nftIds) { Stake memory _stake = stakes[account]; return _stake.nftIds; } /// @dev returns the stats of an account /// @param account address of the account function userStats(address account) public view returns (uint256 nfts, uint256 staked, uint256 multiplier, uint256 share, uint256 reward, bool claimed) { Stake memory _stake = stakes[account]; nfts = _stake.nftIds.length; staked = _stake.amount; multiplier = totalMultiplier(account); share = multiplier * 10000 / totalMultipliers; uint256 stakeTime = 0; if (lockStartTime > block.timestamp) stakeTime = 0; else if (lockStartTime + totalLockTime < block.timestamp) stakeTime = totalLockTime; else stakeTime = block.timestamp - lockStartTime; reward = earned(account) * stakeTime / totalLockTime; claimed = _stake.claimed; } /// @dev allows owner to set the lock start time /// @param _lockStartTime timestamp of when locking starts function setLockStartTime(uint256 _lockStartTime) external whenDepositOn onlyOwner { require(_lockStartTime > block.timestamp, "Cannot set time before current time"); lockStartTime = _lockStartTime; } /// @dev allows owner to set wether or not depositing has started /// @param _depositStarted boolean function setDepositStarted(bool _depositStarted) external onlyOwner { depositStarted = _depositStarted; } /// @dev allows owner to enable "rescue mode" /// @param _enabled boolean function setRescueEnabled(bool _enabled) external onlyOwner { rescueEnabled = _enabled; } /// @dev enables owner to pause / unpause minting /// @param _paused boolean function setPaused(bool _paused) external onlyOwner { if (_paused) _pause(); else _unpause(); } /// @dev allows user to rescue tokens and NFTs /// @param account address of the account /// @param index index of the first NFT to rescue /// @param amount amount of NFTs to rescue function emergencyRescue(address account, uint256 index, uint256 amount) external whenNotPaused whenRescueEnabled nonReentrant { Stake memory _stake = stakes[account]; // transfer NFTs to user for (uint256 i = index; i < (index + amount); i++) { nftAddress.transferFrom(address(this), account, _stake.nftIds[i]); } } /// @dev allows user to rescue tokens /// @param account address of the account function emergencyRescueTokens(address account) external whenNotPaused whenRescueEnabled nonReentrant { Stake memory _stake = stakes[account]; require(!_stake.claimed, "Cannot rescue tokens after claiming"); _stake.claimed = true; // transfer tokens to user require(IERC20(tokenAddress).transfer(account, _stake.amount), "Cannot transfer tokens to user"); } /// @dev allows owner to rescue tokens /// @param amount amount of tokens to rescue function emergencyRewardRescue(uint256 amount) external onlyOwner whenRescueEnabled { require(IERC20(tokenAddress).transfer(_msgSender(), amount), "Cannot transfer tokens to user"); } function onERC721Received( address, address from, uint256, bytes calldata ) external pure override returns (bytes4) { require(from == address(0x0), "Cannot send tokens directly to the bay"); return IERC721Receiver.onERC721Received.selector; } }
// 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); }
// 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; } }
// 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); }
// 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); }
// 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); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.8.0) (security/ReentrancyGuard.sol) pragma solidity ^0.8.0; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. * * TIP: If you would like to learn more about reentrancy and alternative ways * to protect against it, check out our blog post * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul]. */ abstract contract ReentrancyGuard { // Booleans are more expensive than uint256 or any type that takes up a full // word because each write operation emits an extra SLOAD to first read the // slot's contents, replace the bits taken up by the boolean, and then write // back. This is the compiler's defense against contract upgrades and // pointer aliasing, and it cannot be disabled. // The values being non-zero value makes deployment a bit more expensive, // but in exchange the refund on every call to nonReentrant will be lower in // amount. Since refunds are capped to a percentage of the total // transaction's gas, it is best to keep them low in cases like this one, to // increase the likelihood of the full refund coming into effect. uint256 private constant _NOT_ENTERED = 1; uint256 private constant _ENTERED = 2; uint256 private _status; constructor() { _status = _NOT_ENTERED; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and making it call a * `private` function that does the actual work. */ modifier nonReentrant() { _nonReentrantBefore(); _; _nonReentrantAfter(); } function _nonReentrantBefore() private { // On the first call to nonReentrant, _status will be _NOT_ENTERED require(_status != _ENTERED, "ReentrancyGuard: reentrant call"); // Any calls to nonReentrant after this point will fail _status = _ENTERED; } function _nonReentrantAfter() private { // By storing the original value once again, a refund is triggered (see // https://eips.ethereum.org/EIPS/eip-2200) _status = _NOT_ENTERED; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (security/Pausable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your contract. Note that they will not be pausable by * simply including this module, only once the modifiers are put in place. */ abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** * @dev Initializes the contract in unpaused state. */ constructor() { _paused = false; } /** * @dev Modifier to make a function callable only when the contract is not paused. * * Requirements: * * - The contract must not be paused. */ modifier whenNotPaused() { _requireNotPaused(); _; } /** * @dev Modifier to make a function callable only when the contract is paused. * * Requirements: * * - The contract must be paused. */ modifier whenPaused() { _requirePaused(); _; } /** * @dev Returns true if the contract is paused, and false otherwise. */ function paused() public view virtual returns (bool) { return _paused; } /** * @dev Throws if the contract is paused. */ function _requireNotPaused() internal view virtual { require(!paused(), "Pausable: paused"); } /** * @dev Throws if the contract is not paused. */ function _requirePaused() internal view virtual { require(paused(), "Pausable: not paused"); } /** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */ function _pause() internal virtual whenNotPaused { _paused = true; emit Paused(_msgSender()); } /** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */ function _unpause() internal virtual whenPaused { _paused = false; emit Unpaused(_msgSender()); } }
// 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); } }
{ "remappings": [], "optimizer": { "enabled": true, "runs": 200 }, "evmVersion": "paris", "libraries": {}, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"_nftAddress","type":"address"},{"internalType":"address","name":"_tokenAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Claimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"uint256[]","name":"nftIds","type":"uint256[]"}],"name":"Staked","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"COMMON_MULTIPLIER","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EPIC_MULTIPLIER","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"LEGENDARY_MULTIPLIER","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"RARE_MULTIPLIER","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"amountPerNFT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"claim","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"depositStarted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"earned","outputs":[{"internalType":"uint256","name":"_earned","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"emergencyRescue","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"emergencyRescueTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"emergencyRewardRescue","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"lockStartTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"nftAddress","outputs":[{"internalType":"contract IERC721","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"nftId","type":"uint256"}],"name":"nftMultiplier","outputs":[{"internalType":"uint256","name":"multiplier","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"from","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC721Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rescueEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_depositStarted","type":"bool"}],"name":"setDepositStarted","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_lockStartTime","type":"uint256"}],"name":"setLockStartTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_paused","type":"bool"}],"name":"setPaused","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_enabled","type":"bool"}],"name":"setRescueEnabled","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_nftIds","type":"uint256[]"}],"name":"stake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"stakes","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bool","name":"claimed","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"tokenAddress","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalLockTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"totalMultiplier","outputs":[{"internalType":"uint256","name":"multiplier","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalMultipliers","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalNFTsStaked","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalReward","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalStaked","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"userNFTs","outputs":[{"internalType":"uint256[]","name":"nftIds","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"userStats","outputs":[{"internalType":"uint256","name":"nfts","type":"uint256"},{"internalType":"uint256","name":"staked","type":"uint256"},{"internalType":"uint256","name":"multiplier","type":"uint256"},{"internalType":"uint256","name":"share","type":"uint256"},{"internalType":"uint256","name":"reward","type":"uint256"},{"internalType":"bool","name":"claimed","type":"bool"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
60806040526002805460ff191690556003805460ff60a01b1916600160a01b1790556364883e206004553480156200003657600080fd5b5060405162001fab38038062001fab83398101604081905262000059916200011e565b6200006433620000b1565b6000805460ff60a01b191690556001805560028054610100600160a81b0319166101006001600160a01b0394851602179055600380546001600160a01b0319169190921617905562000156565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b80516001600160a01b03811681146200011957600080fd5b919050565b600080604083850312156200013257600080fd5b6200013d8362000101565b91506200014d6020840162000101565b90509250929050565b611e4580620001666000396000f3fe608060405234801561001057600080fd5b50600436106102105760003560e01c8063750142e611610125578063986b048a116100ad578063c6a0479d1161007c578063c6a0479d146104a0578063d198ce6a146104a8578063d44c73d4146104c8578063f2fde38b146104db578063f4bf4dfe146104ee57600080fd5b8063986b048a146104555780639d76ea5814610467578063b99a7a431461047a578063c54704e61461048d57600080fd5b80637f4ca1d7116100f45780637f4ca1d7146103d3578063817b1cd2146103e6578063890acf93146103ef5780638a65d874146104025780638da5cb5b1461044457600080fd5b8063750142e61461039a57806376531008146103ad578063788074ec146103c05780637e818976146103c957600080fd5b80634599fef6116101a857806361e34acc1161017757806361e34acc1461035957806362c7fa761461036c57806363d8840014610375578063715018a614610389578063742b1ae91461039157600080fd5b80634599fef6146103065780634e71d92d1461030f5780635bf8633a146103175780635c975abb1461034757600080fd5b806316934fc4116101e457806316934fc41461028457806316c38b3c146102c3578063292d5d77146102d657806339db714f146102e957600080fd5b80628cc262146102155780630f35f76e1461023b5780630fbf0a9314610243578063150b7a0214610258575b600080fd5b610228610223366004611a3b565b6104f6565b6040519081526020015b60405180910390f35b610228606481565b610256610251366004611a56565b61052f565b005b61026b610266366004611acb565b61090d565b6040516001600160e01b03199091168152602001610232565b6102ae610292366004611a3b565b6009602052600090815260409020805460029091015460ff1682565b60408051928352901515602083015201610232565b6102566102d1366004611b74565b610987565b6102286102e4366004611a3b565b6109a8565b6002546102f69060ff1681565b6040519015158152602001610232565b61022860075481565b610256610a96565b60025461032f9061010090046001600160a01b031681565b6040516001600160a01b039091168152602001610232565b600054600160a01b900460ff166102f6565b610256610367366004611b91565b610dd0565b61022860045481565b6003546102f690600160a01b900460ff1681565b610256610e99565b6102286101f481565b6102286b06765c793fa10079d000000081565b6102566103bb366004611b74565b610eab565b61022860065481565b610228620d2f0081565b6102286103e1366004611b91565b610ec6565b61022860055481565b6102566103fd366004611b74565b611112565b610415610410366004611a3b565b611138565b6040805196875260208701959095529385019290925260608401526080830152151560a082015260c001610232565b6000546001600160a01b031661032f565b6102286a084595161401484a00000081565b60035461032f906001600160a01b031681565b610256610488366004611a3b565b611296565b61025661049b366004611b91565b611462565b61022860c881565b6104bb6104b6366004611a3b565b611544565b6040516102329190611baa565b6102566104d6366004611bee565b6115df565b6102566104e9366004611a3b565b61176d565b610228607d81565b600080610502836109a8565b60075490915061051e6b06765c793fa10079d000000083611c37565b6105289190611c54565b9392505050565b6105376117e3565b600354600160a01b900460ff166105695760405162461bcd60e51b815260040161056090611c76565b60405180910390fd5b42600454116105ba5760405162461bcd60e51b815260206004820152601f60248201527f43616e6e6f74207374616b65206166746572206c6f636b2073746172746564006044820152606401610560565b6105c2611830565b806106055760405162461bcd60e51b815260206004820152601360248201527243616e6e6f74207374616b652030204e46547360681b6044820152606401610560565b600061061c826a084595161401484a000000611c37565b336000818152600960205260409081902060035491516323b872dd60e01b8152939450926001600160a01b03909116916323b872dd91610663919030908790600401611cb9565b6020604051808303816000875af1158015610682573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106a69190611cdd565b5060005b8381101561087357600860008686848181106106c8576106c8611cfa565b602090810292909201358352508101919091526040016000205460ff16156107325760405162461bcd60e51b815260206004820152601f60248201527f43616e6e6f74207374616b65207468652073616d65204e4654207477696365006044820152606401610560565b60025461010090046001600160a01b03166323b872dd333088888681811061075c5761075c611cfa565b905060200201356040518463ffffffff1660e01b815260040161078193929190611cb9565b600060405180830381600087803b15801561079b57600080fd5b505af11580156107af573d6000803e3d6000fd5b50505050816001018585838181106107c9576107c9611cfa565b835460018181018655600095865260208087209302949094013591015550906008908787858181106107fd576107fd611cfa565b90506020020135815260200190815260200160002060006101000a81548160ff02191690831515021790555061084a85858381811061083e5761083e611cfa565b90506020020135610ec6565b6007600082825461085b9190611d10565b9091555081905061086b81611d23565b9150506106aa565b50818160000160008282546108889190611d10565b9250508190555081600560008282546108a19190611d10565b9091555050600680548491906000906108bb908490611d10565b909155505060405133907fb18ab713c223cf8d1394fb3018faad3e87f34414cc9d74b6eff3510d05359d85906108f690859088908890611d3c565b60405180910390a2505061090960018055565b5050565b60006001600160a01b038516156109755760405162461bcd60e51b815260206004820152602660248201527f43616e6e6f742073656e6420746f6b656e73206469726563746c7920746f207460448201526568652062617960d01b6064820152608401610560565b50630a85bd0160e11b95945050505050565b61098f611889565b80156109a05761099d6118e3565b50565b61099d611943565b6001600160a01b0381166000908152600960209081526040808320815160608101835281548152600182018054845181870281018701909552808552869592948584019390929190830182828015610a1f57602002820191906000526020600020905b815481526020019060010190808311610a0b575b50505091835250506002919091015460ff161515602090910152905060005b816020015151811015610a8f57610a7182602001518281518110610a6457610a64611cfa565b6020026020010151610ec6565b610a7b9084611d10565b925080610a8781611d23565b915050610a3e565b5050919050565b610a9e6117e3565b42620d2f00600454610ab09190611d10565b10610afd5760405162461bcd60e51b815260206004820152601d60248201527f43616e6e6f7420636c61696d20647572696e67206c6f636b2074696d650000006044820152606401610560565b610b05611830565b3360009081526009602090815260408083208151606081018352815481526001820180548451818702810187019095528085529194929385840193909290830182828015610b7257602002820191906000526020600020905b815481526020019060010190808311610b5e575b50505091835250506002919091015460ff1615156020909101528051909150610bdd5760405162461bcd60e51b815260206004820152601b60248201527f43616e6e6f7420636c61696d206265666f7265207374616b696e6700000000006044820152606401610560565b806040015115610c245760405162461bcd60e51b815260206004820152601260248201527143616e6e6f7420636c61696d20747769636560701b6044820152606401610560565b6001604082015260005b816020015151811015610cd45760025461010090046001600160a01b03166323b872dd303385602001518581518110610c6957610c69611cfa565b60200260200101516040518463ffffffff1660e01b8152600401610c8f93929190611cb9565b600060405180830381600087803b158015610ca957600080fd5b505af1158015610cbd573d6000803e3d6000fd5b505050508080610ccc90611d23565b915050610c2e565b506000610ce0336104f6565b8251610cec9190611d10565b6003549091506001600160a01b031663a9059cbb336040516001600160e01b031960e084901b1681526001600160a01b039091166004820152602481018490526044016020604051808303816000875af1158015610d4e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d729190611cdd565b610d8e5760405162461bcd60e51b815260040161056090611d7d565b60405181815233907fd8138f8a3f377c5259ca548e70e4c2de94f129f5a11036a15b69513cba2b426a9060200160405180910390a25050610dce60018055565b565b610dd8611889565b60025460ff16610dfa5760405162461bcd60e51b815260040161056090611db4565b6003546001600160a01b031663a9059cbb336040516001600160e01b031960e084901b1681526001600160a01b039091166004820152602481018490526044016020604051808303816000875af1158015610e59573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e7d9190611cdd565b61099d5760405162461bcd60e51b815260040161056090611d7d565b610ea1611889565b610dce600061197f565b610eb3611889565b6002805460ff1916911515919091179055565b60025460405163677dfd1b60e11b81526004810183905260009161010090046001600160a01b0316908290829063cefbfa3690602401602060405180830381865afa158015610f19573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f3d9190611de3565b9050816001600160a01b031663339a1dbd6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f7d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fa19190611de3565b8103610fb1575060649392505050565b816001600160a01b03166343d678626040518163ffffffff1660e01b8152600401602060405180830381865afa158015610fef573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110139190611de3565b81036110235750607d9392505050565b816001600160a01b03166360ab1f076040518163ffffffff1660e01b8152600401602060405180830381865afa158015611061573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110859190611de3565b8103611095575060c89392505050565b816001600160a01b031663e0c2f0b86040518163ffffffff1660e01b8152600401602060405180830381865afa1580156110d3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110f79190611de3565b810361110857506101f49392505050565b5060649392505050565b61111a611889565b60038054911515600160a01b0260ff60a01b19909216919091179055565b600080600080600080600060096000896001600160a01b03166001600160a01b0316815260200190815260200160002060405180606001604052908160008201548152602001600182018054806020026020016040519081016040528092919081815260200182805480156111cc57602002820191906000526020600020905b8154815260200190600101908083116111b8575b50505091835250506002919091015460ff161515602091820152810151518151909850965090506111fc886109a8565b60075490955061120e86612710611c37565b6112189190611c54565b9350600042600454111561122e57506000611260565b42620d2f006004546112409190611d10565b10156112505750620d2f00611260565b60045461125d9042611dfc565b90505b620d2f008161126e8b6104f6565b6112789190611c37565b6112829190611c54565b935081604001519250505091939550919395565b61129e6117e3565b60025460ff166112c05760405162461bcd60e51b815260040161056090611db4565b6112c8611830565b6001600160a01b0381166000908152600960209081526040808320815160608101835281548152600182018054845181870281018701909552808552919492938584019390929083018282801561133e57602002820191906000526020600020905b81548152602001906001019080831161132a575b50505091835250506002919091015460ff1615156020909101526040810151909150156113b95760405162461bcd60e51b815260206004820152602360248201527f43616e6e6f742072657363756520746f6b656e7320616674657220636c61696d604482015262696e6760e81b6064820152608401610560565b60016040828101919091526003548251915163a9059cbb60e01b81526001600160a01b038581166004830152602482019390935291169063a9059cbb906044016020604051808303816000875af1158015611418573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061143c9190611cdd565b6114585760405162461bcd60e51b815260040161056090611d7d565b5061099d60018055565b600354600160a01b900460ff1661148b5760405162461bcd60e51b815260040161056090611c76565b42600454116114dc5760405162461bcd60e51b815260206004820152601f60248201527f43616e6e6f74207374616b65206166746572206c6f636b2073746172746564006044820152606401610560565b6114e4611889565b42811161153f5760405162461bcd60e51b815260206004820152602360248201527f43616e6e6f74207365742074696d65206265666f72652063757272656e742074604482015262696d6560e81b6064820152608401610560565b600455565b6001600160a01b0381166000908152600960209081526040808320815160608181018452825482526001830180548551818802810188019096528086529196959294858401939092908301828280156115bc57602002820191906000526020600020905b8154815260200190600101908083116115a8575b50505091835250506002919091015460ff16151560209182015201519392505050565b6115e76117e3565b60025460ff166116095760405162461bcd60e51b815260040161056090611db4565b611611611830565b6001600160a01b0383166000908152600960209081526040808320815160608101835281548152600182018054845181870281018701909552808552919492938584019390929083018282801561168757602002820191906000526020600020905b815481526020019060010190808311611673575b50505091835250506002919091015460ff1615156020909101529050825b6116af8385611d10565b81101561175d57600260019054906101000a90046001600160a01b03166001600160a01b03166323b872dd3087856020015185815181106116f2576116f2611cfa565b60200260200101516040518463ffffffff1660e01b815260040161171893929190611cb9565b600060405180830381600087803b15801561173257600080fd5b505af1158015611746573d6000803e3d6000fd5b50505050808061175590611d23565b9150506116a5565b505061176860018055565b505050565b611775611889565b6001600160a01b0381166117da5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610560565b61099d8161197f565b600054600160a01b900460ff1615610dce5760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610560565b6002600154036118825760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152606401610560565b6002600155565b6000546001600160a01b03163314610dce5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610560565b6118eb6117e3565b6000805460ff60a01b1916600160a01b1790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586119263390565b6040516001600160a01b03909116815260200160405180910390a1565b61194b6119cf565b6000805460ff60a01b191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa33611926565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600054600160a01b900460ff16610dce5760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b6044820152606401610560565b80356001600160a01b0381168114611a3657600080fd5b919050565b600060208284031215611a4d57600080fd5b61052882611a1f565b60008060208385031215611a6957600080fd5b823567ffffffffffffffff80821115611a8157600080fd5b818501915085601f830112611a9557600080fd5b813581811115611aa457600080fd5b8660208260051b8501011115611ab957600080fd5b60209290920196919550909350505050565b600080600080600060808688031215611ae357600080fd5b611aec86611a1f565b9450611afa60208701611a1f565b935060408601359250606086013567ffffffffffffffff80821115611b1e57600080fd5b818801915088601f830112611b3257600080fd5b813581811115611b4157600080fd5b896020828501011115611b5357600080fd5b9699959850939650602001949392505050565b801515811461099d57600080fd5b600060208284031215611b8657600080fd5b813561052881611b66565b600060208284031215611ba357600080fd5b5035919050565b6020808252825182820181905260009190848201906040850190845b81811015611be257835183529284019291840191600101611bc6565b50909695505050505050565b600080600060608486031215611c0357600080fd5b611c0c84611a1f565b95602085013595506040909401359392505050565b634e487b7160e01b600052601160045260246000fd5b8082028115828204841417611c4e57611c4e611c21565b92915050565b600082611c7157634e487b7160e01b600052601260045260246000fd5b500490565b60208082526023908201527f43616e6e6f74207374616b65206265666f7265206465706f73697420737461726040820152621d195960ea1b606082015260800190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b600060208284031215611cef57600080fd5b815161052881611b66565b634e487b7160e01b600052603260045260246000fd5b80820180821115611c4e57611c4e611c21565b600060018201611d3557611d35611c21565b5060010190565b838152604060208201819052810182905260006001600160fb1b03831115611d6357600080fd5b8260051b8085606085013791909101606001949350505050565b6020808252601e908201527f43616e6e6f74207472616e7366657220746f6b656e7320746f20757365720000604082015260600190565b60208082526015908201527414995cd8dd59481a5cc81b9bdd08195b98589b1959605a1b604082015260600190565b600060208284031215611df557600080fd5b5051919050565b81810381811115611c4e57611c4e611c2156fea264697066735822122034ee9a70b928bc4864cb6c264cf5af134f3d9b7e33fe17054ec902c2d689f32d64736f6c6343000813003300000000000000000000000027c283475ed9524a43b795cdcaf9e3d177a35e0000000000000000000000000062d04c79c1f3a2d7230ffcd3ab01794e1d153239
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106102105760003560e01c8063750142e611610125578063986b048a116100ad578063c6a0479d1161007c578063c6a0479d146104a0578063d198ce6a146104a8578063d44c73d4146104c8578063f2fde38b146104db578063f4bf4dfe146104ee57600080fd5b8063986b048a146104555780639d76ea5814610467578063b99a7a431461047a578063c54704e61461048d57600080fd5b80637f4ca1d7116100f45780637f4ca1d7146103d3578063817b1cd2146103e6578063890acf93146103ef5780638a65d874146104025780638da5cb5b1461044457600080fd5b8063750142e61461039a57806376531008146103ad578063788074ec146103c05780637e818976146103c957600080fd5b80634599fef6116101a857806361e34acc1161017757806361e34acc1461035957806362c7fa761461036c57806363d8840014610375578063715018a614610389578063742b1ae91461039157600080fd5b80634599fef6146103065780634e71d92d1461030f5780635bf8633a146103175780635c975abb1461034757600080fd5b806316934fc4116101e457806316934fc41461028457806316c38b3c146102c3578063292d5d77146102d657806339db714f146102e957600080fd5b80628cc262146102155780630f35f76e1461023b5780630fbf0a9314610243578063150b7a0214610258575b600080fd5b610228610223366004611a3b565b6104f6565b6040519081526020015b60405180910390f35b610228606481565b610256610251366004611a56565b61052f565b005b61026b610266366004611acb565b61090d565b6040516001600160e01b03199091168152602001610232565b6102ae610292366004611a3b565b6009602052600090815260409020805460029091015460ff1682565b60408051928352901515602083015201610232565b6102566102d1366004611b74565b610987565b6102286102e4366004611a3b565b6109a8565b6002546102f69060ff1681565b6040519015158152602001610232565b61022860075481565b610256610a96565b60025461032f9061010090046001600160a01b031681565b6040516001600160a01b039091168152602001610232565b600054600160a01b900460ff166102f6565b610256610367366004611b91565b610dd0565b61022860045481565b6003546102f690600160a01b900460ff1681565b610256610e99565b6102286101f481565b6102286b06765c793fa10079d000000081565b6102566103bb366004611b74565b610eab565b61022860065481565b610228620d2f0081565b6102286103e1366004611b91565b610ec6565b61022860055481565b6102566103fd366004611b74565b611112565b610415610410366004611a3b565b611138565b6040805196875260208701959095529385019290925260608401526080830152151560a082015260c001610232565b6000546001600160a01b031661032f565b6102286a084595161401484a00000081565b60035461032f906001600160a01b031681565b610256610488366004611a3b565b611296565b61025661049b366004611b91565b611462565b61022860c881565b6104bb6104b6366004611a3b565b611544565b6040516102329190611baa565b6102566104d6366004611bee565b6115df565b6102566104e9366004611a3b565b61176d565b610228607d81565b600080610502836109a8565b60075490915061051e6b06765c793fa10079d000000083611c37565b6105289190611c54565b9392505050565b6105376117e3565b600354600160a01b900460ff166105695760405162461bcd60e51b815260040161056090611c76565b60405180910390fd5b42600454116105ba5760405162461bcd60e51b815260206004820152601f60248201527f43616e6e6f74207374616b65206166746572206c6f636b2073746172746564006044820152606401610560565b6105c2611830565b806106055760405162461bcd60e51b815260206004820152601360248201527243616e6e6f74207374616b652030204e46547360681b6044820152606401610560565b600061061c826a084595161401484a000000611c37565b336000818152600960205260409081902060035491516323b872dd60e01b8152939450926001600160a01b03909116916323b872dd91610663919030908790600401611cb9565b6020604051808303816000875af1158015610682573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106a69190611cdd565b5060005b8381101561087357600860008686848181106106c8576106c8611cfa565b602090810292909201358352508101919091526040016000205460ff16156107325760405162461bcd60e51b815260206004820152601f60248201527f43616e6e6f74207374616b65207468652073616d65204e4654207477696365006044820152606401610560565b60025461010090046001600160a01b03166323b872dd333088888681811061075c5761075c611cfa565b905060200201356040518463ffffffff1660e01b815260040161078193929190611cb9565b600060405180830381600087803b15801561079b57600080fd5b505af11580156107af573d6000803e3d6000fd5b50505050816001018585838181106107c9576107c9611cfa565b835460018181018655600095865260208087209302949094013591015550906008908787858181106107fd576107fd611cfa565b90506020020135815260200190815260200160002060006101000a81548160ff02191690831515021790555061084a85858381811061083e5761083e611cfa565b90506020020135610ec6565b6007600082825461085b9190611d10565b9091555081905061086b81611d23565b9150506106aa565b50818160000160008282546108889190611d10565b9250508190555081600560008282546108a19190611d10565b9091555050600680548491906000906108bb908490611d10565b909155505060405133907fb18ab713c223cf8d1394fb3018faad3e87f34414cc9d74b6eff3510d05359d85906108f690859088908890611d3c565b60405180910390a2505061090960018055565b5050565b60006001600160a01b038516156109755760405162461bcd60e51b815260206004820152602660248201527f43616e6e6f742073656e6420746f6b656e73206469726563746c7920746f207460448201526568652062617960d01b6064820152608401610560565b50630a85bd0160e11b95945050505050565b61098f611889565b80156109a05761099d6118e3565b50565b61099d611943565b6001600160a01b0381166000908152600960209081526040808320815160608101835281548152600182018054845181870281018701909552808552869592948584019390929190830182828015610a1f57602002820191906000526020600020905b815481526020019060010190808311610a0b575b50505091835250506002919091015460ff161515602090910152905060005b816020015151811015610a8f57610a7182602001518281518110610a6457610a64611cfa565b6020026020010151610ec6565b610a7b9084611d10565b925080610a8781611d23565b915050610a3e565b5050919050565b610a9e6117e3565b42620d2f00600454610ab09190611d10565b10610afd5760405162461bcd60e51b815260206004820152601d60248201527f43616e6e6f7420636c61696d20647572696e67206c6f636b2074696d650000006044820152606401610560565b610b05611830565b3360009081526009602090815260408083208151606081018352815481526001820180548451818702810187019095528085529194929385840193909290830182828015610b7257602002820191906000526020600020905b815481526020019060010190808311610b5e575b50505091835250506002919091015460ff1615156020909101528051909150610bdd5760405162461bcd60e51b815260206004820152601b60248201527f43616e6e6f7420636c61696d206265666f7265207374616b696e6700000000006044820152606401610560565b806040015115610c245760405162461bcd60e51b815260206004820152601260248201527143616e6e6f7420636c61696d20747769636560701b6044820152606401610560565b6001604082015260005b816020015151811015610cd45760025461010090046001600160a01b03166323b872dd303385602001518581518110610c6957610c69611cfa565b60200260200101516040518463ffffffff1660e01b8152600401610c8f93929190611cb9565b600060405180830381600087803b158015610ca957600080fd5b505af1158015610cbd573d6000803e3d6000fd5b505050508080610ccc90611d23565b915050610c2e565b506000610ce0336104f6565b8251610cec9190611d10565b6003549091506001600160a01b031663a9059cbb336040516001600160e01b031960e084901b1681526001600160a01b039091166004820152602481018490526044016020604051808303816000875af1158015610d4e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d729190611cdd565b610d8e5760405162461bcd60e51b815260040161056090611d7d565b60405181815233907fd8138f8a3f377c5259ca548e70e4c2de94f129f5a11036a15b69513cba2b426a9060200160405180910390a25050610dce60018055565b565b610dd8611889565b60025460ff16610dfa5760405162461bcd60e51b815260040161056090611db4565b6003546001600160a01b031663a9059cbb336040516001600160e01b031960e084901b1681526001600160a01b039091166004820152602481018490526044016020604051808303816000875af1158015610e59573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e7d9190611cdd565b61099d5760405162461bcd60e51b815260040161056090611d7d565b610ea1611889565b610dce600061197f565b610eb3611889565b6002805460ff1916911515919091179055565b60025460405163677dfd1b60e11b81526004810183905260009161010090046001600160a01b0316908290829063cefbfa3690602401602060405180830381865afa158015610f19573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f3d9190611de3565b9050816001600160a01b031663339a1dbd6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610f7d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fa19190611de3565b8103610fb1575060649392505050565b816001600160a01b03166343d678626040518163ffffffff1660e01b8152600401602060405180830381865afa158015610fef573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110139190611de3565b81036110235750607d9392505050565b816001600160a01b03166360ab1f076040518163ffffffff1660e01b8152600401602060405180830381865afa158015611061573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110859190611de3565b8103611095575060c89392505050565b816001600160a01b031663e0c2f0b86040518163ffffffff1660e01b8152600401602060405180830381865afa1580156110d3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110f79190611de3565b810361110857506101f49392505050565b5060649392505050565b61111a611889565b60038054911515600160a01b0260ff60a01b19909216919091179055565b600080600080600080600060096000896001600160a01b03166001600160a01b0316815260200190815260200160002060405180606001604052908160008201548152602001600182018054806020026020016040519081016040528092919081815260200182805480156111cc57602002820191906000526020600020905b8154815260200190600101908083116111b8575b50505091835250506002919091015460ff161515602091820152810151518151909850965090506111fc886109a8565b60075490955061120e86612710611c37565b6112189190611c54565b9350600042600454111561122e57506000611260565b42620d2f006004546112409190611d10565b10156112505750620d2f00611260565b60045461125d9042611dfc565b90505b620d2f008161126e8b6104f6565b6112789190611c37565b6112829190611c54565b935081604001519250505091939550919395565b61129e6117e3565b60025460ff166112c05760405162461bcd60e51b815260040161056090611db4565b6112c8611830565b6001600160a01b0381166000908152600960209081526040808320815160608101835281548152600182018054845181870281018701909552808552919492938584019390929083018282801561133e57602002820191906000526020600020905b81548152602001906001019080831161132a575b50505091835250506002919091015460ff1615156020909101526040810151909150156113b95760405162461bcd60e51b815260206004820152602360248201527f43616e6e6f742072657363756520746f6b656e7320616674657220636c61696d604482015262696e6760e81b6064820152608401610560565b60016040828101919091526003548251915163a9059cbb60e01b81526001600160a01b038581166004830152602482019390935291169063a9059cbb906044016020604051808303816000875af1158015611418573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061143c9190611cdd565b6114585760405162461bcd60e51b815260040161056090611d7d565b5061099d60018055565b600354600160a01b900460ff1661148b5760405162461bcd60e51b815260040161056090611c76565b42600454116114dc5760405162461bcd60e51b815260206004820152601f60248201527f43616e6e6f74207374616b65206166746572206c6f636b2073746172746564006044820152606401610560565b6114e4611889565b42811161153f5760405162461bcd60e51b815260206004820152602360248201527f43616e6e6f74207365742074696d65206265666f72652063757272656e742074604482015262696d6560e81b6064820152608401610560565b600455565b6001600160a01b0381166000908152600960209081526040808320815160608181018452825482526001830180548551818802810188019096528086529196959294858401939092908301828280156115bc57602002820191906000526020600020905b8154815260200190600101908083116115a8575b50505091835250506002919091015460ff16151560209182015201519392505050565b6115e76117e3565b60025460ff166116095760405162461bcd60e51b815260040161056090611db4565b611611611830565b6001600160a01b0383166000908152600960209081526040808320815160608101835281548152600182018054845181870281018701909552808552919492938584019390929083018282801561168757602002820191906000526020600020905b815481526020019060010190808311611673575b50505091835250506002919091015460ff1615156020909101529050825b6116af8385611d10565b81101561175d57600260019054906101000a90046001600160a01b03166001600160a01b03166323b872dd3087856020015185815181106116f2576116f2611cfa565b60200260200101516040518463ffffffff1660e01b815260040161171893929190611cb9565b600060405180830381600087803b15801561173257600080fd5b505af1158015611746573d6000803e3d6000fd5b50505050808061175590611d23565b9150506116a5565b505061176860018055565b505050565b611775611889565b6001600160a01b0381166117da5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610560565b61099d8161197f565b600054600160a01b900460ff1615610dce5760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610560565b6002600154036118825760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152606401610560565b6002600155565b6000546001600160a01b03163314610dce5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610560565b6118eb6117e3565b6000805460ff60a01b1916600160a01b1790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586119263390565b6040516001600160a01b03909116815260200160405180910390a1565b61194b6119cf565b6000805460ff60a01b191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa33611926565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600054600160a01b900460ff16610dce5760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b6044820152606401610560565b80356001600160a01b0381168114611a3657600080fd5b919050565b600060208284031215611a4d57600080fd5b61052882611a1f565b60008060208385031215611a6957600080fd5b823567ffffffffffffffff80821115611a8157600080fd5b818501915085601f830112611a9557600080fd5b813581811115611aa457600080fd5b8660208260051b8501011115611ab957600080fd5b60209290920196919550909350505050565b600080600080600060808688031215611ae357600080fd5b611aec86611a1f565b9450611afa60208701611a1f565b935060408601359250606086013567ffffffffffffffff80821115611b1e57600080fd5b818801915088601f830112611b3257600080fd5b813581811115611b4157600080fd5b896020828501011115611b5357600080fd5b9699959850939650602001949392505050565b801515811461099d57600080fd5b600060208284031215611b8657600080fd5b813561052881611b66565b600060208284031215611ba357600080fd5b5035919050565b6020808252825182820181905260009190848201906040850190845b81811015611be257835183529284019291840191600101611bc6565b50909695505050505050565b600080600060608486031215611c0357600080fd5b611c0c84611a1f565b95602085013595506040909401359392505050565b634e487b7160e01b600052601160045260246000fd5b8082028115828204841417611c4e57611c4e611c21565b92915050565b600082611c7157634e487b7160e01b600052601260045260246000fd5b500490565b60208082526023908201527f43616e6e6f74207374616b65206265666f7265206465706f73697420737461726040820152621d195960ea1b606082015260800190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b600060208284031215611cef57600080fd5b815161052881611b66565b634e487b7160e01b600052603260045260246000fd5b80820180821115611c4e57611c4e611c21565b600060018201611d3557611d35611c21565b5060010190565b838152604060208201819052810182905260006001600160fb1b03831115611d6357600080fd5b8260051b8085606085013791909101606001949350505050565b6020808252601e908201527f43616e6e6f74207472616e7366657220746f6b656e7320746f20757365720000604082015260600190565b60208082526015908201527414995cd8dd59481a5cc81b9bdd08195b98589b1959605a1b604082015260600190565b600060208284031215611df557600080fd5b5051919050565b81810381811115611c4e57611c4e611c2156fea264697066735822122034ee9a70b928bc4864cb6c264cf5af134f3d9b7e33fe17054ec902c2d689f32d64736f6c63430008130033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000027c283475ed9524a43b795cdcaf9e3d177a35e0000000000000000000000000062d04c79c1f3a2d7230ffcd3ab01794e1d153239
-----Decoded View---------------
Arg [0] : _nftAddress (address): 0x27c283475Ed9524A43b795CDCAF9e3D177a35e00
Arg [1] : _tokenAddress (address): 0x62D04C79C1F3a2d7230FFCd3Ab01794e1d153239
-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 00000000000000000000000027c283475ed9524a43b795cdcaf9e3d177a35e00
Arg [1] : 00000000000000000000000062d04c79c1f3a2d7230ffcd3ab01794e1d153239
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.