Source Code
Overview
ETH Balance
0 ETH
ETH Value
$0.00More Info
Private Name Tags
ContractCreator
TokenTracker
Cross-Chain Transactions
Loading...
Loading
Contract Name:
MarchMadness
Compiler Version
v0.8.4+commit.c7e474f2
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import "@openzeppelin/contracts-4.4.1/utils/Counters.sol";
import "@openzeppelin/contracts-4.4.1/access/Ownable.sol";
import "@openzeppelin/contracts-4.4.1/security/Pausable.sol";
import "@openzeppelin/contracts-4.4.1/token/ERC721/extensions/ERC721URIStorage.sol";
contract MarchMadness is ERC721URIStorage, Pausable, Ownable {
/* ========== LIBRARIES ========== */
using Counters for Counters.Counter;
/* ========== STATE VARIABLES ========== */
Counters.Counter private _tokenIds;
string public _name = "Overtime March Madness";
string public _symbol = "OMM";
uint public canNotMintOrUpdateAfter;
uint NUMBER_OF_ROUNDS = 6;
uint[63] public results;
uint[6] public roundToPoints;
mapping(address => bool) public addressAlreadyMinted;
mapping(uint => uint[63]) public itemToBrackets;
mapping(address => uint) public addressToTokenId;
mapping(uint => uint[]) public roundToGameIds;
string public urlToUse;
/* ========== MODIFIER ========== */
modifier notAfterFinalDate() {
require(canNotMintOrUpdateAfter != 0, "canNotMintOrUpdateAfter is not set");
require(block.timestamp < canNotMintOrUpdateAfter, "Can not mint after settled date");
_;
}
/* ========== CONSTRUCTOR ========== */
constructor() ERC721(_name, _symbol) {}
/* ========== OWC ========== */
function mint(uint[63] memory _brackets) external whenNotPaused notAfterFinalDate returns (uint newItemId) {
require(!addressAlreadyMinted[msg.sender], "Address already minted");
_tokenIds.increment();
newItemId = _tokenIds.current();
_mint(msg.sender, newItemId);
addressAlreadyMinted[msg.sender] = true;
itemToBrackets[newItemId] = _brackets;
addressToTokenId[msg.sender] = newItemId;
_setTokenURI(newItemId, urlToUse);
emit Mint(msg.sender, newItemId, _brackets);
}
function updateBracketsForAlreadyMintedItem(uint _tokenId, uint[63] memory _brackets)
external
whenNotPaused
notAfterFinalDate
{
require(_exists(_tokenId), "Item does not exists");
require(ownerOf(_tokenId) == msg.sender, "Caller is not owner of entered tokenId");
itemToBrackets[_tokenId] = _brackets;
emit UpdateBracketsForAlreadyMintedItem(msg.sender, _tokenId, _brackets);
}
/* ========== VIEW ========== */
function getBracketsByMinter(address _minter) public view returns (uint[63] memory brackets) {
uint _tokenId = addressToTokenId[_minter];
if (_tokenId == 0 || itemToBrackets[_tokenId][0] == 0) return brackets;
brackets = itemToBrackets[_tokenId];
return brackets;
}
function getResults() external view returns (uint[63] memory) {
return results;
}
function isTeamWinnerOfGameId(uint _gameId, uint _teamId) public view returns (bool _flag) {
if (isValidGameId(_gameId)) {
if (results[_gameId] == _teamId) _flag = true;
}
return _flag;
}
function getCorrectPositionsByTokenId(uint _tokenId) public view returns (uint correctPredictions) {
uint[63] memory _brackets = itemToBrackets[_tokenId];
if (_brackets[1] == 0) return 0;
for (uint i = 0; i < _brackets.length; i++) {
if (_brackets[i] == results[i]) {
correctPredictions++;
}
}
return correctPredictions;
}
function getCorrectPositionsByMinterAddress(address _minter) public view returns (uint) {
if (addressToTokenId[_minter] == 0) return 0;
return getCorrectPositionsByTokenId(addressToTokenId[_minter]);
}
function getCorrectPositionsPerRoundByTokenId(uint _roundId, uint _tokenId)
public
view
returns (uint correctPredictions)
{
if (!isValidRoundId(_roundId)) return 0;
if (!_exists(_tokenId)) return 0;
uint[] memory gameIdsForRound = roundToGameIds[_roundId];
uint[63] memory brackets = itemToBrackets[_tokenId];
for (uint i = 0; i < gameIdsForRound.length; i++) {
if (isTeamWinnerOfGameId(gameIdsForRound[i], brackets[gameIdsForRound[i]])) correctPredictions++;
}
return correctPredictions;
}
function getCorrectPositionsPerRoundByMinterAddress(uint _roundId, address _minter) public view returns (uint) {
if (addressToTokenId[_minter] == 0) return 0;
return getCorrectPositionsPerRoundByTokenId(_roundId, addressToTokenId[_minter]);
}
function getCorrectPositionsByRound(address _minter) public view returns (uint[6] memory correctPositionsByRound) {
if (!_exists(addressToTokenId[_minter])) return correctPositionsByRound;
for (uint i = 0; i < NUMBER_OF_ROUNDS; i++) {
uint correctPositionPerRound = getCorrectPositionsPerRoundByTokenId(i, addressToTokenId[_minter]);
correctPositionsByRound[i] = correctPositionPerRound;
}
return correctPositionsByRound;
}
function getTotalPointsByTokenId(uint _tokenId) public view returns (uint totalPoints) {
if (!_exists(_tokenId)) return totalPoints;
for (uint i = 0; i < roundToPoints.length; i++) {
uint correctPositionPerRound = getCorrectPositionsPerRoundByTokenId(i, _tokenId);
totalPoints += (correctPositionPerRound * roundToPoints[i]);
}
return totalPoints;
}
function getPointsPerRound(address _minter) public view returns (uint[6] memory pointsPerRound) {
if (addressToTokenId[_minter] == 0) return pointsPerRound;
if (!_exists(addressToTokenId[_minter])) return pointsPerRound;
for (uint i = 0; i < NUMBER_OF_ROUNDS; i++) {
uint correctPositionPerRound = getCorrectPositionsPerRoundByTokenId(i, addressToTokenId[_minter]);
pointsPerRound[i] += (correctPositionPerRound * roundToPoints[i]);
}
return pointsPerRound;
}
function getTotalPointsByMinterAddress(address _minter) public view returns (uint) {
if (addressToTokenId[_minter] == 0) return 0;
return getTotalPointsByTokenId(addressToTokenId[_minter]);
}
/* ========== INTERNALS ========== */
function _beforeTokenTransfer(
address from,
address to,
uint256 tokenId
) internal virtual override {
require(from == address(0) || to == address(0), "NonTransferrableERC721Token: non transferrable");
}
function isValidGameId(uint _gameId) internal pure returns (bool _flag) {
if (_gameId >= 0 && _gameId < 63) _flag = true;
return _flag;
}
function isValidRoundId(uint _roundId) internal pure returns (bool _flag) {
if (_roundId >= 0 && _roundId < 6) _flag = true;
return _flag;
}
function isValidTeamIndex(uint _teamId) internal pure returns (bool _flag) {
if (_teamId > 0 && _teamId <= 64) _flag = true;
return _flag;
}
/* ========== CONTRACT MANAGEMENT ========== */
function setPaused(bool paused) external onlyOwner {
return paused ? _pause() : _unpause();
}
function setURLToUse(string memory _urlToUse) external onlyOwner {
urlToUse = _urlToUse;
}
function setResultForGame(uint _gameId, uint _teamId) external onlyOwner {
require(isValidTeamIndex(_teamId), "Not valid team index");
require(isValidGameId(_gameId), "Not valid game index");
results[_gameId] = _teamId;
emit ResultForGameAdded(_gameId, _teamId);
}
function setFinalDateForPositioning(uint _toDate) external onlyOwner {
canNotMintOrUpdateAfter = _toDate;
emit FinalPositioningDateUpdated(_toDate);
}
function setPointsToRound(uint _roundId, uint _points) external onlyOwner {
require(isValidGameId(_roundId), "Not valid roundId");
roundToPoints[_roundId] = _points;
emit PointsSettledForRound(_roundId, _points);
}
function assignGameIdsToRound(uint _roundId, uint[] memory _gameIds) external onlyOwner {
// Validation of game ids
for (uint i = 0; i < _gameIds.length; i++) {
require(isValidGameId(_gameIds[i]), "Not valid gameId");
}
require(isValidRoundId(_roundId), "Not valid round id");
roundToGameIds[_roundId] = _gameIds;
emit GameIdsAssignedToRound(_roundId, _gameIds);
}
/* ========== EVENTS ========== */
event Mint(address _recipient, uint _id, uint[63] _brackets);
event UpdateBracketsForAlreadyMintedItem(address _minter, uint itemIndex, uint[63] _newBrackets);
event ResultForGameAdded(uint _gameIndex, uint _teamId);
event FinalPositioningDateUpdated(uint _toDate);
event GameIdsAssignedToRound(uint _roundId, uint[] _gameIds);
event PointsSettledForRound(uint _roundId, uint _points);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Counters.sol)
pragma solidity ^0.8.0;
/**
* @title Counters
* @author Matt Condon (@shrugs)
* @dev Provides counters that can only be incremented, decremented or reset. This can be used e.g. to track the number
* of elements in a mapping, issuing ERC721 ids, or counting request ids.
*
* Include with `using Counters for Counters.Counter;`
*/
library Counters {
struct Counter {
// This variable should never be directly accessed by users of the library: interactions must be restricted to
// the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add
// this feature: see https://github.com/ethereum/solidity/issues/4637
uint256 _value; // default: 0
}
function current(Counter storage counter) internal view returns (uint256) {
return counter._value;
}
function increment(Counter storage counter) internal {
unchecked {
counter._value += 1;
}
}
function decrement(Counter storage counter) internal {
uint256 value = counter._value;
require(value > 0, "Counter: decrement overflow");
unchecked {
counter._value = value - 1;
}
}
function reset(Counter storage counter) internal {
counter._value = 0;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)
pragma solidity ^0.8.0;
import "../utils/Context.sol";
/**
* @dev Contract module which provides a basic access control mechanism, where
* there is an account (an owner) that can be granted exclusive access to
* specific functions.
*
* By default, the owner account will be the one that deploys the contract. This
* can later be changed with {transferOwnership}.
*
* This module is used through inheritance. It will make available the modifier
* `onlyOwner`, which can be applied to your functions to restrict their use to
* the owner.
*/
abstract contract Ownable is Context {
address private _owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
/**
* @dev Initializes the contract setting the deployer as the initial owner.
*/
constructor() {
_transferOwnership(_msgSender());
}
/**
* @dev Throws if called by any account other than the owner.
*/
modifier onlyOwner() {
_checkOwner();
_;
}
/**
* @dev Returns the address of the current owner.
*/
function owner() public view virtual returns (address) {
return _owner;
}
/**
* @dev Throws if the sender is not the owner.
*/
function _checkOwner() internal view virtual {
require(owner() == _msgSender(), "Ownable: caller is not the owner");
}
/**
* @dev Leaves the contract without owner. It will not be possible to call
* `onlyOwner` functions anymore. Can only be called by the current owner.
*
* NOTE: Renouncing ownership will leave the contract without an owner,
* thereby removing any functionality that is only available to the owner.
*/
function renounceOwnership() public virtual onlyOwner {
_transferOwnership(address(0));
}
/**
* @dev Transfers ownership of the contract to a new account (`newOwner`).
* Can only be called by the current owner.
*/
function transferOwnership(address newOwner) public virtual onlyOwner {
require(newOwner != address(0), "Ownable: new owner is the zero address");
_transferOwnership(newOwner);
}
/**
* @dev Transfers ownership of the contract to a new account (`newOwner`).
* Internal function without access restriction.
*/
function _transferOwnership(address newOwner) internal virtual {
address oldOwner = _owner;
_owner = newOwner;
emit OwnershipTransferred(oldOwner, newOwner);
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (security/Pausable.sol)
pragma solidity ^0.8.0;
import "../utils/Context.sol";
/**
* @dev Contract module which allows children to implement an emergency stop
* mechanism that can be triggered by an authorized account.
*
* This module is used through inheritance. It will make available the
* modifiers `whenNotPaused` and `whenPaused`, which can be applied to
* the functions of your contract. Note that they will not be pausable by
* simply including this module, only once the modifiers are put in place.
*/
abstract contract Pausable is Context {
/**
* @dev Emitted when the pause is triggered by `account`.
*/
event Paused(address account);
/**
* @dev Emitted when the pause is lifted by `account`.
*/
event Unpaused(address account);
bool private _paused;
/**
* @dev Initializes the contract in unpaused state.
*/
constructor() {
_paused = false;
}
/**
* @dev Modifier to make a function callable only when the contract is not paused.
*
* Requirements:
*
* - The contract must not be paused.
*/
modifier whenNotPaused() {
_requireNotPaused();
_;
}
/**
* @dev Modifier to make a function callable only when the contract is paused.
*
* Requirements:
*
* - The contract must be paused.
*/
modifier whenPaused() {
_requirePaused();
_;
}
/**
* @dev Returns true if the contract is paused, and false otherwise.
*/
function paused() public view virtual returns (bool) {
return _paused;
}
/**
* @dev Throws if the contract is paused.
*/
function _requireNotPaused() internal view virtual {
require(!paused(), "Pausable: paused");
}
/**
* @dev Throws if the contract is not paused.
*/
function _requirePaused() internal view virtual {
require(paused(), "Pausable: not paused");
}
/**
* @dev Triggers stopped state.
*
* Requirements:
*
* - The contract must not be paused.
*/
function _pause() internal virtual whenNotPaused {
_paused = true;
emit Paused(_msgSender());
}
/**
* @dev Returns to normal state.
*
* Requirements:
*
* - The contract must be paused.
*/
function _unpause() internal virtual whenPaused {
_paused = false;
emit Unpaused(_msgSender());
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/extensions/ERC721URIStorage.sol)
pragma solidity ^0.8.0;
import "../ERC721.sol";
/**
* @dev ERC721 token with storage based token URI management.
*/
abstract contract ERC721URIStorage is ERC721 {
using Strings for uint256;
// Optional mapping for token URIs
mapping(uint256 => string) private _tokenURIs;
/**
* @dev See {IERC721Metadata-tokenURI}.
*/
function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
_requireMinted(tokenId);
string memory _tokenURI = _tokenURIs[tokenId];
string memory base = _baseURI();
// If there is no base URI, return the token URI.
if (bytes(base).length == 0) {
return _tokenURI;
}
// If both are set, concatenate the baseURI and tokenURI (via abi.encodePacked).
if (bytes(_tokenURI).length > 0) {
return string(abi.encodePacked(base, _tokenURI));
}
return super.tokenURI(tokenId);
}
/**
* @dev Sets `_tokenURI` as the tokenURI of `tokenId`.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function _setTokenURI(uint256 tokenId, string memory _tokenURI) internal virtual {
require(_exists(tokenId), "ERC721URIStorage: URI set of nonexistent token");
_tokenURIs[tokenId] = _tokenURI;
}
/**
* @dev See {ERC721-_burn}. This override additionally checks to see if a
* token-specific URI was set for the token, and if so, it deletes the token URI from
* the storage mapping.
*/
function _burn(uint256 tokenId) internal virtual override {
super._burn(tokenId);
if (bytes(_tokenURIs[tokenId]).length != 0) {
delete _tokenURIs[tokenId];
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)
pragma solidity ^0.8.0;
/**
* @dev Provides information about the current execution context, including the
* sender of the transaction and its data. While these are generally available
* via msg.sender and msg.data, they should not be accessed in such a direct
* manner, since when dealing with meta-transactions the account sending and
* paying for execution may not be the actual sender (as far as an application
* is concerned).
*
* This contract is only required for intermediate, library-like contracts.
*/
abstract contract Context {
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes calldata) {
return msg.data;
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/ERC721.sol)
pragma solidity ^0.8.0;
import "./IERC721.sol";
import "./IERC721Receiver.sol";
import "./extensions/IERC721Metadata.sol";
import "../../utils/Address.sol";
import "../../utils/Context.sol";
import "../../utils/Strings.sol";
import "../../utils/introspection/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: address zero is not a valid owner");
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: invalid token ID");
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) {
_requireMinted(tokenId);
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 overridden 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 token owner nor approved for all"
);
_approve(to, tokenId);
}
/**
* @dev See {IERC721-getApproved}.
*/
function getApproved(uint256 tokenId) public view virtual override returns (address) {
_requireMinted(tokenId);
return _tokenApprovals[tokenId];
}
/**
* @dev See {IERC721-setApprovalForAll}.
*/
function setApprovalForAll(address operator, bool approved) public virtual override {
_setApprovalForAll(_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: caller is not token 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: caller is not token 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) {
address owner = ERC721.ownerOf(tokenId);
return (spender == owner || isApprovedForAll(owner, spender) || getApproved(tokenId) == 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);
_afterTokenTransfer(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);
_afterTokenTransfer(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 from incorrect owner");
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);
_afterTokenTransfer(from, to, tokenId);
}
/**
* @dev Approve `to` to operate on `tokenId`
*
* Emits an {Approval} event.
*/
function _approve(address to, uint256 tokenId) internal virtual {
_tokenApprovals[tokenId] = to;
emit Approval(ERC721.ownerOf(tokenId), to, tokenId);
}
/**
* @dev Approve `operator` to operate on all of `owner` tokens
*
* Emits an {ApprovalForAll} event.
*/
function _setApprovalForAll(
address owner,
address operator,
bool approved
) internal virtual {
require(owner != operator, "ERC721: approve to caller");
_operatorApprovals[owner][operator] = approved;
emit ApprovalForAll(owner, operator, approved);
}
/**
* @dev Reverts if the `tokenId` has not been minted yet.
*/
function _requireMinted(uint256 tokenId) internal view virtual {
require(_exists(tokenId), "ERC721: invalid token ID");
}
/**
* @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 {
/// @solidity memory-safe-assembly
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 {}
/**
* @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.
* - `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 tokenId
) internal virtual {}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/IERC721.sol)
pragma solidity ^0.8.0;
import "../../utils/introspection/IERC165.sol";
/**
* @dev Required interface of an ERC721 compliant contract.
*/
interface IERC721 is IERC165 {
/**
* @dev Emitted when `tokenId` token is transferred from `from` to `to`.
*/
event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);
/**
* @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.
*/
event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);
/**
* @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.
*/
event ApprovalForAll(address indexed owner, address indexed operator, bool approved);
/**
* @dev Returns the number of tokens in ``owner``'s account.
*/
function balanceOf(address owner) external view returns (uint256 balance);
/**
* @dev Returns the owner of the `tokenId` token.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function ownerOf(uint256 tokenId) external view returns (address owner);
/**
* @dev Safely transfers `tokenId` token from `from` to `to`.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must exist and be owned by `from`.
* - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
*
* Emits a {Transfer} event.
*/
function safeTransferFrom(
address from,
address to,
uint256 tokenId,
bytes calldata data
) external;
/**
* @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
* are aware of the ERC721 protocol to prevent tokens from being forever locked.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must exist and be owned by `from`.
* - If the caller is not `from`, it must have been allowed to move this token by either {approve} or {setApprovalForAll}.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
*
* Emits a {Transfer} event.
*/
function safeTransferFrom(
address from,
address to,
uint256 tokenId
) external;
/**
* @dev Transfers `tokenId` token from `from` to `to`.
*
* WARNING: 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 Approve or remove `operator` as an operator for the caller.
* Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
*
* Requirements:
*
* - The `operator` cannot be the caller.
*
* Emits an {ApprovalForAll} event.
*/
function setApprovalForAll(address operator, bool _approved) external;
/**
* @dev Returns the account approved for `tokenId` token.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function getApproved(uint256 tokenId) external view returns (address operator);
/**
* @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
*
* See {setApprovalForAll}
*/
function isApprovedForAll(address owner, address operator) external view returns (bool);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol)
pragma solidity ^0.8.0;
/**
* @title ERC721 token receiver interface
* @dev Interface for any contract that wants to support safeTransfers
* from ERC721 asset contracts.
*/
interface IERC721Receiver {
/**
* @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
* by `operator` from `from`, this function is called.
*
* It must return its Solidity selector to confirm the token transfer.
* If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.
*
* The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`.
*/
function onERC721Received(
address operator,
address from,
uint256 tokenId,
bytes calldata data
) external returns (bytes4);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol)
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
// OpenZeppelin Contracts (last updated v4.7.0) (utils/Address.sol)
pragma solidity ^0.8.1;
/**
* @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
* ====
*
* [IMPORTANT]
* ====
* You shouldn't rely on `isContract` to protect against flash loan attacks!
*
* Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
* like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
* constructor.
* ====
*/
function isContract(address account) internal view returns (bool) {
// This method relies on extcodesize/address.code.length, which returns 0
// for contracts in construction, since the code is only stored at the end
// of the constructor execution.
return account.code.length > 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
/// @solidity memory-safe-assembly
assembly {
let returndata_size := mload(returndata)
revert(add(32, returndata), returndata_size)
}
} else {
revert(errorMessage);
}
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (utils/Strings.sol)
pragma solidity ^0.8.0;
/**
* @dev String operations.
*/
library Strings {
bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef";
uint8 private constant _ADDRESS_LENGTH = 20;
/**
* @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);
}
/**
* @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation.
*/
function toHexString(address addr) internal pure returns (string memory) {
return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH);
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol)
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
// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol)
pragma solidity ^0.8.0;
/**
* @dev Interface of the ERC165 standard, as defined in the
* https://eips.ethereum.org/EIPS/eip-165[EIP].
*
* Implementers can declare support of contract interfaces, which can then be
* queried by others ({ERC165Checker}).
*
* For an implementation, see {ERC165}.
*/
interface IERC165 {
/**
* @dev Returns true if this contract implements the interface defined by
* `interfaceId`. See the corresponding
* https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
* to learn more about how these ids are created.
*
* This function call must use less than 30 000 gas.
*/
function supportsInterface(bytes4 interfaceId) external view returns (bool);
}{
"optimizer": {
"enabled": true,
"runs": 200
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
},
"libraries": {}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[],"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":false,"internalType":"uint256","name":"_toDate","type":"uint256"}],"name":"FinalPositioningDateUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_roundId","type":"uint256"},{"indexed":false,"internalType":"uint256[]","name":"_gameIds","type":"uint256[]"}],"name":"GameIdsAssignedToRound","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_recipient","type":"address"},{"indexed":false,"internalType":"uint256","name":"_id","type":"uint256"},{"indexed":false,"internalType":"uint256[63]","name":"_brackets","type":"uint256[63]"}],"name":"Mint","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":false,"internalType":"uint256","name":"_roundId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_points","type":"uint256"}],"name":"PointsSettledForRound","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_gameIndex","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_teamId","type":"uint256"}],"name":"ResultForGameAdded","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"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_minter","type":"address"},{"indexed":false,"internalType":"uint256","name":"itemIndex","type":"uint256"},{"indexed":false,"internalType":"uint256[63]","name":"_newBrackets","type":"uint256[63]"}],"name":"UpdateBracketsForAlreadyMintedItem","type":"event"},{"inputs":[],"name":"_name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"addressAlreadyMinted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"addressToTokenId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"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":"uint256","name":"_roundId","type":"uint256"},{"internalType":"uint256[]","name":"_gameIds","type":"uint256[]"}],"name":"assignGameIdsToRound","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":"canNotMintOrUpdateAfter","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_minter","type":"address"}],"name":"getBracketsByMinter","outputs":[{"internalType":"uint256[63]","name":"brackets","type":"uint256[63]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_minter","type":"address"}],"name":"getCorrectPositionsByMinterAddress","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_minter","type":"address"}],"name":"getCorrectPositionsByRound","outputs":[{"internalType":"uint256[6]","name":"correctPositionsByRound","type":"uint256[6]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"getCorrectPositionsByTokenId","outputs":[{"internalType":"uint256","name":"correctPredictions","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_roundId","type":"uint256"},{"internalType":"address","name":"_minter","type":"address"}],"name":"getCorrectPositionsPerRoundByMinterAddress","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_roundId","type":"uint256"},{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"getCorrectPositionsPerRoundByTokenId","outputs":[{"internalType":"uint256","name":"correctPredictions","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_minter","type":"address"}],"name":"getPointsPerRound","outputs":[{"internalType":"uint256[6]","name":"pointsPerRound","type":"uint256[6]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getResults","outputs":[{"internalType":"uint256[63]","name":"","type":"uint256[63]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_minter","type":"address"}],"name":"getTotalPointsByMinterAddress","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"getTotalPointsByTokenId","outputs":[{"internalType":"uint256","name":"totalPoints","type":"uint256"}],"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":[{"internalType":"uint256","name":"_gameId","type":"uint256"},{"internalType":"uint256","name":"_teamId","type":"uint256"}],"name":"isTeamWinnerOfGameId","outputs":[{"internalType":"bool","name":"_flag","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"itemToBrackets","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[63]","name":"_brackets","type":"uint256[63]"}],"name":"mint","outputs":[{"internalType":"uint256","name":"newItemId","type":"uint256"}],"stateMutability":"nonpayable","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":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"results","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"roundToGameIds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"roundToPoints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","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":"uint256","name":"_toDate","type":"uint256"}],"name":"setFinalDateForPositioning","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"paused","type":"bool"}],"name":"setPaused","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_roundId","type":"uint256"},{"internalType":"uint256","name":"_points","type":"uint256"}],"name":"setPointsToRound","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_gameId","type":"uint256"},{"internalType":"uint256","name":"_teamId","type":"uint256"}],"name":"setResultForGame","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_urlToUse","type":"string"}],"name":"setURLToUse","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":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"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":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint256[63]","name":"_brackets","type":"uint256[63]"}],"name":"updateBracketsForAlreadyMintedItem","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"urlToUse","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"}]Contract Creation Code
60c0604052601660808190527f4f76657274696d65204d61726368204d61646e6573730000000000000000000060a09081526200004091600991906200024a565b50604080518082019091526003808252624f4d4d60e81b60209092019182526200006d91600a916200024a565b506006600c553480156200008057600080fd5b50600980546200009090620002f0565b80601f0160208091040260200160405190810160405280929190818152602001828054620000be90620002f0565b80156200010f5780601f10620000e3576101008083540402835291602001916200010f565b820191906000526020600020905b815481529060010190602001808311620000f157829003601f168201915b5050505050600a80546200012390620002f0565b80601f01602080910402602001604051908101604052809291908181526020018280546200015190620002f0565b8015620001a25780601f106200017657610100808354040283529160200191620001a2565b820191906000526020600020905b8154815290600101906020018083116200018457829003601f168201915b50508451620001bc9350600092506020860191506200024a565b508051620001d29060019060208401906200024a565b50506007805460ff1916905550620001ea33620001f0565b6200032d565b600780546001600160a01b03838116610100818102610100600160a81b031985161790945560405193909204169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b8280546200025890620002f0565b90600052602060002090601f0160209004810192826200027c5760008555620002c7565b82601f106200029757805160ff1916838001178555620002c7565b82800160010185558215620002c7579182015b82811115620002c7578251825591602001919060010190620002aa565b50620002d5929150620002d9565b5090565b5b80821115620002d55760008155600101620002da565b600181811c908216806200030557607f821691505b602082108114156200032757634e487b7160e01b600052602260045260246000fd5b50919050565b612e8c806200033d6000396000f3fe608060405234801561001057600080fd5b506004361061028a5760003560e01c8063863ad9ad1161015c578063b88d4fde116100ce578063e985e9c511610087578063e985e9c5146105ac578063ebceceae146105e8578063ed652d1a146105fb578063f2fde38b1461060e578063fd71b28614610621578063ffd9420a1461063457600080fd5b8063b88d4fde14610535578063c65145a414610548578063c87b56dd1461055b578063ca6c261d1461056e578063caf2b72714610591578063d28d8852146105a457600080fd5b806395d89b411161012057806395d89b41146104d9578063a22cb465146104e1578063a321c83c146104f4578063ad3abe9c14610507578063b09f12661461051a578063b3fc4a111461052257600080fd5b8063863ad9ad1461047757806387c089ed1461048a5780638c29bfd21461049d5780638da5cb5b146104b0578063952a1979146104c657600080fd5b80634717f97c116102005780636352211e116101b95780636352211e1461040e57806363c117bd146104215780636511bf2e1461042957806370a0823114610449578063715018a61461045c57806377325cbc1461046457600080fd5b80634717f97c146103955780634e2508ad146103aa5780634e49ff46146103bd5780635c975abb146103dd5780635f5a5093146103e857806362d7d353146103fb57600080fd5b806316c38b3c1161025257806316c38b3c1461032d57806317a7f68e146103405780631b0c27da1461035357806323b872dd14610366578063293fb1731461037957806342842e0e1461038257600080fd5b806301ffc9a71461028f57806306c2b72c146102b757806306fdde03146102d8578063081812fc146102ed578063095ea7b314610318575b600080fd5b6102a261029d3660046128d1565b610647565b60405190151581526020015b60405180910390f35b6102ca6102c536600461294f565b610699565b6040519081526020016102ae565b6102e061078c565b6040516102ae9190612b99565b6103006102fb36600461294f565b61081e565b6040516001600160a01b0390911681526020016102ae565b61032b610326366004612872565b610845565b005b61032b61033b3660046128b7565b610960565b6102ca61034e36600461289b565b610980565b6102ca61036136600461294f565b610b8b565b61032b610374366004612795565b610ba2565b6102ca600b5481565b61032b610390366004612795565b610bd3565b61039d610bee565b6040516102ae9190612b62565b6102ca6103b8366004612967565b610c2a565b6103d06103cb366004612749565b610c7a565b6040516102ae9190612b71565b60075460ff166102a2565b61032b6103f6366004612909565b610d1f565b6102ca610409366004612a61565b610d3e565b61030061041c36600461294f565b610d63565b6102e0610dc3565b6102ca610437366004612749565b60546020526000908152604090205481565b6102ca610457366004612749565b610e51565b61032b610ed7565b61032b6104723660046129ad565b610eeb565b61039d610485366004612749565b611028565b6102ca61049836600461294f565b6110af565b6102ca6104ab366004612a61565b6110bf565b60075461010090046001600160a01b0316610300565b61032b6104d4366004612a61565b6110f0565b6102e06111ea565b61032b6104ef366004612849565b6111f9565b61032b610502366004612989565b611204565b61032b610515366004612a61565b611385565b6102e0611430565b6102ca610530366004612a61565b61143d565b61032b6105433660046127d0565b6115bc565b6102ca610556366004612749565b6115f4565b6102e061056936600461294f565b61163b565b6102a261057c366004612749565b60526020526000908152604090205460ff1681565b6102ca61059f366004612749565b61174c565b6102e0611793565b6102a26105ba366004612763565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b6103d06105f6366004612749565b6117a0565b61032b61060936600461294f565b61189d565b61032b61061c366004612749565b6118e0565b6102a261062f366004612a61565b611956565b6102ca61064236600461294f565b611999565b60006001600160e01b031982166380ac58cd60e01b148061067857506001600160e01b03198216635b5e139f60e01b145b8061069357506301ffc9a760e01b6001600160e01b03198316145b92915050565b60008181526053602052604080822081516107e08101928390528392909190603f9082845b8154815260200190600101908083116106be5750505050509050806001603f81106106f957634e487b7160e01b600052603260045260246000fd5b602002015161070b5750600092915050565b60005b603f81101561078557600d81603f811061073857634e487b7160e01b600052603260045260246000fd5b01548282603f811061075a57634e487b7160e01b600052603260045260246000fd5b60200201511415610773578261076f81612dcf565b9350505b8061077d81612dcf565b91505061070e565b5050919050565b60606000805461079b90612d9a565b80601f01602080910402602001604051908101604052809291908181526020018280546107c790612d9a565b80156108145780601f106107e957610100808354040283529160200191610814565b820191906000526020600020905b8154815290600101906020018083116107f757829003601f168201915b5050505050905090565b600061082982611a14565b506000908152600460205260409020546001600160a01b031690565b600061085082610d63565b9050806001600160a01b0316836001600160a01b031614156108c35760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b336001600160a01b03821614806108df57506108df81336105ba565b6109515760405162461bcd60e51b815260206004820152603e60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206e6f7220617070726f76656420666f7220616c6c000060648201526084016108ba565b61095b8383611a64565b505050565b610968611ad2565b8061097857610975611b32565b50565b610975611b84565b600061098a611bc1565b600b546109a95760405162461bcd60e51b81526004016108ba90612bfe565b600b5442106109fa5760405162461bcd60e51b815260206004820152601f60248201527f43616e206e6f74206d696e7420616674657220736574746c656420646174650060448201526064016108ba565b3360009081526052602052604090205460ff1615610a535760405162461bcd60e51b81526020600482015260166024820152751059191c995cdcc8185b1c9958591e481b5a5b9d195960521b60448201526064016108ba565b610a61600880546001019055565b50600854610a6f3382611c07565b336000908152605260209081526040808320805460ff1916600117905583835260539091529020610aa29083603f612516565b5033600090815260546020526040902081905560568054610b4b918391610ac890612d9a565b80601f0160208091040260200160405190810160405280929190818152602001828054610af490612d9a565b8015610b415780601f10610b1657610100808354040283529160200191610b41565b820191906000526020600020905b815481529060010190602001808311610b2457829003601f168201915b5050505050611d46565b7fee0b5de5941b34401bf7c865d6b46a959d512490a3f9757e3b775aa04387a813338284604051610b7e93929190612b3d565b60405180910390a1919050565b600d81603f8110610b9b57600080fd5b0154905081565b610bac3382611dd1565b610bc85760405162461bcd60e51b81526004016108ba90612c40565b61095b838383611e4f565b61095b838383604051806020016040528060008152506115bc565b610bf6612554565b604080516107e081019182905290600d90603f9082845b815481526020019060010190808311610c0d575050505050905090565b6001600160a01b038116600090815260546020526040812054610c4f57506000610693565b6001600160a01b038216600090815260546020526040902054610c7390849061143d565b9392505050565b610c82612573565b6001600160a01b038216600090815260546020526040902054610ca490611ff6565b610cad57919050565b60005b600c54811015610d19576001600160a01b038316600090815260546020526040812054610cde90839061143d565b905080838360068110610d0157634e487b7160e01b600052603260045260246000fd5b60200201525080610d1181612dcf565b915050610cb0565b50919050565b610d27611ad2565b8051610d3a906056906020840190612591565b5050565b605360205281600052604060002081603f8110610d5a57600080fd5b01549150829050565b6000818152600260205260408120546001600160a01b0316806106935760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b60448201526064016108ba565b60568054610dd090612d9a565b80601f0160208091040260200160405190810160405280929190818152602001828054610dfc90612d9a565b8015610e495780601f10610e1e57610100808354040283529160200191610e49565b820191906000526020600020905b815481529060010190602001808311610e2c57829003601f168201915b505050505081565b60006001600160a01b038216610ebb5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b60648201526084016108ba565b506001600160a01b031660009081526003602052604090205490565b610edf611ad2565b610ee96000612013565b565b610ef3611ad2565b60005b8151811015610f8057610f2f828281518110610f2257634e487b7160e01b600052603260045260246000fd5b602002602001015161206d565b610f6e5760405162461bcd60e51b815260206004820152601060248201526f139bdd081d985b1a590819d85b59525960821b60448201526064016108ba565b80610f7881612dcf565b915050610ef6565b50610f8a82612082565b610fcb5760405162461bcd60e51b8152602060048201526012602482015271139bdd081d985b1a59081c9bdd5b99081a5960721b60448201526064016108ba565b60008281526055602090815260409091208251610fea92840190612604565b507f026ff7b0c2ab55edaf00423b668ee3b4d2c23520deccac97018477ae3aefb5ca828260405161101c929190612c8e565b60405180910390a15050565b611030612554565b6001600160a01b0382166000908152605460205260409020548015806110625750600081815260536020526040902054155b1561106d5750919050565b6000818152605360205260409081902081516107e081019283905291603f9082845b81548152602001906001019080831161108f575050505050915050919050565b604c8160068110610b9b57600080fd5b605560205281600052604060002081815481106110db57600080fd5b90600052602060002001600091509150505481565b6110f8611ad2565b61110181612095565b6111445760405162461bcd60e51b815260206004820152601460248201527309cdee840ecc2d8d2c840e8cac2da40d2dcc8caf60631b60448201526064016108ba565b61114d8261206d565b6111905760405162461bcd60e51b815260206004820152601460248201527309cdee840ecc2d8d2c840cec2daca40d2dcc8caf60631b60448201526064016108ba565b80600d83603f81106111b257634e487b7160e01b600052603260045260246000fd5b015560408051838152602081018390527fcd0391919a6c4c4028a73549dc83917cb39bf3e561c0e8a7c29b95f45f3af41c910161101c565b60606001805461079b90612d9a565b610d3a3383836120b1565b61120c611bc1565b600b5461122b5760405162461bcd60e51b81526004016108ba90612bfe565b600b54421061127c5760405162461bcd60e51b815260206004820152601f60248201527f43616e206e6f74206d696e7420616674657220736574746c656420646174650060448201526064016108ba565b61128582611ff6565b6112c85760405162461bcd60e51b81526020600482015260146024820152734974656d20646f6573206e6f742065786973747360601b60448201526064016108ba565b336112d283610d63565b6001600160a01b0316146113375760405162461bcd60e51b815260206004820152602660248201527f43616c6c6572206973206e6f74206f776e6572206f6620656e746572656420746044820152651bdad95b925960d21b60648201526084016108ba565b60008281526053602052604090206113519082603f612516565b507f98a96b21a5b9cb2322f72dec284116c680d18675f4e59dd0fc0921a2873d891b33838360405161101c93929190612b3d565b61138d611ad2565b6113968261206d565b6113d65760405162461bcd60e51b8152602060048201526011602482015270139bdd081d985b1a59081c9bdd5b991259607a1b60448201526064016108ba565b80604c83600681106113f857634e487b7160e01b600052603260045260246000fd5b015560408051838152602081018390527f8cc3b52ea11c6a8927413e389cb7374db66234a2b06eb100b724f8b35411b993910161101c565b600a8054610dd090612d9a565b600061144883612082565b61145457506000610693565b61145d82611ff6565b61146957506000610693565b6000838152605560209081526040808320805482518185028101850190935280835291929091908301828280156114bf57602002820191906000526020600020905b8154815260200190600101908083116114ab575b50505060008681526053602052604080822081516107e081019283905295965091949350909150603f9082845b8154815260200190600101908083116114ec575050505050905060005b82518110156115b35761158e83828151811061153557634e487b7160e01b600052603260045260246000fd5b60200260200101518385848151811061155e57634e487b7160e01b600052603260045260246000fd5b6020026020010151603f811061158457634e487b7160e01b600052603260045260246000fd5b6020020151611956565b156115a1578361159d81612dcf565b9450505b806115ab81612dcf565b915050611509565b50505092915050565b6115c63383611dd1565b6115e25760405162461bcd60e51b81526004016108ba90612c40565b6115ee84848484612180565b50505050565b6001600160a01b03811660009081526054602052604081205461161957506000919050565b6001600160a01b03821660009081526054602052604090205461069390610699565b606061164682611a14565b6000828152600660205260408120805461165f90612d9a565b80601f016020809104026020016040519081016040528092919081815260200182805461168b90612d9a565b80156116d85780601f106116ad576101008083540402835291602001916116d8565b820191906000526020600020905b8154815290600101906020018083116116bb57829003601f168201915b5050505050905060006116f660408051602081019091526000815290565b9050805160001415611709575092915050565b81511561173b578082604051602001611723929190612ad1565b60405160208183030381529060405292505050919050565b611744846121b3565b949350505050565b6001600160a01b03811660009081526054602052604081205461177157506000919050565b6001600160a01b03821660009081526054602052604090205461069390611999565b60098054610dd090612d9a565b6117a8612573565b6001600160a01b0382166000908152605460205260409020546117ca57919050565b6001600160a01b0382166000908152605460205260409020546117ec90611ff6565b6117f557919050565b60005b600c54811015610d19576001600160a01b03831660009081526054602052604081205461182690839061143d565b9050604c826006811061184957634e487b7160e01b600052603260045260246000fd5b01546118559082612d38565b83836006811061187557634e487b7160e01b600052603260045260246000fd5b602002018181516118869190612d0c565b90525081905061189581612dcf565b9150506117f8565b6118a5611ad2565b600b8190556040518181527fc1456c9966bc3681ed8acbe2d757397502d1fd47f8e7a1bd502cdb6549b480cc9060200160405180910390a150565b6118e8611ad2565b6001600160a01b03811661194d5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016108ba565b61097581612013565b60006119618361206d565b156106935781600d84603f811061198857634e487b7160e01b600052603260045260246000fd5b015414156106935750600192915050565b60006119a482611ff6565b6119ad57919050565b60005b6006811015610d195760006119c5828561143d565b9050604c82600681106119e857634e487b7160e01b600052603260045260246000fd5b01546119f49082612d38565b6119fe9084612d0c565b9250508080611a0c90612dcf565b9150506119b0565b611a1d81611ff6565b6109755760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b60448201526064016108ba565b600081815260046020526040902080546001600160a01b0319166001600160a01b0384169081179091558190611a9982610d63565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6007546001600160a01b03610100909104163314610ee95760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016108ba565b611b3a612226565b6007805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b611b8c611bc1565b6007805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258611b673390565b60075460ff1615610ee95760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b60448201526064016108ba565b6001600160a01b038216611c5d5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f206164647265737360448201526064016108ba565b611c6681611ff6565b15611cb35760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000060448201526064016108ba565b611cbf6000838361226f565b6001600160a01b0382166000908152600360205260408120805460019290611ce8908490612d0c565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b611d4f82611ff6565b611db25760405162461bcd60e51b815260206004820152602e60248201527f45524337323155524953746f726167653a2055524920736574206f66206e6f6e60448201526d32bc34b9ba32b73a103a37b5b2b760911b60648201526084016108ba565b6000828152600660209081526040909120825161095b92840190612591565b600080611ddd83610d63565b9050806001600160a01b0316846001600160a01b03161480611e2457506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff165b806117445750836001600160a01b0316611e3d8461081e565b6001600160a01b031614949350505050565b826001600160a01b0316611e6282610d63565b6001600160a01b031614611ec65760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b60648201526084016108ba565b6001600160a01b038216611f285760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b60648201526084016108ba565b611f3383838361226f565b611f3e600082611a64565b6001600160a01b0383166000908152600360205260408120805460019290611f67908490612d57565b90915550506001600160a01b0382166000908152600360205260408120805460019290611f95908490612d0c565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6000908152600260205260409020546001600160a01b0316151590565b600780546001600160a01b03838116610100818102610100600160a81b031985161790945560405193909204169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6000603f82105b1561207d575060015b919050565b6000600682101561207d57506001919050565b6000808211801561207457506040821161207d57506001919050565b816001600160a01b0316836001600160a01b031614156121135760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c65720000000000000060448201526064016108ba565b6001600160a01b03838116600081815260056020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b61218b848484611e4f565b612197848484846122ef565b6115ee5760405162461bcd60e51b81526004016108ba90612bac565b60606121be82611a14565b60006121d560408051602081019091526000815290565b905060008151116121f55760405180602001604052806000815250610c73565b806121ff846123fc565b604051602001612210929190612ad1565b6040516020818303038152906040529392505050565b60075460ff16610ee95760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b60448201526064016108ba565b6001600160a01b038316158061228c57506001600160a01b038216155b61095b5760405162461bcd60e51b815260206004820152602e60248201527f4e6f6e5472616e736665727261626c65455243373231546f6b656e3a206e6f6e60448201526d207472616e736665727261626c6560901b60648201526084016108ba565b60006001600160a01b0384163b156123f157604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612333903390899088908890600401612b00565b602060405180830381600087803b15801561234d57600080fd5b505af192505050801561237d575060408051601f3d908101601f1916820190925261237a918101906128ed565b60015b6123d7573d8080156123ab576040519150601f19603f3d011682016040523d82523d6000602084013e6123b0565b606091505b5080516123cf5760405162461bcd60e51b81526004016108ba90612bac565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611744565b506001949350505050565b6060816124205750506040805180820190915260018152600360fc1b602082015290565b8160005b811561244a578061243481612dcf565b91506124439050600a83612d24565b9150612424565b60008167ffffffffffffffff81111561247357634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f19166020018201604052801561249d576020820181803683370190505b5090505b8415611744576124b2600183612d57565b91506124bf600a86612dea565b6124ca906030612d0c565b60f81b8183815181106124ed57634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a90535061250f600a86612d24565b94506124a1565b82603f8101928215612544579160200282015b82811115612544578251825591602001919060010190612529565b5061255092915061263e565b5090565b604051806107e00160405280603f906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b82805461259d90612d9a565b90600052602060002090601f0160209004810192826125bf5760008555612544565b82601f106125d857805160ff1916838001178555612544565b828001600101855582156125445791820182811115612544578251825591602001919060010190612529565b8280548282559060005260206000209081019282156125445791602002820182811115612544578251825591602001919060010190612529565b5b80821115612550576000815560010161263f565b600067ffffffffffffffff83111561266d5761266d612e2a565b612680601f8401601f1916602001612cdb565b905082815283838301111561269457600080fd5b828260208301376000602084830101529392505050565b80356001600160a01b038116811461207d57600080fd5b600082601f8301126126d2578081fd5b6040516107e080820182811067ffffffffffffffff821117156126f7576126f7612e2a565b604052818482810187101561270a578485fd5b8492505b603f83101561272e5780358252600192909201916020918201910161270e565b509195945050505050565b8035801515811461207d57600080fd5b60006020828403121561275a578081fd5b610c73826126ab565b60008060408385031215612775578081fd5b61277e836126ab565b915061278c602084016126ab565b90509250929050565b6000806000606084860312156127a9578081fd5b6127b2846126ab565b92506127c0602085016126ab565b9150604084013590509250925092565b600080600080608085870312156127e5578081fd5b6127ee856126ab565b93506127fc602086016126ab565b925060408501359150606085013567ffffffffffffffff81111561281e578182fd5b8501601f8101871361282e578182fd5b61283d87823560208401612653565b91505092959194509250565b6000806040838503121561285b578182fd5b612864836126ab565b915061278c60208401612739565b60008060408385031215612884578182fd5b61288d836126ab565b946020939093013593505050565b60006107e082840312156128ad578081fd5b610c7383836126c2565b6000602082840312156128c8578081fd5b610c7382612739565b6000602082840312156128e2578081fd5b8135610c7381612e40565b6000602082840312156128fe578081fd5b8151610c7381612e40565b60006020828403121561291a578081fd5b813567ffffffffffffffff811115612930578182fd5b8201601f81018413612940578182fd5b61174484823560208401612653565b600060208284031215612960578081fd5b5035919050565b60008060408385031215612979578182fd5b8235915061278c602084016126ab565b600080610800838503121561299c578182fd5b8235915061278c84602085016126c2565b600080604083850312156129bf578182fd5b8235915060208084013567ffffffffffffffff808211156129de578384fd5b818601915086601f8301126129f1578384fd5b813581811115612a0357612a03612e2a565b8060051b9150612a14848301612cdb565b8181528481019084860184860187018b1015612a2e578788fd5b8795505b83861015612a50578035835260019590950194918601918601612a32565b508096505050505050509250929050565b60008060408385031215612a73578182fd5b50508035926020909101359150565b8060005b603f8110156115ee578151845260209384019390910190600101612a86565b60008151808452612abd816020860160208601612d6e565b601f01601f19169290920160200192915050565b60008351612ae3818460208801612d6e565b835190830190612af7818360208801612d6e565b01949350505050565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090612b3390830184612aa5565b9695505050505050565b6001600160a01b03841681526020810183905261082081016117446040830184612a82565b6107e081016106938284612a82565b60c08101818360005b60068110156115b3578151835260209283019290910190600101612b7a565b602081526000610c736020830184612aa5565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526022908201527f63616e4e6f744d696e744f725570646174654166746572206973206e6f742073604082015261195d60f21b606082015260800190565b6020808252602e908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526d1c881b9bdc88185c1c1c9bdd995960921b606082015260800190565b60006040820184835260206040818501528185518084526060860191508287019350845b81811015612cce57845183529383019391830191600101612cb2565b5090979650505050505050565b604051601f8201601f1916810167ffffffffffffffff81118282101715612d0457612d04612e2a565b604052919050565b60008219821115612d1f57612d1f612dfe565b500190565b600082612d3357612d33612e14565b500490565b6000816000190483118215151615612d5257612d52612dfe565b500290565b600082821015612d6957612d69612dfe565b500390565b60005b83811015612d89578181015183820152602001612d71565b838111156115ee5750506000910152565b600181811c90821680612dae57607f821691505b60208210811415610d1957634e487b7160e01b600052602260045260246000fd5b6000600019821415612de357612de3612dfe565b5060010190565b600082612df957612df9612e14565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160e01b03198116811461097557600080fdfea2646970667358221220cadb5fd7646f673713b47a905c93228096f1dbd89f7928f253fbbcc26057b22a64736f6c63430008040033
Deployed Bytecode
0x608060405234801561001057600080fd5b506004361061028a5760003560e01c8063863ad9ad1161015c578063b88d4fde116100ce578063e985e9c511610087578063e985e9c5146105ac578063ebceceae146105e8578063ed652d1a146105fb578063f2fde38b1461060e578063fd71b28614610621578063ffd9420a1461063457600080fd5b8063b88d4fde14610535578063c65145a414610548578063c87b56dd1461055b578063ca6c261d1461056e578063caf2b72714610591578063d28d8852146105a457600080fd5b806395d89b411161012057806395d89b41146104d9578063a22cb465146104e1578063a321c83c146104f4578063ad3abe9c14610507578063b09f12661461051a578063b3fc4a111461052257600080fd5b8063863ad9ad1461047757806387c089ed1461048a5780638c29bfd21461049d5780638da5cb5b146104b0578063952a1979146104c657600080fd5b80634717f97c116102005780636352211e116101b95780636352211e1461040e57806363c117bd146104215780636511bf2e1461042957806370a0823114610449578063715018a61461045c57806377325cbc1461046457600080fd5b80634717f97c146103955780634e2508ad146103aa5780634e49ff46146103bd5780635c975abb146103dd5780635f5a5093146103e857806362d7d353146103fb57600080fd5b806316c38b3c1161025257806316c38b3c1461032d57806317a7f68e146103405780631b0c27da1461035357806323b872dd14610366578063293fb1731461037957806342842e0e1461038257600080fd5b806301ffc9a71461028f57806306c2b72c146102b757806306fdde03146102d8578063081812fc146102ed578063095ea7b314610318575b600080fd5b6102a261029d3660046128d1565b610647565b60405190151581526020015b60405180910390f35b6102ca6102c536600461294f565b610699565b6040519081526020016102ae565b6102e061078c565b6040516102ae9190612b99565b6103006102fb36600461294f565b61081e565b6040516001600160a01b0390911681526020016102ae565b61032b610326366004612872565b610845565b005b61032b61033b3660046128b7565b610960565b6102ca61034e36600461289b565b610980565b6102ca61036136600461294f565b610b8b565b61032b610374366004612795565b610ba2565b6102ca600b5481565b61032b610390366004612795565b610bd3565b61039d610bee565b6040516102ae9190612b62565b6102ca6103b8366004612967565b610c2a565b6103d06103cb366004612749565b610c7a565b6040516102ae9190612b71565b60075460ff166102a2565b61032b6103f6366004612909565b610d1f565b6102ca610409366004612a61565b610d3e565b61030061041c36600461294f565b610d63565b6102e0610dc3565b6102ca610437366004612749565b60546020526000908152604090205481565b6102ca610457366004612749565b610e51565b61032b610ed7565b61032b6104723660046129ad565b610eeb565b61039d610485366004612749565b611028565b6102ca61049836600461294f565b6110af565b6102ca6104ab366004612a61565b6110bf565b60075461010090046001600160a01b0316610300565b61032b6104d4366004612a61565b6110f0565b6102e06111ea565b61032b6104ef366004612849565b6111f9565b61032b610502366004612989565b611204565b61032b610515366004612a61565b611385565b6102e0611430565b6102ca610530366004612a61565b61143d565b61032b6105433660046127d0565b6115bc565b6102ca610556366004612749565b6115f4565b6102e061056936600461294f565b61163b565b6102a261057c366004612749565b60526020526000908152604090205460ff1681565b6102ca61059f366004612749565b61174c565b6102e0611793565b6102a26105ba366004612763565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b6103d06105f6366004612749565b6117a0565b61032b61060936600461294f565b61189d565b61032b61061c366004612749565b6118e0565b6102a261062f366004612a61565b611956565b6102ca61064236600461294f565b611999565b60006001600160e01b031982166380ac58cd60e01b148061067857506001600160e01b03198216635b5e139f60e01b145b8061069357506301ffc9a760e01b6001600160e01b03198316145b92915050565b60008181526053602052604080822081516107e08101928390528392909190603f9082845b8154815260200190600101908083116106be5750505050509050806001603f81106106f957634e487b7160e01b600052603260045260246000fd5b602002015161070b5750600092915050565b60005b603f81101561078557600d81603f811061073857634e487b7160e01b600052603260045260246000fd5b01548282603f811061075a57634e487b7160e01b600052603260045260246000fd5b60200201511415610773578261076f81612dcf565b9350505b8061077d81612dcf565b91505061070e565b5050919050565b60606000805461079b90612d9a565b80601f01602080910402602001604051908101604052809291908181526020018280546107c790612d9a565b80156108145780601f106107e957610100808354040283529160200191610814565b820191906000526020600020905b8154815290600101906020018083116107f757829003601f168201915b5050505050905090565b600061082982611a14565b506000908152600460205260409020546001600160a01b031690565b600061085082610d63565b9050806001600160a01b0316836001600160a01b031614156108c35760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b336001600160a01b03821614806108df57506108df81336105ba565b6109515760405162461bcd60e51b815260206004820152603e60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206e6f7220617070726f76656420666f7220616c6c000060648201526084016108ba565b61095b8383611a64565b505050565b610968611ad2565b8061097857610975611b32565b50565b610975611b84565b600061098a611bc1565b600b546109a95760405162461bcd60e51b81526004016108ba90612bfe565b600b5442106109fa5760405162461bcd60e51b815260206004820152601f60248201527f43616e206e6f74206d696e7420616674657220736574746c656420646174650060448201526064016108ba565b3360009081526052602052604090205460ff1615610a535760405162461bcd60e51b81526020600482015260166024820152751059191c995cdcc8185b1c9958591e481b5a5b9d195960521b60448201526064016108ba565b610a61600880546001019055565b50600854610a6f3382611c07565b336000908152605260209081526040808320805460ff1916600117905583835260539091529020610aa29083603f612516565b5033600090815260546020526040902081905560568054610b4b918391610ac890612d9a565b80601f0160208091040260200160405190810160405280929190818152602001828054610af490612d9a565b8015610b415780601f10610b1657610100808354040283529160200191610b41565b820191906000526020600020905b815481529060010190602001808311610b2457829003601f168201915b5050505050611d46565b7fee0b5de5941b34401bf7c865d6b46a959d512490a3f9757e3b775aa04387a813338284604051610b7e93929190612b3d565b60405180910390a1919050565b600d81603f8110610b9b57600080fd5b0154905081565b610bac3382611dd1565b610bc85760405162461bcd60e51b81526004016108ba90612c40565b61095b838383611e4f565b61095b838383604051806020016040528060008152506115bc565b610bf6612554565b604080516107e081019182905290600d90603f9082845b815481526020019060010190808311610c0d575050505050905090565b6001600160a01b038116600090815260546020526040812054610c4f57506000610693565b6001600160a01b038216600090815260546020526040902054610c7390849061143d565b9392505050565b610c82612573565b6001600160a01b038216600090815260546020526040902054610ca490611ff6565b610cad57919050565b60005b600c54811015610d19576001600160a01b038316600090815260546020526040812054610cde90839061143d565b905080838360068110610d0157634e487b7160e01b600052603260045260246000fd5b60200201525080610d1181612dcf565b915050610cb0565b50919050565b610d27611ad2565b8051610d3a906056906020840190612591565b5050565b605360205281600052604060002081603f8110610d5a57600080fd5b01549150829050565b6000818152600260205260408120546001600160a01b0316806106935760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b60448201526064016108ba565b60568054610dd090612d9a565b80601f0160208091040260200160405190810160405280929190818152602001828054610dfc90612d9a565b8015610e495780601f10610e1e57610100808354040283529160200191610e49565b820191906000526020600020905b815481529060010190602001808311610e2c57829003601f168201915b505050505081565b60006001600160a01b038216610ebb5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b60648201526084016108ba565b506001600160a01b031660009081526003602052604090205490565b610edf611ad2565b610ee96000612013565b565b610ef3611ad2565b60005b8151811015610f8057610f2f828281518110610f2257634e487b7160e01b600052603260045260246000fd5b602002602001015161206d565b610f6e5760405162461bcd60e51b815260206004820152601060248201526f139bdd081d985b1a590819d85b59525960821b60448201526064016108ba565b80610f7881612dcf565b915050610ef6565b50610f8a82612082565b610fcb5760405162461bcd60e51b8152602060048201526012602482015271139bdd081d985b1a59081c9bdd5b99081a5960721b60448201526064016108ba565b60008281526055602090815260409091208251610fea92840190612604565b507f026ff7b0c2ab55edaf00423b668ee3b4d2c23520deccac97018477ae3aefb5ca828260405161101c929190612c8e565b60405180910390a15050565b611030612554565b6001600160a01b0382166000908152605460205260409020548015806110625750600081815260536020526040902054155b1561106d5750919050565b6000818152605360205260409081902081516107e081019283905291603f9082845b81548152602001906001019080831161108f575050505050915050919050565b604c8160068110610b9b57600080fd5b605560205281600052604060002081815481106110db57600080fd5b90600052602060002001600091509150505481565b6110f8611ad2565b61110181612095565b6111445760405162461bcd60e51b815260206004820152601460248201527309cdee840ecc2d8d2c840e8cac2da40d2dcc8caf60631b60448201526064016108ba565b61114d8261206d565b6111905760405162461bcd60e51b815260206004820152601460248201527309cdee840ecc2d8d2c840cec2daca40d2dcc8caf60631b60448201526064016108ba565b80600d83603f81106111b257634e487b7160e01b600052603260045260246000fd5b015560408051838152602081018390527fcd0391919a6c4c4028a73549dc83917cb39bf3e561c0e8a7c29b95f45f3af41c910161101c565b60606001805461079b90612d9a565b610d3a3383836120b1565b61120c611bc1565b600b5461122b5760405162461bcd60e51b81526004016108ba90612bfe565b600b54421061127c5760405162461bcd60e51b815260206004820152601f60248201527f43616e206e6f74206d696e7420616674657220736574746c656420646174650060448201526064016108ba565b61128582611ff6565b6112c85760405162461bcd60e51b81526020600482015260146024820152734974656d20646f6573206e6f742065786973747360601b60448201526064016108ba565b336112d283610d63565b6001600160a01b0316146113375760405162461bcd60e51b815260206004820152602660248201527f43616c6c6572206973206e6f74206f776e6572206f6620656e746572656420746044820152651bdad95b925960d21b60648201526084016108ba565b60008281526053602052604090206113519082603f612516565b507f98a96b21a5b9cb2322f72dec284116c680d18675f4e59dd0fc0921a2873d891b33838360405161101c93929190612b3d565b61138d611ad2565b6113968261206d565b6113d65760405162461bcd60e51b8152602060048201526011602482015270139bdd081d985b1a59081c9bdd5b991259607a1b60448201526064016108ba565b80604c83600681106113f857634e487b7160e01b600052603260045260246000fd5b015560408051838152602081018390527f8cc3b52ea11c6a8927413e389cb7374db66234a2b06eb100b724f8b35411b993910161101c565b600a8054610dd090612d9a565b600061144883612082565b61145457506000610693565b61145d82611ff6565b61146957506000610693565b6000838152605560209081526040808320805482518185028101850190935280835291929091908301828280156114bf57602002820191906000526020600020905b8154815260200190600101908083116114ab575b50505060008681526053602052604080822081516107e081019283905295965091949350909150603f9082845b8154815260200190600101908083116114ec575050505050905060005b82518110156115b35761158e83828151811061153557634e487b7160e01b600052603260045260246000fd5b60200260200101518385848151811061155e57634e487b7160e01b600052603260045260246000fd5b6020026020010151603f811061158457634e487b7160e01b600052603260045260246000fd5b6020020151611956565b156115a1578361159d81612dcf565b9450505b806115ab81612dcf565b915050611509565b50505092915050565b6115c63383611dd1565b6115e25760405162461bcd60e51b81526004016108ba90612c40565b6115ee84848484612180565b50505050565b6001600160a01b03811660009081526054602052604081205461161957506000919050565b6001600160a01b03821660009081526054602052604090205461069390610699565b606061164682611a14565b6000828152600660205260408120805461165f90612d9a565b80601f016020809104026020016040519081016040528092919081815260200182805461168b90612d9a565b80156116d85780601f106116ad576101008083540402835291602001916116d8565b820191906000526020600020905b8154815290600101906020018083116116bb57829003601f168201915b5050505050905060006116f660408051602081019091526000815290565b9050805160001415611709575092915050565b81511561173b578082604051602001611723929190612ad1565b60405160208183030381529060405292505050919050565b611744846121b3565b949350505050565b6001600160a01b03811660009081526054602052604081205461177157506000919050565b6001600160a01b03821660009081526054602052604090205461069390611999565b60098054610dd090612d9a565b6117a8612573565b6001600160a01b0382166000908152605460205260409020546117ca57919050565b6001600160a01b0382166000908152605460205260409020546117ec90611ff6565b6117f557919050565b60005b600c54811015610d19576001600160a01b03831660009081526054602052604081205461182690839061143d565b9050604c826006811061184957634e487b7160e01b600052603260045260246000fd5b01546118559082612d38565b83836006811061187557634e487b7160e01b600052603260045260246000fd5b602002018181516118869190612d0c565b90525081905061189581612dcf565b9150506117f8565b6118a5611ad2565b600b8190556040518181527fc1456c9966bc3681ed8acbe2d757397502d1fd47f8e7a1bd502cdb6549b480cc9060200160405180910390a150565b6118e8611ad2565b6001600160a01b03811661194d5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016108ba565b61097581612013565b60006119618361206d565b156106935781600d84603f811061198857634e487b7160e01b600052603260045260246000fd5b015414156106935750600192915050565b60006119a482611ff6565b6119ad57919050565b60005b6006811015610d195760006119c5828561143d565b9050604c82600681106119e857634e487b7160e01b600052603260045260246000fd5b01546119f49082612d38565b6119fe9084612d0c565b9250508080611a0c90612dcf565b9150506119b0565b611a1d81611ff6565b6109755760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b60448201526064016108ba565b600081815260046020526040902080546001600160a01b0319166001600160a01b0384169081179091558190611a9982610d63565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6007546001600160a01b03610100909104163314610ee95760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016108ba565b611b3a612226565b6007805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b611b8c611bc1565b6007805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258611b673390565b60075460ff1615610ee95760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b60448201526064016108ba565b6001600160a01b038216611c5d5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f206164647265737360448201526064016108ba565b611c6681611ff6565b15611cb35760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000060448201526064016108ba565b611cbf6000838361226f565b6001600160a01b0382166000908152600360205260408120805460019290611ce8908490612d0c565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b611d4f82611ff6565b611db25760405162461bcd60e51b815260206004820152602e60248201527f45524337323155524953746f726167653a2055524920736574206f66206e6f6e60448201526d32bc34b9ba32b73a103a37b5b2b760911b60648201526084016108ba565b6000828152600660209081526040909120825161095b92840190612591565b600080611ddd83610d63565b9050806001600160a01b0316846001600160a01b03161480611e2457506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff165b806117445750836001600160a01b0316611e3d8461081e565b6001600160a01b031614949350505050565b826001600160a01b0316611e6282610d63565b6001600160a01b031614611ec65760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b60648201526084016108ba565b6001600160a01b038216611f285760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b60648201526084016108ba565b611f3383838361226f565b611f3e600082611a64565b6001600160a01b0383166000908152600360205260408120805460019290611f67908490612d57565b90915550506001600160a01b0382166000908152600360205260408120805460019290611f95908490612d0c565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6000908152600260205260409020546001600160a01b0316151590565b600780546001600160a01b03838116610100818102610100600160a81b031985161790945560405193909204169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6000603f82105b1561207d575060015b919050565b6000600682101561207d57506001919050565b6000808211801561207457506040821161207d57506001919050565b816001600160a01b0316836001600160a01b031614156121135760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c65720000000000000060448201526064016108ba565b6001600160a01b03838116600081815260056020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b61218b848484611e4f565b612197848484846122ef565b6115ee5760405162461bcd60e51b81526004016108ba90612bac565b60606121be82611a14565b60006121d560408051602081019091526000815290565b905060008151116121f55760405180602001604052806000815250610c73565b806121ff846123fc565b604051602001612210929190612ad1565b6040516020818303038152906040529392505050565b60075460ff16610ee95760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b60448201526064016108ba565b6001600160a01b038316158061228c57506001600160a01b038216155b61095b5760405162461bcd60e51b815260206004820152602e60248201527f4e6f6e5472616e736665727261626c65455243373231546f6b656e3a206e6f6e60448201526d207472616e736665727261626c6560901b60648201526084016108ba565b60006001600160a01b0384163b156123f157604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612333903390899088908890600401612b00565b602060405180830381600087803b15801561234d57600080fd5b505af192505050801561237d575060408051601f3d908101601f1916820190925261237a918101906128ed565b60015b6123d7573d8080156123ab576040519150601f19603f3d011682016040523d82523d6000602084013e6123b0565b606091505b5080516123cf5760405162461bcd60e51b81526004016108ba90612bac565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611744565b506001949350505050565b6060816124205750506040805180820190915260018152600360fc1b602082015290565b8160005b811561244a578061243481612dcf565b91506124439050600a83612d24565b9150612424565b60008167ffffffffffffffff81111561247357634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f19166020018201604052801561249d576020820181803683370190505b5090505b8415611744576124b2600183612d57565b91506124bf600a86612dea565b6124ca906030612d0c565b60f81b8183815181106124ed57634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a90535061250f600a86612d24565b94506124a1565b82603f8101928215612544579160200282015b82811115612544578251825591602001919060010190612529565b5061255092915061263e565b5090565b604051806107e00160405280603f906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b82805461259d90612d9a565b90600052602060002090601f0160209004810192826125bf5760008555612544565b82601f106125d857805160ff1916838001178555612544565b828001600101855582156125445791820182811115612544578251825591602001919060010190612529565b8280548282559060005260206000209081019282156125445791602002820182811115612544578251825591602001919060010190612529565b5b80821115612550576000815560010161263f565b600067ffffffffffffffff83111561266d5761266d612e2a565b612680601f8401601f1916602001612cdb565b905082815283838301111561269457600080fd5b828260208301376000602084830101529392505050565b80356001600160a01b038116811461207d57600080fd5b600082601f8301126126d2578081fd5b6040516107e080820182811067ffffffffffffffff821117156126f7576126f7612e2a565b604052818482810187101561270a578485fd5b8492505b603f83101561272e5780358252600192909201916020918201910161270e565b509195945050505050565b8035801515811461207d57600080fd5b60006020828403121561275a578081fd5b610c73826126ab565b60008060408385031215612775578081fd5b61277e836126ab565b915061278c602084016126ab565b90509250929050565b6000806000606084860312156127a9578081fd5b6127b2846126ab565b92506127c0602085016126ab565b9150604084013590509250925092565b600080600080608085870312156127e5578081fd5b6127ee856126ab565b93506127fc602086016126ab565b925060408501359150606085013567ffffffffffffffff81111561281e578182fd5b8501601f8101871361282e578182fd5b61283d87823560208401612653565b91505092959194509250565b6000806040838503121561285b578182fd5b612864836126ab565b915061278c60208401612739565b60008060408385031215612884578182fd5b61288d836126ab565b946020939093013593505050565b60006107e082840312156128ad578081fd5b610c7383836126c2565b6000602082840312156128c8578081fd5b610c7382612739565b6000602082840312156128e2578081fd5b8135610c7381612e40565b6000602082840312156128fe578081fd5b8151610c7381612e40565b60006020828403121561291a578081fd5b813567ffffffffffffffff811115612930578182fd5b8201601f81018413612940578182fd5b61174484823560208401612653565b600060208284031215612960578081fd5b5035919050565b60008060408385031215612979578182fd5b8235915061278c602084016126ab565b600080610800838503121561299c578182fd5b8235915061278c84602085016126c2565b600080604083850312156129bf578182fd5b8235915060208084013567ffffffffffffffff808211156129de578384fd5b818601915086601f8301126129f1578384fd5b813581811115612a0357612a03612e2a565b8060051b9150612a14848301612cdb565b8181528481019084860184860187018b1015612a2e578788fd5b8795505b83861015612a50578035835260019590950194918601918601612a32565b508096505050505050509250929050565b60008060408385031215612a73578182fd5b50508035926020909101359150565b8060005b603f8110156115ee578151845260209384019390910190600101612a86565b60008151808452612abd816020860160208601612d6e565b601f01601f19169290920160200192915050565b60008351612ae3818460208801612d6e565b835190830190612af7818360208801612d6e565b01949350505050565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090612b3390830184612aa5565b9695505050505050565b6001600160a01b03841681526020810183905261082081016117446040830184612a82565b6107e081016106938284612a82565b60c08101818360005b60068110156115b3578151835260209283019290910190600101612b7a565b602081526000610c736020830184612aa5565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526022908201527f63616e4e6f744d696e744f725570646174654166746572206973206e6f742073604082015261195d60f21b606082015260800190565b6020808252602e908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526d1c881b9bdc88185c1c1c9bdd995960921b606082015260800190565b60006040820184835260206040818501528185518084526060860191508287019350845b81811015612cce57845183529383019391830191600101612cb2565b5090979650505050505050565b604051601f8201601f1916810167ffffffffffffffff81118282101715612d0457612d04612e2a565b604052919050565b60008219821115612d1f57612d1f612dfe565b500190565b600082612d3357612d33612e14565b500490565b6000816000190483118215151615612d5257612d52612dfe565b500290565b600082821015612d6957612d69612dfe565b500390565b60005b83811015612d89578181015183820152602001612d71565b838111156115ee5750506000910152565b600181811c90821680612dae57607f821691505b60208210811415610d1957634e487b7160e01b600052602260045260246000fd5b6000600019821415612de357612de3612dfe565b5060010190565b600082612df957612df9612e14565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160e01b03198116811461097557600080fdfea2646970667358221220cadb5fd7646f673713b47a905c93228096f1dbd89f7928f253fbbcc26057b22a64736f6c63430008040033
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 34 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
Loading...
Loading
Loading...
Loading
Loading...
Loading
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.