contract YeaHammer is ERC721Pausable, Ownable {

    uint256 private _maxTotalSupply;

    mapping(address => bool) public _minters;

    constructor() public ERC721("yea.hammer", "yeah") {
        _maxTotalSupply = 66600;
        setBaseURI("https://www.douyea.com/hammer-resources/hammer/");
        addMinter(_msgSender());
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyMinter() {
        require(_minters[msg.sender], "Minter: caller is not the owner");
        _;
    }

    function mint(address player, uint256 id) public onlyMinter returns (uint256) {

        require(id <= _maxTotalSupply && id > 0, "Minter: mine pool is empty");

        _mint(player, id);
        _setTokenURI(id, Strings.toString(id));

        return id;
    }


    function setBaseURI(string memory baseURI) public onlyOwner virtual {
        _setBaseURI(baseURI);
    }

    /**
     * @dev Triggers stopped state.
     *
     * Requirements:
     *
     * - The contract must not be paused.
     */
    function pause() public virtual onlyOwner whenNotPaused {
        _pause();
    }

    /**
     * @dev Returns to normal state.
     *
     * Requirements:
     *
     * - The contract must be paused.
     */
    function unpause() public virtual onlyOwner whenPaused {
        _unpause();
    }

    function addMinter(address minter) public onlyOwner {
        _minters[minter] = true;
    }

    function removeMinter(address minter) public onlyOwner {
        _minters[minter] = false;
    }

    function burn(uint256 tokenId) public onlyOwner {
        _burn(tokenId);
    }

}
function unpause() public virtual onlyOwner whenPaused {
    _unpause();
}

/**
 * @dev Returns to normal state.
 *
 * Requirements:
 *
 * - The contract must be paused.
 */