Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 1,607 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Claim Event Rewa... | 16328177 | 761 days ago | IN | 0 ETH | 0.00168469 | ||||
Claim Event Rewa... | 16175569 | 783 days ago | IN | 0 ETH | 0.00186209 | ||||
Claim Event Rewa... | 15760688 | 841 days ago | IN | 0 ETH | 0.00105375 | ||||
Claim Event Rewa... | 15623389 | 860 days ago | IN | 0 ETH | 0.00197468 | ||||
Claim Event Rewa... | 15558127 | 869 days ago | IN | 0 ETH | 0.0004325 | ||||
Claim Event Rewa... | 15553793 | 870 days ago | IN | 0 ETH | 0.00048672 | ||||
Claim Event Rewa... | 15553770 | 870 days ago | IN | 0 ETH | 0.00064081 | ||||
Claim Event Rewa... | 15551277 | 870 days ago | IN | 0 ETH | 0.00062704 | ||||
Claim Event Rewa... | 15550615 | 870 days ago | IN | 0 ETH | 0.00070119 | ||||
Claim Event Rewa... | 15549249 | 870 days ago | IN | 0 ETH | 0.00047002 | ||||
Claim Event Rewa... | 15549163 | 870 days ago | IN | 0 ETH | 0.00083668 | ||||
Claim Event Rewa... | 15548936 | 870 days ago | IN | 0 ETH | 0.00330893 | ||||
Claim Event Rewa... | 15548665 | 870 days ago | IN | 0 ETH | 0.00324951 | ||||
Claim Event Rewa... | 15548664 | 870 days ago | IN | 0 ETH | 0.00312865 | ||||
Claim Event Rewa... | 15506312 | 877 days ago | IN | 0 ETH | 0.00067636 | ||||
Claim Event Rewa... | 15485443 | 881 days ago | IN | 0 ETH | 0.00833957 | ||||
Claim Event Rewa... | 15427957 | 890 days ago | IN | 0 ETH | 0.00090887 | ||||
Claim Event Rewa... | 15410379 | 893 days ago | IN | 0 ETH | 0.00214132 | ||||
Claim Event Rewa... | 15369302 | 899 days ago | IN | 0 ETH | 0.00099522 | ||||
Claim Event Rewa... | 15335735 | 904 days ago | IN | 0 ETH | 0.00106194 | ||||
Claim Event Rewa... | 15329144 | 905 days ago | IN | 0 ETH | 0.00098789 | ||||
Claim Event Rewa... | 15310387 | 908 days ago | IN | 0 ETH | 0.00118784 | ||||
Claim Event Rewa... | 15309889 | 908 days ago | IN | 0 ETH | 0.00170217 | ||||
Claim Event Rewa... | 15309070 | 909 days ago | IN | 0 ETH | 0.0027241 | ||||
Claim Event Rewa... | 15308711 | 909 days ago | IN | 0 ETH | 0.00735812 |
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Source Code Verified (Exact Match)
Contract Name:
Wormhole
Compiler Version
v0.8.7+commit.e28d00a7
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.7; import "@openzeppelin/contracts/token/ERC20/extensions/ERC20Burnable.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "@openzeppelin/contracts/utils/math/Math.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.sol"; import "@openzeppelin/contracts/utils/structs/EnumerableSet.sol"; import "./Interfaces.sol"; contract Wormhole is Ownable { using EnumerableSet for EnumerableSet.UintSet; struct SalvageEvent { uint64 id; uint64 startBlock; uint64 endBlock; uint64 rngSeed; uint16 genesisCount; uint16 babiesCount; } address public genesisAddress; address public babiesAddress; address public cheethAddress; address public rewardAddress; uint16 public genesisSalvageEventReward; uint16 public babiesSalvageEventReward; mapping(uint64 => SalvageEvent) public salvageEvents; mapping(address => mapping(uint256 => uint256[])) public ownerBabiesByEvent; mapping(address => mapping(uint256 => uint256[])) public ownerGenesisByEvent; mapping(uint64 => EnumerableSet.UintSet) private _salvageEventBabies; mapping(uint64 => EnumerableSet.UintSet) private _salvageEventGenesis; mapping(address => EnumerableSet.UintSet) private _unclaimedEvents; function joinEvent( uint64 id, uint256[] calldata babiesIds, uint256[] calldata genesisIds ) external { SalvageEvent storage salvageEvent = salvageEvents[id]; require(block.number < salvageEvent.startBlock, "already started"); uint256 totalCheeth = (babiesIds.length + genesisIds.length) * 250; ERC20Burnable(cheethAddress).transferFrom(msg.sender, address(this), totalCheeth * 1 ether); salvageEvent.babiesCount += uint16(babiesIds.length); salvageEvent.genesisCount += uint16(genesisIds.length); _unclaimedEvents[msg.sender].add(id); for (uint256 index = 0; index < babiesIds.length; index++) { uint256 mouseId = babiesIds[index]; require(_ownerOfToken(mouseId, babiesAddress) == msg.sender, "not allowed"); require(!_salvageEventBabies[id].contains(mouseId), "already in event"); _salvageEventBabies[id].add(mouseId); ownerBabiesByEvent[msg.sender][id].push(mouseId); } for (uint256 index = 0; index < genesisIds.length; index++) { uint256 mouseId = genesisIds[index]; require(_ownerOfToken(mouseId, genesisAddress) == msg.sender, "not allowed"); require(!_salvageEventGenesis[id].contains(mouseId), "already in event"); _salvageEventGenesis[id].add(mouseId); ownerGenesisByEvent[msg.sender][id].push(mouseId); } } function _ownerOfToken(uint256 tokenId, address tokenAddress) internal view returns (address) { return IERC721Enumerable(tokenAddress).ownerOf(tokenId); } function claimEventReward(uint64 id) external { require(!_getIsEventClaimed(id, msg.sender), "already claimed"); uint64 eventReward = _getEventReward(id, msg.sender); RewardLike(rewardAddress).mintMany(msg.sender, eventReward); _markClaimedEvent(id, msg.sender); } // // ADMIN FUNCTIONS function setAddresses( address _babiesAddress, address _genesisAddress, address _cheethAddress, address _rewardAddress ) external onlyOwner { babiesAddress = _babiesAddress; genesisAddress = _genesisAddress; cheethAddress = _cheethAddress; rewardAddress = _rewardAddress; } function setGenesisSalvageEventReward(uint16 _genesisSalvageEventReward) external onlyOwner { genesisSalvageEventReward = _genesisSalvageEventReward; } function setBabiesSalvageEventReward(uint16 _babiesSalvageEventReward) external onlyOwner { babiesSalvageEventReward = _babiesSalvageEventReward; } function registerSalvageEvent(uint64 id, uint64 startBlock) external onlyOwner { require(id > 0, "invalid id"); salvageEvents[id].id = id; salvageEvents[id].startBlock = startBlock; } function startSalvageEvent( uint64 id, uint64 endBlock, uint64 rngSeed ) external onlyOwner { require(id > 0, "invalid id"); salvageEvents[id].id = id; salvageEvents[id].endBlock = endBlock; salvageEvents[id].rngSeed = rngSeed; } function withdraw(address to) external onlyOwner { ERC20Burnable(cheethAddress).transfer(to, ERC20Burnable(cheethAddress).balanceOf(address(this))); } // // GETTERS function getClaimableEventRewards(uint64 id, address wallet) external view returns (uint64) { if (_getIsEventClaimed(id, wallet)) { return 0; } return _getEventReward(id, wallet); } function getEventReward(uint64 id, address wallet) external view returns (uint64) { return _getEventReward(id, wallet); } function getEventMice(uint64 id, address wallet) external view returns (uint256[] memory genesis, uint256[] memory babies) { genesis = ownerGenesisByEvent[wallet][id]; babies = ownerBabiesByEvent[wallet][id]; } // // PRIVATE function _getEventReward(uint64 id, address wallet) internal view returns (uint64) { SalvageEvent memory salvageEvent = salvageEvents[id]; require(block.number > salvageEvent.startBlock, "not started"); require(block.number > salvageEvent.endBlock, "not finished"); uint256[] memory eventBabies = ownerBabiesByEvent[wallet][id]; uint256[] memory eventGenesis = ownerGenesisByEvent[wallet][id]; uint256 baseProbability; uint256 additionalProbability; (baseProbability, additionalProbability) = _eventRewardProbabilities(id, false); uint16 rewardCount; uint256 mouseId; for (uint256 index = 0; index < eventBabies.length; index++) { mouseId = eventBabies[index]; if (_ownerOfToken(mouseId, babiesAddress) != wallet) { continue; } if (_rand(salvageEvent.rngSeed, 10000 + mouseId, id, 1, wallet) < baseProbability) { rewardCount++; } if (_rand(salvageEvent.rngSeed, 10000 + mouseId, id, 2, wallet) < additionalProbability) { rewardCount++; } } (baseProbability, additionalProbability) = _eventRewardProbabilities(id, true); for (uint256 index = 0; index < eventGenesis.length; index++) { mouseId = eventGenesis[index]; if (_ownerOfToken(mouseId, genesisAddress) != wallet) continue; if (_rand(salvageEvent.rngSeed, mouseId, id, 1, wallet) < baseProbability) { rewardCount++; } if (_rand(salvageEvent.rngSeed, mouseId, id, 2, wallet) < additionalProbability) { rewardCount++; } } return rewardCount; } function _eventRewardProbabilities(uint64 id, bool isGenesis) internal view returns (uint256, uint256) { uint256 rewardsCount = isGenesis ? genesisSalvageEventReward : babiesSalvageEventReward; uint16 eventSize = isGenesis ? salvageEvents[id].genesisCount : salvageEvents[id].babiesCount; if (eventSize == 0) return (0, 0); uint256 base = (rewardsCount * 100) / eventSize; uint256 additional; if (rewardsCount > eventSize) { uint256 remainingRewards = rewardsCount - eventSize; additional = (remainingRewards * 100) / eventSize; } return (base, additional); } function _getIsEventClaimed(uint64 id, address player) internal view returns (bool) { return !_unclaimedEvents[player].contains(id); } function _markClaimedEvent(uint64 id, address player) internal { _unclaimedEvents[player].remove(id); } // returns a random number in between 0 and 99 (0 and 99 are valid outputs) function _rand( uint64 randomness, uint256 mouseId, uint64 eventId, uint8 nonce, address wallet ) internal pure returns (uint256) { return uint256(keccak256(abi.encodePacked(wallet, randomness, mouseId, eventId, nonce))) % 100; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/ERC20Burnable.sol) pragma solidity ^0.8.0; import "../ERC20.sol"; import "../../../utils/Context.sol"; /** * @dev Extension of {ERC20} that allows token holders to destroy both their own * tokens and those that they have an allowance for, in a way that can be * recognized off-chain (via event analysis). */ abstract contract ERC20Burnable is Context, ERC20 { /** * @dev Destroys `amount` tokens from the caller. * * See {ERC20-_burn}. */ function burn(uint256 amount) public virtual { _burn(_msgSender(), amount); } /** * @dev Destroys `amount` tokens from `account`, deducting from the caller's * allowance. * * See {ERC20-_burn} and {ERC20-allowance}. * * Requirements: * * - the caller must have allowance for ``accounts``'s tokens of at least * `amount`. */ function burnFrom(address account, uint256 amount) public virtual { uint256 currentAllowance = allowance(account, _msgSender()); require(currentAllowance >= amount, "ERC20: burn amount exceeds allowance"); unchecked { _approve(account, _msgSender(), currentAllowance - amount); } _burn(account, amount); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (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 Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { require(owner() == _msgSender(), "Ownable: caller is not the owner"); _; } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _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); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/math/SafeMath.sol) pragma solidity ^0.8.0; // CAUTION // This version of SafeMath should only be used with Solidity 0.8 or later, // because it relies on the compiler's built in overflow checks. /** * @dev Wrappers over Solidity's arithmetic operations. * * NOTE: `SafeMath` is generally not needed starting with Solidity 0.8, since the compiler * now has built in overflow checking. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { uint256 c = a + b; if (c < a) return (false, 0); return (true, c); } } /** * @dev Returns the substraction of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b > a) return (false, 0); return (true, a - b); } } /** * @dev Returns the multiplication of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) return (true, 0); uint256 c = a * b; if (c / a != b) return (false, 0); return (true, c); } } /** * @dev Returns the division of two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a / b); } } /** * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a % b); } } /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { return a + b; } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { return a - b; } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { return a * b; } /** * @dev Returns the integer division of two unsigned integers, reverting on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { return a / b; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { return a % b; } /** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {trySub}. * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b <= a, errorMessage); return a - b; } } /** * @dev Returns the integer division of two unsigned integers, reverting with custom message on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a / b; } } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting with custom message when dividing by zero. * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {tryMod}. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a % b; } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/math/Math.sol) pragma solidity ^0.8.0; /** * @dev Standard math utilities missing in the Solidity language. */ library Math { /** * @dev Returns the largest of two numbers. */ function max(uint256 a, uint256 b) internal pure returns (uint256) { return a >= b ? a : b; } /** * @dev Returns the smallest of two numbers. */ function min(uint256 a, uint256 b) internal pure returns (uint256) { return a < b ? a : b; } /** * @dev Returns the average of two numbers. The result is rounded towards * zero. */ function average(uint256 a, uint256 b) internal pure returns (uint256) { // (a + b) / 2 can overflow. return (a & b) + (a ^ b) / 2; } /** * @dev Returns the ceiling of the division of two numbers. * * This differs from standard division with `/` in that it rounds up instead * of rounding down. */ function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) { // (a + b - 1) / b can overflow on addition, so we distribute. return a / b + (a % b == 0 ? 0 : 1); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Enumerable.sol) pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Enumerable is IERC721 { /** * @dev Returns the total amount of tokens stored by the contract. */ function totalSupply() external view returns (uint256); /** * @dev Returns a token ID owned by `owner` at a given `index` of its token list. * Use along with {balanceOf} to enumerate all of ``owner``'s tokens. */ function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256 tokenId); /** * @dev Returns a token ID at a given `index` of all the tokens stored by the contract. * Use along with {totalSupply} to enumerate all tokens. */ function tokenByIndex(uint256 index) external view returns (uint256); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/structs/EnumerableSet.sol) pragma solidity ^0.8.0; /** * @dev Library for managing * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive * types. * * Sets have the following properties: * * - Elements are added, removed, and checked for existence in constant time * (O(1)). * - Elements are enumerated in O(n). No guarantees are made on the ordering. * * ``` * contract Example { * // Add the library methods * using EnumerableSet for EnumerableSet.AddressSet; * * // Declare a set state variable * EnumerableSet.AddressSet private mySet; * } * ``` * * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`) * and `uint256` (`UintSet`) are supported. */ library EnumerableSet { // To implement this library for multiple types with as little code // repetition as possible, we write it in terms of a generic Set type with // bytes32 values. // The Set implementation uses private functions, and user-facing // implementations (such as AddressSet) are just wrappers around the // underlying Set. // This means that we can only create new EnumerableSets for types that fit // in bytes32. struct Set { // Storage of set values bytes32[] _values; // Position of the value in the `values` array, plus 1 because index 0 // means a value is not in the set. mapping(bytes32 => uint256) _indexes; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function _add(Set storage set, bytes32 value) private returns (bool) { if (!_contains(set, value)) { set._values.push(value); // The value is stored at length-1, but we add 1 to all indexes // and use 0 as a sentinel value set._indexes[value] = set._values.length; return true; } else { return false; } } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function _remove(Set storage set, bytes32 value) private returns (bool) { // We read and store the value's index to prevent multiple reads from the same storage slot uint256 valueIndex = set._indexes[value]; if (valueIndex != 0) { // Equivalent to contains(set, value) // To delete an element from the _values array in O(1), we swap the element to delete with the last one in // the array, and then remove the last element (sometimes called as 'swap and pop'). // This modifies the order of the array, as noted in {at}. uint256 toDeleteIndex = valueIndex - 1; uint256 lastIndex = set._values.length - 1; if (lastIndex != toDeleteIndex) { bytes32 lastvalue = set._values[lastIndex]; // Move the last value to the index where the value to delete is set._values[toDeleteIndex] = lastvalue; // Update the index for the moved value set._indexes[lastvalue] = valueIndex; // Replace lastvalue's index to valueIndex } // Delete the slot where the moved value was stored set._values.pop(); // Delete the index for the deleted slot delete set._indexes[value]; return true; } else { return false; } } /** * @dev Returns true if the value is in the set. O(1). */ function _contains(Set storage set, bytes32 value) private view returns (bool) { return set._indexes[value] != 0; } /** * @dev Returns the number of values on the set. O(1). */ function _length(Set storage set) private view returns (uint256) { return set._values.length; } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function _at(Set storage set, uint256 index) private view returns (bytes32) { return set._values[index]; } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function _values(Set storage set) private view returns (bytes32[] memory) { return set._values; } // Bytes32Set struct Bytes32Set { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(Bytes32Set storage set, bytes32 value) internal returns (bool) { return _add(set._inner, value); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) { return _remove(set._inner, value); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) { return _contains(set._inner, value); } /** * @dev Returns the number of values in the set. O(1). */ function length(Bytes32Set storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) { return _at(set._inner, index); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(Bytes32Set storage set) internal view returns (bytes32[] memory) { return _values(set._inner); } // AddressSet struct AddressSet { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(AddressSet storage set, address value) internal returns (bool) { return _add(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(AddressSet storage set, address value) internal returns (bool) { return _remove(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(AddressSet storage set, address value) internal view returns (bool) { return _contains(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Returns the number of values in the set. O(1). */ function length(AddressSet storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(AddressSet storage set, uint256 index) internal view returns (address) { return address(uint160(uint256(_at(set._inner, index)))); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(AddressSet storage set) internal view returns (address[] memory) { bytes32[] memory store = _values(set._inner); address[] memory result; assembly { result := store } return result; } // UintSet struct UintSet { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(UintSet storage set, uint256 value) internal returns (bool) { return _add(set._inner, bytes32(value)); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(UintSet storage set, uint256 value) internal returns (bool) { return _remove(set._inner, bytes32(value)); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(UintSet storage set, uint256 value) internal view returns (bool) { return _contains(set._inner, bytes32(value)); } /** * @dev Returns the number of values on the set. O(1). */ function length(UintSet storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(UintSet storage set, uint256 index) internal view returns (uint256) { return uint256(_at(set._inner, index)); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(UintSet storage set) internal view returns (uint256[] memory) { bytes32[] memory store = _values(set._inner); uint256[] memory result; assembly { result := store } return result; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.7; interface RewardLike { function mintMany(address to, uint256 amount) external; } interface IDNAChip is RewardLike { function tokenIdToTraits(uint256 tokenId) external view returns (uint256); function isEvolutionPod(uint256 tokenId) external view returns (bool); function breedingIdToEvolutionPod(uint256 tokenId) external view returns (uint256); } interface IDescriptor { function tokenURI(uint256 _tokenId) external view returns (string memory); function tokenBreedingURI(uint256 _tokenId, uint256 _breedingId) external view returns (string memory); } interface IEvolutionTraits { function getDNAChipSVG(uint256 base) external view returns (string memory); function getEvolutionPodImageTag(uint256 base) external view returns (string memory); function getTraitsImageTags(uint8[8] memory traits) external view returns (string memory); function getMetadata(uint8[8] memory traits) external view returns (string memory); } interface IERC721Like { function transferFrom( address from, address to, uint256 id ) external; function transfer(address to, uint256 id) external; function ownerOf(uint256 id) external returns (address owner); function mint(address to, uint256 tokenid) external; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/ERC20.sol) pragma solidity ^0.8.0; import "./IERC20.sol"; import "./extensions/IERC20Metadata.sol"; import "../../utils/Context.sol"; /** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our guide * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How * to implement supply mechanisms]. * * We have followed general OpenZeppelin Contracts guidelines: functions revert * instead returning `false` on failure. This behavior is nonetheless * conventional and does not conflict with the expectations of ERC20 * applications. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to reconstruct the allowance for all accounts just * by listening to said events. Other implementations of the EIP may not emit * these events, as it isn't required by the specification. * * Finally, the non-standard {decreaseAllowance} and {increaseAllowance} * functions have been added to mitigate the well-known issues around setting * allowances. See {IERC20-approve}. */ contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {name} and {symbol}. * * The default value of {decimals} is 18. To select a different value for * {decimals} you should overload it. * * All two of these values are immutable: they can only be set once during * construction. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev Returns the name of the token. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev Returns the symbol of the token, usually a shorter version of the * name. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev Returns the number of decimals used to get its user representation. * For example, if `decimals` equals `2`, a balance of `505` tokens should * be displayed to a user as `5.05` (`505 / 10 ** 2`). * * Tokens usually opt for a value of 18, imitating the relationship between * Ether and Wei. This is the value {ERC20} uses, unless this function is * overridden; * * NOTE: This information is only used for _display_ purposes: it in * no way affects any of the arithmetic of the contract, including * {IERC20-balanceOf} and {IERC20-transfer}. */ function decimals() public view virtual override returns (uint8) { return 18; } /** * @dev See {IERC20-totalSupply}. */ function totalSupply() public view virtual override returns (uint256) { return _totalSupply; } /** * @dev See {IERC20-balanceOf}. */ function balanceOf(address account) public view virtual override returns (uint256) { return _balances[account]; } /** * @dev See {IERC20-transfer}. * * Requirements: * * - `recipient` cannot be the zero address. * - the caller must have a balance of at least `amount`. */ function transfer(address recipient, uint256 amount) public virtual override returns (bool) { _transfer(_msgSender(), recipient, amount); return true; } /** * @dev See {IERC20-allowance}. */ function allowance(address owner, address spender) public view virtual override returns (uint256) { return _allowances[owner][spender]; } /** * @dev See {IERC20-approve}. * * Requirements: * * - `spender` cannot be the zero address. */ function approve(address spender, uint256 amount) public virtual override returns (bool) { _approve(_msgSender(), spender, amount); return true; } /** * @dev See {IERC20-transferFrom}. * * Emits an {Approval} event indicating the updated allowance. This is not * required by the EIP. See the note at the beginning of {ERC20}. * * Requirements: * * - `sender` and `recipient` cannot be the zero address. * - `sender` must have a balance of at least `amount`. * - the caller must have allowance for ``sender``'s tokens of at least * `amount`. */ function transferFrom( address sender, address recipient, uint256 amount ) public virtual override returns (bool) { _transfer(sender, recipient, amount); uint256 currentAllowance = _allowances[sender][_msgSender()]; require(currentAllowance >= amount, "ERC20: transfer amount exceeds allowance"); unchecked { _approve(sender, _msgSender(), currentAllowance - amount); } return true; } /** * @dev Atomically increases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - `spender` cannot be the zero address. */ function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) { _approve(_msgSender(), spender, _allowances[_msgSender()][spender] + addedValue); return true; } /** * @dev Atomically decreases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - `spender` cannot be the zero address. * - `spender` must have allowance for the caller of at least * `subtractedValue`. */ function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) { uint256 currentAllowance = _allowances[_msgSender()][spender]; require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero"); unchecked { _approve(_msgSender(), spender, currentAllowance - subtractedValue); } return true; } /** * @dev Moves `amount` of tokens from `sender` to `recipient`. * * This internal function is equivalent to {transfer}, and can be used to * e.g. implement automatic token fees, slashing mechanisms, etc. * * Emits a {Transfer} event. * * Requirements: * * - `sender` cannot be the zero address. * - `recipient` cannot be the zero address. * - `sender` must have a balance of at least `amount`. */ function _transfer( address sender, address recipient, uint256 amount ) internal virtual { require(sender != address(0), "ERC20: transfer from the zero address"); require(recipient != address(0), "ERC20: transfer to the zero address"); _beforeTokenTransfer(sender, recipient, amount); uint256 senderBalance = _balances[sender]; require(senderBalance >= amount, "ERC20: transfer amount exceeds balance"); unchecked { _balances[sender] = senderBalance - amount; } _balances[recipient] += amount; emit Transfer(sender, recipient, amount); _afterTokenTransfer(sender, recipient, amount); } /** @dev Creates `amount` tokens and assigns them to `account`, increasing * the total supply. * * Emits a {Transfer} event with `from` set to the zero address. * * Requirements: * * - `account` cannot be the zero address. */ function _mint(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: mint to the zero address"); _beforeTokenTransfer(address(0), account, amount); _totalSupply += amount; _balances[account] += amount; emit Transfer(address(0), account, amount); _afterTokenTransfer(address(0), account, amount); } /** * @dev Destroys `amount` tokens from `account`, reducing the * total supply. * * Emits a {Transfer} event with `to` set to the zero address. * * Requirements: * * - `account` cannot be the zero address. * - `account` must have at least `amount` tokens. */ function _burn(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: burn from the zero address"); _beforeTokenTransfer(account, address(0), amount); uint256 accountBalance = _balances[account]; require(accountBalance >= amount, "ERC20: burn amount exceeds balance"); unchecked { _balances[account] = accountBalance - amount; } _totalSupply -= amount; emit Transfer(account, address(0), amount); _afterTokenTransfer(account, address(0), amount); } /** * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens. * * This internal function is equivalent to `approve`, and can be used to * e.g. set automatic allowances for certain subsystems, etc. * * Emits an {Approval} event. * * Requirements: * * - `owner` cannot be the zero address. * - `spender` cannot be the zero address. */ function _approve( address owner, address spender, uint256 amount ) internal virtual { require(owner != address(0), "ERC20: approve from the zero address"); require(spender != address(0), "ERC20: approve to the zero address"); _allowances[owner][spender] = amount; emit Approval(owner, spender, amount); } /** * @dev Hook that is called before any transfer of tokens. This includes * minting and burning. * * Calling conditions: * * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens * will be transferred to `to`. * - when `from` is zero, `amount` tokens will be minted for `to`. * - when `to` is zero, `amount` of ``from``'s tokens will be burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 amount ) internal virtual {} /** * @dev Hook that is called after any transfer of tokens. This includes * minting and burning. * * Calling conditions: * * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens * has been transferred to `to`. * - when `from` is zero, `amount` tokens have been minted for `to`. * - when `to` is zero, `amount` of ``from``'s tokens have been burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _afterTokenTransfer( address from, address to, uint256 amount ) internal virtual {} }
// 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 v4.4.1 (token/ERC20/IERC20.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address recipient, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom( address sender, address recipient, uint256 amount ) external returns (bool); /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol) pragma solidity ^0.8.0; import "../IERC20.sol"; /** * @dev Interface for the optional metadata functions from the ERC20 standard. * * _Available since v4.1._ */ interface IERC20Metadata is IERC20 { /** * @dev Returns the name of the token. */ function name() external view returns (string memory); /** * @dev Returns the symbol of the token. */ function symbol() external view returns (string memory); /** * @dev Returns the decimals places of the token. */ function decimals() external view returns (uint8); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (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`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool _approved) external; /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */ function isApprovedForAll(address owner, address operator) external view returns (bool); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external; }
// 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); }
{ "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[],"name":"babiesAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"babiesSalvageEventReward","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"cheethAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"id","type":"uint64"}],"name":"claimEventReward","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"genesisAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"genesisSalvageEventReward","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"id","type":"uint64"},{"internalType":"address","name":"wallet","type":"address"}],"name":"getClaimableEventRewards","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"id","type":"uint64"},{"internalType":"address","name":"wallet","type":"address"}],"name":"getEventMice","outputs":[{"internalType":"uint256[]","name":"genesis","type":"uint256[]"},{"internalType":"uint256[]","name":"babies","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"id","type":"uint64"},{"internalType":"address","name":"wallet","type":"address"}],"name":"getEventReward","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"id","type":"uint64"},{"internalType":"uint256[]","name":"babiesIds","type":"uint256[]"},{"internalType":"uint256[]","name":"genesisIds","type":"uint256[]"}],"name":"joinEvent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"ownerBabiesByEvent","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"ownerGenesisByEvent","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"id","type":"uint64"},{"internalType":"uint64","name":"startBlock","type":"uint64"}],"name":"registerSalvageEvent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rewardAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"","type":"uint64"}],"name":"salvageEvents","outputs":[{"internalType":"uint64","name":"id","type":"uint64"},{"internalType":"uint64","name":"startBlock","type":"uint64"},{"internalType":"uint64","name":"endBlock","type":"uint64"},{"internalType":"uint64","name":"rngSeed","type":"uint64"},{"internalType":"uint16","name":"genesisCount","type":"uint16"},{"internalType":"uint16","name":"babiesCount","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_babiesAddress","type":"address"},{"internalType":"address","name":"_genesisAddress","type":"address"},{"internalType":"address","name":"_cheethAddress","type":"address"},{"internalType":"address","name":"_rewardAddress","type":"address"}],"name":"setAddresses","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint16","name":"_babiesSalvageEventReward","type":"uint16"}],"name":"setBabiesSalvageEventReward","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint16","name":"_genesisSalvageEventReward","type":"uint16"}],"name":"setGenesisSalvageEventReward","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint64","name":"id","type":"uint64"},{"internalType":"uint64","name":"endBlock","type":"uint64"},{"internalType":"uint64","name":"rngSeed","type":"uint64"}],"name":"startSalvageEvent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
608060405234801561001057600080fd5b5061001a3361001f565b61006f565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b611c6f8061007e6000396000f3fe608060405234801561001057600080fd5b506004361061014d5760003560e01c80638cf57cb9116100c3578063c1603bdd1161007c578063c1603bdd14610370578063c3a92cfa1461039b578063e133a878146103b0578063ea51c0bd146103c3578063ee4be197146103d6578063f2fde38b146103e957600080fd5b80638cf57cb9146102eb5780638d1b54c5146102fe5780638da5cb5b146103115780639ff2c0c714610322578063af52438e14610335578063be032bd41461034857600080fd5b806351cff8d91161011557806351cff8d9146101d85780636065fb33146101eb5780636f730e3014610216578063715018a614610229578063742ba24914610231578063742ef0331461024457600080fd5b80632590422f146101525780633ff4973c1461016757806345c7fd74146101915780634a945f8d146101a45780634d153cfc146101b7575b600080fd5b61016561016036600461195f565b6103fc565b005b61017a610175366004611928565b61087b565b604051610188929190611a90565b60405180910390f35b61016561019f366004611a12565b610978565b6101656101b236600461181d565b610a4c565b6101ca6101c5366004611879565b610ac6565b604051908152602001610188565b6101656101e63660046117dc565b610b04565b6001546101fe906001600160a01b031681565b6040516001600160a01b039091168152602001610188565b6002546101fe906001600160a01b031681565b610165610c35565b61016561023f3660046118d0565b610c6b565b6102a561025236600461190d565b600560205260009081526040902080546001909101546001600160401b0380831692600160401b8104821692600160801b8204831692600160c01b9092049091169061ffff808216916201000090041686565b604080516001600160401b0397881681529587166020870152938616938501939093529316606083015261ffff92831660808301529190911660a082015260c001610188565b6004546101fe906001600160a01b031681565b61016561030c3660046118d0565b610cb7565b6000546001600160a01b03166101fe565b6003546101fe906001600160a01b031681565b6101656103433660046119df565b610d03565b60045461035d90600160a01b900461ffff1681565b60405161ffff9091168152602001610188565b61038361037e366004611928565b610db3565b6040516001600160401b039091168152602001610188565b60045461035d90600160b01b900461ffff1681565b6101656103be36600461190d565b610dc8565b6103836103d1366004611928565b610e99565b6101ca6103e4366004611879565b610ebc565b6101656103f73660046117dc565b610ee4565b6001600160401b03808616600090815260056020526040902080549091600160401b9091041643106104675760405162461bcd60e51b815260206004820152600f60248201526e185b1c9958591e481cdd185c9d1959608a1b60448201526064015b60405180910390fd5b60006104738386611b19565b61047e9060fa611b45565b6003549091506001600160a01b03166323b872dd33306104a685670de0b6b3a7640000611b45565b6040516001600160e01b031960e086901b1681526001600160a01b0393841660048201529290911660248301526044820152606401602060405180830381600087803b1580156104f557600080fd5b505af1158015610509573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061052d91906118ae565b5060018201805486919060029061054f90849062010000900461ffff16611af3565b92506101000a81548161ffff021916908361ffff160217905550838390508260010160008282829054906101000a900461ffff1661058d9190611af3565b825461ffff9182166101009390930a928302919092021990911617905550336000908152600a602052604090206105cd906001600160401b038916610f7f565b5060005b8581101561071f5760008787838181106105ed576105ed611c0e565b6002546020909102929092013592503391610613915083906001600160a01b0316610f8b565b6001600160a01b0316146106575760405162461bcd60e51b815260206004820152600b60248201526a1b9bdd08185b1b1bddd95960aa1b604482015260640161045e565b6001600160401b03891660009081526008602052604090206106799082611006565b156106b95760405162461bcd60e51b815260206004820152601060248201526f185b1c9958591e481a5b88195d995b9d60821b604482015260640161045e565b6001600160401b03891660009081526008602052604090206106db9082610f7f565b503360009081526006602090815260408083206001600160401b038d168452825282208054600181018255908352912001558061071781611b9d565b9150506105d1565b5060005b8381101561087157600085858381811061073f5761073f611c0e565b6001546020909102929092013592503391610765915083906001600160a01b0316610f8b565b6001600160a01b0316146107a95760405162461bcd60e51b815260206004820152600b60248201526a1b9bdd08185b1b1bddd95960aa1b604482015260640161045e565b6001600160401b03891660009081526009602052604090206107cb9082611006565b1561080b5760405162461bcd60e51b815260206004820152601060248201526f185b1c9958591e481a5b88195d995b9d60821b604482015260640161045e565b6001600160401b038916600090815260096020526040902061082d9082610f7f565b503360009081526007602090815260408083206001600160401b038d168452825282208054600181018255908352912001558061086981611b9d565b915050610723565b5050505050505050565b6001600160a01b03811660009081526007602090815260408083206001600160401b038616845282529182902080548351818402810184019094528084526060938493909291908301828280156108f157602002820191906000526020600020905b8154815260200190600101908083116108dd575b505050506001600160a01b03851660009081526006602090815260408083206001600160401b038a1684528252918290208054835181840281018401909452808452949650919391925083018282801561096a57602002820191906000526020600020905b815481526020019060010190808311610956575b505050505090509250929050565b6000546001600160a01b031633146109a25760405162461bcd60e51b815260040161045e90611abe565b6000836001600160401b0316116109e85760405162461bcd60e51b815260206004820152600a6024820152691a5b9d985b1a59081a5960b21b604482015260640161045e565b6001600160401b039283166000818152600560205260409020805477ffffffffffffffff0000000000000000ffffffffffffffff1916909117600160801b93851693909302929092176001600160c01b0316600160c01b9190931602919091179055565b6000546001600160a01b03163314610a765760405162461bcd60e51b815260040161045e90611abe565b600280546001600160a01b039586166001600160a01b0319918216179091556001805494861694821694909417909355600380549285169284169290921790915560048054919093169116179055565b60076020528260005260406000206020528160005260406000208181548110610aee57600080fd5b9060005260206000200160009250925050505481565b6000546001600160a01b03163314610b2e5760405162461bcd60e51b815260040161045e90611abe565b6003546040516370a0823160e01b81523060048201526001600160a01b039091169063a9059cbb90839083906370a082319060240160206040518083038186803b158015610b7b57600080fd5b505afa158015610b8f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bb391906118f4565b6040516001600160e01b031960e085901b1681526001600160a01b0390921660048301526024820152604401602060405180830381600087803b158015610bf957600080fd5b505af1158015610c0d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c3191906118ae565b5050565b6000546001600160a01b03163314610c5f5760405162461bcd60e51b815260040161045e90611abe565b610c69600061101e565b565b6000546001600160a01b03163314610c955760405162461bcd60e51b815260040161045e90611abe565b6004805461ffff909216600160b01b0261ffff60b01b19909216919091179055565b6000546001600160a01b03163314610ce15760405162461bcd60e51b815260040161045e90611abe565b6004805461ffff909216600160a01b0261ffff60a01b19909216919091179055565b6000546001600160a01b03163314610d2d5760405162461bcd60e51b815260040161045e90611abe565b6000826001600160401b031611610d735760405162461bcd60e51b815260206004820152600a6024820152691a5b9d985b1a59081a5960b21b604482015260640161045e565b6001600160401b039182166000818152600560205260409020805492909316600160401b026fffffffffffffffffffffffffffffffff1990921617179055565b6000610dbf838361106e565b90505b92915050565b610dd2813361143b565b15610e115760405162461bcd60e51b815260206004820152600f60248201526e185b1c9958591e4818db185a5b5959608a1b604482015260640161045e565b6000610e1d823361106e565b60048054604051632f41832b60e11b815233928101929092526001600160401b03831660248301529192506001600160a01b0390911690635e83065690604401600060405180830381600087803b158015610e7757600080fd5b505af1158015610e8b573d6000803e3d6000fd5b50505050610c31823361146e565b6000610ea5838361143b565b15610eb257506000610dc2565b610dbf838361106e565b60066020528260005260406000206020528160005260406000208181548110610aee57600080fd5b6000546001600160a01b03163314610f0e5760405162461bcd60e51b815260040161045e90611abe565b6001600160a01b038116610f735760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161045e565b610f7c8161101e565b50565b6000610dbf838361149e565b6040516331a9108f60e11b8152600481018390526000906001600160a01b03831690636352211e9060240160206040518083038186803b158015610fce57600080fd5b505afa158015610fe2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610dbf9190611800565b60008181526001830160205260408120541515610dbf565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6001600160401b038083166000908152600560209081526040808320815160c08101835281548087168252600160401b81048716948201859052600160801b8104871693820193909352600160c01b909204909416606082015260019093015461ffff8082166080860152620100009091041660a084015290919043116111255760405162461bcd60e51b815260206004820152600b60248201526a1b9bdd081cdd185c9d195960aa1b604482015260640161045e565b80604001516001600160401b031643116111705760405162461bcd60e51b815260206004820152600c60248201526b1b9bdd08199a5b9a5cda195960a21b604482015260640161045e565b6001600160a01b03831660009081526006602090815260408083206001600160401b03881684528252808320805482518185028101850190935280835291929091908301828280156111e157602002820191906000526020600020905b8154815260200190600101908083116111cd575b505050506001600160a01b03861660009081526007602090815260408083206001600160401b038b1684528252808320805482518185028101850190935280835295965092949093509083018282801561125a57602002820191906000526020600020905b815481526020019060010190808311611246575b5050505050905060008061126f8860006114ed565b9092509050600080805b86518110156113545786818151811061129457611294611c0e565b60200260200101519150896001600160a01b03166112c783600260009054906101000a90046001600160a01b0316610f8b565b6001600160a01b0316146112da57611342565b846112fa8960600151846127106112f19190611b19565b8e60018f6115f6565b101561130e578261130a81611b7b565b9350505b8361132e8960600151846127106113259190611b19565b8e60028f6115f6565b1015611342578261133e81611b7b565b9350505b8061134c81611b9d565b915050611279565b506113608a60016114ed565b909450925060005b85518110156114295785818151811061138357611383611c0e565b60200260200101519150896001600160a01b03166113b683600160009054906101000a90046001600160a01b0316610f8b565b6001600160a01b0316146113c957611417565b846113dc8960600151848e60018f6115f6565b10156113f057826113ec81611b7b565b9350505b836114038960600151848e60028f6115f6565b1015611417578261141381611b7b565b9350505b8061142181611b9d565b915050611368565b505061ffff1698975050505050505050565b6001600160a01b0381166000908152600a60205260408120611466906001600160401b038516611006565b159392505050565b6001600160a01b0381166000908152600a60205260409020611499906001600160401b038416611682565b505050565b60008181526001830160205260408120546114e557508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610dc2565b506000610dc2565b60008060008361150a57600454600160b01b900461ffff16611519565b600454600160a01b900461ffff165b61ffff169050600084611551576001600160401b03861660009081526005602052604090206001015462010000900461ffff16611572565b6001600160401b03861660009081526005602052604090206001015461ffff165b905061ffff811661158b576000809350935050506115ef565b600061ffff821661159d846064611b45565b6115a79190611b31565b905060008261ffff168411156115e75760006115c761ffff851686611b64565b905061ffff84166115d9826064611b45565b6115e39190611b31565b9150505b909450925050505b9250929050565b6040516bffffffffffffffffffffffff19606083901b1660208201526001600160c01b031960c087811b82166034840152603c830187905285901b16605c8201526001600160f81b031960f884901b166064828101919091526000916065016040516020818303038152906040528051906020012060001c6116789190611bb8565b9695505050505050565b6000610dbf8383600081815260018301602052604081205480156117725760006116ad600183611b64565b85549091506000906116c190600190611b64565b90508181146117265760008660000182815481106116e1576116e1611c0e565b906000526020600020015490508087600001848154811061170457611704611c0e565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061173757611737611bf8565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610dc2565b6000915050610dc2565b60008083601f84011261178e57600080fd5b5081356001600160401b038111156117a557600080fd5b6020830191508360208260051b85010111156115ef57600080fd5b80356001600160401b03811681146117d757600080fd5b919050565b6000602082840312156117ee57600080fd5b81356117f981611c24565b9392505050565b60006020828403121561181257600080fd5b81516117f981611c24565b6000806000806080858703121561183357600080fd5b843561183e81611c24565b9350602085013561184e81611c24565b9250604085013561185e81611c24565b9150606085013561186e81611c24565b939692955090935050565b60008060006060848603121561188e57600080fd5b833561189981611c24565b95602085013595506040909401359392505050565b6000602082840312156118c057600080fd5b815180151581146117f957600080fd5b6000602082840312156118e257600080fd5b813561ffff811681146117f957600080fd5b60006020828403121561190657600080fd5b5051919050565b60006020828403121561191f57600080fd5b610dbf826117c0565b6000806040838503121561193b57600080fd5b611944836117c0565b9150602083013561195481611c24565b809150509250929050565b60008060008060006060868803121561197757600080fd5b611980866117c0565b945060208601356001600160401b038082111561199c57600080fd5b6119a889838a0161177c565b909650945060408801359150808211156119c157600080fd5b506119ce8882890161177c565b969995985093965092949392505050565b600080604083850312156119f257600080fd5b6119fb836117c0565b9150611a09602084016117c0565b90509250929050565b600080600060608486031215611a2757600080fd5b611a30846117c0565b9250611a3e602085016117c0565b9150611a4c604085016117c0565b90509250925092565b600081518084526020808501945080840160005b83811015611a8557815187529582019590820190600101611a69565b509495945050505050565b604081526000611aa36040830185611a55565b8281036020840152611ab58185611a55565b95945050505050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b600061ffff808316818516808303821115611b1057611b10611bcc565b01949350505050565b60008219821115611b2c57611b2c611bcc565b500190565b600082611b4057611b40611be2565b500490565b6000816000190483118215151615611b5f57611b5f611bcc565b500290565b600082821015611b7657611b76611bcc565b500390565b600061ffff80831681811415611b9357611b93611bcc565b6001019392505050565b6000600019821415611bb157611bb1611bcc565b5060010190565b600082611bc757611bc7611be2565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b6001600160a01b0381168114610f7c57600080fdfea26469706673582212206b7b8b402b033815da349c34141f5174a924c7088746b722367dab60d35e48b964736f6c63430008070033
Deployed Bytecode
0x608060405234801561001057600080fd5b506004361061014d5760003560e01c80638cf57cb9116100c3578063c1603bdd1161007c578063c1603bdd14610370578063c3a92cfa1461039b578063e133a878146103b0578063ea51c0bd146103c3578063ee4be197146103d6578063f2fde38b146103e957600080fd5b80638cf57cb9146102eb5780638d1b54c5146102fe5780638da5cb5b146103115780639ff2c0c714610322578063af52438e14610335578063be032bd41461034857600080fd5b806351cff8d91161011557806351cff8d9146101d85780636065fb33146101eb5780636f730e3014610216578063715018a614610229578063742ba24914610231578063742ef0331461024457600080fd5b80632590422f146101525780633ff4973c1461016757806345c7fd74146101915780634a945f8d146101a45780634d153cfc146101b7575b600080fd5b61016561016036600461195f565b6103fc565b005b61017a610175366004611928565b61087b565b604051610188929190611a90565b60405180910390f35b61016561019f366004611a12565b610978565b6101656101b236600461181d565b610a4c565b6101ca6101c5366004611879565b610ac6565b604051908152602001610188565b6101656101e63660046117dc565b610b04565b6001546101fe906001600160a01b031681565b6040516001600160a01b039091168152602001610188565b6002546101fe906001600160a01b031681565b610165610c35565b61016561023f3660046118d0565b610c6b565b6102a561025236600461190d565b600560205260009081526040902080546001909101546001600160401b0380831692600160401b8104821692600160801b8204831692600160c01b9092049091169061ffff808216916201000090041686565b604080516001600160401b0397881681529587166020870152938616938501939093529316606083015261ffff92831660808301529190911660a082015260c001610188565b6004546101fe906001600160a01b031681565b61016561030c3660046118d0565b610cb7565b6000546001600160a01b03166101fe565b6003546101fe906001600160a01b031681565b6101656103433660046119df565b610d03565b60045461035d90600160a01b900461ffff1681565b60405161ffff9091168152602001610188565b61038361037e366004611928565b610db3565b6040516001600160401b039091168152602001610188565b60045461035d90600160b01b900461ffff1681565b6101656103be36600461190d565b610dc8565b6103836103d1366004611928565b610e99565b6101ca6103e4366004611879565b610ebc565b6101656103f73660046117dc565b610ee4565b6001600160401b03808616600090815260056020526040902080549091600160401b9091041643106104675760405162461bcd60e51b815260206004820152600f60248201526e185b1c9958591e481cdd185c9d1959608a1b60448201526064015b60405180910390fd5b60006104738386611b19565b61047e9060fa611b45565b6003549091506001600160a01b03166323b872dd33306104a685670de0b6b3a7640000611b45565b6040516001600160e01b031960e086901b1681526001600160a01b0393841660048201529290911660248301526044820152606401602060405180830381600087803b1580156104f557600080fd5b505af1158015610509573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061052d91906118ae565b5060018201805486919060029061054f90849062010000900461ffff16611af3565b92506101000a81548161ffff021916908361ffff160217905550838390508260010160008282829054906101000a900461ffff1661058d9190611af3565b825461ffff9182166101009390930a928302919092021990911617905550336000908152600a602052604090206105cd906001600160401b038916610f7f565b5060005b8581101561071f5760008787838181106105ed576105ed611c0e565b6002546020909102929092013592503391610613915083906001600160a01b0316610f8b565b6001600160a01b0316146106575760405162461bcd60e51b815260206004820152600b60248201526a1b9bdd08185b1b1bddd95960aa1b604482015260640161045e565b6001600160401b03891660009081526008602052604090206106799082611006565b156106b95760405162461bcd60e51b815260206004820152601060248201526f185b1c9958591e481a5b88195d995b9d60821b604482015260640161045e565b6001600160401b03891660009081526008602052604090206106db9082610f7f565b503360009081526006602090815260408083206001600160401b038d168452825282208054600181018255908352912001558061071781611b9d565b9150506105d1565b5060005b8381101561087157600085858381811061073f5761073f611c0e565b6001546020909102929092013592503391610765915083906001600160a01b0316610f8b565b6001600160a01b0316146107a95760405162461bcd60e51b815260206004820152600b60248201526a1b9bdd08185b1b1bddd95960aa1b604482015260640161045e565b6001600160401b03891660009081526009602052604090206107cb9082611006565b1561080b5760405162461bcd60e51b815260206004820152601060248201526f185b1c9958591e481a5b88195d995b9d60821b604482015260640161045e565b6001600160401b038916600090815260096020526040902061082d9082610f7f565b503360009081526007602090815260408083206001600160401b038d168452825282208054600181018255908352912001558061086981611b9d565b915050610723565b5050505050505050565b6001600160a01b03811660009081526007602090815260408083206001600160401b038616845282529182902080548351818402810184019094528084526060938493909291908301828280156108f157602002820191906000526020600020905b8154815260200190600101908083116108dd575b505050506001600160a01b03851660009081526006602090815260408083206001600160401b038a1684528252918290208054835181840281018401909452808452949650919391925083018282801561096a57602002820191906000526020600020905b815481526020019060010190808311610956575b505050505090509250929050565b6000546001600160a01b031633146109a25760405162461bcd60e51b815260040161045e90611abe565b6000836001600160401b0316116109e85760405162461bcd60e51b815260206004820152600a6024820152691a5b9d985b1a59081a5960b21b604482015260640161045e565b6001600160401b039283166000818152600560205260409020805477ffffffffffffffff0000000000000000ffffffffffffffff1916909117600160801b93851693909302929092176001600160c01b0316600160c01b9190931602919091179055565b6000546001600160a01b03163314610a765760405162461bcd60e51b815260040161045e90611abe565b600280546001600160a01b039586166001600160a01b0319918216179091556001805494861694821694909417909355600380549285169284169290921790915560048054919093169116179055565b60076020528260005260406000206020528160005260406000208181548110610aee57600080fd5b9060005260206000200160009250925050505481565b6000546001600160a01b03163314610b2e5760405162461bcd60e51b815260040161045e90611abe565b6003546040516370a0823160e01b81523060048201526001600160a01b039091169063a9059cbb90839083906370a082319060240160206040518083038186803b158015610b7b57600080fd5b505afa158015610b8f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bb391906118f4565b6040516001600160e01b031960e085901b1681526001600160a01b0390921660048301526024820152604401602060405180830381600087803b158015610bf957600080fd5b505af1158015610c0d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c3191906118ae565b5050565b6000546001600160a01b03163314610c5f5760405162461bcd60e51b815260040161045e90611abe565b610c69600061101e565b565b6000546001600160a01b03163314610c955760405162461bcd60e51b815260040161045e90611abe565b6004805461ffff909216600160b01b0261ffff60b01b19909216919091179055565b6000546001600160a01b03163314610ce15760405162461bcd60e51b815260040161045e90611abe565b6004805461ffff909216600160a01b0261ffff60a01b19909216919091179055565b6000546001600160a01b03163314610d2d5760405162461bcd60e51b815260040161045e90611abe565b6000826001600160401b031611610d735760405162461bcd60e51b815260206004820152600a6024820152691a5b9d985b1a59081a5960b21b604482015260640161045e565b6001600160401b039182166000818152600560205260409020805492909316600160401b026fffffffffffffffffffffffffffffffff1990921617179055565b6000610dbf838361106e565b90505b92915050565b610dd2813361143b565b15610e115760405162461bcd60e51b815260206004820152600f60248201526e185b1c9958591e4818db185a5b5959608a1b604482015260640161045e565b6000610e1d823361106e565b60048054604051632f41832b60e11b815233928101929092526001600160401b03831660248301529192506001600160a01b0390911690635e83065690604401600060405180830381600087803b158015610e7757600080fd5b505af1158015610e8b573d6000803e3d6000fd5b50505050610c31823361146e565b6000610ea5838361143b565b15610eb257506000610dc2565b610dbf838361106e565b60066020528260005260406000206020528160005260406000208181548110610aee57600080fd5b6000546001600160a01b03163314610f0e5760405162461bcd60e51b815260040161045e90611abe565b6001600160a01b038116610f735760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161045e565b610f7c8161101e565b50565b6000610dbf838361149e565b6040516331a9108f60e11b8152600481018390526000906001600160a01b03831690636352211e9060240160206040518083038186803b158015610fce57600080fd5b505afa158015610fe2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610dbf9190611800565b60008181526001830160205260408120541515610dbf565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6001600160401b038083166000908152600560209081526040808320815160c08101835281548087168252600160401b81048716948201859052600160801b8104871693820193909352600160c01b909204909416606082015260019093015461ffff8082166080860152620100009091041660a084015290919043116111255760405162461bcd60e51b815260206004820152600b60248201526a1b9bdd081cdd185c9d195960aa1b604482015260640161045e565b80604001516001600160401b031643116111705760405162461bcd60e51b815260206004820152600c60248201526b1b9bdd08199a5b9a5cda195960a21b604482015260640161045e565b6001600160a01b03831660009081526006602090815260408083206001600160401b03881684528252808320805482518185028101850190935280835291929091908301828280156111e157602002820191906000526020600020905b8154815260200190600101908083116111cd575b505050506001600160a01b03861660009081526007602090815260408083206001600160401b038b1684528252808320805482518185028101850190935280835295965092949093509083018282801561125a57602002820191906000526020600020905b815481526020019060010190808311611246575b5050505050905060008061126f8860006114ed565b9092509050600080805b86518110156113545786818151811061129457611294611c0e565b60200260200101519150896001600160a01b03166112c783600260009054906101000a90046001600160a01b0316610f8b565b6001600160a01b0316146112da57611342565b846112fa8960600151846127106112f19190611b19565b8e60018f6115f6565b101561130e578261130a81611b7b565b9350505b8361132e8960600151846127106113259190611b19565b8e60028f6115f6565b1015611342578261133e81611b7b565b9350505b8061134c81611b9d565b915050611279565b506113608a60016114ed565b909450925060005b85518110156114295785818151811061138357611383611c0e565b60200260200101519150896001600160a01b03166113b683600160009054906101000a90046001600160a01b0316610f8b565b6001600160a01b0316146113c957611417565b846113dc8960600151848e60018f6115f6565b10156113f057826113ec81611b7b565b9350505b836114038960600151848e60028f6115f6565b1015611417578261141381611b7b565b9350505b8061142181611b9d565b915050611368565b505061ffff1698975050505050505050565b6001600160a01b0381166000908152600a60205260408120611466906001600160401b038516611006565b159392505050565b6001600160a01b0381166000908152600a60205260409020611499906001600160401b038416611682565b505050565b60008181526001830160205260408120546114e557508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610dc2565b506000610dc2565b60008060008361150a57600454600160b01b900461ffff16611519565b600454600160a01b900461ffff165b61ffff169050600084611551576001600160401b03861660009081526005602052604090206001015462010000900461ffff16611572565b6001600160401b03861660009081526005602052604090206001015461ffff165b905061ffff811661158b576000809350935050506115ef565b600061ffff821661159d846064611b45565b6115a79190611b31565b905060008261ffff168411156115e75760006115c761ffff851686611b64565b905061ffff84166115d9826064611b45565b6115e39190611b31565b9150505b909450925050505b9250929050565b6040516bffffffffffffffffffffffff19606083901b1660208201526001600160c01b031960c087811b82166034840152603c830187905285901b16605c8201526001600160f81b031960f884901b166064828101919091526000916065016040516020818303038152906040528051906020012060001c6116789190611bb8565b9695505050505050565b6000610dbf8383600081815260018301602052604081205480156117725760006116ad600183611b64565b85549091506000906116c190600190611b64565b90508181146117265760008660000182815481106116e1576116e1611c0e565b906000526020600020015490508087600001848154811061170457611704611c0e565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061173757611737611bf8565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610dc2565b6000915050610dc2565b60008083601f84011261178e57600080fd5b5081356001600160401b038111156117a557600080fd5b6020830191508360208260051b85010111156115ef57600080fd5b80356001600160401b03811681146117d757600080fd5b919050565b6000602082840312156117ee57600080fd5b81356117f981611c24565b9392505050565b60006020828403121561181257600080fd5b81516117f981611c24565b6000806000806080858703121561183357600080fd5b843561183e81611c24565b9350602085013561184e81611c24565b9250604085013561185e81611c24565b9150606085013561186e81611c24565b939692955090935050565b60008060006060848603121561188e57600080fd5b833561189981611c24565b95602085013595506040909401359392505050565b6000602082840312156118c057600080fd5b815180151581146117f957600080fd5b6000602082840312156118e257600080fd5b813561ffff811681146117f957600080fd5b60006020828403121561190657600080fd5b5051919050565b60006020828403121561191f57600080fd5b610dbf826117c0565b6000806040838503121561193b57600080fd5b611944836117c0565b9150602083013561195481611c24565b809150509250929050565b60008060008060006060868803121561197757600080fd5b611980866117c0565b945060208601356001600160401b038082111561199c57600080fd5b6119a889838a0161177c565b909650945060408801359150808211156119c157600080fd5b506119ce8882890161177c565b969995985093965092949392505050565b600080604083850312156119f257600080fd5b6119fb836117c0565b9150611a09602084016117c0565b90509250929050565b600080600060608486031215611a2757600080fd5b611a30846117c0565b9250611a3e602085016117c0565b9150611a4c604085016117c0565b90509250925092565b600081518084526020808501945080840160005b83811015611a8557815187529582019590820190600101611a69565b509495945050505050565b604081526000611aa36040830185611a55565b8281036020840152611ab58185611a55565b95945050505050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b600061ffff808316818516808303821115611b1057611b10611bcc565b01949350505050565b60008219821115611b2c57611b2c611bcc565b500190565b600082611b4057611b40611be2565b500490565b6000816000190483118215151615611b5f57611b5f611bcc565b500290565b600082821015611b7657611b76611bcc565b500390565b600061ffff80831681811415611b9357611b93611bcc565b6001019392505050565b6000600019821415611bb157611bb1611bcc565b5060010190565b600082611bc757611bc7611be2565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b6001600160a01b0381168114610f7c57600080fdfea26469706673582212206b7b8b402b033815da349c34141f5174a924c7088746b722367dab60d35e48b964736f6c63430008070033
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.