Contract 0xa76f8a11765e017c22ce61F45e72258Eb626eCd8

 

Contract Overview

Balance:
0 BNB

BNB Value:
$0.00

Token:
Txn Hash
Block
From
To
Value [Txn Fee]
0x59fb3d28ce8fa5f320e5658e8de6644b5aa938f1505be930a29d7423fc88b42065040522021-04-12 15:10:0464 days 18 hrs ago0x9ca2d9e94b4971f6010481baf87fcddef8e779f8 IN  0xa76f8a11765e017c22ce61f45e72258eb626ecd80 BNB0.000390401
0x8db2407de77b55313d9c54488938877fc89d5e7d1ceb66d5cda841dec760de0965040522021-04-12 15:10:0464 days 18 hrs ago0x9ca2d9e94b4971f6010481baf87fcddef8e779f8 IN  0xa76f8a11765e017c22ce61f45e72258eb626ecd80 BNB0.000390269
0xa477e84235876399c87b73cb45f80360bd57d8d484adabd30694bc486bbd6e0765039182021-04-12 15:03:2264 days 18 hrs ago0x9ca2d9e94b4971f6010481baf87fcddef8e779f8 IN  0xa76f8a11765e017c22ce61f45e72258eb626ecd80 BNB0.001660659
0xb3d536495cdad51810f51b8766c876984be4966fca3ff00758c6a32f11a8267565039142021-04-12 15:03:1064 days 18 hrs ago0x9ca2d9e94b4971f6010481baf87fcddef8e779f8 IN  0xa76f8a11765e017c22ce61f45e72258eb626ecd80 BNB0.00173756
0x7f0b5db4c030ef9764af62b877b81dbeb4bcc367e449c27fd1f2361775b1cf8a64249962021-04-09 21:10:3067 days 12 hrs ago0x6b54fbcafa1e4824a6ba004208ffe5fb8acccfe8 IN  0xa76f8a11765e017c22ce61f45e72258eb626ecd80 BNB0.000761255
0x496c965fd08ed542996a9dc9f99a6102cf9953adf1116e8e25e3c7cfee606b1864249712021-04-09 21:09:1567 days 12 hrs ago0x6b54fbcafa1e4824a6ba004208ffe5fb8acccfe8 IN  0xa76f8a11765e017c22ce61f45e72258eb626ecd80 BNB0.000326385
0x58e47c7099dd9d97863c1c9eb7213df34178d845e68744b68751a76b111813c964247282021-04-09 20:57:0667 days 12 hrs ago0x40e0dcd7024030c7b5e1d474fe95aaf7bb880ad0 IN  0xa76f8a11765e017c22ce61f45e72258eb626ecd80 BNB0.000326385
0x5f8900510f0a35917d4ecdb04f70317fd5309a40b34df4da252bc134af86bd9564246272021-04-09 20:52:0367 days 13 hrs ago0x6b54fbcafa1e4824a6ba004208ffe5fb8acccfe8 IN  0xa76f8a11765e017c22ce61f45e72258eb626ecd80 BNB0.000529025
0xb14af8cb8d70e64d91de0be0cbe0404b0b83825f4e2e97bb2811a276fa8c655064245962021-04-09 20:50:3067 days 13 hrs ago0x6b54fbcafa1e4824a6ba004208ffe5fb8acccfe8 IN  0xa76f8a11765e017c22ce61f45e72258eb626ecd80 BNB0.000519605
0x908a831fa51c22f23c04056dcc8878a91a3c51e42727a08d8bb755286168ce5c64245712021-04-09 20:49:1567 days 13 hrs ago0x6b54fbcafa1e4824a6ba004208ffe5fb8acccfe8 IN  0xa76f8a11765e017c22ce61f45e72258eb626ecd80 BNB0.000660185
0x761ffd1d350e1e3d66c551596ceb2ab0c86ea5ec136a5e20be3203d2fe4c997264245022021-04-09 20:45:4867 days 13 hrs ago0x6b54fbcafa1e4824a6ba004208ffe5fb8acccfe8 IN  0xa76f8a11765e017c22ce61f45e72258eb626ecd80 BNB0.000285065
0x2d9e551dba8b0a136146f610fdb49ef882183bd36491e991206d29e06b8e0c2264243822021-04-09 20:39:4867 days 13 hrs agoEVOdefi: Deployer IN  0xa76f8a11765e017c22ce61f45e72258eb626ecd80 BNB0.00031036
0x1f279458092a61def822a15c050b6abff74f2da9014ee506ea5777eef148f07564243412021-04-09 20:37:4567 days 13 hrs agoEVOdefi: Deployer IN  Contract Creation0 BNB0.02534082
[ Download CSV Export 
Parent Txn Hash Block From To Value
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
MasterChef

Compiler Version
v0.8.0+commit.c7dfd78e

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity Standard Json-Input format)

File 1 of 15 : GenToken.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.6.12;
pragma experimental ABIEncoderV2;

import "./OwnableToken.sol";


contract GenToken is OwnableToken {
  constructor() OwnableToken("Gen Token", "GEN") {}
}

File 2 of 15 : MasterChef.sol
// SPDX-License-Identifier: MIT

pragma solidity 0.8.0;

import "../oz/utils/structs/EnumerableSet.sol";
import "../oz/access/Ownable.sol";
import "../oz/token/ERC20/ERC20.sol";
import "../oz/token/ERC20/IERC20.sol";
import "../oz/token/ERC20/utils/SafeERC20.sol";
import "../oz/token/ERC721/utils/ERC721Holder.sol";
import '../oz/token/ERC721/IERC721.sol';
import "../oz/utils/math/SafeMath.sol";
import "./GenToken.sol";


interface IProxy {
    function bonus(address user) external view returns (uint);
    function getNFTPowerBonusBlocks(uint nftId) external view returns (uint);
    function getNFTPowerBonus() external view returns (uint);
    function downgradeMyNFT(uint nftId) external;
}

interface IGenNFT is IERC721 {
    function changeType(uint tokenId, uint toTypeId) external;
}

contract MasterChef is Ownable, ERC721Holder {
    using SafeERC20 for IERC20;
    using SafeMath for uint;
    
    // Info of each user.
    struct UserInfo {
        uint256 amount;         // How many LP tokens the user has provided.
        uint256 rewardDebt;     // Reward debt. See explanation below.
        uint256 power;          // User power
        uint lastPoweredBlock;  // last powered Block
        uint lastClaimedBlock;  // last powered Block
    }
    
    IProxy proxy;

    // Info of each pool.
    struct PoolInfo {
        uint256 totalPower;
        IERC20 lpToken;           // Address of LP token contract.
        uint256 allocPoint;       // How many allocation points assigned to this pool. Gens to distribute per block.
        uint256 lastRewardBlock;  // Last block number that Gens distribution occurs.
        uint256 accGenPerPower;   // Accumulated Gens per share, times 1e12. See below.
        uint16 depositFeeBP;      // Deposit fee in basis points
    }

    GenToken public gen;
    IERC20 public busd;
    address public busdGenLP;
    IGenNFT public nft;
    // Dev address.
    address public devaddr;
    // GEN tokens created per block.
    uint256 public genPerBlock;
    // Deposit Fee address
    address public feeAddress;

    // Info of each pool.
    PoolInfo[] public poolInfo;
    
    // Info of each user that stakes LP tokens.
    mapping (uint256 => mapping (address => UserInfo)) public userInfo;
    
    // Total allocation points. Must be the sum of all allocation points in all pools.
    uint256 public totalAllocPoint = 0;
    // The block number when Gen mining starts.
    uint256 public startBlock;
    
    uint public topPrice = 100; // 10$
    uint public bottomPrice = 10; //100$
    uint public lastBlockUpdate = 0;
    uint public emissionUpdateInterval = 3600; // 3 hours

    event Deposit(address indexed user, uint256 indexed pid, uint256 amount);
    event Withdraw(address indexed user, uint256 indexed pid, uint256 amount);
    event EmergencyWithdraw(address indexed user, uint256 indexed pid, uint256 amount);

    constructor(
        GenToken _gen,
        IERC20 _busd,
        IGenNFT _nft,
        address _busdGenLP,
        IProxy _proxy,
        address _devaddr,
        address _feeAddress,
        uint256 _genPerBlock,
        uint256 _startBlock
    ) public {
        require(_devaddr != address(0), "address can't be 0");
        require(_feeAddress != address(0), "address can't be 0");
        
        gen = _gen;
        busd = _busd;
        nft = _nft;
        busdGenLP = _busdGenLP;
        devaddr = _devaddr;
        proxy = _proxy;
        feeAddress = _feeAddress;
        genPerBlock = _genPerBlock;
        startBlock = _startBlock;
    }

    function poolLength() external view returns (uint256) {
        return poolInfo.length;
    }

    // Add a new lp to the pool. Can only be called by the owner.
    // XXX DO NOT add the same LP token more than once. Rewards will be messed up if you do.
    function add(uint256 _allocPoint, IERC20 _lpToken, uint16 _depositFeeBP, bool _withUpdate) public onlyOwner {
        require(_depositFeeBP <= 10000, "add: invalid deposit fee basis points");
        if (_withUpdate) {
            massUpdatePools();
        }
        
        uint256 lastRewardBlock = block.number > startBlock ? block.number : startBlock;
        totalAllocPoint = totalAllocPoint.add(_allocPoint);
        poolInfo.push(PoolInfo({
            totalPower:0,
            lpToken: _lpToken,
            allocPoint: _allocPoint,
            lastRewardBlock: lastRewardBlock,
            accGenPerPower: 0,
            depositFeeBP: _depositFeeBP
        }));
    }

    // Update the given pool's GEN allocation point and deposit fee. Can only be called by the owner.
    function set(uint256 _pid, uint256 _allocPoint, uint16 _depositFeeBP, bool _withUpdate) public onlyOwner {
        require(_depositFeeBP <= 10000, "set: invalid deposit fee basis points");
        if (_withUpdate) {
            massUpdatePools();
        }
        totalAllocPoint = totalAllocPoint.sub(poolInfo[_pid].allocPoint).add(_allocPoint);
        poolInfo[_pid].allocPoint = _allocPoint;
        poolInfo[_pid].depositFeeBP = _depositFeeBP;
    }

    // View function to see pending GENs on frontend.
    function pendingGen(uint256 _pid, address _user) external view returns (uint256) {
        return _pendingGen(_pid, _user);
    }

    // Update reward variables for all pools. Be careful of gas spending!
    function massUpdatePools() public {
        uint256 length = poolInfo.length;
        for (uint256 pid = 0; pid < length; ++pid) {
            updatePool(pid);
        }
    }

    // Update reward variables of the given pool to be up-to-date.
    function updatePool(uint256 _pid) public {
        PoolInfo storage pool = poolInfo[_pid];
        if (block.number <= pool.lastRewardBlock) {
            return;
        }
        if (pool.totalPower == 0 || pool.allocPoint == 0) {
            pool.lastRewardBlock = block.number;
            return;
        }
        uint256 blockAmount = block.number.sub(pool.lastRewardBlock);
        uint256 genReward = blockAmount.mul(genPerBlock).mul(pool.allocPoint).div(totalAllocPoint);
        gen.mint(devaddr, genReward.div(10));
        gen.mint(address(this), genReward);
        pool.accGenPerPower = pool.accGenPerPower.add(genReward.mul(1e12).div(pool.totalPower));
        pool.lastRewardBlock = block.number;
    }

    // Deposit LP tokens to MasterChef for GEN allocation.
    function deposit(uint256 _pid, uint256 _amount) public {
        PoolInfo storage pool = poolInfo[_pid];
        UserInfo storage user = userInfo[_pid][msg.sender];
        updatePool(_pid);
        claim(_pid);
        
        if(_amount > 0) {
            pool.lpToken.safeTransferFrom(address(msg.sender), address(this), _amount);
            if(pool.depositFeeBP > 0){
                uint256 depositFee = _amount.mul(pool.depositFeeBP).div(10000);
                pool.lpToken.safeTransfer(feeAddress, depositFee);
                user.amount = user.amount.add(_amount).sub(depositFee);
            }else{
                user.amount = user.amount.add(_amount);
            }
        }
        
        updatePower(_pid);
        
        user.rewardDebt = user.power.mul(pool.accGenPerPower).div(1e12);
        emit Deposit(msg.sender, _pid, _amount);
    }

    // Withdraw LP tokens from MasterChef.
    function withdraw(uint256 _pid, uint256 _amount) public {
        PoolInfo storage pool = poolInfo[_pid];
        UserInfo storage user = userInfo[_pid][msg.sender];
        require(user.amount >= _amount, "withdraw: not good");
        
        updatePool(_pid);
        claim(_pid);
        
        if (_amount > 0) {
            user.amount = user.amount.sub(_amount);
            pool.lpToken.safeTransfer(address(msg.sender), _amount);
        }
        
        updatePower(_pid);
        
        user.rewardDebt = user.power.mul(pool.accGenPerPower).div(1e12);
        emit Withdraw(msg.sender, _pid, _amount);
    }
    
    function powerUpWithNFTs(uint256 _pid, uint[] memory _nftIds) public {
        PoolInfo storage pool = poolInfo[_pid];
        UserInfo storage user = userInfo[_pid][msg.sender];
        
        updatePool(_pid);
        claim(_pid);
        
        for (uint i =0; i < _nftIds.length; i++) {
            uint nftId = _nftIds[i];
            if (nft.ownerOf(nftId) == msg.sender) {
                if (user.lastPoweredBlock >= block.number) {
                    user.lastPoweredBlock += proxy.getNFTPowerBonusBlocks(nftId);
                } else {
                    user.lastPoweredBlock = block.number + proxy.getNFTPowerBonusBlocks(nftId); 
                }
                
                nft.changeType(nftId,0);
            }
        }
        
            
        updatePower(_pid);
    
        user.rewardDebt = user.power.mul(pool.accGenPerPower).div(1e12);
        emit Deposit(msg.sender, _pid, 1);
    }
    
    function updatePower(uint256 _pid) public {
        PoolInfo storage pool = poolInfo[_pid];
        UserInfo storage user = userInfo[_pid][msg.sender];
        
        uint256 currentPower = user.power;
        uint powerBonus = 100;
        
        if (user.lastPoweredBlock >= block.number) {
            powerBonus += proxy.getNFTPowerBonus();
        }
        powerBonus += proxy.bonus(msg.sender);
        
        user.power = user.amount.mul(powerBonus).div(100);
        
        pool.totalPower = pool.totalPower.add(user.power).sub(currentPower);
    }
    
    // Withdraw without caring about rewards. EMERGENCY ONLY.
    function emergencyWithdraw(uint256 _pid) public {
        PoolInfo storage pool = poolInfo[_pid];
        UserInfo storage user = userInfo[_pid][msg.sender];
        
        pool.totalPower = pool.totalPower.sub(user.power);
        uint256 amount = user.amount;
        user.power = 0;
        user.amount = 0;
        user.rewardDebt = 0;

        pool.lpToken.safeTransfer(address(msg.sender), amount);
        emit EmergencyWithdraw(msg.sender, _pid, amount);
    }
    
     function claim(uint256 _pid) internal {
        UserInfo storage user = userInfo[_pid][msg.sender];
        
        user.lastClaimedBlock = block.number;
        
        if (user.amount > 0) {
            uint256 pending = _pendingGen(_pid, msg.sender);
            
            if (pending > 0) {
                safeGenTransfer(msg.sender, pending);
            }
        }
        updateEmissionIfNeeded();
    }
    
     function _pendingGen(uint256 _pid, address _user) internal view returns (uint256) {
        PoolInfo storage pool = poolInfo[_pid];
        UserInfo storage user = userInfo[_pid][_user];
        uint256 accGenPerPower = pool.accGenPerPower;
        uint256 blockAmount = block.number.sub(pool.lastRewardBlock);
        
        uint256 lpSupply = pool.lpToken.balanceOf(address(this));
        if (block.number > pool.lastRewardBlock && lpSupply != 0 && pool.totalPower != 0) {
            uint256 genReward = blockAmount.mul(genPerBlock).mul(pool.allocPoint).div(totalAllocPoint);
            accGenPerPower = accGenPerPower.add(genReward.mul(1e12).div(pool.totalPower));
        }
        
        if ((user.lastClaimedBlock < user.lastPoweredBlock) && (block.number > user.lastPoweredBlock) && (user.power > 0)) {
            uint powerBonus = 100;
            
            powerBonus += proxy.getNFTPowerBonus() * (user.lastPoweredBlock - user.lastClaimedBlock) / (block.number - user.lastClaimedBlock);
            powerBonus += proxy.bonus(msg.sender);
        
            uint truePower = user.amount.mul(powerBonus).div(100);
            return user.power.mul(accGenPerPower).div(1e12).sub(user.rewardDebt) * truePower / user.power;
        }
        
        return user.power.mul(accGenPerPower).div(1e12).sub(user.rewardDebt);
    }

    // Safe gen transfer function, just in case if rounding error causes pool to not have enough GENs.
    function safeGenTransfer(address _to, uint256 _amount) internal {
        uint256 genBal = gen.balanceOf(address(this));
        if (_amount > genBal) {
            gen.transfer(_to, genBal);
        } else {
            gen.transfer(_to, _amount);
        }
    }
    
    // Update dev address by the previous dev.
    function dev(address _devaddr) public {
        require(msg.sender == devaddr, "dev: wut?");
        devaddr = _devaddr;
    }

    function setFeeAddress(address _feeAddress) public{
        require(msg.sender == feeAddress, "setFeeAddress: FORBIDDEN");
        feeAddress = _feeAddress;
    }

    //Pancake has to add hidden dummy pools inorder to alter the emission, here we make it simple and transparent to all.
    function updateEmissionRate(uint256 _genPerBlock) public onlyOwner {
        massUpdatePools();
        genPerBlock = _genPerBlock;
    }

    function updateEmissionIfNeeded() public {
        if (block.number - lastBlockUpdate > emissionUpdateInterval) { //every 3 hours
             lastBlockUpdate = block.number;
             
             uint genBalance = gen.balanceOf(busdGenLP);
             uint priceCents = bottomPrice * 100;
             if (genBalance > 0) {
                massUpdatePools();
                priceCents = busd.balanceOf(busdGenLP).mul(100).div(genBalance);    
             }

             if (priceCents < bottomPrice * 100) {
                massUpdatePools();
                genPerBlock = priceCents.mul(1e18).div(bottomPrice).div(100);
             } else
             if (priceCents > topPrice * 100) {
                 massUpdatePools();
                genPerBlock = priceCents.mul(1e18).div(topPrice).div(100);
             } else if (genPerBlock != 1e18) {
                 massUpdatePools();
                 genPerBlock = 1e18;
             }
        }
    }
    
    function updateEmissionParameters(uint _topPrice, uint _bottomPrice, uint _emissionUpdateInterval) public onlyOwner {
        topPrice = _topPrice;
        bottomPrice = _bottomPrice;
        emissionUpdateInterval = _emissionUpdateInterval;
    }
    
    function setProxy(IProxy _proxy) public onlyOwner {
        proxy = _proxy;
    }
}

File 3 of 15 : OwnableToken.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.6.12;
pragma experimental ABIEncoderV2;

import "../oz/access/Ownable.sol";
import "../oz/token/ERC20/ERC20.sol";

contract OwnableToken is ERC20, Ownable  {

  constructor(string memory name, string memory symbol) ERC20(name, symbol) { }

  function mint(address account, uint amount) public onlyOwner {
    _mint(account, amount);
  }

  function burn(address account, uint amount) public onlyOwner {
    _burn(account, amount);
  }

}

File 4 of 15 : Ownable.sol
// SPDX-License-Identifier: MIT

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 () {
        address msgSender = _msgSender();
        _owner = msgSender;
        emit OwnershipTransferred(address(0), msgSender);
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
        _;
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        emit OwnershipTransferred(_owner, address(0));
        _owner = 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");
        emit OwnershipTransferred(_owner, newOwner);
        _owner = newOwner;
    }
}

File 5 of 15 : ERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IERC20.sol";
import "../../utils/Context.sol";

/**
 * @dev Implementation of the {IERC20} interface.
 *
 * This implementation is agnostic to the way tokens are created. This means
 * that a supply mechanism has to be added in a derived contract using {_mint}.
 * For a generic mechanism see {ERC20PresetMinterPauser}.
 *
 * TIP: For a detailed writeup see our guide
 * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How
 * to implement supply mechanisms].
 *
 * We have followed general OpenZeppelin guidelines: functions revert instead
 * of returning `false` on failure. This behavior is nonetheless conventional
 * and does not conflict with the expectations of ERC20 applications.
 *
 * Additionally, an {Approval} event is emitted on calls to {transferFrom}.
 * This allows applications to reconstruct the allowance for all accounts just
 * by listening to said events. Other implementations of the EIP may not emit
 * these events, as it isn't required by the specification.
 *
 * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}
 * functions have been added to mitigate the well-known issues around setting
 * allowances. See {IERC20-approve}.
 */
contract ERC20 is Context, IERC20 {
    mapping (address => uint256) private _balances;

    mapping (address => mapping (address => uint256)) private _allowances;

    uint256 private _totalSupply;

    string private _name;
    string private _symbol;

    /**
     * @dev Sets the values for {name} and {symbol}.
     *
     * The defaut value of {decimals} is 18. To select a different value for
     * {decimals} you should overload it.
     *
     * All three of these values are immutable: they can only be set once during
     * construction.
     */
    constructor (string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @dev Returns the name of the token.
     */
    function name() public view virtual returns (string memory) {
        return _name;
    }

    /**
     * @dev Returns the symbol of the token, usually a shorter version of the
     * name.
     */
    function symbol() public view virtual returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns the number of decimals used to get its user representation.
     * For example, if `decimals` equals `2`, a balance of `505` tokens should
     * be displayed to a user as `5,05` (`505 / 10 ** 2`).
     *
     * Tokens usually opt for a value of 18, imitating the relationship between
     * Ether and Wei. This is the value {ERC20} uses, unless this function is
     * overloaded;
     *
     * NOTE: This information is only used for _display_ purposes: it in
     * no way affects any of the arithmetic of the contract, including
     * {IERC20-balanceOf} and {IERC20-transfer}.
     */
    function decimals() public view virtual returns (uint8) {
        return 18;
    }

    /**
     * @dev See {IERC20-totalSupply}.
     */
    function totalSupply() public view virtual override returns (uint256) {
        return _totalSupply;
    }

    /**
     * @dev See {IERC20-balanceOf}.
     */
    function balanceOf(address account) public view virtual override returns (uint256) {
        return _balances[account];
    }

    /**
     * @dev See {IERC20-transfer}.
     *
     * Requirements:
     *
     * - `recipient` cannot be the zero address.
     * - the caller must have a balance of at least `amount`.
     */
    function transfer(address recipient, uint256 amount) public virtual override returns (bool) {
        _transfer(_msgSender(), recipient, amount);
        return true;
    }

    /**
     * @dev See {IERC20-allowance}.
     */
    function allowance(address owner, address spender) public view virtual override returns (uint256) {
        return _allowances[owner][spender];
    }

    /**
     * @dev See {IERC20-approve}.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function approve(address spender, uint256 amount) public virtual override returns (bool) {
        _approve(_msgSender(), spender, amount);
        return true;
    }

    /**
     * @dev See {IERC20-transferFrom}.
     *
     * Emits an {Approval} event indicating the updated allowance. This is not
     * required by the EIP. See the note at the beginning of {ERC20}.
     *
     * Requirements:
     *
     * - `sender` and `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     * - the caller must have allowance for ``sender``'s tokens of at least
     * `amount`.
     */
    function transferFrom(address sender, address recipient, uint256 amount) public virtual override returns (bool) {
        _transfer(sender, recipient, amount);

        uint256 currentAllowance = _allowances[sender][_msgSender()];
        require(currentAllowance >= amount, "ERC20: transfer amount exceeds allowance");
        _approve(sender, _msgSender(), currentAllowance - amount);

        return true;
    }

    /**
     * @dev Atomically increases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender] + addedValue);
        return true;
    }

    /**
     * @dev Atomically decreases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     * - `spender` must have allowance for the caller of at least
     * `subtractedValue`.
     */
    function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {
        uint256 currentAllowance = _allowances[_msgSender()][spender];
        require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero");
        _approve(_msgSender(), spender, currentAllowance - subtractedValue);

        return true;
    }

    /**
     * @dev Moves tokens `amount` from `sender` to `recipient`.
     *
     * This is internal function is equivalent to {transfer}, and can be used to
     * e.g. implement automatic token fees, slashing mechanisms, etc.
     *
     * Emits a {Transfer} event.
     *
     * Requirements:
     *
     * - `sender` cannot be the zero address.
     * - `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     */
    function _transfer(address sender, address recipient, uint256 amount) internal virtual {
        require(sender != address(0), "ERC20: transfer from the zero address");
        require(recipient != address(0), "ERC20: transfer to the zero address");

        _beforeTokenTransfer(sender, recipient, amount);

        uint256 senderBalance = _balances[sender];
        require(senderBalance >= amount, "ERC20: transfer amount exceeds balance");
        _balances[sender] = senderBalance - amount;
        _balances[recipient] += amount;

        emit Transfer(sender, recipient, amount);
    }

    /** @dev Creates `amount` tokens and assigns them to `account`, increasing
     * the total supply.
     *
     * Emits a {Transfer} event with `from` set to the zero address.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     */
    function _mint(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: mint to the zero address");

        _beforeTokenTransfer(address(0), account, amount);

        _totalSupply += amount;
        _balances[account] += amount;
        emit Transfer(address(0), account, amount);
    }

    /**
     * @dev Destroys `amount` tokens from `account`, reducing the
     * total supply.
     *
     * Emits a {Transfer} event with `to` set to the zero address.
     *
     * Requirements:
     *
     * - `account` cannot be the zero address.
     * - `account` must have at least `amount` tokens.
     */
    function _burn(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: burn from the zero address");

        _beforeTokenTransfer(account, address(0), amount);

        uint256 accountBalance = _balances[account];
        require(accountBalance >= amount, "ERC20: burn amount exceeds balance");
        _balances[account] = accountBalance - amount;
        _totalSupply -= amount;

        emit Transfer(account, address(0), amount);
    }

    /**
     * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.
     *
     * This internal function is equivalent to `approve`, and can be used to
     * e.g. set automatic allowances for certain subsystems, etc.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `owner` cannot be the zero address.
     * - `spender` cannot be the zero address.
     */
    function _approve(address owner, address spender, uint256 amount) internal virtual {
        require(owner != address(0), "ERC20: approve from the zero address");
        require(spender != address(0), "ERC20: approve to the zero address");

        _allowances[owner][spender] = amount;
        emit Approval(owner, spender, amount);
    }

    /**
     * @dev Hook that is called before any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * will be to transferred to `to`.
     * - when `from` is zero, `amount` tokens will be minted for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens will be burned.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(address from, address to, uint256 amount) internal virtual { }
}

File 6 of 15 : IERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns the amount of tokens owned by `account`.
     */
    function balanceOf(address account) external view returns (uint256);

    /**
     * @dev Moves `amount` tokens from the caller's account to `recipient`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address recipient, uint256 amount) external returns (bool);

    /**
     * @dev Returns the remaining number of tokens that `spender` will be
     * allowed to spend on behalf of `owner` through {transferFrom}. This is
     * zero by default.
     *
     * This value changes when {approve} or {transferFrom} are called.
     */
    function allowance(address owner, address spender) external view returns (uint256);

    /**
     * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * IMPORTANT: Beware that changing an allowance with this method brings the risk
     * that someone may use both the old and the new allowance by unfortunate
     * transaction ordering. One possible solution to mitigate this race
     * condition is to first reduce the spender's allowance to 0 and set the
     * desired value afterwards:
     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
     *
     * Emits an {Approval} event.
     */
    function approve(address spender, uint256 amount) external returns (bool);

    /**
     * @dev Moves `amount` tokens from `sender` to `recipient` using the
     * allowance mechanism. `amount` is then deducted from the caller's
     * allowance.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);

    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

    /**
     * @dev Emitted when the allowance of a `spender` for an `owner` is set by
     * a call to {approve}. `value` is the new allowance.
     */
    event Approval(address indexed owner, address indexed spender, uint256 value);
}

File 7 of 15 : SafeERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../IERC20.sol";
import "../../../utils/Address.sol";

/**
 * @title SafeERC20
 * @dev Wrappers around ERC20 operations that throw on failure (when the token
 * contract returns false). Tokens that return no value (and instead revert or
 * throw on failure) are also supported, non-reverting calls are assumed to be
 * successful.
 * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract,
 * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
 */
library SafeERC20 {
    using Address for address;

    function safeTransfer(IERC20 token, address to, uint256 value) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));
    }

    function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));
    }

    /**
     * @dev Deprecated. This function has issues similar to the ones found in
     * {IERC20-approve}, and its usage is discouraged.
     *
     * Whenever possible, use {safeIncreaseAllowance} and
     * {safeDecreaseAllowance} instead.
     */
    function safeApprove(IERC20 token, address spender, uint256 value) internal {
        // safeApprove should only be called when setting an initial allowance,
        // or when resetting it to zero. To increase and decrease it, use
        // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
        // solhint-disable-next-line max-line-length
        require((value == 0) || (token.allowance(address(this), spender) == 0),
            "SafeERC20: approve from non-zero to non-zero allowance"
        );
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
    }

    function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal {
        uint256 newAllowance = token.allowance(address(this), spender) + value;
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(IERC20 token, address spender, uint256 value) internal {
        // unchecked {
            uint256 oldAllowance = token.allowance(address(this), spender);
            require(oldAllowance >= value, "SafeERC20: decreased allowance below zero");
            uint256 newAllowance = oldAllowance - value;
            _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
        // }
    }

    /**
     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
     * on the return value: the return value is optional (but if data is returned, it must not be false).
     * @param token The token targeted by the call.
     * @param data The call data (encoded using abi.encode or one of its variants).
     */
    function _callOptionalReturn(IERC20 token, bytes memory data) private {
        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
        // we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that
        // the target address contains contract code and also asserts for success in the low-level call.

        bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed");
        if (returndata.length > 0) { // Return data is optional
            // solhint-disable-next-line max-line-length
            require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
        }
    }
}

File 8 of 15 : IERC721.sol
// SPDX-License-Identifier: MIT

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`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(address from, address to, uint256 tokenId) external;

    /**
     * @dev Transfers `tokenId` token from `from` to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(address from, address to, uint256 tokenId) external;

    /**
     * @dev Gives permission to `to` to transfer `tokenId` token to another account.
     * The approval is cleared when the token is transferred.
     *
     * Only a single account can be approved at a time, so approving the zero address clears previous approvals.
     *
     * Requirements:
     *
     * - The caller must own the token or be an approved operator.
     * - `tokenId` must exist.
     *
     * Emits an {Approval} event.
     */
    function approve(address to, uint256 tokenId) external;

    /**
     * @dev Returns the account approved for `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function getApproved(uint256 tokenId) external view returns (address operator);

    /**
     * @dev Approve or remove `operator` as an operator for the caller.
     * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
     *
     * Requirements:
     *
     * - The `operator` cannot be the caller.
     *
     * Emits an {ApprovalForAll} event.
     */
    function setApprovalForAll(address operator, bool _approved) external;

    /**
     * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
     *
     * See {setApprovalForAll}
     */
    function isApprovedForAll(address owner, address operator) external view returns (bool);

    /**
      * @dev Safely transfers `tokenId` token from `from` to `to`.
      *
      * Requirements:
      *
      * - `from` cannot be the zero address.
      * - `to` cannot be the zero address.
      * - `tokenId` token must exist and be owned by `from`.
      * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
      * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
      *
      * Emits a {Transfer} event.
      */
    function safeTransferFrom(address from, address to, uint256 tokenId, bytes calldata data) external;
}

File 9 of 15 : IERC721Receiver.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @title ERC721 token receiver interface
 * @dev Interface for any contract that wants to support safeTransfers
 * from ERC721 asset contracts.
 */
interface IERC721Receiver {
    /**
     * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
     * by `operator` from `from`, this function is called.
     *
     * It must return its Solidity selector to confirm the token transfer.
     * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.
     *
     * The selector can be obtained in Solidity with `IERC721.onERC721Received.selector`.
     */
    function onERC721Received(address operator, address from, uint256 tokenId, bytes calldata data) external returns (bytes4);
}

File 10 of 15 : ERC721Holder.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../IERC721Receiver.sol";

  /**
   * @dev Implementation of the {IERC721Receiver} interface.
   *
   * Accepts all token transfers.
   * Make sure the contract is able to use its token with {IERC721-safeTransferFrom}, {IERC721-approve} or {IERC721-setApprovalForAll}.
   */
contract ERC721Holder is IERC721Receiver {

    /**
     * @dev See {IERC721Receiver-onERC721Received}.
     *
     * Always returns `IERC721Receiver.onERC721Received.selector`.
     */
    function onERC721Received(address, address, uint256, bytes memory) public virtual override returns (bytes4) {
        return this.onERC721Received.selector;
    }
}

File 11 of 15 : Address.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        // solhint-disable-next-line no-inline-assembly
        assembly { size := extcodesize(account) }
        return size > 0;
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        // solhint-disable-next-line avoid-low-level-calls, avoid-call-value
        (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");

        // solhint-disable-next-line avoid-low-level-calls
        (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");

        // solhint-disable-next-line avoid-low-level-calls
        (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");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.delegatecall(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private 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

                // solhint-disable-next-line no-inline-assembly
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

File 12 of 15 : Context.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/*
 * @dev Provides information about the current execution context, including the
 * sender of the transaction and its data. While these are generally available
 * via msg.sender and msg.data, they should not be accessed in such a direct
 * manner, since when dealing with meta-transactions the account sending and
 * paying for execution may not be the actual sender (as far as an application
 * is concerned).
 *
 * This contract is only required for intermediate, library-like contracts.
 */
abstract contract Context {
    function _msgSender() internal view virtual returns (address) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes calldata) {
        this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
        return msg.data;
    }
}

File 13 of 15 : IERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC165 standard, as defined in the
 * https://eips.ethereum.org/EIPS/eip-165[EIP].
 *
 * Implementers can declare support of contract interfaces, which can then be
 * queried by others ({ERC165Checker}).
 *
 * For an implementation, see {ERC165}.
 */
interface IERC165 {
    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30 000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool);
}

File 14 of 15 : SafeMath.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

// CAUTION
// This version of SafeMath should only be used with Solidity 0.8 or later,
// because it relies on the compiler's built in overflow checks.

/**
 * @dev Wrappers over Solidity's arithmetic operations.
 *
 * NOTE: `SafeMath` is no longer needed starting with Solidity 0.8. The compiler
 * now has built in overflow checking.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            uint256 c = a + b;
            if (c < a) return (false, 0);
            return (true, c);
        }
    }

    /**
     * @dev Returns the substraction of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b > a) return (false, 0);
            return (true, a - b);
        }
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
            // benefit is lost if 'b' is also tested.
            // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
            if (a == 0) return (true, 0);
            uint256 c = a * b;
            if (c / a != b) return (false, 0);
            return (true, c);
        }
    }

    /**
     * @dev Returns the division of two unsigned integers, with a division by zero flag.
     *
     * _Available since v3.4._
     */
    function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b == 0) return (false, 0);
            return (true, a / b);
        }
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag.
     *
     * _Available since v3.4._
     */
    function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b == 0) return (false, 0);
            return (true, a % b);
        }
    }

    /**
     * @dev Returns the addition of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `+` operator.
     *
     * Requirements:
     *
     * - Addition cannot overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        return a + b;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b) internal pure returns (uint256) {
        return a - b;
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `*` operator.
     *
     * Requirements:
     *
     * - Multiplication cannot overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        return a * b;
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator.
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        return a / b;
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b) internal pure returns (uint256) {
        return a % b;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
     * overflow (when the result is negative).
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {trySub}.
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        unchecked {
            require(b <= a, errorMessage);
            return a - b;
        }
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting with custom message on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        unchecked {
            require(b > 0, errorMessage);
            return a / b;
        }
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting with custom message when dividing by zero.
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {tryMod}.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        unchecked {
            require(b > 0, errorMessage);
            return a % b;
        }
    }
}

File 15 of 15 : EnumerableSet.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Library for managing
 * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive
 * types.
 *
 * Sets have the following properties:
 *
 * - Elements are added, removed, and checked for existence in constant time
 * (O(1)).
 * - Elements are enumerated in O(n). No guarantees are made on the ordering.
 *
 * ```
 * contract Example {
 *     // Add the library methods
 *     using EnumerableSet for EnumerableSet.AddressSet;
 *
 *     // Declare a set state variable
 *     EnumerableSet.AddressSet private mySet;
 * }
 * ```
 *
 * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`)
 * and `uint256` (`UintSet`) are supported.
 */
library EnumerableSet {
    // To implement this library for multiple types with as little code
    // repetition as possible, we write it in terms of a generic Set type with
    // bytes32 values.
    // The Set implementation uses private functions, and user-facing
    // implementations (such as AddressSet) are just wrappers around the
    // underlying Set.
    // This means that we can only create new EnumerableSets for types that fit
    // in bytes32.

    struct Set {
        // Storage of set values
        bytes32[] _values;

        // Position of the value in the `values` array, plus 1 because index 0
        // means a value is not in the set.
        mapping (bytes32 => uint256) _indexes;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function _add(Set storage set, bytes32 value) private returns (bool) {
        if (!_contains(set, value)) {
            set._values.push(value);
            // The value is stored at length-1, but we add 1 to all indexes
            // and use 0 as a sentinel value
            set._indexes[value] = set._values.length;
            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function _remove(Set storage set, bytes32 value) private returns (bool) {
        // We read and store the value's index to prevent multiple reads from the same storage slot
        uint256 valueIndex = set._indexes[value];

        if (valueIndex != 0) { // Equivalent to contains(set, value)
            // To delete an element from the _values array in O(1), we swap the element to delete with the last one in
            // the array, and then remove the last element (sometimes called as 'swap and pop').
            // This modifies the order of the array, as noted in {at}.

            uint256 toDeleteIndex = valueIndex - 1;
            uint256 lastIndex = set._values.length - 1;

            // When the value to delete is the last one, the swap operation is unnecessary. However, since this occurs
            // so rarely, we still do the swap anyway to avoid the gas cost of adding an 'if' statement.

            bytes32 lastvalue = set._values[lastIndex];

            // Move the last value to the index where the value to delete is
            set._values[toDeleteIndex] = lastvalue;
            // Update the index for the moved value
            set._indexes[lastvalue] = toDeleteIndex + 1; // All indexes are 1-based

            // Delete the slot where the moved value was stored
            set._values.pop();

            // Delete the index for the deleted slot
            delete set._indexes[value];

            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function _contains(Set storage set, bytes32 value) private view returns (bool) {
        return set._indexes[value] != 0;
    }

    /**
     * @dev Returns the number of values on the set. O(1).
     */
    function _length(Set storage set) private view returns (uint256) {
        return set._values.length;
    }

   /**
    * @dev Returns the value stored at position `index` in the set. O(1).
    *
    * Note that there are no guarantees on the ordering of values inside the
    * array, and it may change when more values are added or removed.
    *
    * Requirements:
    *
    * - `index` must be strictly less than {length}.
    */
    function _at(Set storage set, uint256 index) private view returns (bytes32) {
        require(set._values.length > index, "EnumerableSet: index out of bounds");
        return set._values[index];
    }

    // Bytes32Set

    struct Bytes32Set {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _add(set._inner, value);
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _remove(set._inner, value);
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) {
        return _contains(set._inner, value);
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(Bytes32Set storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

   /**
    * @dev Returns the value stored at position `index` in the set. O(1).
    *
    * Note that there are no guarantees on the ordering of values inside the
    * array, and it may change when more values are added or removed.
    *
    * Requirements:
    *
    * - `index` must be strictly less than {length}.
    */
    function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) {
        return _at(set._inner, index);
    }

    // AddressSet

    struct AddressSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(AddressSet storage set, address value) internal returns (bool) {
        return _add(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(AddressSet storage set, address value) internal returns (bool) {
        return _remove(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(AddressSet storage set, address value) internal view returns (bool) {
        return _contains(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(AddressSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

   /**
    * @dev Returns the value stored at position `index` in the set. O(1).
    *
    * Note that there are no guarantees on the ordering of values inside the
    * array, and it may change when more values are added or removed.
    *
    * Requirements:
    *
    * - `index` must be strictly less than {length}.
    */
    function at(AddressSet storage set, uint256 index) internal view returns (address) {
        return address(uint160(uint256(_at(set._inner, index))));
    }


    // UintSet

    struct UintSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(UintSet storage set, uint256 value) internal returns (bool) {
        return _add(set._inner, bytes32(value));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(UintSet storage set, uint256 value) internal returns (bool) {
        return _remove(set._inner, bytes32(value));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(UintSet storage set, uint256 value) internal view returns (bool) {
        return _contains(set._inner, bytes32(value));
    }

    /**
     * @dev Returns the number of values on the set. O(1).
     */
    function length(UintSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

   /**
    * @dev Returns the value stored at position `index` in the set. O(1).
    *
    * Note that there are no guarantees on the ordering of values inside the
    * array, and it may change when more values are added or removed.
    *
    * Requirements:
    *
    * - `index` must be strictly less than {length}.
    */
    function at(UintSet storage set, uint256 index) internal view returns (uint256) {
        return uint256(_at(set._inner, index));
    }
}

Settings
{
  "remappings": [],
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "evmVersion": "istanbul",
  "libraries": {},
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "abi"
      ]
    }
  }
}

Contract ABI

[{"inputs":[{"internalType":"contract GenToken","name":"_gen","type":"address"},{"internalType":"contract IERC20","name":"_busd","type":"address"},{"internalType":"contract IGenNFT","name":"_nft","type":"address"},{"internalType":"address","name":"_busdGenLP","type":"address"},{"internalType":"contract IProxy","name":"_proxy","type":"address"},{"internalType":"address","name":"_devaddr","type":"address"},{"internalType":"address","name":"_feeAddress","type":"address"},{"internalType":"uint256","name":"_genPerBlock","type":"uint256"},{"internalType":"uint256","name":"_startBlock","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"uint256","name":"pid","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"uint256","name":"pid","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"EmergencyWithdraw","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":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"uint256","name":"pid","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdraw","type":"event"},{"inputs":[{"internalType":"uint256","name":"_allocPoint","type":"uint256"},{"internalType":"contract IERC20","name":"_lpToken","type":"address"},{"internalType":"uint16","name":"_depositFeeBP","type":"uint16"},{"internalType":"bool","name":"_withUpdate","type":"bool"}],"name":"add","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"bottomPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"busd","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"busdGenLP","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_devaddr","type":"address"}],"name":"dev","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"devaddr","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"}],"name":"emergencyWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"emissionUpdateInterval","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"feeAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"gen","outputs":[{"internalType":"contract GenToken","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"genPerBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lastBlockUpdate","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"massUpdatePools","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"nft","outputs":[{"internalType":"contract IGenNFT","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC721Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"address","name":"_user","type":"address"}],"name":"pendingGen","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"poolInfo","outputs":[{"internalType":"uint256","name":"totalPower","type":"uint256"},{"internalType":"contract IERC20","name":"lpToken","type":"address"},{"internalType":"uint256","name":"allocPoint","type":"uint256"},{"internalType":"uint256","name":"lastRewardBlock","type":"uint256"},{"internalType":"uint256","name":"accGenPerPower","type":"uint256"},{"internalType":"uint16","name":"depositFeeBP","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"poolLength","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"uint256[]","name":"_nftIds","type":"uint256[]"}],"name":"powerUpWithNFTs","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"uint256","name":"_allocPoint","type":"uint256"},{"internalType":"uint16","name":"_depositFeeBP","type":"uint16"},{"internalType":"bool","name":"_withUpdate","type":"bool"}],"name":"set","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_feeAddress","type":"address"}],"name":"setFeeAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IProxy","name":"_proxy","type":"address"}],"name":"setProxy","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"startBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"topPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalAllocPoint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"updateEmissionIfNeeded","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_topPrice","type":"uint256"},{"internalType":"uint256","name":"_bottomPrice","type":"uint256"},{"internalType":"uint256","name":"_emissionUpdateInterval","type":"uint256"}],"name":"updateEmissionParameters","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_genPerBlock","type":"uint256"}],"name":"updateEmissionRate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"}],"name":"updatePool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"}],"name":"updatePower","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"","type":"address"}],"name":"userInfo","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"rewardDebt","type":"uint256"},{"internalType":"uint256","name":"power","type":"uint256"},{"internalType":"uint256","name":"lastPoweredBlock","type":"uint256"},{"internalType":"uint256","name":"lastClaimedBlock","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60806040526000600b556064600d55600a600e556000600f55610e106010553480156200002b57600080fd5b5060405162002a6238038062002a628339810160408190526200004e9162000191565b60006200005a6200018d565b600080546001600160a01b0319166001600160a01b0383169081178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a3506001600160a01b038416620000d65760405162461bcd60e51b8152600401620000cd906200024f565b60405180910390fd5b6001600160a01b038316620000ff5760405162461bcd60e51b8152600401620000cd906200024f565b600280546001600160a01b03199081166001600160a01b039b8c1617909155600380548216998b1699909917909855600580548916978a169790971790965560048054881695891695909517909455600680548716928816929092179091556001805486169287169290921790915560088054909416941693909317909155600791909155600c5562000294565b3390565b60008060008060008060008060006101208a8c031215620001b0578485fd5b8951620001bd816200027b565b60208b0151909950620001d0816200027b565b60408b0151909850620001e3816200027b565b60608b0151909750620001f6816200027b565b60808b015190965062000209816200027b565b60a08b01519095506200021c816200027b565b60c08b01519094506200022f816200027b565b8093505060e08a015191506101008a015190509295985092959850929598565b6020808252601290820152710616464726573732063616e277420626520360741b604082015260600190565b6001600160a01b03811681146200029157600080fd5b50565b6127be80620002a46000396000f3fe608060405234801561001057600080fd5b506004361061021c5760003560e01c806368df3f8411610125578063b42dfa0d116100ad578063d34513791161007c578063d345137914610408578063d49e77cd1461041b578063d963842214610423578063e2bbb15814610436578063f2fde38b146104495761021c565b8063b42dfa0d146103dd578063b7970bb5146103e5578063d0e887d4146103ed578063d1bf17a6146103f55761021c565b80638d88a90e116100f45780638d88a90e146103835780638da5cb5b1461039657806393f1a40b1461039e57806397107d6d146103c25780639a6a8d85146103d55761021c565b806368df3f841461034d578063715018a61461035557806384e82a331461035d5780638705fcd4146103705761021c565b8063441a3e70116101a85780635312ea8e116101775780635312ea8e14610304578063575014fa1461031757806361d5f34f1461031f578063630b5ba114610332578063642484911461033a5761021c565b8063441a3e70146102ce57806347ccca02146102e157806348cd4cb1146102e957806351eb05a6146102f15761021c565b80631526fe27116101ef5780631526fe271461027c57806317caf6f1146102a157806334c388b5146102a95780633ca5b234146102be57806341275358146102c65761021c565b8063081e3eda14610221578063082ed05c1461023f5780630ba84cd214610247578063150b7a021461025c575b600080fd5b61022961045c565b6040516102369190612366565b60405180910390f35b610229610462565b61025a61025536600461210a565b610468565b005b61026f61026a366004612032565b6104bd565b6040516102369190612351565b61028f61028a36600461210a565b6104cd565b604051610236969594939291906125f4565b610229610521565b6102b1610527565b6040516102369190612300565b6102b1610536565b6102b1610545565b61025a6102dc36600461226c565b610554565b6102b1610679565b610229610688565b61025a6102ff36600461210a565b61068e565b61025a61031236600461210a565b610849565b61022961090f565b61022961032d36600461213a565b610915565b61025a61092a565b61025a610348366004612169565b610955565b61025a610ca2565b61025a610eb1565b61025a61036b36600461221c565b610f3a565b61025a61037e366004611ffa565b611130565b61025a610391366004611ffa565b61117c565b6102b16111c8565b6103b16103ac36600461213a565b6111d7565b604051610236959493929190612637565b61025a6103d0366004611ffa565b611211565b610229611272565b6102b1611278565b610229611287565b61022961128d565b61025a6104033660046122b9565b611293565b61025a61041636600461210a565b6112e0565b6102b161149a565b61025a61043136600461228d565b6114a9565b61025a61044436600461226c565b6115fd565b61025a610457366004611ffa565b611758565b60095490565b600f5481565b610470611818565b6001600160a01b03166104816111c8565b6001600160a01b0316146104b05760405162461bcd60e51b81526004016104a7906124db565b60405180910390fd5b6104b861092a565b600755565b630a85bd0160e11b949350505050565b600981815481106104dd57600080fd5b60009182526020909120600690910201805460018201546002830154600384015460048501546005909501549395506001600160a01b0390921693909261ffff1686565b600b5481565b6004546001600160a01b031681565b6003546001600160a01b031681565b6008546001600160a01b031681565b60006009838154811061057757634e487b7160e01b600052603260045260246000fd5b60009182526020808320868452600a8252604080852033865290925292208054600690920290920192508311156105c05760405162461bcd60e51b81526004016104a790612547565b6105c98461068e565b6105d28461181c565b82156105ff5780546105e4908461186a565b815560018201546105ff906001600160a01b03163385611876565b610608846112e0565b61063264e8d4a5100061062c846004015484600201546118d190919063ffffffff16565b906118dd565b6001820155604051849033907ff279e6a1f5e320cca91135676d9cb6e44ca8a08c0b88342bcdb1144f6511b5689061066b908790612366565b60405180910390a350505050565b6005546001600160a01b031681565b600c5481565b6000600982815481106106b157634e487b7160e01b600052603260045260246000fd5b90600052602060002090600602019050806003015443116106d25750610846565b805415806106e257506002810154155b156106f35743600390910155610846565b600061070c82600301544361186a90919063ffffffff16565b90506000610739600b5461062c8560020154610733600754876118d190919063ffffffff16565b906118d1565b6002546006549192506001600160a01b03908116916340c10f19911661076084600a6118dd565b6040518363ffffffff1660e01b815260040161077d929190612338565b600060405180830381600087803b15801561079757600080fd5b505af11580156107ab573d6000803e3d6000fd5b50506002546040516340c10f1960e01b81526001600160a01b0390911692506340c10f1991506107e19030908590600401612338565b600060405180830381600087803b1580156107fb57600080fd5b505af115801561080f573d6000803e3d6000fd5b50508454610837925061082c915061062c8464e8d4a510006118d1565b6004850154906118e9565b60048401555050436003909101555b50565b60006009828154811061086c57634e487b7160e01b600052603260045260246000fd5b60009182526020808320858452600a8252604080852033865290925292206002810154600690920290920180549093506108a59161186a565b825580546000600283018190558083556001808401919091558301546108d5906001600160a01b03163383611876565b83336001600160a01b03167fbb757047c2b5f3974fe26b7c10f732e7bce710b0952a71082702781e62ae05958360405161066b9190612366565b60105481565b600061092183836118f5565b90505b92915050565b60095460005b81811015610951576109418161068e565b61094a8161271e565b9050610930565b5050565b60006009838154811061097857634e487b7160e01b600052603260045260246000fd5b60009182526020808320868452600a825260408085203386529092529220600690910290910191506109a98461068e565b6109b28461181c565b60005b8351811015610c315760008482815181106109e057634e487b7160e01b600052603260045260246000fd5b60209081029190910101516005546040516331a9108f60e11b815291925033916001600160a01b0390911690636352211e90610a20908590600401612366565b60206040518083038186803b158015610a3857600080fd5b505afa158015610a4c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a709190612016565b6001600160a01b03161415610c1e5743836003015410610b2857600154604051636a63993160e01b81526001600160a01b0390911690636a63993190610aba908490600401612366565b60206040518083038186803b158015610ad257600080fd5b505afa158015610ae6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b0a9190612122565b836003016000828254610b1d9190612684565b90915550610bb89050565b600154604051636a63993160e01b81526001600160a01b0390911690636a63993190610b58908490600401612366565b60206040518083038186803b158015610b7057600080fd5b505afa158015610b84573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ba89190612122565b610bb29043612684565b60038401555b600554604051630956601160e01b81526001600160a01b0390911690630956601190610beb908490600090600401612629565b600060405180830381600087803b158015610c0557600080fd5b505af1158015610c19573d6000803e3d6000fd5b505050505b5080610c298161271e565b9150506109b5565b50610c3b846112e0565b610c5f64e8d4a5100061062c846004015484600201546118d190919063ffffffff16565b816001018190555083336001600160a01b03167f90890809c654f11d6e72a28fa60149770a0d11ec6c92319d6ceb2bb0a4ea1a15600160405161066b9190612366565b601054600f54610cb290436126db565b1115610eaf5743600f55600254600480546040516370a0823160e01b81526000936001600160a01b03908116936370a0823193610cf29392169101612300565b60206040518083038186803b158015610d0a57600080fd5b505afa158015610d1e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d429190612122565b90506000600e546064610d5591906126bc565b90508115610df957610d6561092a565b600354600480546040516370a0823160e01b8152610df693869361062c936064936001600160a01b03938416936370a0823193610da6939091169101612300565b60206040518083038186803b158015610dbe57600080fd5b505afa158015610dd2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107339190612122565b90505b600e54610e079060646126bc565b811015610e4457610e1661092a565b610e3c606461062c600e5461062c670de0b6b3a7640000866118d190919063ffffffff16565b600755610951565b600d54610e529060646126bc565b811115610e8757610e6161092a565b610e3c606461062c600d5461062c670de0b6b3a7640000866118d190919063ffffffff16565b600754670de0b6b3a76400001461095157610ea061092a565b670de0b6b3a764000060075550505b565b610eb9611818565b6001600160a01b0316610eca6111c8565b6001600160a01b031614610ef05760405162461bcd60e51b81526004016104a7906124db565b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b610f42611818565b6001600160a01b0316610f536111c8565b6001600160a01b031614610f795760405162461bcd60e51b81526004016104a7906124db565b6127108261ffff161115610f9f5760405162461bcd60e51b81526004016104a7906123a2565b8015610fad57610fad61092a565b6000600c544311610fc057600c54610fc2565b435b600b54909150610fd290866118e9565b600b556040805160c08101825260008082526001600160a01b0396871660208301908152928201978852606082019384526080820181815261ffff96871660a0840190815260098054600181018255935292517f6e1540171b6c0c960b71a7020d9f60077f6af931a8bbf590da0223dacf75c7af60069093029283015592517f6e1540171b6c0c960b71a7020d9f60077f6af931a8bbf590da0223dacf75c7b0820180546001600160a01b031916919098161790965595517f6e1540171b6c0c960b71a7020d9f60077f6af931a8bbf590da0223dacf75c7b186015590517f6e1540171b6c0c960b71a7020d9f60077f6af931a8bbf590da0223dacf75c7b2850155517f6e1540171b6c0c960b71a7020d9f60077f6af931a8bbf590da0223dacf75c7b38401555091517f6e1540171b6c0c960b71a7020d9f60077f6af931a8bbf590da0223dacf75c7b4909101805461ffff191691909216179055565b6008546001600160a01b0316331461115a5760405162461bcd60e51b81526004016104a790612573565b600880546001600160a01b0319166001600160a01b0392909216919091179055565b6006546001600160a01b031633146111a65760405162461bcd60e51b81526004016104a790612473565b600680546001600160a01b0319166001600160a01b0392909216919091179055565b6000546001600160a01b031690565b600a602090815260009283526040808420909152908252902080546001820154600283015460038401546004909401549293919290919085565b611219611818565b6001600160a01b031661122a6111c8565b6001600160a01b0316146112505760405162461bcd60e51b81526004016104a7906124db565b600180546001600160a01b0319166001600160a01b0392909216919091179055565b600e5481565b6002546001600160a01b031681565b60075481565b600d5481565b61129b611818565b6001600160a01b03166112ac6111c8565b6001600160a01b0316146112d25760405162461bcd60e51b81526004016104a7906124db565b600d92909255600e55601055565b60006009828154811061130357634e487b7160e01b600052603260045260246000fd5b60009182526020808320858452600a8252604080852033865290925292206002810154600382015460069093029093019350919060649043116113d357600160009054906101000a90046001600160a01b03166001600160a01b03166372c1bc196040518163ffffffff1660e01b815260040160206040518083038186803b15801561138e57600080fd5b505afa1580156113a2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113c69190612122565b6113d09082612684565b90505b60015460405163d8cb4aa360e01b81526001600160a01b039091169063d8cb4aa390611403903390600401612300565b60206040518083038186803b15801561141b57600080fd5b505afa15801561142f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114539190612122565b61145d9082612684565b83549091506114739060649061062c90846118d1565b60028401819055845461149191849161148b916118e9565b9061186a565b90935550505050565b6006546001600160a01b031681565b6114b1611818565b6001600160a01b03166114c26111c8565b6001600160a01b0316146114e85760405162461bcd60e51b81526004016104a7906124db565b6127108261ffff16111561150e5760405162461bcd60e51b81526004016104a790612496565b801561151c5761151c61092a565b61156d836115676009878154811061154457634e487b7160e01b600052603260045260246000fd5b906000526020600020906006020160020154600b5461186a90919063ffffffff16565b906118e9565b600b81905550826009858154811061159557634e487b7160e01b600052603260045260246000fd5b90600052602060002090600602016002018190555081600985815481106115cc57634e487b7160e01b600052603260045260246000fd5b906000526020600020906006020160050160006101000a81548161ffff021916908361ffff16021790555050505050565b60006009838154811061162057634e487b7160e01b600052603260045260246000fd5b60009182526020808320868452600a825260408085203386529092529220600690910290910191506116518461068e565b61165a8461181c565b82156116f257600182015461167a906001600160a01b0316333086611c7d565b600582015461ffff16156116e35760058201546000906116a7906127109061062c90879061ffff166118d1565b60085460018501549192506116c9916001600160a01b03908116911683611876565b81546116db90829061148b90876118e9565b8255506116f2565b80546116ef90846118e9565b81555b6116fb846112e0565b61171f64e8d4a5100061062c846004015484600201546118d190919063ffffffff16565b6001820155604051849033907f90890809c654f11d6e72a28fa60149770a0d11ec6c92319d6ceb2bb0a4ea1a159061066b908790612366565b611760611818565b6001600160a01b03166117716111c8565b6001600160a01b0316146117975760405162461bcd60e51b81526004016104a7906124db565b6001600160a01b0381166117bd5760405162461bcd60e51b81526004016104a7906123e7565b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b3390565b6000818152600a60209081526040808320338452909152902043600482015580541561186257600061184e83336118f5565b90508015611860576118603382611ca4565b505b610951610ca2565b600061092182846126db565b6118cc8363a9059cbb60e01b8484604051602401611895929190612338565b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152611e3d565b505050565b600061092182846126bc565b6000610921828461269c565b60006109218284612684565b6000806009848154811061191957634e487b7160e01b600052603260045260246000fd5b60009182526020808320878452600a825260408085206001600160a01b0389168652909252908320600692909202016004810154600382015491945091929061196390439061186a565b60018501546040516370a0823160e01b81529192506000916001600160a01b03909116906370a082319061199b903090600401612300565b60206040518083038186803b1580156119b357600080fd5b505afa1580156119c7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906119eb9190612122565b90508460030154431180156119ff57508015155b8015611a0b5750845415155b15611a5c576000611a35600b5461062c8860020154610733600754886118d190919063ffffffff16565b8654909150611a5890611a519061062c8464e8d4a510006118d1565b85906118e9565b9350505b83600301548460040154108015611a765750836003015443115b8015611a86575060008460020154115b15611c49576004840154606490611a9d90436126db565b85600401548660030154611ab191906126db565b600160009054906101000a90046001600160a01b03166001600160a01b03166372c1bc196040518163ffffffff1660e01b815260040160206040518083038186803b158015611aff57600080fd5b505afa158015611b13573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611b379190612122565b611b4191906126bc565b611b4b919061269c565b611b559082612684565b60015460405163d8cb4aa360e01b81529192506001600160a01b03169063d8cb4aa390611b86903390600401612300565b60206040518083038186803b158015611b9e57600080fd5b505afa158015611bb2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611bd69190612122565b611be09082612684565b90506000611c00606461062c8489600001546118d190919063ffffffff16565b60028701546001880154919250908290611c279061148b64e8d4a5100061062c868c6118d1565b611c3191906126bc565b611c3b919061269c565b975050505050505050610924565b611c71846001015461148b64e8d4a5100061062c8789600201546118d190919063ffffffff16565b98975050505050505050565b611c9e846323b872dd60e01b85858560405160240161189593929190612314565b50505050565b6002546040516370a0823160e01b81526000916001600160a01b0316906370a0823190611cd5903090600401612300565b60206040518083038186803b158015611ced57600080fd5b505afa158015611d01573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d259190612122565b905080821115611db95760025460405163a9059cbb60e01b81526001600160a01b039091169063a9059cbb90611d619086908590600401612338565b602060405180830381600087803b158015611d7b57600080fd5b505af1158015611d8f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611db391906120ee565b506118cc565b60025460405163a9059cbb60e01b81526001600160a01b039091169063a9059cbb90611deb9086908690600401612338565b602060405180830381600087803b158015611e0557600080fd5b505af1158015611e19573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c9e91906120ee565b6000611e92826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316611ecc9092919063ffffffff16565b8051909150156118cc5780806020019051810190611eb091906120ee565b6118cc5760405162461bcd60e51b81526004016104a7906125aa565b6060611edb8484600085611ee5565b90505b9392505050565b606082471015611f075760405162461bcd60e51b81526004016104a79061242d565b611f1085611fa5565b611f2c5760405162461bcd60e51b81526004016104a790612510565b600080866001600160a01b03168587604051611f4891906122e4565b60006040518083038185875af1925050503d8060008114611f85576040519150601f19603f3d011682016040523d82523d6000602084013e611f8a565b606091505b5091509150611f9a828286611faf565b979650505050505050565b803b15155b919050565b60608315611fbe575081611ede565b825115611fce5782518084602001fd5b8160405162461bcd60e51b81526004016104a7919061236f565b803561ffff81168114611faa57600080fd5b60006020828403121561200b578081fd5b8135611ede81612765565b600060208284031215612027578081fd5b8151611ede81612765565b60008060008060808587031215612047578283fd5b843561205281612765565b935060208581013561206381612765565b935060408601359250606086013567ffffffffffffffff80821115612086578384fd5b818801915088601f830112612099578384fd5b8135818111156120ab576120ab61274f565b6120bd601f8201601f1916850161265a565b915080825289848285010111156120d2578485fd5b8084840185840137810190920192909252939692955090935050565b6000602082840312156120ff578081fd5b8151611ede8161277a565b60006020828403121561211b578081fd5b5035919050565b600060208284031215612133578081fd5b5051919050565b6000806040838503121561214c578182fd5b82359150602083013561215e81612765565b809150509250929050565b6000806040838503121561217b578182fd5b8235915060208084013567ffffffffffffffff8082111561219a578384fd5b818601915086601f8301126121ad578384fd5b8135818111156121bf576121bf61274f565b83810291506121cf84830161265a565b8181528481019084860184860187018b10156121e9578788fd5b8795505b8386101561220b5780358352600195909501949186019186016121ed565b508096505050505050509250929050565b60008060008060808587031215612231578384fd5b84359350602085013561224381612765565b925061225160408601611fe8565b915060608501356122618161277a565b939692955090935050565b6000806040838503121561227e578182fd5b50508035926020909101359150565b600080600080608085870312156122a2578182fd5b843593506020850135925061225160408601611fe8565b6000806000606084860312156122cd578081fd5b505081359360208301359350604090920135919050565b600082516122f68184602087016126f2565b9190910192915050565b6001600160a01b0391909116815260200190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b6001600160a01b03929092168252602082015260400190565b6001600160e01b031991909116815260200190565b90815260200190565b600060208252825180602084015261238e8160408501602087016126f2565b601f01601f19169190910160400192915050565b60208082526025908201527f6164643a20696e76616c6964206465706f7369742066656520626173697320706040820152646f696e747360d81b606082015260800190565b60208082526026908201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160408201526564647265737360d01b606082015260800190565b60208082526026908201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6040820152651c8818d85b1b60d21b606082015260800190565b6020808252600990820152686465763a207775743f60b81b604082015260600190565b60208082526025908201527f7365743a20696e76616c6964206465706f7369742066656520626173697320706040820152646f696e747360d81b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b6020808252601d908201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604082015260600190565b6020808252601290820152711dda5d1a191c985dce881b9bdd0819dbdbd960721b604082015260600190565b60208082526018908201527f736574466565416464726573733a20464f5242494444454e0000000000000000604082015260600190565b6020808252602a908201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6040820152691bdd081cdd58d8d9595960b21b606082015260800190565b9586526001600160a01b0394909416602086015260408501929092526060840152608083015261ffff1660a082015260c00190565b918252602082015260400190565b948552602085019390935260408401919091526060830152608082015260a00190565b60405181810167ffffffffffffffff8111828210171561267c5761267c61274f565b604052919050565b6000821982111561269757612697612739565b500190565b6000826126b757634e487b7160e01b81526012600452602481fd5b500490565b60008160001904831182151516156126d6576126d6612739565b500290565b6000828210156126ed576126ed612739565b500390565b60005b8381101561270d5781810151838201526020016126f5565b83811115611c9e5750506000910152565b600060001982141561273257612732612739565b5060010190565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b038116811461084657600080fd5b801515811461084657600080fdfea2646970667358221220ca2ecd854349ab95aff6afb43e536b1c062dcc939e499e803748ed5f3a74f17d64736f6c63430008000033000000000000000000000000b0f2939a1c0e43683e5954c9fe142f7df9f8d967000000000000000000000000e9e7cea3dedca5984780bafc599bd69add087d560000000000000000000000002d801b4737f2c1079a8f63f4f57832f276d71c76000000000000000000000000c89fbab3143ca9a41834b2818b33f4886e7fde01000000000000000000000000443fe2adb210efc88f098e830610f4a18830f922000000000000000000000000bf7f015db6b89cf4b15960e53b055770a4a6debe00000000000000000000000047b69a3474a51f2f6a21a65af8d781b1e0ada85f0000000000000000000000000000000000000000000000000de0b6b3a76400000000000000000000000000000000000000000000000000000000000000633e40

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

000000000000000000000000b0f2939a1c0e43683e5954c9fe142f7df9f8d967000000000000000000000000e9e7cea3dedca5984780bafc599bd69add087d560000000000000000000000002d801b4737f2c1079a8f63f4f57832f276d71c76000000000000000000000000c89fbab3143ca9a41834b2818b33f4886e7fde01000000000000000000000000443fe2adb210efc88f098e830610f4a18830f922000000000000000000000000bf7f015db6b89cf4b15960e53b055770a4a6debe00000000000000000000000047b69a3474a51f2f6a21a65af8d781b1e0ada85f0000000000000000000000000000000000000000000000000de0b6b3a76400000000000000000000000000000000000000000000000000000000000000633e40

-----Encoded View---------------
9 Constructor Arguments found :
Arg [0] : 000000000000000000000000b0f2939a1c0e43683e5954c9fe142f7df9f8d967
Arg [1] : 000000000000000000000000e9e7cea3dedca5984780bafc599bd69add087d56
Arg [2] : 0000000000000000000000002d801b4737f2c1079a8f63f4f57832f276d71c76
Arg [3] : 000000000000000000000000c89fbab3143ca9a41834b2818b33f4886e7fde01
Arg [4] : 000000000000000000000000443fe2adb210efc88f098e830610f4a18830f922
Arg [5] : 000000000000000000000000bf7f015db6b89cf4b15960e53b055770a4a6debe
Arg [6] : 00000000000000000000000047b69a3474a51f2f6a21a65af8d781b1e0ada85f
Arg [7] : 0000000000000000000000000000000000000000000000000de0b6b3a7640000
Arg [8] : 0000000000000000000000000000000000000000000000000000000000633e40


Block Transaction Gas Used Reward
Age Block Fee Address BC Fee Address Voting Power Jailed Incoming
Block Uncle Number Difficulty Gas Used Reward
Loading
Loading
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.