More Info
Private Name Tags
Latest 25 from a total of 444 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Set Banker | 11434907 | 1369 days ago | IN | 0 ETH | 0.00259283 | ||||
Set Secondary Ma... | 11434873 | 1369 days ago | IN | 0 ETH | 0.0025691 | ||||
Set Primary Mana... | 11434870 | 1369 days ago | IN | 0 ETH | 0.00257347 | ||||
Withdraw Balance | 11087791 | 1422 days ago | IN | 0 ETH | 0.00251664 | ||||
Buy Asset | 11059070 | 1426 days ago | IN | 19.81232523 ETH | 0.01049213 | ||||
Create Sale | 11022727 | 1432 days ago | IN | 0 ETH | 0.0291756 | ||||
Buy Asset | 11014795 | 1433 days ago | IN | 8.70599539 ETH | 0.00730232 | ||||
Create Sale | 10965214 | 1441 days ago | IN | 0 ETH | 0.0437634 | ||||
Buy Asset | 10955564 | 1442 days ago | IN | 18.9987949 ETH | 0.01211761 | ||||
Create Sale | 10907330 | 1450 days ago | IN | 0 ETH | 0.0900468 | ||||
Buy Asset | 10900434 | 1451 days ago | IN | 1.56710312 ETH | 0.02172416 | ||||
Create Sale | 10848660 | 1459 days ago | IN | 0 ETH | 0.0291756 | ||||
Buy Asset | 10841566 | 1460 days ago | IN | 2.37564335 ETH | 0.03275699 | ||||
Create Sale | 10789803 | 1468 days ago | IN | 0 ETH | 0.15629368 | ||||
Withdraw Balance | 8678380 | 1803 days ago | IN | 0 ETH | 0.00024434 | ||||
Buy Asset | 8661599 | 1805 days ago | IN | 89.92011574 ETH | 0.00264851 | ||||
Create Sale | 8625997 | 1811 days ago | IN | 0 ETH | 0.00284057 | ||||
Buy Asset | 8624714 | 1811 days ago | IN | 30.06463348 ETH | 0.00566598 | ||||
Withdraw Balance | 8606966 | 1814 days ago | IN | 0 ETH | 0.00060935 | ||||
Create Sale | 8587694 | 1817 days ago | IN | 0 ETH | 0.00595025 | ||||
Buy Asset | 8587468 | 1817 days ago | IN | 9.83885416 ETH | 0.00391347 | ||||
Create Sale | 8561966 | 1821 days ago | IN | 0 ETH | 0.00355819 | ||||
Buy Asset | 8561194 | 1821 days ago | IN | 22.53097222 ETH | 0.00348167 | ||||
Create Sale | 8523540 | 1827 days ago | IN | 0 ETH | 0.00505362 | ||||
Withdraw Balance | 8518288 | 1828 days ago | IN | 0 ETH | 0.00029562 |
Latest 25 internal transactions (View All)
Advanced mode:
Parent Transaction Hash | Block | From | To | |||
---|---|---|---|---|---|---|
11087791 | 1422 days ago | 51.34238922 ETH | ||||
11059070 | 1426 days ago | 0.02697569 ETH | ||||
11014795 | 1433 days ago | 0.01863891 ETH | ||||
10955564 | 1442 days ago | 0.03352928 ETH | ||||
10900434 | 1451 days ago | 0.01669609 ETH | ||||
10841566 | 1460 days ago | 0.02163281 ETH | ||||
8678380 | 1803 days ago | 119.8142554 ETH | ||||
8661599 | 1805 days ago | 0.14548611 ETH | ||||
8624714 | 1811 days ago | 0.02500771 ETH | ||||
8606966 | 1814 days ago | 32.10746527 ETH | ||||
8587468 | 1817 days ago | 0.25375 ETH | ||||
8561194 | 1821 days ago | 0.00861111 ETH | ||||
8518288 | 1828 days ago | 254.27847029 ETH | ||||
8517783 | 1828 days ago | 0.0608179 ETH | ||||
8482369 | 1833 days ago | 0.10040895 ETH | ||||
8442264 | 1840 days ago | 0.19956712 ETH | ||||
8442248 | 1840 days ago | 0.00031018 ETH | ||||
8442239 | 1840 days ago | 0.00012268 ETH | ||||
7857886 | 1931 days ago | 61.36623338 ETH | ||||
7194242 | 2041 days ago | 0.00186425 ETH | ||||
7189309 | 2042 days ago | 0.00003918 ETH | ||||
7189304 | 2042 days ago | 0.00003918 ETH | ||||
7178028 | 2044 days ago | 0.00005069 ETH | ||||
7177986 | 2044 days ago | 0.00007615 ETH | ||||
7177901 | 2044 days ago | 0.00001603 ETH |
Loading...
Loading
Contract Name:
CSCTimeSaleManager
Compiler Version
v0.4.23+commit.124ca40d
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity)
/** *Submitted for verification at Etherscan.io on 2018-07-30 */ pragma solidity ^0.4.23; /* Controls state and access rights for contract functions * @title Operational Control * @author Fazri Zubair & Farhan Khwaja (Lucid Sight, Inc.) * Inspired and adapted from contract created by OpenZeppelin * Ref: https://github.com/OpenZeppelin/zeppelin-solidity/ */ contract OperationalControl { // Facilitates access & control for the game. // Roles: // -The Managers (Primary/Secondary): Has universal control of all elements (No ability to withdraw) // -The Banker: The Bank can withdraw funds and adjust fees / prices. // -otherManagers: Contracts that need access to functions for gameplay /// @dev Emited when contract is upgraded event ContractUpgrade(address newContract); // The addresses of the accounts (or contracts) that can execute actions within each roles. address public managerPrimary; address public managerSecondary; address public bankManager; // Contracts that require access for gameplay mapping(address => uint8) public otherManagers; // @dev Keeps track whether the contract is paused. When that is true, most actions are blocked bool public paused = false; // @dev Keeps track whether the contract erroredOut. When that is true, most actions are blocked & refund can be claimed bool public error = false; /// @dev Operation modifiers for limiting access modifier onlyManager() { require(msg.sender == managerPrimary || msg.sender == managerSecondary); _; } modifier onlyBanker() { require(msg.sender == bankManager); _; } modifier onlyOtherManagers() { require(otherManagers[msg.sender] == 1); _; } modifier anyOperator() { require( msg.sender == managerPrimary || msg.sender == managerSecondary || msg.sender == bankManager || otherManagers[msg.sender] == 1 ); _; } /// @dev Assigns a new address to act as the Other Manager. (State = 1 is active, 0 is disabled) function setOtherManager(address _newOp, uint8 _state) external onlyManager { require(_newOp != address(0)); otherManagers[_newOp] = _state; } /// @dev Assigns a new address to act as the Primary Manager. function setPrimaryManager(address _newGM) external onlyManager { require(_newGM != address(0)); managerPrimary = _newGM; } /// @dev Assigns a new address to act as the Secondary Manager. function setSecondaryManager(address _newGM) external onlyManager { require(_newGM != address(0)); managerSecondary = _newGM; } /// @dev Assigns a new address to act as the Banker. function setBanker(address _newBK) external onlyManager { require(_newBK != address(0)); bankManager = _newBK; } /*** Pausable functionality adapted from OpenZeppelin ***/ /// @dev Modifier to allow actions only when the contract IS NOT paused modifier whenNotPaused() { require(!paused); _; } /// @dev Modifier to allow actions only when the contract IS paused modifier whenPaused { require(paused); _; } /// @dev Modifier to allow actions only when the contract has Error modifier whenError { require(error); _; } /// @dev Called by any Operator role to pause the contract. /// Used only if a bug or exploit is discovered (Here to limit losses / damage) function pause() external onlyManager whenNotPaused { paused = true; } /// @dev Unpauses the smart contract. Can only be called by the Game Master /// @notice This is public rather than external so it can be called by derived contracts. function unpause() public onlyManager whenPaused { // can't unpause if contract was upgraded paused = false; } /// @dev Unpauses the smart contract. Can only be called by the Game Master /// @notice This is public rather than external so it can be called by derived contracts. function hasError() public onlyManager whenPaused { error = true; } /// @dev Unpauses the smart contract. Can only be called by the Game Master /// @notice This is public rather than external so it can be called by derived contracts. function noError() public onlyManager whenPaused { error = false; } } contract CSCNFTFactory { /** Public Functions */ function getAssetDetails(uint256 _assetId) public view returns( uint256 assetId, uint256 ownersIndex, uint256 assetTypeSeqId, uint256 assetType, uint256 createdTimestamp, uint256 isAttached, address creator, address owner ); function getAssetDetailsURI(uint256 _assetId) public view returns( uint256 assetId, uint256 ownersIndex, uint256 assetTypeSeqId, uint256 assetType, uint256 createdTimestamp, uint256 isAttached, address creator, address owner, string metaUriAddress ); function getAssetRawMeta(uint256 _assetId) public view returns( uint256 dataA, uint128 dataB ); function getAssetIdItemType(uint256 _assetId) public view returns( uint256 assetType ); function getAssetIdTypeSequenceId(uint256 _assetId) public view returns( uint256 assetTypeSequenceId ); function getIsNFTAttached( uint256 _tokenId) public view returns( uint256 isAttached ); function getAssetIdCreator(uint256 _assetId) public view returns( address creator ); function getAssetIdOwnerAndOIndex(uint256 _assetId) public view returns( address owner, uint256 ownerIndex ); function getAssetIdOwnerIndex(uint256 _assetId) public view returns( uint256 ownerIndex ); function getAssetIdOwner(uint256 _assetId) public view returns( address owner ); function isAssetIdOwnerOrApproved(address requesterAddress, uint256 _assetId) public view returns( bool ); /// @param _owner The owner whose ships tokens we are interested in. /// @dev This method MUST NEVER be called by smart contract code. First, it's fairly /// expensive (it walks the entire NFT owners array looking for NFT belonging to owner), /// but it also returns a dynamic array, which is only supported for web3 calls, and /// not contract-to-contract calls. function tokensOfOwner(address _owner) external view returns(uint256[] ownerTokens); // Get the name of the Asset type function getTypeName (uint32 _type) public returns(string); function RequestDetachment( uint256 _tokenId ) public; function AttachAsset( uint256 _tokenId ) public; function BatchAttachAssets(uint256[10] _ids) public; function BatchDetachAssets(uint256[10] _ids) public; function RequestDetachmentOnPause (uint256 _tokenId) public; function burnAsset(uint256 _assetID) public; function balanceOf(address _owner) public view returns (uint256 _balance); function ownerOf(uint256 _tokenId) public view returns (address _owner); function exists(uint256 _tokenId) public view returns (bool _exists); function approve(address _to, uint256 _tokenId) public; function getApproved(uint256 _tokenId) public view returns (address _operator); function setApprovalForAll(address _operator, bool _approved) public; function isApprovedForAll(address _owner, address _operator) public view returns (bool); function transferFrom(address _from, address _to, uint256 _tokenId) public; function safeTransferFrom(address _from, address _to, uint256 _tokenId) public; function safeTransferFrom( address _from, address _to, uint256 _tokenId, bytes _data ) public; } /** * @title ERC721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC721 asset contracts. */ contract ERC721Receiver { /** * @dev Magic value to be returned upon successful reception of an NFT * Equals to `bytes4(keccak256("onERC721Received(address,uint256,bytes)"))`, * which can be also obtained as `ERC721Receiver(0).onERC721Received.selector` */ bytes4 constant ERC721_RECEIVED = 0xf0b9e5ba; /** * @notice Handle the receipt of an NFT * @dev The ERC721 smart contract calls this function on the recipient * after a `safetransfer`. This function MAY throw to revert and reject the * transfer. This function MUST use 50,000 gas or less. Return of other * than the magic value MUST result in the transaction being reverted. * Note: the contract address is always the message sender. * @param _from The sending address * @param _tokenId The NFT identifier which is being transfered * @param _data Additional data with no specified format * @return `bytes4(keccak256("onERC721Received(address,uint256,bytes)"))` */ function onERC721Received( address _from, uint256 _tokenId, bytes _data ) public returns(bytes4); } contract ERC721Holder is ERC721Receiver { function onERC721Received(address, uint256, bytes) public returns(bytes4) { return ERC721_RECEIVED; } } contract CSCTimeSaleManager is ERC721Holder, OperationalControl { //DATATYPES & CONSTANTS struct CollectibleSale { // Current owner of NFT (ERC721) address seller; // Price (in wei) at beginning of sale (For Buying) uint256 startingPrice; // Price (in wei) at end of sale (For Buying) uint256 endingPrice; // Duration (in seconds) of sale, 2592000 = 30 days uint256 duration; // Time when sale started // NOTE: 0 if this sale has been concluded uint64 startedAt; // Flag denoting is the Sale still active bool isActive; // address of the wallet who bought the asset address buyer; // ERC721 AssetID uint256 tokenId; } struct PastSales { uint256[5] sales; } // CSCNTFAddress address public NFTAddress; // Map from token to their corresponding sale. mapping (uint256 => CollectibleSale) public tokenIdToSale; // Count of AssetType Sales mapping (uint256 => uint256) public assetTypeSaleCount; // Last 5 Prices of AssetType Sales mapping (uint256 => PastSales) internal assetTypeSalePrices; uint256 public avgSalesToCount = 5; // type to sales of type mapping(uint256 => uint256[]) public assetTypeSalesTokenId; event SaleWinner(address owner, uint256 collectibleId, uint256 buyingPrice); event SaleCreated(uint256 tokenID, uint256 startingPrice, uint256 endingPrice, uint256 duration, uint64 startedAt); event SaleCancelled(address seller, uint256 collectibleId); constructor() public { require(msg.sender != address(0)); paused = true; error = false; managerPrimary = msg.sender; managerSecondary = msg.sender; bankManager = msg.sender; } function setNFTAddress(address _address) public onlyManager { NFTAddress = _address; } function setAvgSalesCount(uint256 _count) public onlyManager { avgSalesToCount = _count; } /// @dev Creates and begins a new sale. function CreateSale(uint256 _tokenId, uint256 _startingPrice, uint256 _endingPrice, uint64 _duration, address _seller) public anyOperator { _createSale(_tokenId, _startingPrice, _endingPrice, _duration, _seller); } function BatchCreateSales(uint256[] _tokenIds, uint256 _startingPrice, uint256 _endingPrice, uint64 _duration, address _seller) public anyOperator { uint256 _tokenId; for (uint256 i = 0; i < _tokenIds.length; ++i) { _tokenId = _tokenIds[i]; _createSale(_tokenId, _startingPrice, _endingPrice, _duration, _seller); } } function CreateSaleAvgPrice(uint256 _tokenId, uint256 _margin, uint _minPrice, uint256 _endingPrice, uint64 _duration, address _seller) public anyOperator { var cscNFT = CSCNFTFactory(NFTAddress); uint256 assetType = cscNFT.getAssetIdItemType(_tokenId); // Avg Price of last sales uint256 salePrice = GetAssetTypeAverageSalePrice(assetType); // 0-10,000 is mapped to 0%-100% - will be typically 12000 or 120% salePrice = salePrice * _margin / 10000; if(salePrice < _minPrice) { salePrice = _minPrice; } _createSale(_tokenId, salePrice, _endingPrice, _duration, _seller); } function BatchCreateSaleAvgPrice(uint256[] _tokenIds, uint256 _margin, uint _minPrice, uint256 _endingPrice, uint64 _duration, address _seller) public anyOperator { var cscNFT = CSCNFTFactory(NFTAddress); uint256 assetType; uint256 _tokenId; uint256 salePrice; for (uint256 i = 0; i < _tokenIds.length; ++i) { _tokenId = _tokenIds[i]; assetType = cscNFT.getAssetIdItemType(_tokenId); // Avg Price of last sales salePrice = GetAssetTypeAverageSalePrice(assetType); // 0-10,000 is mapped to 0%-100% - will be typically 12000 or 120% salePrice = salePrice * _margin / 10000; if(salePrice < _minPrice) { salePrice = _minPrice; } _tokenId = _tokenIds[i]; _createSale(_tokenId, salePrice, _endingPrice, _duration, _seller); } } function BatchCancelSales(uint256[] _tokenIds) public anyOperator { uint256 _tokenId; for (uint256 i = 0; i < _tokenIds.length; ++i) { _tokenId = _tokenIds[i]; _cancelSale(_tokenId); } } function CancelSale(uint256 _assetId) public anyOperator { _cancelSale(_assetId); } function GetCurrentSalePrice(uint256 _assetId) external view returns(uint256 _price) { CollectibleSale memory _sale = tokenIdToSale[_assetId]; return _currentPrice(_sale); } function GetCurrentTypeSalePrice(uint256 _assetType) external view returns(uint256 _price) { CollectibleSale memory _sale = tokenIdToSale[assetTypeSalesTokenId[_assetType][0]]; return _currentPrice(_sale); } function GetCurrentTypeDuration(uint256 _assetType) external view returns(uint256 _duration) { CollectibleSale memory _sale = tokenIdToSale[assetTypeSalesTokenId[_assetType][0]]; return _sale.duration; } function GetCurrentTypeStartTime(uint256 _assetType) external view returns(uint256 _startedAt) { CollectibleSale memory _sale = tokenIdToSale[assetTypeSalesTokenId[_assetType][0]]; return _sale.startedAt; } function GetCurrentTypeSaleItem(uint256 _assetType) external view returns(address seller, uint256 startingPrice, uint256 endingPrice, uint256 duration, uint256 startedAt, uint256 tokenId) { CollectibleSale memory _sale = tokenIdToSale[assetTypeSalesTokenId[_assetType][0]]; return ( _sale.seller, _sale.startingPrice, _sale.endingPrice, _sale.duration, _sale.startedAt, _sale.tokenId ); } function GetCurrentTypeSaleCount(uint256 _assetType) external view returns(uint256 _count) { return assetTypeSalesTokenId[_assetType].length; } function BuyCurrentTypeOfAsset(uint256 _assetType) external whenNotPaused payable { require(msg.sender != address(0)); require(msg.sender != address(this)); CollectibleSale memory _sale = tokenIdToSale[assetTypeSalesTokenId[_assetType][0]]; require(_isOnSale(_sale)); _buy(_sale.tokenId, msg.sender, msg.value); } /// @dev BuyNow Function which call the interncal buy function /// after doing all the pre-checks required to initiate a buy function BuyAsset(uint256 _assetId) external whenNotPaused payable { require(msg.sender != address(0)); require(msg.sender != address(this)); CollectibleSale memory _sale = tokenIdToSale[_assetId]; require(_isOnSale(_sale)); //address seller = _sale.seller; _buy(_assetId, msg.sender, msg.value); } function GetAssetTypeAverageSalePrice(uint256 _assetType) public view returns (uint256) { uint256 sum = 0; for (uint256 i = 0; i < avgSalesToCount; i++) { sum += assetTypeSalePrices[_assetType].sales[i]; } return sum / 5; } /// @dev Override unpause so it requires all external contract addresses /// to be set before contract can be unpaused. Also, we can't have /// newContractAddress set either, because then the contract was upgraded. /// @notice This is public rather than external so we can call super.unpause /// without using an expensive CALL. function unpause() public anyOperator whenPaused { // Actually unpause the contract. super.unpause(); } /// @dev Remove all Ether from the contract, which is the owner's cuts /// as well as any Ether sent directly to the contract address. /// Always transfers to the NFT (ERC721) contract, but can be called either by /// the owner or the NFT (ERC721) contract. function withdrawBalance() public onlyBanker { // We are using this boolean method to make sure that even if one fails it will still work bankManager.transfer(address(this).balance); } /// @dev Returns sales info for an CSLCollectibles (ERC721) on sale. /// @param _assetId - ID of the token on sale function getSale(uint256 _assetId) external view returns (address seller, uint256 startingPrice, uint256 endingPrice, uint256 duration, uint256 startedAt, bool isActive, address buyer, uint256 tokenId) { CollectibleSale memory sale = tokenIdToSale[_assetId]; require(_isOnSale(sale)); return ( sale.seller, sale.startingPrice, sale.endingPrice, sale.duration, sale.startedAt, sale.isActive, sale.buyer, sale.tokenId ); } /** Internal Functions */ function _createSale(uint256 _tokenId, uint256 _startingPrice, uint256 _endingPrice, uint64 _duration, address _seller) internal { var cscNFT = CSCNFTFactory(NFTAddress); require(cscNFT.isAssetIdOwnerOrApproved(this, _tokenId) == true); CollectibleSale memory onSale = tokenIdToSale[_tokenId]; require(onSale.isActive == false); // Sanity check that no inputs overflow how many bits we've allocated // to store them in the sale struct. require(_startingPrice == uint256(uint128(_startingPrice))); require(_endingPrice == uint256(uint128(_endingPrice))); require(_duration == uint256(uint64(_duration))); //Transfer ownership if needed if(cscNFT.ownerOf(_tokenId) != address(this)) { require(cscNFT.isApprovedForAll(msg.sender, this) == true); cscNFT.safeTransferFrom(cscNFT.ownerOf(_tokenId), this, _tokenId); } CollectibleSale memory sale = CollectibleSale( _seller, uint128(_startingPrice), uint128(_endingPrice), uint64(_duration), uint64(now), true, address(0), uint256(_tokenId) ); _addSale(_tokenId, sale); } /// @dev Adds an sale to the list of open sales. Also fires the /// SaleCreated event. function _addSale(uint256 _assetId, CollectibleSale _sale) internal { // Require that all sales have a duration of // at least one minute. require(_sale.duration >= 1 minutes); tokenIdToSale[_assetId] = _sale; var cscNFT = CSCNFTFactory(NFTAddress); uint256 assetType = cscNFT.getAssetIdItemType(_assetId); assetTypeSalesTokenId[assetType].push(_assetId); SaleCreated( uint256(_assetId), uint256(_sale.startingPrice), uint256(_sale.endingPrice), uint256(_sale.duration), uint64(_sale.startedAt) ); } /// @dev Returns current price of a Collectible (ERC721) on sale. Broken into two /// functions (this one, that computes the duration from the sale /// structure, and the other that does the price computation) so we /// can easily test that the price computation works correctly. function _currentPrice(CollectibleSale memory _sale) internal view returns (uint256) { uint256 secondsPassed = 0; // A bit of insurance against negative values (or wraparound). // Probably not necessary (since Ethereum guarnatees that the // now variable doesn't ever go backwards). if (now > _sale.startedAt) { secondsPassed = now - _sale.startedAt; } return _computeCurrentPrice( _sale.startingPrice, _sale.endingPrice, _sale.duration, secondsPassed ); } /// @dev Computes the current price of an sale. Factored out /// from _currentPrice so we can run extensive unit tests. /// When testing, make this function public and turn on /// `Current price computation` test suite. function _computeCurrentPrice(uint256 _startingPrice, uint256 _endingPrice, uint256 _duration, uint256 _secondsPassed) internal pure returns (uint256) { // NOTE: We don't use SafeMath (or similar) in this function because // all of our public functions carefully cap the maximum values for // time (at 64-bits) and currency (at 128-bits). _duration is // also known to be non-zero (see the require() statement in // _addSale()) if (_secondsPassed >= _duration) { // We've reached the end of the dynamic pricing portion // of the sale, just return the end price. return _endingPrice; } else { // Starting price can be higher than ending price (and often is!), so // this delta can be negative. int256 totalPriceChange = int256(_endingPrice) - int256(_startingPrice); // This multiplication can't overflow, _secondsPassed will easily fit within // 64-bits, and totalPriceChange will easily fit within 128-bits, their product // will always fit within 256-bits. int256 currentPriceChange = totalPriceChange * int256(_secondsPassed) / int256(_duration); // currentPriceChange can be negative, but if so, will have a magnitude // less that _startingPrice. Thus, this result will always end up positive. int256 currentPrice = int256(_startingPrice) + currentPriceChange; return uint256(currentPrice); } } function _buy(uint256 _assetId, address _buyer, uint256 _price) internal { CollectibleSale storage _sale = tokenIdToSale[_assetId]; // Check that the bid is greater than or equal to the current buyOut price uint256 currentPrice = _currentPrice(_sale); require(_price >= currentPrice); _sale.buyer = _buyer; _sale.isActive = false; _removeSale(_assetId); uint256 bidExcess = _price - currentPrice; _buyer.transfer(bidExcess); var cscNFT = CSCNFTFactory(NFTAddress); uint256 assetType = cscNFT.getAssetIdItemType(_assetId); _updateSaleAvgHistory(assetType, _price); cscNFT.safeTransferFrom(this, _buyer, _assetId); emit SaleWinner(_buyer, _assetId, _price); } function _cancelSale (uint256 _assetId) internal { CollectibleSale storage _sale = tokenIdToSale[_assetId]; require(_sale.isActive == true); address sellerAddress = _sale.seller; _removeSale(_assetId); var cscNFT = CSCNFTFactory(NFTAddress); cscNFT.safeTransferFrom(this, sellerAddress, _assetId); emit SaleCancelled(sellerAddress, _assetId); } /// @dev Returns true if the FT (ERC721) is on sale. function _isOnSale(CollectibleSale memory _sale) internal view returns (bool) { return (_sale.startedAt > 0 && _sale.isActive); } function _updateSaleAvgHistory(uint256 _assetType, uint256 _price) internal { assetTypeSaleCount[_assetType] += 1; assetTypeSalePrices[_assetType].sales[assetTypeSaleCount[_assetType] % avgSalesToCount] = _price; } /// @dev Removes an sale from the list of open sales. /// @param _assetId - ID of the token on sale function _removeSale(uint256 _assetId) internal { delete tokenIdToSale[_assetId]; var cscNFT = CSCNFTFactory(NFTAddress); uint256 assetType = cscNFT.getAssetIdItemType(_assetId); bool hasFound = false; for (uint i = 0; i < assetTypeSalesTokenId[assetType].length; i++) { if ( assetTypeSalesTokenId[assetType][i] == _assetId) { hasFound = true; } if(hasFound == true) { if(i+1 < assetTypeSalesTokenId[assetType].length) assetTypeSalesTokenId[assetType][i] = assetTypeSalesTokenId[assetType][i+1]; else delete assetTypeSalesTokenId[assetType][i]; } } assetTypeSalesTokenId[assetType].length--; } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"constant":false,"inputs":[{"name":"_assetId","type":"uint256"}],"name":"BuyAsset","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"otherManagers","outputs":[{"name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_tokenIds","type":"uint256[]"},{"name":"_margin","type":"uint256"},{"name":"_minPrice","type":"uint256"},{"name":"_endingPrice","type":"uint256"},{"name":"_duration","type":"uint64"},{"name":"_seller","type":"address"}],"name":"BatchCreateSaleAvgPrice","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"NFTAddress","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_count","type":"uint256"}],"name":"setAvgSalesCount","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"uint256"}],"name":"tokenIdToSale","outputs":[{"name":"seller","type":"address"},{"name":"startingPrice","type":"uint256"},{"name":"endingPrice","type":"uint256"},{"name":"duration","type":"uint256"},{"name":"startedAt","type":"uint64"},{"name":"isActive","type":"bool"},{"name":"buyer","type":"address"},{"name":"tokenId","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"unpause","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_assetType","type":"uint256"}],"name":"GetCurrentTypeDuration","outputs":[{"name":"_duration","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_tokenId","type":"uint256"},{"name":"_startingPrice","type":"uint256"},{"name":"_endingPrice","type":"uint256"},{"name":"_duration","type":"uint64"},{"name":"_seller","type":"address"}],"name":"CreateSale","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"paused","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"withdrawBalance","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"uint256"}],"name":"assetTypeSaleCount","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_address","type":"address"}],"name":"setNFTAddress","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_assetId","type":"uint256"}],"name":"CancelSale","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_assetId","type":"uint256"}],"name":"GetCurrentSalePrice","outputs":[{"name":"_price","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"_assetType","type":"uint256"}],"name":"GetCurrentTypeSalePrice","outputs":[{"name":"_price","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_tokenIds","type":"uint256[]"},{"name":"_startingPrice","type":"uint256"},{"name":"_endingPrice","type":"uint256"},{"name":"_duration","type":"uint64"},{"name":"_seller","type":"address"}],"name":"BatchCreateSales","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_tokenIds","type":"uint256[]"}],"name":"BatchCancelSales","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_newGM","type":"address"}],"name":"setSecondaryManager","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"uint256"},{"name":"","type":"uint256"}],"name":"assetTypeSalesTokenId","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"pause","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_assetType","type":"uint256"}],"name":"GetCurrentTypeSaleItem","outputs":[{"name":"seller","type":"address"},{"name":"startingPrice","type":"uint256"},{"name":"endingPrice","type":"uint256"},{"name":"duration","type":"uint256"},{"name":"startedAt","type":"uint256"},{"name":"tokenId","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"noError","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_assetType","type":"uint256"}],"name":"GetCurrentTypeStartTime","outputs":[{"name":"_startedAt","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"hasError","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"managerPrimary","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_newOp","type":"address"},{"name":"_state","type":"uint8"}],"name":"setOtherManager","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_newGM","type":"address"}],"name":"setPrimaryManager","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"error","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"_assetType","type":"uint256"}],"name":"GetAssetTypeAverageSalePrice","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_tokenId","type":"uint256"},{"name":"_margin","type":"uint256"},{"name":"_minPrice","type":"uint256"},{"name":"_endingPrice","type":"uint256"},{"name":"_duration","type":"uint64"},{"name":"_seller","type":"address"}],"name":"CreateSaleAvgPrice","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_assetId","type":"uint256"}],"name":"getSale","outputs":[{"name":"seller","type":"address"},{"name":"startingPrice","type":"uint256"},{"name":"endingPrice","type":"uint256"},{"name":"duration","type":"uint256"},{"name":"startedAt","type":"uint256"},{"name":"isActive","type":"bool"},{"name":"buyer","type":"address"},{"name":"tokenId","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_assetType","type":"uint256"}],"name":"BuyCurrentTypeOfAsset","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":true,"inputs":[],"name":"avgSalesToCount","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"bankManager","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"managerSecondary","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"","type":"address"},{"name":"","type":"uint256"},{"name":"","type":"bytes"}],"name":"onERC721Received","outputs":[{"name":"","type":"bytes4"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_newBK","type":"address"}],"name":"setBanker","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_assetType","type":"uint256"}],"name":"GetCurrentTypeSaleCount","outputs":[{"name":"_count","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"name":"owner","type":"address"},{"indexed":false,"name":"collectibleId","type":"uint256"},{"indexed":false,"name":"buyingPrice","type":"uint256"}],"name":"SaleWinner","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"tokenID","type":"uint256"},{"indexed":false,"name":"startingPrice","type":"uint256"},{"indexed":false,"name":"endingPrice","type":"uint256"},{"indexed":false,"name":"duration","type":"uint256"},{"indexed":false,"name":"startedAt","type":"uint64"}],"name":"SaleCreated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"seller","type":"address"},{"indexed":false,"name":"collectibleId","type":"uint256"}],"name":"SaleCancelled","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"newContract","type":"address"}],"name":"ContractUpgrade","type":"event"}]
Contract Creation Code
60806040526004805461ffff19169055600560085534801561002057600080fd5b5033600160a060020a0316151561003657600080fd5b6004805461ff001960ff1990911660019081179190911690915560008054600160a060020a033316600160a060020a0319918216811790925582548116821790925560028054909216179055612972806100916000396000f3006080604052600436106101c85763ffffffff60e060020a60003504166253093381146101cd57806323d7af24146101da5780632ab4672a14610211578063310c87cc146102905780633688632e146102c157806338644c5e146102d95780633f4ba83a1461034e57806343f4cb4b146103635780635569fc0b1461038d5780635c975abb146103c45780635fd8c710146103ed57806367591a9f1461040257806369d037381461041a5780636ecd7b701461043b5780637ff4454414610453578063806b6c281461046b57806380ac613f146104835780638210f13b146104fd578063825bdb741461055257806382845b74146105735780638456cb591461058e57806385476d6e146105a35780638a53f230146105f857806399dfa7111461060d578063ad5e46cb14610625578063b777cad71461063a578063bb1d45fc1461064f578063c0619c7014610676578063c79f8b6214610697578063d0a56299146106ac578063d7c61e7b146106c4578063d8f6d596146106fe578063e4f3f47f1461076a578063e56e477614610775578063e9e2990e1461078a578063ee70f3921461079f578063f0b9e5ba146107b4578063f1ff732b14610852578063febec05914610873575b600080fd5b6101d860043561088b565b005b3480156101e657600080fd5b506101fb600160a060020a036004351661098a565b6040805160ff9092168252519081900360200190f35b34801561021d57600080fd5b50604080516020600480358082013583810280860185019096528085526101d8953695939460249493850192918291850190849080828437509497505084359550505060208301359260408101359250606081013567ffffffffffffffff16915060800135600160a060020a031661099f565b34801561029c57600080fd5b506102a5610b29565b60408051600160a060020a039092168252519081900360200190f35b3480156102cd57600080fd5b506101d8600435610b3e565b3480156102e557600080fd5b506102f1600435610b79565b60408051600160a060020a03998a168152602081019890985287810196909652606087019490945267ffffffffffffffff9092166080860152151560a085015290931660c083015260e08201929092529051908190036101000190f35b34801561035a57600080fd5b506101d8610be0565b34801561036f57600080fd5b5061037b600435610c70565b60408051918252519081900360200190f35b34801561039957600080fd5b506101d860043560243560443567ffffffffffffffff60643516600160a060020a0360843516610d3f565b3480156103d057600080fd5b506103d9610dc8565b604080519115158252519081900360200190f35b3480156103f957600080fd5b506101d8610dd1565b34801561040e57600080fd5b5061037b600435610e2a565b34801561042657600080fd5b506101d8600160a060020a0360043516610e3c565b34801561044757600080fd5b506101d8600435610ea9565b34801561045f57600080fd5b5061037b600435610f27565b34801561047757600080fd5b5061037b600435610fcf565b34801561048f57600080fd5b50604080516020600480358082013583810280860185019096528085526101d89536959394602494938501929182918501908490808284375094975050843595505050602083013592604081013567ffffffffffffffff16925060600135600160a060020a031690506110a0565b34801561050957600080fd5b50604080516020600480358082013583810280860185019096528085526101d89536959394602494938501929182918501908490808284375094975061115d9650505050505050565b34801561055e57600080fd5b506101d8600160a060020a0360043516611212565b34801561057f57600080fd5b5061037b60043560243561128c565b34801561059a57600080fd5b506101d86112bc565b3480156105af57600080fd5b506105bb600435611311565b60408051600160a060020a0390971687526020870195909552858501939093526060850191909152608084015260a0830152519081900360c00190f35b34801561060457600080fd5b506101d86113fb565b34801561061957600080fd5b5061037b60043561144f565b34801561063157600080fd5b506101d861151f565b34801561064657600080fd5b506102a5611577565b34801561065b57600080fd5b506101d8600160a060020a036004351660ff60243516611586565b34801561068257600080fd5b506101d8600160a060020a03600435166115fe565b3480156106a357600080fd5b506103d9611678565b3480156106b857600080fd5b5061037b600435611686565b3480156106d057600080fd5b506101d860043560243560443560643567ffffffffffffffff60843516600160a060020a0360a435166116c8565b34801561070a57600080fd5b50610716600435611806565b60408051600160a060020a03998a16815260208101989098528781019690965260608701949094526080860192909252151560a085015290931660c083015260e08201929092529051908190036101000190f35b6101d860043561190b565b34801561078157600080fd5b5061037b611a3a565b34801561079657600080fd5b506102a5611a40565b3480156107ab57600080fd5b506102a5611a4f565b3480156107c057600080fd5b50604080516020600460443581810135601f810184900484028501840190955284845261081d948235600160a060020a0316946024803595369594606494920191908190840183828082843750949750611a5e9650505050505050565b604080517fffffffff000000000000000000000000000000000000000000000000000000009092168252519081900360200190f35b34801561085e57600080fd5b506101d8600160a060020a0360043516611a86565b34801561087f57600080fd5b5061037b600435611b00565b6108936128c2565b60045460ff16156108a357600080fd5b33600160a060020a031615156108b857600080fd5b30600160a060020a031633600160a060020a0316141515156108d957600080fd5b506000818152600560208181526040928390208351610100810185528154600160a060020a03908116825260018301549382019390935260028201549481019490945260038101546060850152600481015467ffffffffffffffff8116608086015260ff68010000000000000000820416151560a0860152604860020a900490911660c0840152015460e082015261097081611b12565b151561097b57600080fd5b610986823334611b38565b5050565b60036020526000908152604090205460ff1681565b60008054819081908190819033600160a060020a03908116911614806109d3575060015433600160a060020a039081169116145b806109ec575060025433600160a060020a039081169116145b80610a125750600160a060020a03331660009081526003602052604090205460ff166001145b1515610a1d57600080fd5b50600454620100009004600160a060020a0316935060005b8a51811015610b1c578a81815181101515610a4c57fe5b90602001906020020151925084600160a060020a0316631b87ccae846040518263ffffffff1660e060020a02815260040180828152602001915050602060405180830381600087803b158015610aa157600080fd5b505af1158015610ab5573d6000803e3d6000fd5b505050506040513d6020811015610acb57600080fd5b50519350610ad884611686565b612710908b0204915088821015610aed578891505b8a81815181101515610afb57fe5b906020019060200201519250610b1483838a8a8a611de8565b600101610a35565b5050505050505050505050565b600454620100009004600160a060020a031681565b60005433600160a060020a0390811691161480610b69575060015433600160a060020a039081169116145b1515610b7457600080fd5b600855565b6005602081905260009182526040909120805460018201546002830154600384015460048501549490950154600160a060020a03938416959294919367ffffffffffffffff83169260ff6801000000000000000082041692604860020a9091049091169088565b60005433600160a060020a0390811691161480610c0b575060015433600160a060020a039081169116145b80610c24575060025433600160a060020a039081169116145b80610c4a5750600160a060020a03331660009081526003602052604090205460ff166001145b1515610c5557600080fd5b60045460ff161515610c6657600080fd5b610c6e612228565b565b6000610c7a6128c2565b60008381526009602052604081208054600592919082908110610c9957fe5b600091825260208083209190910154835282810193909352604091820190208151610100810183528154600160a060020a039081168252600183015494820194909452600282015492810192909252600381015460608301819052600482015467ffffffffffffffff8116608085015268010000000000000000810460ff16151560a0850152604860020a900490931660c08301526005015460e0909101529392505050565b60005433600160a060020a0390811691161480610d6a575060015433600160a060020a039081169116145b80610d83575060025433600160a060020a039081169116145b80610da95750600160a060020a03331660009081526003602052604090205460ff166001145b1515610db457600080fd5b610dc18585858585611de8565b5050505050565b60045460ff1681565b60025433600160a060020a03908116911614610dec57600080fd5b600254604051600160a060020a039182169130163180156108fc02916000818181858888f19350505050158015610e27573d6000803e3d6000fd5b50565b60066020526000908152604090205481565b60005433600160a060020a0390811691161480610e67575060015433600160a060020a039081169116145b1515610e7257600080fd5b60048054600160a060020a03909216620100000275ffffffffffffffffffffffffffffffffffffffff000019909216919091179055565b60005433600160a060020a0390811691161480610ed4575060015433600160a060020a039081169116145b80610eed575060025433600160a060020a039081169116145b80610f135750600160a060020a03331660009081526003602052604090205460ff166001145b1515610f1e57600080fd5b610e278161227b565b6000610f316128c2565b506000828152600560208181526040928390208351610100810185528154600160a060020a03908116825260018301549382019390935260028201549481019490945260038101546060850152600481015467ffffffffffffffff8116608086015260ff68010000000000000000820416151560a0860152604860020a900490911660c0840152015460e0820152610fc8816123ab565b9392505050565b6000610fd96128c2565b60008381526009602052604081208054600592919082908110610ff857fe5b6000918252602080832090910154835282810193909352604091820190208151610100810183528154600160a060020a03908116825260018301549482019490945260028201549281019290925260038101546060830152600481015467ffffffffffffffff8116608084015260ff68010000000000000000820416151560a0840152604860020a900490921660c082015260059091015460e08201529050610fc8816123ab565b60008054819033600160a060020a03908116911614806110ce575060015433600160a060020a039081169116145b806110e7575060025433600160a060020a039081169116145b8061110d5750600160a060020a03331660009081526003602052604090205460ff166001145b151561111857600080fd5b5060005b865181101561115457868181518110151561113357fe5b90602001906020020151915061114c8287878787611de8565b60010161111c565b50505050505050565b60008054819033600160a060020a039081169116148061118b575060015433600160a060020a039081169116145b806111a4575060025433600160a060020a039081169116145b806111ca5750600160a060020a03331660009081526003602052604090205460ff166001145b15156111d557600080fd5b5060005b825181101561120d5782818151811015156111f057fe5b9060200190602002015191506112058261227b565b6001016111d9565b505050565b60005433600160a060020a039081169116148061123d575060015433600160a060020a039081169116145b151561124857600080fd5b600160a060020a038116151561125d57600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b6009602052816000526040600020818154811015156112a757fe5b90600052602060002001600091509150505481565b60005433600160a060020a03908116911614806112e7575060015433600160a060020a039081169116145b15156112f257600080fd5b60045460ff161561130257600080fd5b6004805460ff19166001179055565b6000806000806000806113226128c2565b6000888152600960205260408120805460059291908290811061134157fe5b600091825260208083209190910154835282810193909352604091820190208151610100810183528154600160a060020a0390811680835260018401549583018690526002840154948301859052600384015460608401819052600485015467ffffffffffffffff81166080860181905268010000000000000000820460ff16151560a0870152604860020a90910490931660c085015260059094015460e09093018390529d949c50929a50909850909650945092505050565b60005433600160a060020a0390811691161480611426575060015433600160a060020a039081169116145b151561143157600080fd5b60045460ff16151561144257600080fd5b6004805461ff0019169055565b60006114596128c2565b6000838152600960205260408120805460059291908290811061147857fe5b600091825260208083209190910154835282810193909352604091820190208151610100810183528154600160a060020a03908116825260018301549482019490945260028201549281019290925260038101546060830152600481015467ffffffffffffffff81166080840181905268010000000000000000820460ff16151560a0850152604860020a90910490931660c08301526005015460e0909101529392505050565b60005433600160a060020a039081169116148061154a575060015433600160a060020a039081169116145b151561155557600080fd5b60045460ff16151561156657600080fd5b6004805461ff001916610100179055565b600054600160a060020a031681565b60005433600160a060020a03908116911614806115b1575060015433600160a060020a039081169116145b15156115bc57600080fd5b600160a060020a03821615156115d157600080fd5b600160a060020a03919091166000908152600360205260409020805460ff191660ff909216919091179055565b60005433600160a060020a0390811691161480611629575060015433600160a060020a039081169116145b151561163457600080fd5b600160a060020a038116151561164957600080fd5b6000805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b600454610100900460ff1681565b600080805b6008548110156116bd57600084815260076020526040902081600581106116ae57fe5b0154919091019060010161168b565b506005900492915050565b600080548190819033600160a060020a03908116911614806116f8575060015433600160a060020a039081169116145b80611711575060025433600160a060020a039081169116145b806117375750600160a060020a03331660009081526003602052604090205460ff166001145b151561174257600080fd5b600460029054906101000a9004600160a060020a0316925082600160a060020a0316631b87ccae8a6040518263ffffffff1660e060020a02815260040180828152602001915050602060405180830381600087803b1580156117a357600080fd5b505af11580156117b7573d6000803e3d6000fd5b505050506040513d60208110156117cd57600080fd5b505191506117da82611686565b612710908902049050868110156117ee5750855b6117fb8982888888611de8565b505050505050505050565b60008060008060008060008061181a6128c2565b506000898152600560208181526040928390208351610100810185528154600160a060020a03908116825260018301549382019390935260028201549481019490945260038101546060850152600481015467ffffffffffffffff8116608086015260ff68010000000000000000820416151560a0860152604860020a900490911660c0840152015460e08201526118b181611b12565b15156118bc57600080fd5b8051602082015160408301516060840151608085015160a086015160c087015160e0880151969f50949d50929b5090995067ffffffffffffffff16975095509350915050919395975091939597565b6119136128c2565b60045460ff161561192357600080fd5b33600160a060020a0316151561193857600080fd5b30600160a060020a031633600160a060020a03161415151561195957600080fd5b6000828152600960205260408120805460059291908290811061197857fe5b6000918252602080832090910154835282810193909352604091820190208151610100810183528154600160a060020a03908116825260018301549482019490945260028201549281019290925260038101546060830152600481015467ffffffffffffffff8116608084015260ff68010000000000000000820416151560a0840152604860020a900490921660c082015260059091015460e08201529050611a2081611b12565b1515611a2b57600080fd5b6109868160e001513334611b38565b60085481565b600254600160a060020a031681565b600154600160a060020a031681565b7ff0b9e5ba000000000000000000000000000000000000000000000000000000009392505050565b60005433600160a060020a0390811691161480611ab1575060015433600160a060020a039081169116145b1515611abc57600080fd5b600160a060020a0381161515611ad157600080fd5b6002805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b60009081526009602052604090205490565b600080826080015167ffffffffffffffff16118015611b3257508160a001515b92915050565b60008381526005602081815260408084208151610100810183528154600160a060020a03908116825260018301549482019490945260028201549281019290925260038101546060830152600481015467ffffffffffffffff8116608084015260ff68010000000000000000820416151560a0840152604860020a900490921660c08201529181015460e08301529190819081908190611bd7906123ab565b935083861015611be657600080fd5b6004850180547cffffffffffffffffffffffffffffffffffffffff0000000000000000001916604860020a600160a060020a038a16021768ff000000000000000019169055611c34886123f1565b6040518487039350600160a060020a0388169084156108fc029085906000818181858888f19350505050158015611c6f573d6000803e3d6000fd5b50600460029054906101000a9004600160a060020a0316915081600160a060020a0316631b87ccae896040518263ffffffff1660e060020a02815260040180828152602001915050602060405180830381600087803b158015611cd157600080fd5b505af1158015611ce5573d6000803e3d6000fd5b505050506040513d6020811015611cfb57600080fd5b50519050611d09818761261d565b604080517f42842e0e000000000000000000000000000000000000000000000000000000008152600160a060020a0330811660048301528981166024830152604482018b90529151918416916342842e0e9160648082019260009290919082900301818387803b158015611d7c57600080fd5b505af1158015611d90573d6000803e3d6000fd5b505060408051600160a060020a038b168152602081018c90528082018a905290517f45506b548e2b7a98e7653fdab206680de3a76e0eb2f61c08394e6424c9b3ad619350908190036060019150a15050505050505050565b6000611df26128c2565b611dfa6128c2565b600460029054906101000a9004600160a060020a0316925082600160a060020a031663f84af7f3308a6040518363ffffffff1660e060020a0281526004018083600160a060020a0316600160a060020a0316815260200182815260200192505050602060405180830381600087803b158015611e7557600080fd5b505af1158015611e89573d6000803e3d6000fd5b505050506040513d6020811015611e9f57600080fd5b50511515600114611eaf57600080fd5b6000888152600560208181526040928390208351610100810185528154600160a060020a03908116825260018301549382019390935260028201549481019490945260038101546060850152600481015467ffffffffffffffff8116608086015260ff6801000000000000000082041615801560a0870152604860020a90910490921660c08501529091015460e0830152909250611f4c57600080fd5b6fffffffffffffffffffffffffffffffff87168714611f6a57600080fd5b6fffffffffffffffffffffffffffffffff86168614611f8857600080fd5b30600160a060020a031683600160a060020a0316636352211e8a6040518263ffffffff1660e060020a02815260040180828152602001915050602060405180830381600087803b158015611fdb57600080fd5b505af1158015611fef573d6000803e3d6000fd5b505050506040513d602081101561200557600080fd5b5051600160a060020a0316146121ad57604080517fe985e9c5000000000000000000000000000000000000000000000000000000008152600160a060020a033381166004830152308116602483015291519185169163e985e9c5916044808201926020929091908290030181600087803b15801561208257600080fd5b505af1158015612096573d6000803e3d6000fd5b505050506040513d60208110156120ac57600080fd5b505115156001146120bc57600080fd5b82600160a060020a03166342842e0e84600160a060020a0316636352211e8b6040518263ffffffff1660e060020a02815260040180828152602001915050602060405180830381600087803b15801561211457600080fd5b505af1158015612128573d6000803e3d6000fd5b505050506040513d602081101561213e57600080fd5b50516040805163ffffffff841660e060020a028152600160a060020a039283166004820152309092166024830152604482018c905251606480830192600092919082900301818387803b15801561219457600080fd5b505af11580156121a8573d6000803e3d6000fd5b505050505b506040805161010081018252600160a060020a03851681526fffffffffffffffffffffffffffffffff808916602083015287169181019190915267ffffffffffffffff808616606083015242166080820152600160a0820152600060c082015260e0810188905261221e8882612663565b5050505050505050565b60005433600160a060020a0390811691161480612253575060015433600160a060020a039081169116145b151561225e57600080fd5b60045460ff16151561226f57600080fd5b6004805460ff19169055565b60008181526005602052604081206004810154909190819068010000000000000000900460ff1615156001146122b057600080fd5b8254600160a060020a031691506122c6846123f1565b5060048054604080517f42842e0e000000000000000000000000000000000000000000000000000000008152600160a060020a03308116948201949094528484166024820152604481018790529051620100009092049092169182916342842e0e9160648082019260009290919082900301818387803b15801561234957600080fd5b505af115801561235d573d6000803e3d6000fd5b505060408051600160a060020a03861681526020810188905281517fc9b961c43fe701b83ae14bfe2d7625ea85b27c33b4aae8d1fdf4b344d5ea1dbc9450908190039091019150a150505050565b6080810151600090819067ffffffffffffffff164211156123d95750608082015167ffffffffffffffff1642035b610fc883602001518460400151856060015184612885565b6000818152600560208181526040808420805473ffffffffffffffffffffffffffffffffffffffff19168155600181018590556002810185905560038101859055600480820180547fffffff00000000000000000000000000000000000000000000000000000000001690559301849055825481517f1b87ccae000000000000000000000000000000000000000000000000000000008152938401869052905162010000909104600160a060020a03169392839283928692631b87ccae92602480830193919282900301818787803b1580156124cc57600080fd5b505af11580156124e0573d6000803e3d6000fd5b505050506040513d60208110156124f657600080fd5b50519250600091508190505b6000838152600960205260409020548110156125f657600083815260096020526040902080548691908390811061253557fe5b9060005260206000200154141561254b57600191505b600182151514156125ee576000838152600960205260409020546001820110156125c857600083815260096020526040902080546001830190811061258c57fe5b906000526020600020015460096000858152602001908152602001600020828154811015156125b757fe5b6000918252602090912001556125ee565b60008381526009602052604090208054829081106125e257fe5b60009182526020822001555b600101612502565b6000838152600960205260409020805490612615906000198301612906565b505050505050565b600082815260066020818152604080842080546001019081905560078352932060085492909152839290919081151561265257fe5b066005811061265d57fe5b01555050565b600080603c83606001511015151561267a57600080fd5b600084815260056020818152604080842087518154600160a060020a0391821673ffffffffffffffffffffffffffffffffffffffff199091161782558389015160018301558289015160028301556060890151600383015560808901516004808401805460a08d015160c08e01518616604860020a027cffffffffffffffffffffffffffffffffffffffff00000000000000000019911515680100000000000000000268ff00000000000000001967ffffffffffffffff90971667ffffffffffffffff19909416939093179590951691909117169290921790915560e08a01519290950191909155835482517f1b87ccae0000000000000000000000000000000000000000000000000000000081529485018a90529151620100009092041695508593631b87ccae936024808201949392918390030190829087803b1580156127c257600080fd5b505af11580156127d6573d6000803e3d6000fd5b505050506040513d60208110156127ec57600080fd5b5051600081815260096020908152604080832080546001810182559084529282902090920187905585810151868301516060808901516080808b015187518d815296870195909552858701939093529084015267ffffffffffffffff9091169082015290519192507f63a961310560faa9fef6286931f6e109c6bc7b31f798ae8da4cf19005ec45579919081900360a00190a150505050565b6000808080858510612899578693506128b7565b8787039250858584028115156128ab57fe5b05915081880190508093505b505050949350505050565b6040805161010081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081019190915290565b81548183558181111561120d5760008381526020902061120d91810190830161294391905b8082111561293f576000815560010161292b565b5090565b905600a165627a7a723058203d5aae27dc7d0feda7a01108025692ad2d35e454dddbb296b6f937018d56f12e0029
Deployed Bytecode
0x6080604052600436106101c85763ffffffff60e060020a60003504166253093381146101cd57806323d7af24146101da5780632ab4672a14610211578063310c87cc146102905780633688632e146102c157806338644c5e146102d95780633f4ba83a1461034e57806343f4cb4b146103635780635569fc0b1461038d5780635c975abb146103c45780635fd8c710146103ed57806367591a9f1461040257806369d037381461041a5780636ecd7b701461043b5780637ff4454414610453578063806b6c281461046b57806380ac613f146104835780638210f13b146104fd578063825bdb741461055257806382845b74146105735780638456cb591461058e57806385476d6e146105a35780638a53f230146105f857806399dfa7111461060d578063ad5e46cb14610625578063b777cad71461063a578063bb1d45fc1461064f578063c0619c7014610676578063c79f8b6214610697578063d0a56299146106ac578063d7c61e7b146106c4578063d8f6d596146106fe578063e4f3f47f1461076a578063e56e477614610775578063e9e2990e1461078a578063ee70f3921461079f578063f0b9e5ba146107b4578063f1ff732b14610852578063febec05914610873575b600080fd5b6101d860043561088b565b005b3480156101e657600080fd5b506101fb600160a060020a036004351661098a565b6040805160ff9092168252519081900360200190f35b34801561021d57600080fd5b50604080516020600480358082013583810280860185019096528085526101d8953695939460249493850192918291850190849080828437509497505084359550505060208301359260408101359250606081013567ffffffffffffffff16915060800135600160a060020a031661099f565b34801561029c57600080fd5b506102a5610b29565b60408051600160a060020a039092168252519081900360200190f35b3480156102cd57600080fd5b506101d8600435610b3e565b3480156102e557600080fd5b506102f1600435610b79565b60408051600160a060020a03998a168152602081019890985287810196909652606087019490945267ffffffffffffffff9092166080860152151560a085015290931660c083015260e08201929092529051908190036101000190f35b34801561035a57600080fd5b506101d8610be0565b34801561036f57600080fd5b5061037b600435610c70565b60408051918252519081900360200190f35b34801561039957600080fd5b506101d860043560243560443567ffffffffffffffff60643516600160a060020a0360843516610d3f565b3480156103d057600080fd5b506103d9610dc8565b604080519115158252519081900360200190f35b3480156103f957600080fd5b506101d8610dd1565b34801561040e57600080fd5b5061037b600435610e2a565b34801561042657600080fd5b506101d8600160a060020a0360043516610e3c565b34801561044757600080fd5b506101d8600435610ea9565b34801561045f57600080fd5b5061037b600435610f27565b34801561047757600080fd5b5061037b600435610fcf565b34801561048f57600080fd5b50604080516020600480358082013583810280860185019096528085526101d89536959394602494938501929182918501908490808284375094975050843595505050602083013592604081013567ffffffffffffffff16925060600135600160a060020a031690506110a0565b34801561050957600080fd5b50604080516020600480358082013583810280860185019096528085526101d89536959394602494938501929182918501908490808284375094975061115d9650505050505050565b34801561055e57600080fd5b506101d8600160a060020a0360043516611212565b34801561057f57600080fd5b5061037b60043560243561128c565b34801561059a57600080fd5b506101d86112bc565b3480156105af57600080fd5b506105bb600435611311565b60408051600160a060020a0390971687526020870195909552858501939093526060850191909152608084015260a0830152519081900360c00190f35b34801561060457600080fd5b506101d86113fb565b34801561061957600080fd5b5061037b60043561144f565b34801561063157600080fd5b506101d861151f565b34801561064657600080fd5b506102a5611577565b34801561065b57600080fd5b506101d8600160a060020a036004351660ff60243516611586565b34801561068257600080fd5b506101d8600160a060020a03600435166115fe565b3480156106a357600080fd5b506103d9611678565b3480156106b857600080fd5b5061037b600435611686565b3480156106d057600080fd5b506101d860043560243560443560643567ffffffffffffffff60843516600160a060020a0360a435166116c8565b34801561070a57600080fd5b50610716600435611806565b60408051600160a060020a03998a16815260208101989098528781019690965260608701949094526080860192909252151560a085015290931660c083015260e08201929092529051908190036101000190f35b6101d860043561190b565b34801561078157600080fd5b5061037b611a3a565b34801561079657600080fd5b506102a5611a40565b3480156107ab57600080fd5b506102a5611a4f565b3480156107c057600080fd5b50604080516020600460443581810135601f810184900484028501840190955284845261081d948235600160a060020a0316946024803595369594606494920191908190840183828082843750949750611a5e9650505050505050565b604080517fffffffff000000000000000000000000000000000000000000000000000000009092168252519081900360200190f35b34801561085e57600080fd5b506101d8600160a060020a0360043516611a86565b34801561087f57600080fd5b5061037b600435611b00565b6108936128c2565b60045460ff16156108a357600080fd5b33600160a060020a031615156108b857600080fd5b30600160a060020a031633600160a060020a0316141515156108d957600080fd5b506000818152600560208181526040928390208351610100810185528154600160a060020a03908116825260018301549382019390935260028201549481019490945260038101546060850152600481015467ffffffffffffffff8116608086015260ff68010000000000000000820416151560a0860152604860020a900490911660c0840152015460e082015261097081611b12565b151561097b57600080fd5b610986823334611b38565b5050565b60036020526000908152604090205460ff1681565b60008054819081908190819033600160a060020a03908116911614806109d3575060015433600160a060020a039081169116145b806109ec575060025433600160a060020a039081169116145b80610a125750600160a060020a03331660009081526003602052604090205460ff166001145b1515610a1d57600080fd5b50600454620100009004600160a060020a0316935060005b8a51811015610b1c578a81815181101515610a4c57fe5b90602001906020020151925084600160a060020a0316631b87ccae846040518263ffffffff1660e060020a02815260040180828152602001915050602060405180830381600087803b158015610aa157600080fd5b505af1158015610ab5573d6000803e3d6000fd5b505050506040513d6020811015610acb57600080fd5b50519350610ad884611686565b612710908b0204915088821015610aed578891505b8a81815181101515610afb57fe5b906020019060200201519250610b1483838a8a8a611de8565b600101610a35565b5050505050505050505050565b600454620100009004600160a060020a031681565b60005433600160a060020a0390811691161480610b69575060015433600160a060020a039081169116145b1515610b7457600080fd5b600855565b6005602081905260009182526040909120805460018201546002830154600384015460048501549490950154600160a060020a03938416959294919367ffffffffffffffff83169260ff6801000000000000000082041692604860020a9091049091169088565b60005433600160a060020a0390811691161480610c0b575060015433600160a060020a039081169116145b80610c24575060025433600160a060020a039081169116145b80610c4a5750600160a060020a03331660009081526003602052604090205460ff166001145b1515610c5557600080fd5b60045460ff161515610c6657600080fd5b610c6e612228565b565b6000610c7a6128c2565b60008381526009602052604081208054600592919082908110610c9957fe5b600091825260208083209190910154835282810193909352604091820190208151610100810183528154600160a060020a039081168252600183015494820194909452600282015492810192909252600381015460608301819052600482015467ffffffffffffffff8116608085015268010000000000000000810460ff16151560a0850152604860020a900490931660c08301526005015460e0909101529392505050565b60005433600160a060020a0390811691161480610d6a575060015433600160a060020a039081169116145b80610d83575060025433600160a060020a039081169116145b80610da95750600160a060020a03331660009081526003602052604090205460ff166001145b1515610db457600080fd5b610dc18585858585611de8565b5050505050565b60045460ff1681565b60025433600160a060020a03908116911614610dec57600080fd5b600254604051600160a060020a039182169130163180156108fc02916000818181858888f19350505050158015610e27573d6000803e3d6000fd5b50565b60066020526000908152604090205481565b60005433600160a060020a0390811691161480610e67575060015433600160a060020a039081169116145b1515610e7257600080fd5b60048054600160a060020a03909216620100000275ffffffffffffffffffffffffffffffffffffffff000019909216919091179055565b60005433600160a060020a0390811691161480610ed4575060015433600160a060020a039081169116145b80610eed575060025433600160a060020a039081169116145b80610f135750600160a060020a03331660009081526003602052604090205460ff166001145b1515610f1e57600080fd5b610e278161227b565b6000610f316128c2565b506000828152600560208181526040928390208351610100810185528154600160a060020a03908116825260018301549382019390935260028201549481019490945260038101546060850152600481015467ffffffffffffffff8116608086015260ff68010000000000000000820416151560a0860152604860020a900490911660c0840152015460e0820152610fc8816123ab565b9392505050565b6000610fd96128c2565b60008381526009602052604081208054600592919082908110610ff857fe5b6000918252602080832090910154835282810193909352604091820190208151610100810183528154600160a060020a03908116825260018301549482019490945260028201549281019290925260038101546060830152600481015467ffffffffffffffff8116608084015260ff68010000000000000000820416151560a0840152604860020a900490921660c082015260059091015460e08201529050610fc8816123ab565b60008054819033600160a060020a03908116911614806110ce575060015433600160a060020a039081169116145b806110e7575060025433600160a060020a039081169116145b8061110d5750600160a060020a03331660009081526003602052604090205460ff166001145b151561111857600080fd5b5060005b865181101561115457868181518110151561113357fe5b90602001906020020151915061114c8287878787611de8565b60010161111c565b50505050505050565b60008054819033600160a060020a039081169116148061118b575060015433600160a060020a039081169116145b806111a4575060025433600160a060020a039081169116145b806111ca5750600160a060020a03331660009081526003602052604090205460ff166001145b15156111d557600080fd5b5060005b825181101561120d5782818151811015156111f057fe5b9060200190602002015191506112058261227b565b6001016111d9565b505050565b60005433600160a060020a039081169116148061123d575060015433600160a060020a039081169116145b151561124857600080fd5b600160a060020a038116151561125d57600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b6009602052816000526040600020818154811015156112a757fe5b90600052602060002001600091509150505481565b60005433600160a060020a03908116911614806112e7575060015433600160a060020a039081169116145b15156112f257600080fd5b60045460ff161561130257600080fd5b6004805460ff19166001179055565b6000806000806000806113226128c2565b6000888152600960205260408120805460059291908290811061134157fe5b600091825260208083209190910154835282810193909352604091820190208151610100810183528154600160a060020a0390811680835260018401549583018690526002840154948301859052600384015460608401819052600485015467ffffffffffffffff81166080860181905268010000000000000000820460ff16151560a0870152604860020a90910490931660c085015260059094015460e09093018390529d949c50929a50909850909650945092505050565b60005433600160a060020a0390811691161480611426575060015433600160a060020a039081169116145b151561143157600080fd5b60045460ff16151561144257600080fd5b6004805461ff0019169055565b60006114596128c2565b6000838152600960205260408120805460059291908290811061147857fe5b600091825260208083209190910154835282810193909352604091820190208151610100810183528154600160a060020a03908116825260018301549482019490945260028201549281019290925260038101546060830152600481015467ffffffffffffffff81166080840181905268010000000000000000820460ff16151560a0850152604860020a90910490931660c08301526005015460e0909101529392505050565b60005433600160a060020a039081169116148061154a575060015433600160a060020a039081169116145b151561155557600080fd5b60045460ff16151561156657600080fd5b6004805461ff001916610100179055565b600054600160a060020a031681565b60005433600160a060020a03908116911614806115b1575060015433600160a060020a039081169116145b15156115bc57600080fd5b600160a060020a03821615156115d157600080fd5b600160a060020a03919091166000908152600360205260409020805460ff191660ff909216919091179055565b60005433600160a060020a0390811691161480611629575060015433600160a060020a039081169116145b151561163457600080fd5b600160a060020a038116151561164957600080fd5b6000805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b600454610100900460ff1681565b600080805b6008548110156116bd57600084815260076020526040902081600581106116ae57fe5b0154919091019060010161168b565b506005900492915050565b600080548190819033600160a060020a03908116911614806116f8575060015433600160a060020a039081169116145b80611711575060025433600160a060020a039081169116145b806117375750600160a060020a03331660009081526003602052604090205460ff166001145b151561174257600080fd5b600460029054906101000a9004600160a060020a0316925082600160a060020a0316631b87ccae8a6040518263ffffffff1660e060020a02815260040180828152602001915050602060405180830381600087803b1580156117a357600080fd5b505af11580156117b7573d6000803e3d6000fd5b505050506040513d60208110156117cd57600080fd5b505191506117da82611686565b612710908902049050868110156117ee5750855b6117fb8982888888611de8565b505050505050505050565b60008060008060008060008061181a6128c2565b506000898152600560208181526040928390208351610100810185528154600160a060020a03908116825260018301549382019390935260028201549481019490945260038101546060850152600481015467ffffffffffffffff8116608086015260ff68010000000000000000820416151560a0860152604860020a900490911660c0840152015460e08201526118b181611b12565b15156118bc57600080fd5b8051602082015160408301516060840151608085015160a086015160c087015160e0880151969f50949d50929b5090995067ffffffffffffffff16975095509350915050919395975091939597565b6119136128c2565b60045460ff161561192357600080fd5b33600160a060020a0316151561193857600080fd5b30600160a060020a031633600160a060020a03161415151561195957600080fd5b6000828152600960205260408120805460059291908290811061197857fe5b6000918252602080832090910154835282810193909352604091820190208151610100810183528154600160a060020a03908116825260018301549482019490945260028201549281019290925260038101546060830152600481015467ffffffffffffffff8116608084015260ff68010000000000000000820416151560a0840152604860020a900490921660c082015260059091015460e08201529050611a2081611b12565b1515611a2b57600080fd5b6109868160e001513334611b38565b60085481565b600254600160a060020a031681565b600154600160a060020a031681565b7ff0b9e5ba000000000000000000000000000000000000000000000000000000009392505050565b60005433600160a060020a0390811691161480611ab1575060015433600160a060020a039081169116145b1515611abc57600080fd5b600160a060020a0381161515611ad157600080fd5b6002805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b60009081526009602052604090205490565b600080826080015167ffffffffffffffff16118015611b3257508160a001515b92915050565b60008381526005602081815260408084208151610100810183528154600160a060020a03908116825260018301549482019490945260028201549281019290925260038101546060830152600481015467ffffffffffffffff8116608084015260ff68010000000000000000820416151560a0840152604860020a900490921660c08201529181015460e08301529190819081908190611bd7906123ab565b935083861015611be657600080fd5b6004850180547cffffffffffffffffffffffffffffffffffffffff0000000000000000001916604860020a600160a060020a038a16021768ff000000000000000019169055611c34886123f1565b6040518487039350600160a060020a0388169084156108fc029085906000818181858888f19350505050158015611c6f573d6000803e3d6000fd5b50600460029054906101000a9004600160a060020a0316915081600160a060020a0316631b87ccae896040518263ffffffff1660e060020a02815260040180828152602001915050602060405180830381600087803b158015611cd157600080fd5b505af1158015611ce5573d6000803e3d6000fd5b505050506040513d6020811015611cfb57600080fd5b50519050611d09818761261d565b604080517f42842e0e000000000000000000000000000000000000000000000000000000008152600160a060020a0330811660048301528981166024830152604482018b90529151918416916342842e0e9160648082019260009290919082900301818387803b158015611d7c57600080fd5b505af1158015611d90573d6000803e3d6000fd5b505060408051600160a060020a038b168152602081018c90528082018a905290517f45506b548e2b7a98e7653fdab206680de3a76e0eb2f61c08394e6424c9b3ad619350908190036060019150a15050505050505050565b6000611df26128c2565b611dfa6128c2565b600460029054906101000a9004600160a060020a0316925082600160a060020a031663f84af7f3308a6040518363ffffffff1660e060020a0281526004018083600160a060020a0316600160a060020a0316815260200182815260200192505050602060405180830381600087803b158015611e7557600080fd5b505af1158015611e89573d6000803e3d6000fd5b505050506040513d6020811015611e9f57600080fd5b50511515600114611eaf57600080fd5b6000888152600560208181526040928390208351610100810185528154600160a060020a03908116825260018301549382019390935260028201549481019490945260038101546060850152600481015467ffffffffffffffff8116608086015260ff6801000000000000000082041615801560a0870152604860020a90910490921660c08501529091015460e0830152909250611f4c57600080fd5b6fffffffffffffffffffffffffffffffff87168714611f6a57600080fd5b6fffffffffffffffffffffffffffffffff86168614611f8857600080fd5b30600160a060020a031683600160a060020a0316636352211e8a6040518263ffffffff1660e060020a02815260040180828152602001915050602060405180830381600087803b158015611fdb57600080fd5b505af1158015611fef573d6000803e3d6000fd5b505050506040513d602081101561200557600080fd5b5051600160a060020a0316146121ad57604080517fe985e9c5000000000000000000000000000000000000000000000000000000008152600160a060020a033381166004830152308116602483015291519185169163e985e9c5916044808201926020929091908290030181600087803b15801561208257600080fd5b505af1158015612096573d6000803e3d6000fd5b505050506040513d60208110156120ac57600080fd5b505115156001146120bc57600080fd5b82600160a060020a03166342842e0e84600160a060020a0316636352211e8b6040518263ffffffff1660e060020a02815260040180828152602001915050602060405180830381600087803b15801561211457600080fd5b505af1158015612128573d6000803e3d6000fd5b505050506040513d602081101561213e57600080fd5b50516040805163ffffffff841660e060020a028152600160a060020a039283166004820152309092166024830152604482018c905251606480830192600092919082900301818387803b15801561219457600080fd5b505af11580156121a8573d6000803e3d6000fd5b505050505b506040805161010081018252600160a060020a03851681526fffffffffffffffffffffffffffffffff808916602083015287169181019190915267ffffffffffffffff808616606083015242166080820152600160a0820152600060c082015260e0810188905261221e8882612663565b5050505050505050565b60005433600160a060020a0390811691161480612253575060015433600160a060020a039081169116145b151561225e57600080fd5b60045460ff16151561226f57600080fd5b6004805460ff19169055565b60008181526005602052604081206004810154909190819068010000000000000000900460ff1615156001146122b057600080fd5b8254600160a060020a031691506122c6846123f1565b5060048054604080517f42842e0e000000000000000000000000000000000000000000000000000000008152600160a060020a03308116948201949094528484166024820152604481018790529051620100009092049092169182916342842e0e9160648082019260009290919082900301818387803b15801561234957600080fd5b505af115801561235d573d6000803e3d6000fd5b505060408051600160a060020a03861681526020810188905281517fc9b961c43fe701b83ae14bfe2d7625ea85b27c33b4aae8d1fdf4b344d5ea1dbc9450908190039091019150a150505050565b6080810151600090819067ffffffffffffffff164211156123d95750608082015167ffffffffffffffff1642035b610fc883602001518460400151856060015184612885565b6000818152600560208181526040808420805473ffffffffffffffffffffffffffffffffffffffff19168155600181018590556002810185905560038101859055600480820180547fffffff00000000000000000000000000000000000000000000000000000000001690559301849055825481517f1b87ccae000000000000000000000000000000000000000000000000000000008152938401869052905162010000909104600160a060020a03169392839283928692631b87ccae92602480830193919282900301818787803b1580156124cc57600080fd5b505af11580156124e0573d6000803e3d6000fd5b505050506040513d60208110156124f657600080fd5b50519250600091508190505b6000838152600960205260409020548110156125f657600083815260096020526040902080548691908390811061253557fe5b9060005260206000200154141561254b57600191505b600182151514156125ee576000838152600960205260409020546001820110156125c857600083815260096020526040902080546001830190811061258c57fe5b906000526020600020015460096000858152602001908152602001600020828154811015156125b757fe5b6000918252602090912001556125ee565b60008381526009602052604090208054829081106125e257fe5b60009182526020822001555b600101612502565b6000838152600960205260409020805490612615906000198301612906565b505050505050565b600082815260066020818152604080842080546001019081905560078352932060085492909152839290919081151561265257fe5b066005811061265d57fe5b01555050565b600080603c83606001511015151561267a57600080fd5b600084815260056020818152604080842087518154600160a060020a0391821673ffffffffffffffffffffffffffffffffffffffff199091161782558389015160018301558289015160028301556060890151600383015560808901516004808401805460a08d015160c08e01518616604860020a027cffffffffffffffffffffffffffffffffffffffff00000000000000000019911515680100000000000000000268ff00000000000000001967ffffffffffffffff90971667ffffffffffffffff19909416939093179590951691909117169290921790915560e08a01519290950191909155835482517f1b87ccae0000000000000000000000000000000000000000000000000000000081529485018a90529151620100009092041695508593631b87ccae936024808201949392918390030190829087803b1580156127c257600080fd5b505af11580156127d6573d6000803e3d6000fd5b505050506040513d60208110156127ec57600080fd5b5051600081815260096020908152604080832080546001810182559084529282902090920187905585810151868301516060808901516080808b015187518d815296870195909552858701939093529084015267ffffffffffffffff9091169082015290519192507f63a961310560faa9fef6286931f6e109c6bc7b31f798ae8da4cf19005ec45579919081900360a00190a150505050565b6000808080858510612899578693506128b7565b8787039250858584028115156128ab57fe5b05915081880190508093505b505050949350505050565b6040805161010081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081019190915290565b81548183558181111561120d5760008381526020902061120d91810190830161294391905b8082111561293f576000815560010161292b565b5090565b905600a165627a7a723058203d5aae27dc7d0feda7a01108025692ad2d35e454dddbb296b6f937018d56f12e0029
Swarm Source
bzzr://3d5aae27dc7d0feda7a01108025692ad2d35e454dddbb296b6f937018d56f12e
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 26 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.