|
|
@ -89,7 +89,7 @@ contract Main is Owned {
|
|
|
|
/// @param from Sender of the bombs
|
|
|
|
/// @param from Sender of the bombs
|
|
|
|
/// @param tokenId Unaboomer token which was targeted
|
|
|
|
/// @param tokenId Unaboomer token which was targeted
|
|
|
|
/// @param hit Whether or not the bomb killed the token or not (was a dud / already killed)
|
|
|
|
/// @param hit Whether or not the bomb killed the token or not (was a dud / already killed)
|
|
|
|
/// @param owned Whether or not the sender was the owner of the BOOMR token
|
|
|
|
/// @param owned Whether or not the sender was the owner of the BOOMER token
|
|
|
|
event SentBomb(address indexed from, uint256 indexed tokenId, bool hit, bool owned);
|
|
|
|
event SentBomb(address indexed from, uint256 indexed tokenId, bool hit, bool owned);
|
|
|
|
|
|
|
|
|
|
|
|
constructor() Owned(msg.sender) {}
|
|
|
|
constructor() Owned(msg.sender) {}
|
|
|
@ -105,8 +105,8 @@ contract Main is Owned {
|
|
|
|
require(success, "failed to withdraw");
|
|
|
|
require(success, "failed to withdraw");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// Set price per BOOMR
|
|
|
|
/// Set price per BOOMER
|
|
|
|
/// @param _price Price in wei to mint BOOMR token
|
|
|
|
/// @param _price Price in wei to mint BOOMER token
|
|
|
|
function setBoomerPrice(uint256 _price) external onlyOwner {
|
|
|
|
function setBoomerPrice(uint256 _price) external onlyOwner {
|
|
|
|
unaboomerPrice = _price;
|
|
|
|
unaboomerPrice = _price;
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -118,7 +118,7 @@ contract Main is Owned {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// Set contract address for Unaboomer tokens
|
|
|
|
/// Set contract address for Unaboomer tokens
|
|
|
|
/// @param _address Address of the Unaboomer / BOOMR contract
|
|
|
|
/// @param _address Address of the Unaboomer / BOOMER contract
|
|
|
|
function setUnaboomerContract(address _address) external onlyOwner {
|
|
|
|
function setUnaboomerContract(address _address) external onlyOwner {
|
|
|
|
unaboomer = Unaboomer(_address);
|
|
|
|
unaboomer = Unaboomer(_address);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -152,46 +152,46 @@ contract Main is Owned {
|
|
|
|
// Getters
|
|
|
|
// Getters
|
|
|
|
// =========================================================================
|
|
|
|
// =========================================================================
|
|
|
|
|
|
|
|
|
|
|
|
/// Get BOOMR token balance of wallet
|
|
|
|
/// Get BOOMER token balance of wallet
|
|
|
|
/// @param _address Wallet address to query balance of BOOMR token
|
|
|
|
/// @param _address Wallet address to query balance of BOOMER token
|
|
|
|
/// @return balance Amount of BOOMR tokens owned by _address
|
|
|
|
/// @return balance Amount of BOOMER tokens owned by _address
|
|
|
|
function unaboomerBalance(address _address) public view returns (uint256) {
|
|
|
|
function unaboomerBalance(address _address) public view returns (uint256) {
|
|
|
|
return unaboomer.balanceOf(_address);
|
|
|
|
return unaboomer.balanceOf(_address);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// Get BOOMR amount minted (including ones that have been burned/killed)
|
|
|
|
/// Get BOOMER amount minted (including ones that have been burned/killed)
|
|
|
|
/// @param _address Wallet address to query the amount of BOOMR token minted
|
|
|
|
/// @param _address Wallet address to query the amount of BOOMER token minted
|
|
|
|
/// @return balance Amount of BOOMR tokens that have been minted by _address
|
|
|
|
/// @return balance Amount of BOOMER tokens that have been minted by _address
|
|
|
|
function unaboomersMinted(address _address) public view returns (uint256) {
|
|
|
|
function unaboomersMinted(address _address) public view returns (uint256) {
|
|
|
|
return unaboomer.tokensMintedByWallet(_address);
|
|
|
|
return unaboomer.tokensMintedByWallet(_address);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// Get BOOMR token total supply
|
|
|
|
/// Get BOOMER token total supply
|
|
|
|
/// @return supply Amount of BOOMR tokens minted in total
|
|
|
|
/// @return supply Amount of BOOMER tokens minted in total
|
|
|
|
function unaboomersRadicalized() public view returns (uint256) {
|
|
|
|
function unaboomersRadicalized() public view returns (uint256) {
|
|
|
|
return unaboomer.minted();
|
|
|
|
return unaboomer.minted();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// Get BOOMR kill count (unaboomers killed)
|
|
|
|
/// Get BOOMER kill count (unaboomers killed)
|
|
|
|
/// @return killCount Amount of BOOMR tokens "killed" (dead pfp)
|
|
|
|
/// @return killCount Amount of BOOMER tokens "killed" (dead pfp)
|
|
|
|
function unaboomersKilled() public view returns (uint256) {
|
|
|
|
function unaboomersKilled() public view returns (uint256) {
|
|
|
|
return unaboomer.burned();
|
|
|
|
return unaboomer.burned();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// Get BOOMR token max supply
|
|
|
|
/// Get BOOMER token max supply
|
|
|
|
/// @return maxSupply Maximum amount of BOOMR tokens that can ever exist
|
|
|
|
/// @return maxSupply Maximum amount of BOOMER tokens that can ever exist
|
|
|
|
function unaboomerMaxSupply() public view returns (uint256) {
|
|
|
|
function unaboomerMaxSupply() public view returns (uint256) {
|
|
|
|
return unaboomer.MAX_SUPPLY();
|
|
|
|
return unaboomer.MAX_SUPPLY();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// Get BOOMR token survivor count
|
|
|
|
/// Get BOOMER token survivor count
|
|
|
|
/// @return survivorCount Maximum amount of BOOMR survivor tokens that can ever exist
|
|
|
|
/// @return survivorCount Maximum amount of BOOMER survivor tokens that can ever exist
|
|
|
|
function unaboomerMaxSurvivorCount() public view returns (uint256) {
|
|
|
|
function unaboomerMaxSurvivorCount() public view returns (uint256) {
|
|
|
|
return unaboomer.MAX_SURVIVOR_COUNT();
|
|
|
|
return unaboomer.MAX_SURVIVOR_COUNT();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// Get BOOMR token max mint amount per wallet
|
|
|
|
/// Get BOOMER token max mint amount per wallet
|
|
|
|
/// @return mintAmount Maximum amount of BOOMR tokens that can be minted per wallet
|
|
|
|
/// @return mintAmount Maximum amount of BOOMER tokens that can be minted per wallet
|
|
|
|
function unaboomerMaxMintPerWallet() public view returns (uint256) {
|
|
|
|
function unaboomerMaxMintPerWallet() public view returns (uint256) {
|
|
|
|
return unaboomer.MAX_MINT_AMOUNT();
|
|
|
|
return unaboomer.MAX_MINT_AMOUNT();
|
|
|
|
}
|
|
|
|
}
|
|
|
|