ERC-721
Overview
Max Total Supply
7,905 WGAMEL2
Holders
145
Market
Onchain Market Cap
$0.00
Circulating Supply Market Cap
-
Other Info
Token Contract
Balance
1 WGAMEL2Loading...
Loading
Loading...
Loading
Loading...
Loading
Contract Name:
Woolf
Compiler Version
v0.8.0+commit.c7dfd78e
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT LICENSE pragma solidity ^0.8.0; import "./Ownable.sol"; import "./Pausable.sol"; import "./ERC721Enumerable.sol"; import "./IWoolf.sol"; import "./IBarn.sol"; import "./ITraits.sol"; import "./WOOL.sol"; import "./MILK.sol"; import "./IERC20.sol"; import "./Randomizer.sol"; contract Woolf is IWoolf, ERC721Enumerable, Ownable, Pausable { // mint price uint256 public MINT_PRICE = 36 ether; // max number of tokens that can be minted - 50000 in production uint256 public wool_price = 500000 ether; uint256 public weed_price = 5000 ether; uint256 public immutable MAX_TOKENS; // number of tokens that can be claimed for free - 20% of MAX_TOKENS uint256 public PAID_TOKENS; // number of tokens have been minted so far uint16 public minted; address public feeWallet = 0x588dd1F57a93e555B7cD4358cb8442f5Cac71FfC; // mapping from tokenId to a struct containing the token's traits mapping(uint256 => SheepWolf) public tokenTraits; // mapping from hashed(tokenTrait) to the tokenId it's associated with // used to ensure there are no duplicates mapping(uint256 => uint256) public existingCombinations; // list of probabilities for each trait type // 0 - 9 are associated with Sheep, 10 - 18 are associated with Wolves uint8[][18] public rarities; // list of aliases for Walker's Alias algorithm // 0 - 9 are associated with Sheep, 10 - 18 are associated with Wolves uint8[][18] public aliases; // reference to the Barn for choosing random Wolf thieves IBarn public barn; // reference to $WOOL for burning on mint WOOL public wool; MILK public milk; IERC20 public weed; // reference to Traits ITraits public traits; Randomizer public randomizer; /** * instantiates contract and rarity tables */ constructor( address _wool, address _milk, address _traits, uint256 _maxTokens ) ERC721("Wolf Game L2", "WGAMEL2") { wool = WOOL(_wool); milk = MILK(_milk); traits = ITraits(_traits); MAX_TOKENS = _maxTokens; PAID_TOKENS = _maxTokens / 5; // I know this looks weird but it saves users gas by making lookup O(1) // A.J. Walker's Alias Algorithm // sheep // fur rarities[0] = [15, 50, 200, 250, 255]; aliases[0] = [4, 4, 4, 4, 4]; // head rarities[1] = [ 190, 215, 240, 100, 110, 135, 160, 185, 80, 210, 235, 240, 80, 80, 100, 100, 100, 245, 250, 255 ]; aliases[1] = [ 1, 2, 4, 0, 5, 6, 7, 9, 0, 10, 11, 17, 0, 0, 0, 0, 4, 18, 19, 19 ]; // ears rarities[2] = [255, 30, 60, 60, 150, 156]; aliases[2] = [0, 0, 0, 0, 0, 0]; // eyes rarities[3] = [ 221, 100, 181, 140, 224, 147, 84, 228, 140, 224, 250, 160, 241, 207, 173, 84, 254, 220, 196, 140, 168, 252, 140, 183, 236, 252, 224, 255 ]; aliases[3] = [ 1, 2, 5, 0, 1, 7, 1, 10, 5, 10, 11, 12, 13, 14, 16, 11, 17, 23, 13, 14, 17, 23, 23, 24, 27, 27, 27, 27 ]; // nose rarities[4] = [175, 100, 40, 250, 115, 100, 185, 175, 180, 255]; aliases[4] = [3, 0, 4, 6, 6, 7, 8, 8, 9, 9]; // mouth rarities[5] = [ 80, 225, 227, 228, 112, 240, 64, 160, 167, 217, 171, 64, 240, 126, 80, 255 ]; aliases[5] = [1, 2, 3, 8, 2, 8, 8, 9, 9, 10, 13, 10, 13, 15, 13, 15]; // neck rarities[6] = [255]; aliases[6] = [0]; // feet rarities[7] = [ 243, 189, 133, 133, 57, 95, 152, 135, 133, 57, 222, 168, 57, 57, 38, 114, 114, 114, 255 ]; aliases[7] = [ 1, 7, 0, 0, 0, 0, 0, 10, 0, 0, 11, 18, 0, 0, 0, 1, 7, 11, 18 ]; // alphaIndex rarities[8] = [255]; aliases[8] = [0]; // wolves // fur rarities[9] = [210, 90, 9, 9, 9, 150, 9, 255, 9]; aliases[9] = [5, 0, 0, 5, 5, 7, 5, 7, 5]; // head rarities[10] = [255]; aliases[10] = [0]; // ears rarities[11] = [255]; aliases[11] = [0]; // eyes rarities[12] = [ 135, 177, 219, 141, 183, 225, 147, 189, 231, 135, 135, 135, 135, 246, 150, 150, 156, 165, 171, 180, 186, 195, 201, 210, 243, 252, 255 ]; aliases[12] = [ 1, 2, 3, 4, 5, 6, 7, 8, 13, 3, 6, 14, 15, 16, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 26, 26 ]; // nose rarities[13] = [255]; aliases[13] = [0]; // mouth rarities[14] = [ 239, 244, 249, 234, 234, 234, 234, 234, 234, 234, 130, 255, 247 ]; aliases[14] = [1, 2, 11, 0, 11, 11, 11, 11, 11, 11, 11, 11, 11]; // neck rarities[15] = [ 75, 180, 165, 120, 60, 150, 105, 195, 45, 225, 75, 45, 195, 120, 255 ]; aliases[15] = [1, 9, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 14, 12, 14]; // feet rarities[16] = [255]; aliases[16] = [0]; // alphaIndex rarities[17] = [8, 160, 73, 255]; aliases[17] = [2, 3, 3, 3]; } /** EXTERNAL */ /** * mint a token - 90% Sheep, 10% Wolves * The first 20% are free to claim, the remaining cost $WOOL */ /** 0 FTM 1 WOOL 2 WEED */ function mint( uint256 amount, bool stake, uint8 tokenType ) external payable whenNotPaused { require(tx.origin == _msgSender(), "Only EOA"); require(minted + amount <= MAX_TOKENS, "All tokens minted"); require(amount > 0 && amount <= 10, "Invalid mint amount"); if (tokenType == 0 && minted < PAID_TOKENS) { if (minted + amount <= PAID_TOKENS) { require(msg.value >= amount * MINT_PRICE, "not enought FTM"); } else { require( msg.value >= (amount + minted - PAID_TOKENS) * MINT_PRICE, "not enought FTM" ); } } uint256 totalWoolCost = 0; uint256 totalWeedCost = 0; uint256 totalMilkCost = 0; uint16[] memory tokenIds = stake ? new uint16[](amount) : new uint16[](0); uint256 seed; for (uint256 i = 0; i < amount; i++) { minted++; seed = randomizer.random(minted); generate(minted, seed); address recipient = selectRecipient(seed); if (!stake || recipient != _msgSender()) { _safeMint(recipient, minted); } else { _safeMint(address(barn), minted); tokenIds[i] = minted; } if (tokenType == 1 && minted < PAID_TOKENS) { totalWoolCost += wool_price; } else if (tokenType == 2 && minted < PAID_TOKENS) { totalWeedCost += weed_price; } totalMilkCost += mintCost(minted); } if (totalWoolCost > 0) wool.burn(_msgSender(), totalWoolCost); if (totalMilkCost > 0) milk.burn(_msgSender(), totalMilkCost); if (totalWeedCost > 0) weed.transferFrom(_msgSender(), address(this), totalWeedCost); if (stake) barn.addManyToBarnAndPack(_msgSender(), tokenIds); } /** * the first 20% are paid in ETH * the next 20% are 20000 $WOOL * the next 40% are 40000 $WOOL * the final 20% are 80000 $WOOL * @param tokenId the ID to check the cost of to mint * @return the cost of the given token ID */ function mintCost(uint256 tokenId) public view returns (uint256) { if (tokenId <= PAID_TOKENS) return 0; if (tokenId <= (MAX_TOKENS * 2) / 5) return 20000 ether; if (tokenId <= (MAX_TOKENS * 4) / 5) return 40000 ether; return 80000 ether; } function transferFrom( address from, address to, uint256 tokenId ) public virtual override { // Hardcode the Barn's approval so that users don't have to waste gas approving if (_msgSender() != address(barn)) require( _isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved" ); _transfer(from, to, tokenId); } /** INTERNAL */ /** * generates traits for a specific token, checking to make sure it's unique * @param tokenId the id of the token to generate traits for * @param seed a pseudorandom 256 bit number to derive traits from * @return t - a struct of traits for the given token ID */ function generate(uint256 tokenId, uint256 seed) internal returns (SheepWolf memory t) { t = selectTraits(seed); if (existingCombinations[structToHash(t)] == 0) { tokenTraits[tokenId] = t; existingCombinations[structToHash(t)] = tokenId; return t; } return generate(tokenId, randomizer.random(seed)); } /** * uses A.J. Walker's Alias algorithm for O(1) rarity table lookup * ensuring O(1) instead of O(n) reduces mint cost by more than 50% * probability & alias tables are generated off-chain beforehand * @param seed portion of the 256 bit seed to remove trait correlation * @param traitType the trait type to select a trait for * @return the ID of the randomly selected trait */ function selectTrait(uint16 seed, uint8 traitType) internal view returns (uint8) { uint8 trait = uint8(seed) % uint8(rarities[traitType].length); if (seed >> 8 < rarities[traitType][trait]) return trait; return aliases[traitType][trait]; } /** * the first 20% (ETH purchases) go to the minter * the remaining 80% have a 10% chance to be given to a random staked wolf * @param seed a random value to select a recipient from * @return the address of the recipient (either the minter or the Wolf thief's owner) */ function selectRecipient(uint256 seed) internal view returns (address) { if (minted <= PAID_TOKENS || ((seed >> 245) % 10) != 0) return _msgSender(); // top 10 bits haven't been used address thief = barn.randomWolfOwner(seed >> 144); // 144 bits reserved for trait selection if (thief == address(0x0)) return _msgSender(); return thief; } /** * selects the species and all of its traits based on the seed value * @param seed a pseudorandom 256 bit number to derive traits from * @return t - a struct of randomly selected traits */ function selectTraits(uint256 seed) internal view returns (SheepWolf memory t) { t.isSheep = (seed & 0xFFFF) % 10 != 0; uint8 shift = t.isSheep ? 0 : 9; seed >>= 16; t.fur = selectTrait(uint16(seed & 0xFFFF), 0 + shift); seed >>= 16; t.head = selectTrait(uint16(seed & 0xFFFF), 1 + shift); seed >>= 16; t.ears = selectTrait(uint16(seed & 0xFFFF), 2 + shift); seed >>= 16; t.eyes = selectTrait(uint16(seed & 0xFFFF), 3 + shift); seed >>= 16; t.nose = selectTrait(uint16(seed & 0xFFFF), 4 + shift); seed >>= 16; t.mouth = selectTrait(uint16(seed & 0xFFFF), 5 + shift); seed >>= 16; t.neck = selectTrait(uint16(seed & 0xFFFF), 6 + shift); seed >>= 16; t.feet = selectTrait(uint16(seed & 0xFFFF), 7 + shift); seed >>= 16; t.alphaIndex = selectTrait(uint16(seed & 0xFFFF), 8 + shift); } /** * converts a struct to a 256 bit hash to check for uniqueness * @param s the struct to pack into a hash * @return the 256 bit hash of the struct */ function structToHash(SheepWolf memory s) internal pure returns (uint256) { return uint256( keccak256( abi.encodePacked( s.isSheep, s.fur, s.head, s.eyes, s.mouth, s.neck, s.ears, s.feet, s.alphaIndex ) ) ); } /** READ */ function getTokenTraits(uint256 tokenId) external view override returns (SheepWolf memory) { return tokenTraits[tokenId]; } function getPaidTokens() external view override returns (uint256) { return PAID_TOKENS; } /** ADMIN */ /** * called after deployment so that the contract can get random wolf thieves * @param _barn the address of the Barn */ function setBarn(address _barn) external onlyOwner { barn = IBarn(_barn); } /** * allows owner to withdraw funds from minting */ function withdraw() external onlyOwner { payable(feeWallet).transfer(address(this).balance); } function setFeeWallet(address _feeWallet) external onlyOwner { feeWallet = _feeWallet; } /** * updates the number of tokens for sale */ function setPaidTokens(uint256 _paidTokens) external onlyOwner { PAID_TOKENS = _paidTokens; } /** * enables owner to pause / unpause minting */ function setPaused(bool _paused) external onlyOwner { if (_paused) _pause(); else _unpause(); } /** RENDER */ function setMintPrice(uint256 _price, uint256 tokenType) external onlyOwner { if (tokenType == 0) { MINT_PRICE = _price; } else if (tokenType == 1) { wool_price = _price; } else if (tokenType == 2) { weed_price = _price; } } function setWeed(address _weed) external onlyOwner { weed = IERC20(_weed); } function setWool(address _wool) external onlyOwner { wool = WOOL(_wool); } function setMilk(address _milk) external onlyOwner { milk = MILK(_milk); } function setRandomizer(address _randomizer) external onlyOwner { randomizer = Randomizer(_randomizer); } function tokenURI(uint256 tokenId) public view override returns (string memory) { require( _exists(tokenId), "ERC721Metadata: URI query for nonexistent token" ); return traits.tokenURI(tokenId); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./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() { _setOwner(_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 { _setOwner(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"); _setOwner(newOwner); } function _setOwner(address newOwner) private { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./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 Returns true if the contract is paused, and false otherwise. */ function paused() public view virtual returns (bool) { return _paused; } /** * @dev Modifier to make a function callable only when the contract is not paused. * * Requirements: * * - The contract must not be paused. */ modifier whenNotPaused() { require(!paused(), "Pausable: paused"); _; } /** * @dev Modifier to make a function callable only when the contract is paused. * * Requirements: * * - The contract must be paused. */ modifier whenPaused() { 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 pragma solidity ^0.8.0; import "./ERC721.sol"; import "./IERC721Enumerable.sol"; /** * @dev This implements an optional extension of {ERC721} defined in the EIP that adds * enumerability of all the token ids in the contract as well as all token ids owned by each * account. */ abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex; // Array with all token ids, used for enumeration uint256[] private _allTokens; // Mapping from token id to position in the allTokens array mapping(uint256 => uint256) private _allTokensIndex; /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) { return interfaceId == type(IERC721Enumerable).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}. */ function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual override returns (uint256) { require(index < ERC721.balanceOf(owner), "ERC721Enumerable: owner index out of bounds"); return _ownedTokens[owner][index]; } /** * @dev See {IERC721Enumerable-totalSupply}. */ function totalSupply() public view virtual override returns (uint256) { return _allTokens.length; } /** * @dev See {IERC721Enumerable-tokenByIndex}. */ function tokenByIndex(uint256 index) public view virtual override returns (uint256) { require(index < ERC721Enumerable.totalSupply(), "ERC721Enumerable: global index out of bounds"); return _allTokens[index]; } /** * @dev Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``from``'s `tokenId` will be burned. * - `from` cannot be the zero address. * - `to` cannot be the zero address. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual override { super._beforeTokenTransfer(from, to, tokenId); if (from == address(0)) { _addTokenToAllTokensEnumeration(tokenId); } else if (from != to) { _removeTokenFromOwnerEnumeration(from, tokenId); } if (to == address(0)) { _removeTokenFromAllTokensEnumeration(tokenId); } else if (to != from) { _addTokenToOwnerEnumeration(to, tokenId); } } /** * @dev Private function to add a token to this extension's ownership-tracking data structures. * @param to address representing the new owner of the given token ID * @param tokenId uint256 ID of the token to be added to the tokens list of the given address */ function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private { uint256 length = ERC721.balanceOf(to); _ownedTokens[to][length] = tokenId; _ownedTokensIndex[tokenId] = length; } /** * @dev Private function to add a token to this extension's token tracking data structures. * @param tokenId uint256 ID of the token to be added to the tokens list */ function _addTokenToAllTokensEnumeration(uint256 tokenId) private { _allTokensIndex[tokenId] = _allTokens.length; _allTokens.push(tokenId); } /** * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that * while the token is not assigned a new owner, the `_ownedTokensIndex` mapping is _not_ updated: this allows for * gas optimizations e.g. when performing a transfer operation (avoiding double writes). * This has O(1) time complexity, but alters the order of the _ownedTokens array. * @param from address representing the previous owner of the given token ID * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address */ function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private { // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and // then delete the last slot (swap and pop). uint256 lastTokenIndex = ERC721.balanceOf(from) - 1; uint256 tokenIndex = _ownedTokensIndex[tokenId]; // When the token to delete is the last token, the swap operation is unnecessary if (tokenIndex != lastTokenIndex) { uint256 lastTokenId = _ownedTokens[from][lastTokenIndex]; _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index } // This also deletes the contents at the last position of the array delete _ownedTokensIndex[tokenId]; delete _ownedTokens[from][lastTokenIndex]; } /** * @dev Private function to remove a token from this extension's token tracking data structures. * This has O(1) time complexity, but alters the order of the _allTokens array. * @param tokenId uint256 ID of the token to be removed from the tokens list */ function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private { // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and // then delete the last slot (swap and pop). uint256 lastTokenIndex = _allTokens.length - 1; uint256 tokenIndex = _allTokensIndex[tokenId]; // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding // an 'if' statement (like in _removeTokenFromOwnerEnumeration) uint256 lastTokenId = _allTokens[lastTokenIndex]; _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index // This also deletes the contents at the last position of the array delete _allTokensIndex[tokenId]; _allTokens.pop(); } }
// SPDX-License-Identifier: MIT LICENSE pragma solidity ^0.8.0; interface IWoolf { // struct to store each token's traits struct SheepWolf { bool isSheep; uint8 fur; uint8 head; uint8 ears; uint8 eyes; uint8 nose; uint8 mouth; uint8 neck; uint8 feet; uint8 alphaIndex; } function getPaidTokens() external view returns (uint256); function getTokenTraits(uint256 tokenId) external view returns (SheepWolf memory); }
// SPDX-License-Identifier: MIT LICENSE pragma solidity ^0.8.0; interface IBarn { function addManyToBarnAndPack(address account, uint16[] calldata tokenIds) external; function randomWolfOwner(uint256 seed) external view returns (address); }
// SPDX-License-Identifier: MIT LICENSE pragma solidity ^0.8.0; interface ITraits { function tokenURI(uint256 tokenId) external view returns (string memory); }
// SPDX-License-Identifier: MIT LICENSE pragma solidity ^0.8.0; import "./ERC20.sol"; import "./Ownable.sol"; contract WOOL is ERC20, Ownable { // a mapping from an address to whether or not it can mint / burn mapping(address => bool) controllers; constructor() ERC20("WOOL", "WOOL") { } /** * mints $WOOL to a recipient * @param to the recipient of the $WOOL * @param amount the amount of $WOOL to mint */ function mint(address to, uint256 amount) external { require(controllers[msg.sender], "Only controllers can mint"); _mint(to, amount); } /** * burns $WOOL from a holder * @param from the holder of the $WOOL * @param amount the amount of $WOOL to burn */ function burn(address from, uint256 amount) external { require(controllers[msg.sender], "Only controllers can burn"); _burn(from, amount); } /** * enables an address to mint / burn * @param controller the address to enable */ function addController(address controller) external onlyOwner { controllers[controller] = true; } /** * disables an address from minting / burning * @param controller the address to disbale */ function removeController(address controller) external onlyOwner { controllers[controller] = false; } }
// SPDX-License-Identifier: MIT LICENSE pragma solidity ^0.8.0; import "./ERC20.sol"; import "./Ownable.sol"; contract MILK is ERC20, Ownable { // a mapping from an address to whether or not it can mint / burn mapping(address => bool) controllers; constructor() ERC20("MILK", "MILK") { } /** * mints $MILK to a recipient * @param to the recipient of the $MILK * @param amount the amount of $MILK to mint */ function mint(address to, uint256 amount) external { require(controllers[msg.sender], "Only controllers can mint"); _mint(to, amount); } /** * burns $MILK from a holder * @param from the holder of the $MILK * @param amount the amount of $MILK to burn */ function burn(address from, uint256 amount) external { require(controllers[msg.sender], "Only controllers can burn"); _burn(from, amount); } /** * enables an address to mint / burn * @param controller the address to enable */ function addController(address controller) external onlyOwner { controllers[controller] = true; } /** * disables an address from minting / burning * @param controller the address to disbale */ function removeController(address controller) external onlyOwner { controllers[controller] = false; } }
// SPDX-License-Identifier: MIT 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 LICENSE pragma solidity ^0.8.0; contract Randomizer { /** * generates a pseudorandom number * @param seed a value ensure different outcomes for different sources in the same block * @return a pseudorandom value */ function random(uint256 seed) public view returns (uint256) { return uint256( keccak256( abi.encodePacked( tx.origin, blockhash(block.number - 1), block.timestamp, seed, block.number ) ) ); } }
// SPDX-License-Identifier: MIT 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 pragma solidity ^0.8.0; import "./IERC721.sol"; import "./IERC721Receiver.sol"; import "./IERC721Metadata.sol"; import "./Address.sol"; import "./Context.sol"; import "./Strings.sol"; import "./ERC165.sol"; /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */ contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _owners; // Mapping owner address to token count mapping(address => uint256) private _balances; // Mapping from token ID to approved address mapping(uint256 => address) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; /** * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view virtual override returns (uint256) { require(owner != address(0), "ERC721: balance query for the zero address"); return _balances[owner]; } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view virtual override returns (address) { address owner = _owners[tokenId]; require(owner != address(0), "ERC721: owner query for nonexistent token"); return owner; } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token"); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : ""; } /** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overriden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ""; } /** * @dev See {IERC721-approve}. */ function approve(address to, uint256 tokenId) public virtual override { address owner = ERC721.ownerOf(tokenId); require(to != owner, "ERC721: approval to current owner"); require( _msgSender() == owner || isApprovedForAll(owner, _msgSender()), "ERC721: approve caller is not owner nor approved for all" ); _approve(to, tokenId); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view virtual override returns (address) { require(_exists(tokenId), "ERC721: approved query for nonexistent token"); return _tokenApprovals[tokenId]; } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { require(operator != _msgSender(), "ERC721: approve to caller"); _operatorApprovals[_msgSender()][operator] = approved; emit ApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-transferFrom}. */ function transferFrom( address from, address to, uint256 tokenId ) public virtual override { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _transfer(from, to, tokenId); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ""); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _safeTransfer(from, to, tokenId, _data); } /** * @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. * * `_data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g. * implement alternative mechanisms to perform token transfer, such as signature-based. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { _transfer(from, to, tokenId); require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer"); } /** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */ function _exists(uint256 tokenId) internal view virtual returns (bool) { return _owners[tokenId] != address(0); } /** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */ function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { require(_exists(tokenId), "ERC721: operator query for nonexistent token"); address owner = ERC721.ownerOf(tokenId); return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender)); } /** * @dev Safely mints `tokenId` and transfers it to `to`. * * Requirements: * * - `tokenId` must not exist. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeMint(address to, uint256 tokenId) internal virtual { _safeMint(to, tokenId, ""); } /** * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ function _safeMint( address to, uint256 tokenId, bytes memory _data ) internal virtual { _mint(to, tokenId); require( _checkOnERC721Received(address(0), to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer" ); } /** * @dev Mints `tokenId` and transfers it to `to`. * * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible * * Requirements: * * - `tokenId` must not exist. * - `to` cannot be the zero address. * * Emits a {Transfer} event. */ function _mint(address to, uint256 tokenId) internal virtual { require(to != address(0), "ERC721: mint to the zero address"); require(!_exists(tokenId), "ERC721: token already minted"); _beforeTokenTransfer(address(0), to, tokenId); _balances[to] += 1; _owners[tokenId] = to; emit Transfer(address(0), to, tokenId); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId) internal virtual { address owner = ERC721.ownerOf(tokenId); _beforeTokenTransfer(owner, address(0), tokenId); // Clear approvals _approve(address(0), tokenId); _balances[owner] -= 1; delete _owners[tokenId]; emit Transfer(owner, address(0), tokenId); } /** * @dev Transfers `tokenId` from `from` to `to`. * As opposed to {transferFrom}, this imposes no restrictions on msg.sender. * * Requirements: * * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * * Emits a {Transfer} event. */ function _transfer( address from, address to, uint256 tokenId ) internal virtual { require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer of token that is not own"); require(to != address(0), "ERC721: transfer to the zero address"); _beforeTokenTransfer(from, to, tokenId); // Clear approvals from the previous owner _approve(address(0), tokenId); _balances[from] -= 1; _balances[to] += 1; _owners[tokenId] = to; emit Transfer(from, to, tokenId); } /** * @dev Approve `to` to operate on `tokenId` * * Emits a {Approval} event. */ function _approve(address to, uint256 tokenId) internal virtual { _tokenApprovals[tokenId] = to; emit Approval(ERC721.ownerOf(tokenId), to, tokenId); } /** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address. * The call is not executed if the target address is not a contract. * * @param from address representing the previous owner of the given token ID * @param to target address that will receive the tokens * @param tokenId uint256 ID of the token to be transferred * @param _data bytes optional data to send along with the call * @return bool whether the call correctly returned the expected magic value */ function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { if (to.isContract()) { try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) { return retval == IERC721Receiver.onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert("ERC721: transfer to non ERC721Receiver implementer"); } else { assembly { revert(add(32, reason), mload(reason)) } } } } else { return true; } } /** * @dev Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``from``'s `tokenId` 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 tokenId ) internal virtual {} }
// SPDX-License-Identifier: MIT 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 pragma solidity ^0.8.0; import "./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 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 `IERC721.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */ function tokenURI(uint256 tokenId) external view returns (string memory); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; assembly { size := extcodesize(account) } return size > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT 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 pragma solidity ^0.8.0; import "./IERC20.sol"; import "./IERC20Metadata.sol"; import "./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 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); }
{ "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
[{"inputs":[{"internalType":"address","name":"_wool","type":"address"},{"internalType":"address","name":"_milk","type":"address"},{"internalType":"address","name":"_traits","type":"address"},{"internalType":"uint256","name":"_maxTokens","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"MAX_TOKENS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MINT_PRICE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PAID_TOKENS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"aliases","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"barn","outputs":[{"internalType":"contract IBarn","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"existingCombinations","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"feeWallet","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPaidTokens","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getTokenTraits","outputs":[{"components":[{"internalType":"bool","name":"isSheep","type":"bool"},{"internalType":"uint8","name":"fur","type":"uint8"},{"internalType":"uint8","name":"head","type":"uint8"},{"internalType":"uint8","name":"ears","type":"uint8"},{"internalType":"uint8","name":"eyes","type":"uint8"},{"internalType":"uint8","name":"nose","type":"uint8"},{"internalType":"uint8","name":"mouth","type":"uint8"},{"internalType":"uint8","name":"neck","type":"uint8"},{"internalType":"uint8","name":"feet","type":"uint8"},{"internalType":"uint8","name":"alphaIndex","type":"uint8"}],"internalType":"struct IWoolf.SheepWolf","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"milk","outputs":[{"internalType":"contract MILK","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bool","name":"stake","type":"bool"},{"internalType":"uint8","name":"tokenType","type":"uint8"}],"name":"mint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"mintCost","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minted","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"randomizer","outputs":[{"internalType":"contract Randomizer","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"rarities","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_barn","type":"address"}],"name":"setBarn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_feeWallet","type":"address"}],"name":"setFeeWallet","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_milk","type":"address"}],"name":"setMilk","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_price","type":"uint256"},{"internalType":"uint256","name":"tokenType","type":"uint256"}],"name":"setMintPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_paidTokens","type":"uint256"}],"name":"setPaidTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_paused","type":"bool"}],"name":"setPaused","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_randomizer","type":"address"}],"name":"setRandomizer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_weed","type":"address"}],"name":"setWeed","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_wool","type":"address"}],"name":"setWool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"tokenTraits","outputs":[{"internalType":"bool","name":"isSheep","type":"bool"},{"internalType":"uint8","name":"fur","type":"uint8"},{"internalType":"uint8","name":"head","type":"uint8"},{"internalType":"uint8","name":"ears","type":"uint8"},{"internalType":"uint8","name":"eyes","type":"uint8"},{"internalType":"uint8","name":"nose","type":"uint8"},{"internalType":"uint8","name":"mouth","type":"uint8"},{"internalType":"uint8","name":"neck","type":"uint8"},{"internalType":"uint8","name":"feet","type":"uint8"},{"internalType":"uint8","name":"alphaIndex","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"traits","outputs":[{"internalType":"contract ITraits","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"weed","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"weed_price","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"wool","outputs":[{"internalType":"contract WOOL","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"wool_price","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
60a06040526801f399b1438a100000600b556969e10de76676d0800000600c5569010f0cf064dd59200000600d55600f805462010000600160b01b03191675588dd1f57a93e555b7cd4358cb8442f5cac71ffc00001790553480156200006457600080fd5b5060405162004c2238038062004c22833981016040819052620000879162001199565b604080518082018252600c81526b2bb7b6331023b0b6b290261960a11b6020808301918252835180850190945260078452662ba3a0a6a2a61960c91b908401528151919291620000da9160009162001033565b508051620000f090600190602084019062001033565b5050506200010d6200010762000fdd60201b60201c565b62000fe1565b600a805460ff60a01b19169055603780546001600160a01b038087166001600160a01b03199283161790925560388054868416908316179055603a805492851692909116919091179055608081905262000169600582620011ea565b600e556040805160a081018252600f81526032602082015260c89181019190915260fa606082015260ff6080820152620001a8906012906005620010c2565b506040805160a081018252600480825260208201819052918101829052606081018290526080810191909152620001e4906024906005620010c2565b50604080516102808101825260be815260d7602082015260f0918101829052606460608201819052606e6080830152608760a08084019190915260c083015260b960e08301526050610100830181905260d261012084015260eb61014084015261016083019390935261018082018390526101a08201929092526101c081018290526101e0810182905261020081019190915260f561022082015260fa61024082015260ff6102608201526200029f906013906014620010c2565b5060408051610280810182526001815260026020820152600491810182905260006060820181905260056080830152600660a0830152600760c0830152600960e08301526101008201819052600a610120830152600b610140830152601161016083015261018082018190526101a082018190526101c082018190526101e082015261020081019190915260126102208201526013610240820181905261026082015262000352906025906014620010c2565b506040805160c08101825260ff8152601e6020820152603c918101829052606081019190915260966080820152609c60a082015262000396906014906006620010c2565b506040805160c081018252600080825260208201819052918101829052606081018290526080810182905260a0810191909152620003d9906026906006620010c2565b50604080516103808101825260dd81526064602082015260b591810191909152608c6060820181905260e060808301819052609360a080850191909152605460c0850181905260e4838601526101008501849052610120850183905260fa61014086015261016085019190915260f161018085015260cf6101a085015260ad6101c08501526101e084015260fe61020084015260dc61022084015260c4610240840152610260830182905260a861028084015260fc6102a084018190526102c084019290925260b76102e084015260ec61030084015261032083019190915261034082015260ff610360820152620004d690601590601c620010c2565b50604080516103808101825260018082526002602083015260059282018390526000606083015260808201819052600760a083015260c0820152600a60e08201819052610100820192909252610120810191909152600b6101408201819052600c610160830152600d6101808301819052600e6101a0840181905260106101c08501526101e084019290925260116102008401819052601761022085018190526102408501929092526102608401929092526102808301919091526102a082018190526102c082015260186102e0820152601b610300820181905261032082018190526103408201819052610360820152620005d790602790601c620010c2565b50604080516101408101825260af80825260646020830181905260289383019390935260fa60608301526073608083015260a082019290925260b960c082015260e081019190915260b461010082015260ff6101208201526200063f90601690600a620010c2565b50604080516101408101825260038152600060208201526004918101919091526006606082018190526080820152600760a0820152600860c0820181905260e082015260096101008201819052610120820152620006a290602890600a620010c2565b506040805161020081018252605080825260e1602083015260e38284015260e460608301526070608083015260f060a080840182905260c0840185905260e084015260a761010084015260d961012084015260ab610140840152610160830193909352610180820192909252607e6101a08201526101c081019190915260ff6101e082015262000737906017906010620010c2565b50604080516102008101825260018152600260208201819052600392820192909252600860608201819052608082019290925260a0810182905260c0810191909152600960e08201819052610100820152600a6101208201819052600d61014083018190526101608301919091526101808201819052600f6101a083018190526101c08301919091526101e0820152620007d6906029906010620010c2565b50604080516020810190915260ff8152620007f6906018906001620010c2565b506040805160208101909152600081526200081690602a906001620010c2565b50604080516102608101825260f3815260bd6020820152608591810182905260608101829052603960808201819052605f60a0830152609860c0830152608760e0830152610100820192909252610120810182905260de61014082015260a861016082015261018081018290526101a081019190915260266101c082015260726101e08201819052610200820181905261022082015260ff610240820152620008c4906019906013620010c2565b50604080516102608101825260018082526007602083018190526000938301849052606083018490526080830184905260a0830184905260c08301849052600a60e084015261010083018490526101208301849052600b61014084018190526012610160850181905261018085018690526101a085018690526101c08501959095526101e08401929092526102008301526102208201526102408101919091526200097490602b906013620010c2565b50604080516020810190915260ff81526200099490601a906001620010c2565b50604080516020810190915260008152620009b490602c906001620010c2565b50604080516101208101825260d28152605a602082015260099181018290526060810182905260808101829052609660a082015260c0810182905260ff60e0820152610100810182905262000a0d91601b9190620010c2565b5060408051610120810182526005808252600060208301819052928201929092526060810182905260808101829052600760a0820181905260c0820183905260e082015261010081019190915262000a6a90602d906009620010c2565b50604080516020810190915260ff815262000a8a90601c906001620010c2565b5060408051602081019091526000815262000aaa90602e906001620010c2565b50604080516020810190915260ff815262000aca90601d906001620010c2565b5060408051602081019091526000815262000aea90602f906001620010c2565b506040805161036081018252608780825260b1602083015260db92820192909252608d606082015260b7608082015260e160a0820152609360c082015260bd60e082015260e761010082015261012081018290526101408101829052610160810182905261018081019190915260f66101a082015260966101c082018190526101e0820152609c61020082015260a561022082015260ab61024082015260b461026082015260ba61028082015260c36102a082015260c96102c082015260d26102e082015260f361030082015260fc61032082015260ff61034082015262000bd790601e90601b620010c2565b506040805161036081018252600181526002602082015260039181018290526004606082015260056080820152600660a08201819052600760c0830152600860e0830152600d610100830152610120820192909252610140810191909152600e610160820152600f61018082015260106101a082018190526101c082015260116101e08201526012610200820152601361022082015260146102408201526015610260820152601661028082015260176102a082015260186102c082015260196102e0820152601a6103008201819052610320820181905261034082015262000cc590603090601b620010c2565b50604080516020810190915260ff815262000ce590601f906001620010c2565b5060408051602081019091526000815262000d05906031906001620010c2565b50604080516101a08101825260ef815260f4602082015260f99181019190915260ea606082018190526080820181905260a0820181905260c0820181905260e082018190526101008201819052610120820152608261014082015260ff61016082015260f76101808201526012600e62000d8492910190600d620010c2565b50604080516101a0810182526001815260026020820152600b918101829052600060608201526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101829052610160810182905261018081019190915262000dff90603290600d620010c2565b50604080516101e081018252604b80825260b4602083015260a592820192909252607860608201819052603c6080830152609660a0830152606960c083015260c360e08301819052602d610100840181905260e16101208501526101408401949094526101608301939093526101808201929092526101a081019190915260ff6101c082015262000e9590602190600f620010c2565b50604080516101e08101825260018152600960208201526000918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052600c61012082018190526101408201839052610160820192909252600e61018082018190526101a08201929092526101c081019190915262000f2690603390600f620010c2565b50604080516020810190915260ff815262000f46906022906001620010c2565b5060408051602081019091526000815262000f66906034906001620010c2565b50604080516080810182526008815260a0602082015260499181019190915260ff606082015262000f9c906023906004620010c2565b506040805160808101825260028152600360208201819052918101829052606081019190915262000fd2906035906004620010c2565b505050505062001248565b3390565b600a80546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b82805462001041906200120b565b90600052602060002090601f016020900481019282620010655760008555620010b0565b82601f106200108057805160ff1916838001178555620010b0565b82800160010185558215620010b0579182015b82811115620010b057825182559160200191906001019062001093565b50620010be92915062001165565b5090565b82805482825590600052602060002090601f01602090048101928215620010b05791602002820160005b838211156200112c57835183826101000a81548160ff021916908360ff1602179055509260200192600101602081600001049283019260010302620010ec565b80156200115b5782816101000a81549060ff02191690556001016020816000010492830192600103026200112c565b5050620010be9291505b5b80821115620010be576000815560010162001166565b80516001600160a01b03811681146200119457600080fd5b919050565b60008060008060808587031215620011af578384fd5b620011ba856200117c565b9350620011ca602086016200117c565b9250620011da604086016200117c565b6060959095015193969295505050565b6000826200120657634e487b7160e01b81526012600452602481fd5b500490565b6002810460018216806200122057607f821691505b602082108114156200124257634e487b7160e01b600052602260045260246000fd5b50919050565b6080516139a96200127960003960008181610c2f01528181610c7d015281816110ce0152611bbe01526139a96000f3fe6080604052600436106102e45760003560e01c806370a0823111610190578063c002d23d116100dc578063e0a81da511610095578063f10fb5841161006f578063f10fb58414610872578063f25f4b5614610887578063f2fde38b1461089c578063f47c84c5146108bc576102e4565b8063e0a81da514610828578063e1fc334f1461083d578063e985e9c514610852576102e4565b8063c002d23d14610773578063c084f54014610788578063c87b56dd1461079d578063cc740dfe146107bd578063dbf8b168146107dd578063e05c57bf146107f2576102e4565b806390d49b9d11610149578063963402ab11610123578063963402ab146106f3578063a1b8f37414610713578063a22cb46514610733578063b88d4fde14610753576102e4565b806390d49b9d1461069157806394e56847146106b157806395d89b41146106de576102e4565b806370a08231146105ff578063715018a61461061f578063767bcab51461063457806381a1452c146106545780638da5cb5b146106675780638fbb5fa71461067c576102e4565b806333df4b2c1161024f57806342842e0e116102085780634f6ccce7116101e25780634f6ccce7146105955780635c3dbbda146105b55780635c975abb146105ca5780636352211e146105df576102e4565b806342842e0e1461053e57806349e3b2921461055e5780634f02c42014610573576102e4565b806333df4b2c146104875780633431a753146104b457806336838391146104d45780633b342a85146104f45780633ccfd60b146105145780634018b1f814610529576102e4565b806316c38b3c116102a157806316c38b3c146103d057806318160ddd146103f0578063194f480e1461041257806323b872dd1461042757806327de8f27146104475780632f745c5914610467576102e4565b806301ffc9a7146102e95780630442bfa81461031f57806306fdde0314610341578063081812fc14610363578063095ea7b314610390578063110a2ded146103b0575b600080fd5b3480156102f557600080fd5b50610309610304366004612d00565b6108d1565b6040516103169190612fed565b60405180910390f35b34801561032b57600080fd5b5061033f61033a366004612e21565b6108fe565b005b34801561034d57600080fd5b5061035661097b565b604051610316919061304b565b34801561036f57600080fd5b5061038361037e366004612dab565b610a0d565b6040516103169190612f05565b34801561039c57600080fd5b5061033f6103ab366004612c9d565b610a50565b3480156103bc57600080fd5b5061033f6103cb366004612b19565b610ae8565b3480156103dc57600080fd5b5061033f6103eb366004612cc8565b610b49565b3480156103fc57600080fd5b50610405610ba6565b604051610316919061372e565b34801561041e57600080fd5b50610383610bac565b34801561043357600080fd5b5061033f610442366004612b89565b610bbb565b34801561045357600080fd5b50610405610462366004612dab565b610c15565b34801561047357600080fd5b50610405610482366004612c9d565b610cd5565b34801561049357600080fd5b506104a76104a2366004612e21565b610d2a565b6040516103169190613737565b3480156104c057600080fd5b5061033f6104cf366004612dab565b610d70565b3480156104e057600080fd5b506104a76104ef366004612e21565b610db4565b34801561050057600080fd5b5061033f61050f366004612b19565b610dc4565b34801561052057600080fd5b5061033f610e25565b34801561053557600080fd5b50610405610ea5565b34801561054a57600080fd5b5061033f610559366004612b89565b610eab565b34801561056a57600080fd5b50610405610ec6565b34801561057f57600080fd5b50610588610ecc565b604051610316919061371f565b3480156105a157600080fd5b506104056105b0366004612dab565b610ed6565b3480156105c157600080fd5b50610405610f31565b3480156105d657600080fd5b50610309610f37565b3480156105eb57600080fd5b506103836105fa366004612dab565b610f47565b34801561060b57600080fd5b5061040561061a366004612b19565b610f7c565b34801561062b57600080fd5b5061033f610fc0565b34801561064057600080fd5b5061033f61064f366004612b19565b61100b565b61033f610662366004612ddb565b61106c565b34801561067357600080fd5b50610383611671565b34801561068857600080fd5b50610383611680565b34801561069d57600080fd5b5061033f6106ac366004612b19565b61168f565b3480156106bd57600080fd5b506106d16106cc366004612dab565b6116f8565b6040516103169190613656565b3480156106ea57600080fd5b506103566117b5565b3480156106ff57600080fd5b5061033f61070e366004612b19565b6117c4565b34801561071f57600080fd5b5061040561072e366004612dab565b611825565b34801561073f57600080fd5b5061033f61074e366004612c70565b611837565b34801561075f57600080fd5b5061033f61076e366004612bc9565b611905565b34801561077f57600080fd5b50610405611944565b34801561079457600080fd5b5061040561194a565b3480156107a957600080fd5b506103566107b8366004612dab565b611950565b3480156107c957600080fd5b5061033f6107d8366004612b19565b6119fb565b3480156107e957600080fd5b50610383611a5c565b3480156107fe57600080fd5b5061081261080d366004612dab565b611a6b565b6040516103169a99989796959493929190612ff8565b34801561083457600080fd5b50610383611ade565b34801561084957600080fd5b50610383611aed565b34801561085e57600080fd5b5061030961086d366004612b51565b611afc565b34801561087e57600080fd5b50610383611b2a565b34801561089357600080fd5b50610383611b39565b3480156108a857600080fd5b5061033f6108b7366004612b19565b611b4e565b3480156108c857600080fd5b50610405611bbc565b60006001600160e01b0319821663780e9d6360e01b14806108f657506108f682611be0565b90505b919050565b610906611c20565b6001600160a01b0316610917611671565b6001600160a01b0316146109465760405162461bcd60e51b815260040161093d90613455565b60405180910390fd5b8061095557600b829055610977565b806001141561096857600c829055610977565b806002141561097757600d8290555b5050565b60606000805461098a9061384a565b80601f01602080910402602001604051908101604052809291908181526020018280546109b69061384a565b8015610a035780601f106109d857610100808354040283529160200191610a03565b820191906000526020600020905b8154815290600101906020018083116109e657829003601f168201915b5050505050905090565b6000610a1882611c24565b610a345760405162461bcd60e51b815260040161093d90613409565b506000908152600460205260409020546001600160a01b031690565b6000610a5b82610f47565b9050806001600160a01b0316836001600160a01b03161415610a8f5760405162461bcd60e51b815260040161093d90613522565b806001600160a01b0316610aa1611c20565b6001600160a01b03161480610abd5750610abd8161086d611c20565b610ad95760405162461bcd60e51b815260040161093d906132e4565b610ae38383611c41565b505050565b610af0611c20565b6001600160a01b0316610b01611671565b6001600160a01b031614610b275760405162461bcd60e51b815260040161093d90613455565b603880546001600160a01b0319166001600160a01b0392909216919091179055565b610b51611c20565b6001600160a01b0316610b62611671565b6001600160a01b031614610b885760405162461bcd60e51b815260040161093d90613455565b8015610b9b57610b96611caf565b610ba3565b610ba3611d27565b50565b60085490565b6036546001600160a01b031681565b6036546001600160a01b0316610bcf611c20565b6001600160a01b031614610c0a57610bee610be8611c20565b82611d81565b610c0a5760405162461bcd60e51b815260040161093d90613563565b610ae3838383611e06565b6000600e548211610c28575060006108f9565b6005610c557f000000000000000000000000000000000000000000000000000000000000000060026137e8565b610c5f91906137d4565b8211610c76575069043c33c19375648000006108f9565b6005610ca37f000000000000000000000000000000000000000000000000000000000000000060046137e8565b610cad91906137d4565b8211610cc45750690878678326eac90000006108f9565b506910f0cf064dd592000000919050565b6000610ce083610f7c565b8210610cfe5760405162461bcd60e51b815260040161093d9061308c565b506001600160a01b03821660009081526006602090815260408083208484529091529020545b92915050565b60128260128110610d3a57600080fd5b018181548110610d4957600080fd5b9060005260206000209060209182820401919006915091509054906101000a900460ff1681565b610d78611c20565b6001600160a01b0316610d89611671565b6001600160a01b031614610daf5760405162461bcd60e51b815260040161093d90613455565b600e55565b60248260128110610d3a57600080fd5b610dcc611c20565b6001600160a01b0316610ddd611671565b6001600160a01b031614610e035760405162461bcd60e51b815260040161093d90613455565b603680546001600160a01b0319166001600160a01b0392909216919091179055565b610e2d611c20565b6001600160a01b0316610e3e611671565b6001600160a01b031614610e645760405162461bcd60e51b815260040161093d90613455565b600f546040516001600160a01b036201000090920491909116904780156108fc02916000818181858888f19350505050158015610ba3573d6000803e3d6000fd5b600e5490565b610ae383838360405180602001604052806000815250611905565b600d5481565b600f5461ffff1681565b6000610ee0610ba6565b8210610efe5760405162461bcd60e51b815260040161093d906135e1565b60088281548110610f1f57634e487b7160e01b600052603260045260246000fd5b90600052602060002001549050919050565b600c5481565b600a54600160a01b900460ff1690565b6000818152600260205260408120546001600160a01b0316806108f65760405162461bcd60e51b815260040161093d9061338b565b60006001600160a01b038216610fa45760405162461bcd60e51b815260040161093d90613341565b506001600160a01b031660009081526003602052604090205490565b610fc8611c20565b6001600160a01b0316610fd9611671565b6001600160a01b031614610fff5760405162461bcd60e51b815260040161093d90613455565b6110096000611f33565b565b611013611c20565b6001600160a01b0316611024611671565b6001600160a01b03161461104a5760405162461bcd60e51b815260040161093d90613455565b603b80546001600160a01b0319166001600160a01b0392909216919091179055565b611074610f37565b156110915760405162461bcd60e51b815260040161093d906132ba565b611099611c20565b6001600160a01b0316326001600160a01b0316146110c95760405162461bcd60e51b815260040161093d906131d1565b600f547f0000000000000000000000000000000000000000000000000000000000000000906110fd90859061ffff16613797565b111561111b5760405162461bcd60e51b815260040161093d9061316f565b60008311801561112c5750600a8311155b6111485760405162461bcd60e51b815260040161093d906135b4565b60ff81161580156111605750600e54600f5461ffff16105b156111fa57600e54600f5461117a90859061ffff16613797565b116111b057600b5461118c90846137e8565b3410156111ab5760405162461bcd60e51b815260040161093d9061362d565b6111fa565b600b54600e54600f546111c79061ffff1686613797565b6111d19190613807565b6111db91906137e8565b3410156111fa5760405162461bcd60e51b815260040161093d9061362d565b600080600080856112195760408051600081526020810190915261126b565b8667ffffffffffffffff81111561124057634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611269578160200160208202803683370190505b505b90506000805b8881101561148357600f805461ffff1690600061128d83613885565b82546101009290920a61ffff818102199093169183160217909155603b54600f5460405163b863bd3760e01b81526001600160a01b03909216935063b863bd37926112dd9291169060040161371f565b60206040518083038186803b1580156112f557600080fd5b505afa158015611309573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061132d9190612dc3565b600f549092506113419061ffff1683611f85565b50600061134d836121d4565b9050881580611375575061135f611c20565b6001600160a01b0316816001600160a01b031614155b1561139157600f5461138c90829061ffff166122b6565b6113f1565b603654600f546113ae916001600160a01b03169061ffff166122b6565b600f54845161ffff909116908590849081106113da57634e487b7160e01b600052603260045260246000fd5b602002602001019061ffff16908161ffff16815250505b8760ff16600114801561140b5750600e54600f5461ffff16105b1561142457600c5461141d9088613797565b9650611453565b8760ff16600214801561143e5750600e54600f5461ffff16105b1561145357600d546114509087613797565b95505b600f546114639061ffff16610c15565b61146d9086613797565b945050808061147b906138a7565b915050611271565b5084156114f4576037546001600160a01b0316639dc29fac6114a3611c20565b876040518363ffffffff1660e01b81526004016114c1929190612fd4565b600060405180830381600087803b1580156114db57600080fd5b505af11580156114ef573d6000803e3d6000fd5b505050505b8215611564576038546001600160a01b0316639dc29fac611513611c20565b856040518363ffffffff1660e01b8152600401611531929190612fd4565b600060405180830381600087803b15801561154b57600080fd5b505af115801561155f573d6000803e3d6000fd5b505050505b83156115f7576039546001600160a01b03166323b872dd611583611c20565b30876040518463ffffffff1660e01b81526004016115a393929190612f19565b602060405180830381600087803b1580156115bd57600080fd5b505af11580156115d1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115f59190612ce4565b505b8615611667576036546001600160a01b03166381d449c1611616611c20565b846040518363ffffffff1660e01b8152600401611634929190612f7a565b600060405180830381600087803b15801561164e57600080fd5b505af1158015611662573d6000803e3d6000fd5b505050505b5050505050505050565b600a546001600160a01b031690565b6037546001600160a01b031681565b611697611c20565b6001600160a01b03166116a8611671565b6001600160a01b0316146116ce5760405162461bcd60e51b815260040161093d90613455565b600f80546001600160a01b03909216620100000262010000600160b01b0319909216919091179055565b611700612ac5565b50600090815260106020908152604091829020825161014081018452905460ff808216151583526101008083048216948401949094526201000082048116948301949094526301000000810484166060830152640100000000810484166080830152650100000000008104841660a083015266010000000000008104841660c0830152600160381b8104841660e0830152600160401b8104841692820192909252600160481b90910490911661012082015290565b60606001805461098a9061384a565b6117cc611c20565b6001600160a01b03166117dd611671565b6001600160a01b0316146118035760405162461bcd60e51b815260040161093d90613455565b603980546001600160a01b0319166001600160a01b0392909216919091179055565b60116020526000908152604090205481565b61183f611c20565b6001600160a01b0316826001600160a01b031614156118705760405162461bcd60e51b815260040161093d90613237565b806005600061187d611c20565b6001600160a01b03908116825260208083019390935260409182016000908120918716808252919093529120805460ff1916921515929092179091556118c1611c20565b6001600160a01b03167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31836040516118f99190612fed565b60405180910390a35050565b611916611910611c20565b83611d81565b6119325760405162461bcd60e51b815260040161093d90613563565b61193e848484846122d0565b50505050565b600b5481565b600e5481565b606061195b82611c24565b6119775760405162461bcd60e51b815260040161093d906134d3565b603a5460405163c87b56dd60e01b81526001600160a01b039091169063c87b56dd906119a790859060040161372e565b60006040518083038186803b1580156119bf57600080fd5b505afa1580156119d3573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526108f69190810190612d38565b611a03611c20565b6001600160a01b0316611a14611671565b6001600160a01b031614611a3a5760405162461bcd60e51b815260040161093d90613455565b603780546001600160a01b0319166001600160a01b0392909216919091179055565b6038546001600160a01b031681565b60106020526000908152604090205460ff80821691610100810482169162010000820481169163010000008104821691640100000000820481169165010000000000810482169166010000000000008204811691600160381b8104821691600160401b8204811691600160481b9004168a565b6039546001600160a01b031681565b603a546001600160a01b031681565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b603b546001600160a01b031681565b600f546201000090046001600160a01b031681565b611b56611c20565b6001600160a01b0316611b67611671565b6001600160a01b031614611b8d5760405162461bcd60e51b815260040161093d90613455565b6001600160a01b038116611bb35760405162461bcd60e51b815260040161093d90613129565b610ba381611f33565b7f000000000000000000000000000000000000000000000000000000000000000081565b60006001600160e01b031982166380ac58cd60e01b1480611c1157506001600160e01b03198216635b5e139f60e01b145b806108f657506108f682612303565b3390565b6000908152600260205260409020546001600160a01b0316151590565b600081815260046020526040902080546001600160a01b0319166001600160a01b0384169081179091558190611c7682610f47565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b611cb7610f37565b15611cd45760405162461bcd60e51b815260040161093d906132ba565b600a805460ff60a01b1916600160a01b1790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258611d10611c20565b604051611d1d9190612f05565b60405180910390a1565b611d2f610f37565b611d4b5760405162461bcd60e51b815260040161093d9061305e565b600a805460ff60a01b191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa611d10611c20565b6000611d8c82611c24565b611da85760405162461bcd60e51b815260040161093d9061326e565b6000611db383610f47565b9050806001600160a01b0316846001600160a01b03161480611dee5750836001600160a01b0316611de384610a0d565b6001600160a01b0316145b80611dfe5750611dfe8185611afc565b949350505050565b826001600160a01b0316611e1982610f47565b6001600160a01b031614611e3f5760405162461bcd60e51b815260040161093d9061348a565b6001600160a01b038216611e655760405162461bcd60e51b815260040161093d906131f3565b611e7083838361231c565b611e7b600082611c41565b6001600160a01b0383166000908152600360205260408120805460019290611ea4908490613807565b90915550506001600160a01b0382166000908152600360205260408120805460019290611ed2908490613797565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b600a80546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b611f8d612ac5565b611f96826123a5565b905060116000611fa583612513565b8152602001908152602001600020546000141561214257806010600085815260200190815260200160002060008201518160000160006101000a81548160ff02191690831515021790555060208201518160000160016101000a81548160ff021916908360ff16021790555060408201518160000160026101000a81548160ff021916908360ff16021790555060608201518160000160036101000a81548160ff021916908360ff16021790555060808201518160000160046101000a81548160ff021916908360ff16021790555060a08201518160000160056101000a81548160ff021916908360ff16021790555060c08201518160000160066101000a81548160ff021916908360ff16021790555060e08201518160000160076101000a81548160ff021916908360ff1602179055506101008201518160000160086101000a81548160ff021916908360ff1602179055506101208201518160000160096101000a81548160ff021916908360ff160217905550905050826011600061212c84612513565b8152602081019190915260400160002055610d24565b603b5460405163b863bd3760e01b81526121cd9185916001600160a01b039091169063b863bd379061217890879060040161372e565b60206040518083038186803b15801561219057600080fd5b505afa1580156121a4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906121c89190612dc3565b611f85565b9392505050565b600e54600f5460009161ffff9091161115806121fd57506121fa600a60f584901c6138c2565b15155b156122115761220a611c20565b90506108f9565b603654604051631e4c4f3560e11b81526000916001600160a01b031690633c989e6a9061224690609087901c9060040161372e565b60206040518083038186803b15801561225e57600080fd5b505afa158015612272573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906122969190612b35565b90506001600160a01b0381166108f6576122ae611c20565b9150506108f9565b610977828260405180602001604052806000815250612572565b6122db848484611e06565b6122e7848484846125a5565b61193e5760405162461bcd60e51b815260040161093d906130d7565b6001600160e01b031981166301ffc9a760e01b14919050565b612327838383610ae3565b6001600160a01b0383166123435761233e816126c0565b612366565b816001600160a01b0316836001600160a01b031614612366576123668382612704565b6001600160a01b0382166123825761237d816127a1565b610ae3565b826001600160a01b0316826001600160a01b031614610ae357610ae3828261287a565b6123ad612ac5565b6123bc600a61ffff84166138c2565b15158082526000906123cf5760096123d2565b60005b60109390931c9290506123f361ffff84166123ee8360006137af565b6128be565b60ff16602083015260109290921c9161241561ffff84166123ee8360016137af565b60ff16604083015260109290921c9161243761ffff84166123ee8360026137af565b60ff16606083015260109290921c9161245961ffff84166123ee8360036137af565b60ff16608083015260109290921c9161247b61ffff84166123ee8360046137af565b60ff1660a083015260109290921c9161249d61ffff84166123ee8360056137af565b60ff1660c083015260109290921c916124bf61ffff84166123ee8360066137af565b60ff1660e083015260109290921c916124e161ffff84166123ee8360076137af565b60ff1661010083015260109290921c9161250461ffff84166123ee8360086137af565b60ff1661012083015250919050565b8051602080830151604080850151608086015160c087015160e088015160608901516101008a01516101208b0151965160009a6125549a9099989101612e8c565b60408051601f19818403018152919052805160209091012092915050565b61257c83836129e0565b61258960008484846125a5565b610ae35760405162461bcd60e51b815260040161093d906130d7565b60006125b9846001600160a01b0316612abf565b156126b557836001600160a01b031663150b7a026125d5611c20565b8786866040518563ffffffff1660e01b81526004016125f79493929190612f3d565b602060405180830381600087803b15801561261157600080fd5b505af1925050508015612641575060408051601f3d908101601f1916820190925261263e91810190612d1c565b60015b61269b573d80801561266f576040519150601f19603f3d011682016040523d82523d6000602084013e612674565b606091505b5080516126935760405162461bcd60e51b815260040161093d906130d7565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611dfe565b506001949350505050565b600880546000838152600960205260408120829055600182018355919091527ff3f7a9fe364faab93b216da50a3214154f22a0a2b415b23a84c8169e8b636ee30155565b6000600161271184610f7c565b61271b9190613807565b60008381526007602052604090205490915080821461276e576001600160a01b03841660009081526006602090815260408083208584528252808320548484528184208190558352600790915290208190555b5060009182526007602090815260408084208490556001600160a01b039094168352600681528383209183525290812055565b6008546000906127b390600190613807565b600083815260096020526040812054600880549394509092849081106127e957634e487b7160e01b600052603260045260246000fd5b90600052602060002001549050806008838154811061281857634e487b7160e01b600052603260045260246000fd5b600091825260208083209091019290925582815260099091526040808220849055858252812055600880548061285e57634e487b7160e01b600052603160045260246000fd5b6001900381819060005260206000200160009055905550505050565b600061288583610f7c565b6001600160a01b039093166000908152600660209081526040808320868452825280832085905593825260079052919091209190915550565b60008060128360ff16601281106128e557634e487b7160e01b600052603260045260246000fd5b01546128f190856138d6565b905060128360ff166012811061291757634e487b7160e01b600052603260045260246000fd5b018160ff168154811061293a57634e487b7160e01b600052603260045260246000fd5b60009182526020918290209181049091015460ff601f9092166101000a90048116600886901c9091161015612970579050610d24565b60248360ff166012811061299457634e487b7160e01b600052603260045260246000fd5b018160ff16815481106129b757634e487b7160e01b600052603260045260246000fd5b90600052602060002090602091828204019190069054906101000a900460ff1691505092915050565b6001600160a01b038216612a065760405162461bcd60e51b815260040161093d906133d4565b612a0f81611c24565b15612a2c5760405162461bcd60e51b815260040161093d9061319a565b612a386000838361231c565b6001600160a01b0382166000908152600360205260408120805460019290612a61908490613797565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b3b151590565b6040805161014081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081019190915290565b600060208284031215612b2a578081fd5b81356121cd8161393a565b600060208284031215612b46578081fd5b81516121cd8161393a565b60008060408385031215612b63578081fd5b8235612b6e8161393a565b91506020830135612b7e8161393a565b809150509250929050565b600080600060608486031215612b9d578081fd5b8335612ba88161393a565b92506020840135612bb88161393a565b929592945050506040919091013590565b60008060008060808587031215612bde578081fd5b8435612be98161393a565b93506020850135612bf98161393a565b925060408501359150606085013567ffffffffffffffff811115612c1b578182fd5b8501601f81018713612c2b578182fd5b8035612c3e612c398261376f565b613745565b818152886020838501011115612c52578384fd5b81602084016020830137908101602001929092525092959194509250565b60008060408385031215612c82578182fd5b8235612c8d8161393a565b91506020830135612b7e8161394f565b60008060408385031215612caf578182fd5b8235612cba8161393a565b946020939093013593505050565b600060208284031215612cd9578081fd5b81356121cd8161394f565b600060208284031215612cf5578081fd5b81516121cd8161394f565b600060208284031215612d11578081fd5b81356121cd8161395d565b600060208284031215612d2d578081fd5b81516121cd8161395d565b600060208284031215612d49578081fd5b815167ffffffffffffffff811115612d5f578182fd5b8201601f81018413612d6f578182fd5b8051612d7d612c398261376f565b818152856020838501011115612d91578384fd5b612da282602083016020860161381e565b95945050505050565b600060208284031215612dbc578081fd5b5035919050565b600060208284031215612dd4578081fd5b5051919050565b600080600060608486031215612def578081fd5b833592506020840135612e018161394f565b9150604084013560ff81168114612e16578182fd5b809150509250925092565b60008060408385031215612e33578182fd5b50508035926020909101359150565b15159052565b60008151808452612e6081602086016020860161381e565b601f01601f19169290920160200192915050565b60ff169052565b60f81b6001600160f81b0319169052565b89151560f890811b82526001600160f81b03198a821b8116600184015289821b8116600284015288821b8116600384015287821b8116600484015286821b8116600584015285821b811660068401529084901b1660078201526000612ef46008830184612e7b565b506009019998505050505050505050565b6001600160a01b0391909116815260200190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090612f7090830184612e48565b9695505050505050565b6001600160a01b038316815260406020808301829052835191830182905260009184820191906060850190845b81811015612fc757845161ffff1683529383019391830191600101612fa7565b5090979650505050505050565b6001600160a01b03929092168252602082015260400190565b901515815260200190565b9915158a5260ff98891660208b015296881660408a01529487166060890152928616608088015290851660a0870152841660c0860152831660e08501528216610100840152166101208201526101400190565b6000602082526121cd6020830184612e48565b60208082526014908201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b604082015260600190565b6020808252602b908201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560408201526a74206f6620626f756e647360a81b606082015260800190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526026908201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160408201526564647265737360d01b606082015260800190565b602080825260119082015270105b1b081d1bdad95b9cc81b5a5b9d1959607a1b604082015260600190565b6020808252601c908201527f4552433732313a20746f6b656e20616c7265616479206d696e74656400000000604082015260600190565b6020808252600890820152674f6e6c7920454f4160c01b604082015260600190565b60208082526024908201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646040820152637265737360e01b606082015260800190565b60208082526019908201527f4552433732313a20617070726f766520746f2063616c6c657200000000000000604082015260600190565b6020808252602c908201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860408201526b34b9ba32b73a103a37b5b2b760a11b606082015260800190565b60208082526010908201526f14185d5cd8589b194e881c185d5cd95960821b604082015260600190565b60208082526038908201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760408201527f6e6572206e6f7220617070726f76656420666f7220616c6c0000000000000000606082015260800190565b6020808252602a908201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604082015269726f206164647265737360b01b606082015260800190565b60208082526029908201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460408201526832b73a103a37b5b2b760b91b606082015260800190565b6020808252818101527f4552433732313a206d696e7420746f20746865207a65726f2061646472657373604082015260600190565b6020808252602c908201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860408201526b34b9ba32b73a103a37b5b2b760a11b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526029908201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960408201526839903737ba1037bbb760b91b606082015260800190565b6020808252602f908201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60408201526e3732bc34b9ba32b73a103a37b5b2b760891b606082015260800190565b60208082526021908201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656040820152603960f91b606082015260800190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b602080825260139082015272125b9d985b1a59081b5a5b9d08185b5bdd5b9d606a1b604082015260600190565b6020808252602c908201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60408201526b7574206f6620626f756e647360a01b606082015260800190565b6020808252600f908201526e6e6f7420656e6f756768742046544d60881b604082015260600190565b60006101408201905061366a828451612e42565b602083015161367c6020840182612e74565b50604083015161368f6040840182612e74565b5060608301516136a26060840182612e74565b5060808301516136b56080840182612e74565b5060a08301516136c860a0840182612e74565b5060c08301516136db60c0840182612e74565b5060e08301516136ee60e0840182612e74565b506101008084015161370282850182612e74565b50506101208084015161371782850182612e74565b505092915050565b61ffff91909116815260200190565b90815260200190565b60ff91909116815260200190565b60405181810167ffffffffffffffff8111828210171561376757613767613924565b604052919050565b600067ffffffffffffffff82111561378957613789613924565b50601f01601f191660200190565b600082198211156137aa576137aa6138f8565b500190565b600060ff821660ff84168060ff038211156137cc576137cc6138f8565b019392505050565b6000826137e3576137e361390e565b500490565b6000816000190483118215151615613802576138026138f8565b500290565b600082821015613819576138196138f8565b500390565b60005b83811015613839578181015183820152602001613821565b8381111561193e5750506000910152565b60028104600182168061385e57607f821691505b6020821081141561387f57634e487b7160e01b600052602260045260246000fd5b50919050565b600061ffff8083168181141561389d5761389d6138f8565b6001019392505050565b60006000198214156138bb576138bb6138f8565b5060010190565b6000826138d1576138d161390e565b500690565b600060ff8316806138e9576138e961390e565b8060ff84160691505092915050565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610ba357600080fd5b8015158114610ba357600080fd5b6001600160e01b031981168114610ba357600080fdfea2646970667358221220c9c6c1df7c0e7c5d82e415511d7bba0b5256f87e1b4c8418585bbeb91b903a6664736f6c634300080000330000000000000000000000002e4bf93bded3236d0719aa3ceb43932f279efe1f00000000000000000000000090ad9988e7050db30829164b8e9837a351654863000000000000000000000000b6591e04238a187053186b07593ba4aab20acba8000000000000000000000000000000000000000000000000000000000000c350
Deployed Bytecode
0x6080604052600436106102e45760003560e01c806370a0823111610190578063c002d23d116100dc578063e0a81da511610095578063f10fb5841161006f578063f10fb58414610872578063f25f4b5614610887578063f2fde38b1461089c578063f47c84c5146108bc576102e4565b8063e0a81da514610828578063e1fc334f1461083d578063e985e9c514610852576102e4565b8063c002d23d14610773578063c084f54014610788578063c87b56dd1461079d578063cc740dfe146107bd578063dbf8b168146107dd578063e05c57bf146107f2576102e4565b806390d49b9d11610149578063963402ab11610123578063963402ab146106f3578063a1b8f37414610713578063a22cb46514610733578063b88d4fde14610753576102e4565b806390d49b9d1461069157806394e56847146106b157806395d89b41146106de576102e4565b806370a08231146105ff578063715018a61461061f578063767bcab51461063457806381a1452c146106545780638da5cb5b146106675780638fbb5fa71461067c576102e4565b806333df4b2c1161024f57806342842e0e116102085780634f6ccce7116101e25780634f6ccce7146105955780635c3dbbda146105b55780635c975abb146105ca5780636352211e146105df576102e4565b806342842e0e1461053e57806349e3b2921461055e5780634f02c42014610573576102e4565b806333df4b2c146104875780633431a753146104b457806336838391146104d45780633b342a85146104f45780633ccfd60b146105145780634018b1f814610529576102e4565b806316c38b3c116102a157806316c38b3c146103d057806318160ddd146103f0578063194f480e1461041257806323b872dd1461042757806327de8f27146104475780632f745c5914610467576102e4565b806301ffc9a7146102e95780630442bfa81461031f57806306fdde0314610341578063081812fc14610363578063095ea7b314610390578063110a2ded146103b0575b600080fd5b3480156102f557600080fd5b50610309610304366004612d00565b6108d1565b6040516103169190612fed565b60405180910390f35b34801561032b57600080fd5b5061033f61033a366004612e21565b6108fe565b005b34801561034d57600080fd5b5061035661097b565b604051610316919061304b565b34801561036f57600080fd5b5061038361037e366004612dab565b610a0d565b6040516103169190612f05565b34801561039c57600080fd5b5061033f6103ab366004612c9d565b610a50565b3480156103bc57600080fd5b5061033f6103cb366004612b19565b610ae8565b3480156103dc57600080fd5b5061033f6103eb366004612cc8565b610b49565b3480156103fc57600080fd5b50610405610ba6565b604051610316919061372e565b34801561041e57600080fd5b50610383610bac565b34801561043357600080fd5b5061033f610442366004612b89565b610bbb565b34801561045357600080fd5b50610405610462366004612dab565b610c15565b34801561047357600080fd5b50610405610482366004612c9d565b610cd5565b34801561049357600080fd5b506104a76104a2366004612e21565b610d2a565b6040516103169190613737565b3480156104c057600080fd5b5061033f6104cf366004612dab565b610d70565b3480156104e057600080fd5b506104a76104ef366004612e21565b610db4565b34801561050057600080fd5b5061033f61050f366004612b19565b610dc4565b34801561052057600080fd5b5061033f610e25565b34801561053557600080fd5b50610405610ea5565b34801561054a57600080fd5b5061033f610559366004612b89565b610eab565b34801561056a57600080fd5b50610405610ec6565b34801561057f57600080fd5b50610588610ecc565b604051610316919061371f565b3480156105a157600080fd5b506104056105b0366004612dab565b610ed6565b3480156105c157600080fd5b50610405610f31565b3480156105d657600080fd5b50610309610f37565b3480156105eb57600080fd5b506103836105fa366004612dab565b610f47565b34801561060b57600080fd5b5061040561061a366004612b19565b610f7c565b34801561062b57600080fd5b5061033f610fc0565b34801561064057600080fd5b5061033f61064f366004612b19565b61100b565b61033f610662366004612ddb565b61106c565b34801561067357600080fd5b50610383611671565b34801561068857600080fd5b50610383611680565b34801561069d57600080fd5b5061033f6106ac366004612b19565b61168f565b3480156106bd57600080fd5b506106d16106cc366004612dab565b6116f8565b6040516103169190613656565b3480156106ea57600080fd5b506103566117b5565b3480156106ff57600080fd5b5061033f61070e366004612b19565b6117c4565b34801561071f57600080fd5b5061040561072e366004612dab565b611825565b34801561073f57600080fd5b5061033f61074e366004612c70565b611837565b34801561075f57600080fd5b5061033f61076e366004612bc9565b611905565b34801561077f57600080fd5b50610405611944565b34801561079457600080fd5b5061040561194a565b3480156107a957600080fd5b506103566107b8366004612dab565b611950565b3480156107c957600080fd5b5061033f6107d8366004612b19565b6119fb565b3480156107e957600080fd5b50610383611a5c565b3480156107fe57600080fd5b5061081261080d366004612dab565b611a6b565b6040516103169a99989796959493929190612ff8565b34801561083457600080fd5b50610383611ade565b34801561084957600080fd5b50610383611aed565b34801561085e57600080fd5b5061030961086d366004612b51565b611afc565b34801561087e57600080fd5b50610383611b2a565b34801561089357600080fd5b50610383611b39565b3480156108a857600080fd5b5061033f6108b7366004612b19565b611b4e565b3480156108c857600080fd5b50610405611bbc565b60006001600160e01b0319821663780e9d6360e01b14806108f657506108f682611be0565b90505b919050565b610906611c20565b6001600160a01b0316610917611671565b6001600160a01b0316146109465760405162461bcd60e51b815260040161093d90613455565b60405180910390fd5b8061095557600b829055610977565b806001141561096857600c829055610977565b806002141561097757600d8290555b5050565b60606000805461098a9061384a565b80601f01602080910402602001604051908101604052809291908181526020018280546109b69061384a565b8015610a035780601f106109d857610100808354040283529160200191610a03565b820191906000526020600020905b8154815290600101906020018083116109e657829003601f168201915b5050505050905090565b6000610a1882611c24565b610a345760405162461bcd60e51b815260040161093d90613409565b506000908152600460205260409020546001600160a01b031690565b6000610a5b82610f47565b9050806001600160a01b0316836001600160a01b03161415610a8f5760405162461bcd60e51b815260040161093d90613522565b806001600160a01b0316610aa1611c20565b6001600160a01b03161480610abd5750610abd8161086d611c20565b610ad95760405162461bcd60e51b815260040161093d906132e4565b610ae38383611c41565b505050565b610af0611c20565b6001600160a01b0316610b01611671565b6001600160a01b031614610b275760405162461bcd60e51b815260040161093d90613455565b603880546001600160a01b0319166001600160a01b0392909216919091179055565b610b51611c20565b6001600160a01b0316610b62611671565b6001600160a01b031614610b885760405162461bcd60e51b815260040161093d90613455565b8015610b9b57610b96611caf565b610ba3565b610ba3611d27565b50565b60085490565b6036546001600160a01b031681565b6036546001600160a01b0316610bcf611c20565b6001600160a01b031614610c0a57610bee610be8611c20565b82611d81565b610c0a5760405162461bcd60e51b815260040161093d90613563565b610ae3838383611e06565b6000600e548211610c28575060006108f9565b6005610c557f000000000000000000000000000000000000000000000000000000000000c35060026137e8565b610c5f91906137d4565b8211610c76575069043c33c19375648000006108f9565b6005610ca37f000000000000000000000000000000000000000000000000000000000000c35060046137e8565b610cad91906137d4565b8211610cc45750690878678326eac90000006108f9565b506910f0cf064dd592000000919050565b6000610ce083610f7c565b8210610cfe5760405162461bcd60e51b815260040161093d9061308c565b506001600160a01b03821660009081526006602090815260408083208484529091529020545b92915050565b60128260128110610d3a57600080fd5b018181548110610d4957600080fd5b9060005260206000209060209182820401919006915091509054906101000a900460ff1681565b610d78611c20565b6001600160a01b0316610d89611671565b6001600160a01b031614610daf5760405162461bcd60e51b815260040161093d90613455565b600e55565b60248260128110610d3a57600080fd5b610dcc611c20565b6001600160a01b0316610ddd611671565b6001600160a01b031614610e035760405162461bcd60e51b815260040161093d90613455565b603680546001600160a01b0319166001600160a01b0392909216919091179055565b610e2d611c20565b6001600160a01b0316610e3e611671565b6001600160a01b031614610e645760405162461bcd60e51b815260040161093d90613455565b600f546040516001600160a01b036201000090920491909116904780156108fc02916000818181858888f19350505050158015610ba3573d6000803e3d6000fd5b600e5490565b610ae383838360405180602001604052806000815250611905565b600d5481565b600f5461ffff1681565b6000610ee0610ba6565b8210610efe5760405162461bcd60e51b815260040161093d906135e1565b60088281548110610f1f57634e487b7160e01b600052603260045260246000fd5b90600052602060002001549050919050565b600c5481565b600a54600160a01b900460ff1690565b6000818152600260205260408120546001600160a01b0316806108f65760405162461bcd60e51b815260040161093d9061338b565b60006001600160a01b038216610fa45760405162461bcd60e51b815260040161093d90613341565b506001600160a01b031660009081526003602052604090205490565b610fc8611c20565b6001600160a01b0316610fd9611671565b6001600160a01b031614610fff5760405162461bcd60e51b815260040161093d90613455565b6110096000611f33565b565b611013611c20565b6001600160a01b0316611024611671565b6001600160a01b03161461104a5760405162461bcd60e51b815260040161093d90613455565b603b80546001600160a01b0319166001600160a01b0392909216919091179055565b611074610f37565b156110915760405162461bcd60e51b815260040161093d906132ba565b611099611c20565b6001600160a01b0316326001600160a01b0316146110c95760405162461bcd60e51b815260040161093d906131d1565b600f547f000000000000000000000000000000000000000000000000000000000000c350906110fd90859061ffff16613797565b111561111b5760405162461bcd60e51b815260040161093d9061316f565b60008311801561112c5750600a8311155b6111485760405162461bcd60e51b815260040161093d906135b4565b60ff81161580156111605750600e54600f5461ffff16105b156111fa57600e54600f5461117a90859061ffff16613797565b116111b057600b5461118c90846137e8565b3410156111ab5760405162461bcd60e51b815260040161093d9061362d565b6111fa565b600b54600e54600f546111c79061ffff1686613797565b6111d19190613807565b6111db91906137e8565b3410156111fa5760405162461bcd60e51b815260040161093d9061362d565b600080600080856112195760408051600081526020810190915261126b565b8667ffffffffffffffff81111561124057634e487b7160e01b600052604160045260246000fd5b604051908082528060200260200182016040528015611269578160200160208202803683370190505b505b90506000805b8881101561148357600f805461ffff1690600061128d83613885565b82546101009290920a61ffff818102199093169183160217909155603b54600f5460405163b863bd3760e01b81526001600160a01b03909216935063b863bd37926112dd9291169060040161371f565b60206040518083038186803b1580156112f557600080fd5b505afa158015611309573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061132d9190612dc3565b600f549092506113419061ffff1683611f85565b50600061134d836121d4565b9050881580611375575061135f611c20565b6001600160a01b0316816001600160a01b031614155b1561139157600f5461138c90829061ffff166122b6565b6113f1565b603654600f546113ae916001600160a01b03169061ffff166122b6565b600f54845161ffff909116908590849081106113da57634e487b7160e01b600052603260045260246000fd5b602002602001019061ffff16908161ffff16815250505b8760ff16600114801561140b5750600e54600f5461ffff16105b1561142457600c5461141d9088613797565b9650611453565b8760ff16600214801561143e5750600e54600f5461ffff16105b1561145357600d546114509087613797565b95505b600f546114639061ffff16610c15565b61146d9086613797565b945050808061147b906138a7565b915050611271565b5084156114f4576037546001600160a01b0316639dc29fac6114a3611c20565b876040518363ffffffff1660e01b81526004016114c1929190612fd4565b600060405180830381600087803b1580156114db57600080fd5b505af11580156114ef573d6000803e3d6000fd5b505050505b8215611564576038546001600160a01b0316639dc29fac611513611c20565b856040518363ffffffff1660e01b8152600401611531929190612fd4565b600060405180830381600087803b15801561154b57600080fd5b505af115801561155f573d6000803e3d6000fd5b505050505b83156115f7576039546001600160a01b03166323b872dd611583611c20565b30876040518463ffffffff1660e01b81526004016115a393929190612f19565b602060405180830381600087803b1580156115bd57600080fd5b505af11580156115d1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115f59190612ce4565b505b8615611667576036546001600160a01b03166381d449c1611616611c20565b846040518363ffffffff1660e01b8152600401611634929190612f7a565b600060405180830381600087803b15801561164e57600080fd5b505af1158015611662573d6000803e3d6000fd5b505050505b5050505050505050565b600a546001600160a01b031690565b6037546001600160a01b031681565b611697611c20565b6001600160a01b03166116a8611671565b6001600160a01b0316146116ce5760405162461bcd60e51b815260040161093d90613455565b600f80546001600160a01b03909216620100000262010000600160b01b0319909216919091179055565b611700612ac5565b50600090815260106020908152604091829020825161014081018452905460ff808216151583526101008083048216948401949094526201000082048116948301949094526301000000810484166060830152640100000000810484166080830152650100000000008104841660a083015266010000000000008104841660c0830152600160381b8104841660e0830152600160401b8104841692820192909252600160481b90910490911661012082015290565b60606001805461098a9061384a565b6117cc611c20565b6001600160a01b03166117dd611671565b6001600160a01b0316146118035760405162461bcd60e51b815260040161093d90613455565b603980546001600160a01b0319166001600160a01b0392909216919091179055565b60116020526000908152604090205481565b61183f611c20565b6001600160a01b0316826001600160a01b031614156118705760405162461bcd60e51b815260040161093d90613237565b806005600061187d611c20565b6001600160a01b03908116825260208083019390935260409182016000908120918716808252919093529120805460ff1916921515929092179091556118c1611c20565b6001600160a01b03167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31836040516118f99190612fed565b60405180910390a35050565b611916611910611c20565b83611d81565b6119325760405162461bcd60e51b815260040161093d90613563565b61193e848484846122d0565b50505050565b600b5481565b600e5481565b606061195b82611c24565b6119775760405162461bcd60e51b815260040161093d906134d3565b603a5460405163c87b56dd60e01b81526001600160a01b039091169063c87b56dd906119a790859060040161372e565b60006040518083038186803b1580156119bf57600080fd5b505afa1580156119d3573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526108f69190810190612d38565b611a03611c20565b6001600160a01b0316611a14611671565b6001600160a01b031614611a3a5760405162461bcd60e51b815260040161093d90613455565b603780546001600160a01b0319166001600160a01b0392909216919091179055565b6038546001600160a01b031681565b60106020526000908152604090205460ff80821691610100810482169162010000820481169163010000008104821691640100000000820481169165010000000000810482169166010000000000008204811691600160381b8104821691600160401b8204811691600160481b9004168a565b6039546001600160a01b031681565b603a546001600160a01b031681565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b603b546001600160a01b031681565b600f546201000090046001600160a01b031681565b611b56611c20565b6001600160a01b0316611b67611671565b6001600160a01b031614611b8d5760405162461bcd60e51b815260040161093d90613455565b6001600160a01b038116611bb35760405162461bcd60e51b815260040161093d90613129565b610ba381611f33565b7f000000000000000000000000000000000000000000000000000000000000c35081565b60006001600160e01b031982166380ac58cd60e01b1480611c1157506001600160e01b03198216635b5e139f60e01b145b806108f657506108f682612303565b3390565b6000908152600260205260409020546001600160a01b0316151590565b600081815260046020526040902080546001600160a01b0319166001600160a01b0384169081179091558190611c7682610f47565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b611cb7610f37565b15611cd45760405162461bcd60e51b815260040161093d906132ba565b600a805460ff60a01b1916600160a01b1790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258611d10611c20565b604051611d1d9190612f05565b60405180910390a1565b611d2f610f37565b611d4b5760405162461bcd60e51b815260040161093d9061305e565b600a805460ff60a01b191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa611d10611c20565b6000611d8c82611c24565b611da85760405162461bcd60e51b815260040161093d9061326e565b6000611db383610f47565b9050806001600160a01b0316846001600160a01b03161480611dee5750836001600160a01b0316611de384610a0d565b6001600160a01b0316145b80611dfe5750611dfe8185611afc565b949350505050565b826001600160a01b0316611e1982610f47565b6001600160a01b031614611e3f5760405162461bcd60e51b815260040161093d9061348a565b6001600160a01b038216611e655760405162461bcd60e51b815260040161093d906131f3565b611e7083838361231c565b611e7b600082611c41565b6001600160a01b0383166000908152600360205260408120805460019290611ea4908490613807565b90915550506001600160a01b0382166000908152600360205260408120805460019290611ed2908490613797565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b600a80546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b611f8d612ac5565b611f96826123a5565b905060116000611fa583612513565b8152602001908152602001600020546000141561214257806010600085815260200190815260200160002060008201518160000160006101000a81548160ff02191690831515021790555060208201518160000160016101000a81548160ff021916908360ff16021790555060408201518160000160026101000a81548160ff021916908360ff16021790555060608201518160000160036101000a81548160ff021916908360ff16021790555060808201518160000160046101000a81548160ff021916908360ff16021790555060a08201518160000160056101000a81548160ff021916908360ff16021790555060c08201518160000160066101000a81548160ff021916908360ff16021790555060e08201518160000160076101000a81548160ff021916908360ff1602179055506101008201518160000160086101000a81548160ff021916908360ff1602179055506101208201518160000160096101000a81548160ff021916908360ff160217905550905050826011600061212c84612513565b8152602081019190915260400160002055610d24565b603b5460405163b863bd3760e01b81526121cd9185916001600160a01b039091169063b863bd379061217890879060040161372e565b60206040518083038186803b15801561219057600080fd5b505afa1580156121a4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906121c89190612dc3565b611f85565b9392505050565b600e54600f5460009161ffff9091161115806121fd57506121fa600a60f584901c6138c2565b15155b156122115761220a611c20565b90506108f9565b603654604051631e4c4f3560e11b81526000916001600160a01b031690633c989e6a9061224690609087901c9060040161372e565b60206040518083038186803b15801561225e57600080fd5b505afa158015612272573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906122969190612b35565b90506001600160a01b0381166108f6576122ae611c20565b9150506108f9565b610977828260405180602001604052806000815250612572565b6122db848484611e06565b6122e7848484846125a5565b61193e5760405162461bcd60e51b815260040161093d906130d7565b6001600160e01b031981166301ffc9a760e01b14919050565b612327838383610ae3565b6001600160a01b0383166123435761233e816126c0565b612366565b816001600160a01b0316836001600160a01b031614612366576123668382612704565b6001600160a01b0382166123825761237d816127a1565b610ae3565b826001600160a01b0316826001600160a01b031614610ae357610ae3828261287a565b6123ad612ac5565b6123bc600a61ffff84166138c2565b15158082526000906123cf5760096123d2565b60005b60109390931c9290506123f361ffff84166123ee8360006137af565b6128be565b60ff16602083015260109290921c9161241561ffff84166123ee8360016137af565b60ff16604083015260109290921c9161243761ffff84166123ee8360026137af565b60ff16606083015260109290921c9161245961ffff84166123ee8360036137af565b60ff16608083015260109290921c9161247b61ffff84166123ee8360046137af565b60ff1660a083015260109290921c9161249d61ffff84166123ee8360056137af565b60ff1660c083015260109290921c916124bf61ffff84166123ee8360066137af565b60ff1660e083015260109290921c916124e161ffff84166123ee8360076137af565b60ff1661010083015260109290921c9161250461ffff84166123ee8360086137af565b60ff1661012083015250919050565b8051602080830151604080850151608086015160c087015160e088015160608901516101008a01516101208b0151965160009a6125549a9099989101612e8c565b60408051601f19818403018152919052805160209091012092915050565b61257c83836129e0565b61258960008484846125a5565b610ae35760405162461bcd60e51b815260040161093d906130d7565b60006125b9846001600160a01b0316612abf565b156126b557836001600160a01b031663150b7a026125d5611c20565b8786866040518563ffffffff1660e01b81526004016125f79493929190612f3d565b602060405180830381600087803b15801561261157600080fd5b505af1925050508015612641575060408051601f3d908101601f1916820190925261263e91810190612d1c565b60015b61269b573d80801561266f576040519150601f19603f3d011682016040523d82523d6000602084013e612674565b606091505b5080516126935760405162461bcd60e51b815260040161093d906130d7565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611dfe565b506001949350505050565b600880546000838152600960205260408120829055600182018355919091527ff3f7a9fe364faab93b216da50a3214154f22a0a2b415b23a84c8169e8b636ee30155565b6000600161271184610f7c565b61271b9190613807565b60008381526007602052604090205490915080821461276e576001600160a01b03841660009081526006602090815260408083208584528252808320548484528184208190558352600790915290208190555b5060009182526007602090815260408084208490556001600160a01b039094168352600681528383209183525290812055565b6008546000906127b390600190613807565b600083815260096020526040812054600880549394509092849081106127e957634e487b7160e01b600052603260045260246000fd5b90600052602060002001549050806008838154811061281857634e487b7160e01b600052603260045260246000fd5b600091825260208083209091019290925582815260099091526040808220849055858252812055600880548061285e57634e487b7160e01b600052603160045260246000fd5b6001900381819060005260206000200160009055905550505050565b600061288583610f7c565b6001600160a01b039093166000908152600660209081526040808320868452825280832085905593825260079052919091209190915550565b60008060128360ff16601281106128e557634e487b7160e01b600052603260045260246000fd5b01546128f190856138d6565b905060128360ff166012811061291757634e487b7160e01b600052603260045260246000fd5b018160ff168154811061293a57634e487b7160e01b600052603260045260246000fd5b60009182526020918290209181049091015460ff601f9092166101000a90048116600886901c9091161015612970579050610d24565b60248360ff166012811061299457634e487b7160e01b600052603260045260246000fd5b018160ff16815481106129b757634e487b7160e01b600052603260045260246000fd5b90600052602060002090602091828204019190069054906101000a900460ff1691505092915050565b6001600160a01b038216612a065760405162461bcd60e51b815260040161093d906133d4565b612a0f81611c24565b15612a2c5760405162461bcd60e51b815260040161093d9061319a565b612a386000838361231c565b6001600160a01b0382166000908152600360205260408120805460019290612a61908490613797565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b3b151590565b6040805161014081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081019190915290565b600060208284031215612b2a578081fd5b81356121cd8161393a565b600060208284031215612b46578081fd5b81516121cd8161393a565b60008060408385031215612b63578081fd5b8235612b6e8161393a565b91506020830135612b7e8161393a565b809150509250929050565b600080600060608486031215612b9d578081fd5b8335612ba88161393a565b92506020840135612bb88161393a565b929592945050506040919091013590565b60008060008060808587031215612bde578081fd5b8435612be98161393a565b93506020850135612bf98161393a565b925060408501359150606085013567ffffffffffffffff811115612c1b578182fd5b8501601f81018713612c2b578182fd5b8035612c3e612c398261376f565b613745565b818152886020838501011115612c52578384fd5b81602084016020830137908101602001929092525092959194509250565b60008060408385031215612c82578182fd5b8235612c8d8161393a565b91506020830135612b7e8161394f565b60008060408385031215612caf578182fd5b8235612cba8161393a565b946020939093013593505050565b600060208284031215612cd9578081fd5b81356121cd8161394f565b600060208284031215612cf5578081fd5b81516121cd8161394f565b600060208284031215612d11578081fd5b81356121cd8161395d565b600060208284031215612d2d578081fd5b81516121cd8161395d565b600060208284031215612d49578081fd5b815167ffffffffffffffff811115612d5f578182fd5b8201601f81018413612d6f578182fd5b8051612d7d612c398261376f565b818152856020838501011115612d91578384fd5b612da282602083016020860161381e565b95945050505050565b600060208284031215612dbc578081fd5b5035919050565b600060208284031215612dd4578081fd5b5051919050565b600080600060608486031215612def578081fd5b833592506020840135612e018161394f565b9150604084013560ff81168114612e16578182fd5b809150509250925092565b60008060408385031215612e33578182fd5b50508035926020909101359150565b15159052565b60008151808452612e6081602086016020860161381e565b601f01601f19169290920160200192915050565b60ff169052565b60f81b6001600160f81b0319169052565b89151560f890811b82526001600160f81b03198a821b8116600184015289821b8116600284015288821b8116600384015287821b8116600484015286821b8116600584015285821b811660068401529084901b1660078201526000612ef46008830184612e7b565b506009019998505050505050505050565b6001600160a01b0391909116815260200190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090612f7090830184612e48565b9695505050505050565b6001600160a01b038316815260406020808301829052835191830182905260009184820191906060850190845b81811015612fc757845161ffff1683529383019391830191600101612fa7565b5090979650505050505050565b6001600160a01b03929092168252602082015260400190565b901515815260200190565b9915158a5260ff98891660208b015296881660408a01529487166060890152928616608088015290851660a0870152841660c0860152831660e08501528216610100840152166101208201526101400190565b6000602082526121cd6020830184612e48565b60208082526014908201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b604082015260600190565b6020808252602b908201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560408201526a74206f6620626f756e647360a81b606082015260800190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526026908201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160408201526564647265737360d01b606082015260800190565b602080825260119082015270105b1b081d1bdad95b9cc81b5a5b9d1959607a1b604082015260600190565b6020808252601c908201527f4552433732313a20746f6b656e20616c7265616479206d696e74656400000000604082015260600190565b6020808252600890820152674f6e6c7920454f4160c01b604082015260600190565b60208082526024908201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646040820152637265737360e01b606082015260800190565b60208082526019908201527f4552433732313a20617070726f766520746f2063616c6c657200000000000000604082015260600190565b6020808252602c908201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860408201526b34b9ba32b73a103a37b5b2b760a11b606082015260800190565b60208082526010908201526f14185d5cd8589b194e881c185d5cd95960821b604082015260600190565b60208082526038908201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760408201527f6e6572206e6f7220617070726f76656420666f7220616c6c0000000000000000606082015260800190565b6020808252602a908201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604082015269726f206164647265737360b01b606082015260800190565b60208082526029908201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460408201526832b73a103a37b5b2b760b91b606082015260800190565b6020808252818101527f4552433732313a206d696e7420746f20746865207a65726f2061646472657373604082015260600190565b6020808252602c908201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860408201526b34b9ba32b73a103a37b5b2b760a11b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526029908201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960408201526839903737ba1037bbb760b91b606082015260800190565b6020808252602f908201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60408201526e3732bc34b9ba32b73a103a37b5b2b760891b606082015260800190565b60208082526021908201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656040820152603960f91b606082015260800190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b602080825260139082015272125b9d985b1a59081b5a5b9d08185b5bdd5b9d606a1b604082015260600190565b6020808252602c908201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60408201526b7574206f6620626f756e647360a01b606082015260800190565b6020808252600f908201526e6e6f7420656e6f756768742046544d60881b604082015260600190565b60006101408201905061366a828451612e42565b602083015161367c6020840182612e74565b50604083015161368f6040840182612e74565b5060608301516136a26060840182612e74565b5060808301516136b56080840182612e74565b5060a08301516136c860a0840182612e74565b5060c08301516136db60c0840182612e74565b5060e08301516136ee60e0840182612e74565b506101008084015161370282850182612e74565b50506101208084015161371782850182612e74565b505092915050565b61ffff91909116815260200190565b90815260200190565b60ff91909116815260200190565b60405181810167ffffffffffffffff8111828210171561376757613767613924565b604052919050565b600067ffffffffffffffff82111561378957613789613924565b50601f01601f191660200190565b600082198211156137aa576137aa6138f8565b500190565b600060ff821660ff84168060ff038211156137cc576137cc6138f8565b019392505050565b6000826137e3576137e361390e565b500490565b6000816000190483118215151615613802576138026138f8565b500290565b600082821015613819576138196138f8565b500390565b60005b83811015613839578181015183820152602001613821565b8381111561193e5750506000910152565b60028104600182168061385e57607f821691505b6020821081141561387f57634e487b7160e01b600052602260045260246000fd5b50919050565b600061ffff8083168181141561389d5761389d6138f8565b6001019392505050565b60006000198214156138bb576138bb6138f8565b5060010190565b6000826138d1576138d161390e565b500690565b600060ff8316806138e9576138e961390e565b8060ff84160691505092915050565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610ba357600080fd5b8015158114610ba357600080fd5b6001600160e01b031981168114610ba357600080fdfea2646970667358221220c9c6c1df7c0e7c5d82e415511d7bba0b5256f87e1b4c8418585bbeb91b903a6664736f6c63430008000033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000002e4bf93bded3236d0719aa3ceb43932f279efe1f00000000000000000000000090ad9988e7050db30829164b8e9837a351654863000000000000000000000000b6591e04238a187053186b07593ba4aab20acba8000000000000000000000000000000000000000000000000000000000000c350
-----Decoded View---------------
Arg [0] : _wool (address): 0x2E4bF93BdEd3236D0719aa3ceB43932f279EFe1F
Arg [1] : _milk (address): 0x90ad9988e7050Db30829164b8E9837A351654863
Arg [2] : _traits (address): 0xB6591e04238a187053186B07593ba4aab20ACba8
Arg [3] : _maxTokens (uint256): 50000
-----Encoded View---------------
4 Constructor Arguments found :
Arg [0] : 0000000000000000000000002e4bf93bded3236d0719aa3ceb43932f279efe1f
Arg [1] : 00000000000000000000000090ad9988e7050db30829164b8e9837a351654863
Arg [2] : 000000000000000000000000b6591e04238a187053186b07593ba4aab20acba8
Arg [3] : 000000000000000000000000000000000000000000000000000000000000c350
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.