Holesky Testnet

Contract

0xE0D790015b7797982fc29C4Ee0fdC69A13d6CCd0

Overview

ETH Balance

0 ETH

Multichain Info

N/A
Transaction Hash
Method
Block
From
To

There are no matching entries

Please try again later

Advanced mode:
Parent Transaction Hash Block
From
To
View All Internal Transactions
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
Launchpad

Compiler Version
vyper:0.3.7

Optimization Enabled:
N/A

Other Settings:
default evmVersion, MIT license

Contract Source Code (Vyper language format)

# @version 0.3.7

"""
@title Launchpad
@license MIT
"""

votingEscrow: public(immutable(address))
rewardDistributor: public(immutable(address))
rewardFaucet: public(immutable(address))
balToken: public(immutable(address))
balMinter: public(immutable(address))


interface IVotingEscrow:
    def initialize(
        _token: address,
        _name: String[64],
        _symbol: String[32],
        _admin: address,
        _admin_unlock_all: address,
        _admin_early_unlock: address,
        _maxLockTime: uint256,
        _balToken: address,
        _balMinter: address,
        _rewardReceiver: address,
        _rewardReceiverChangeable: bool,
        _rewardDistributor: address
    ): nonpayable

interface IRewardDistributor:
    def initialize(
        _veAddress: address,
        _rewardFaucet: address,
        _startTime: uint256,
        _admin: address
    ): nonpayable

interface IRewardFaucet:
    def initialize(
        _rewardDistributor: address,
    ): nonpayable

event VESystemCreated:
    token: indexed(address)
    votingEscrow: address
    rewardDistributor: address
    rewardFaucet: address
    admin: address


@external
def __init__(
    _votingEscrow: address,
    _rewardDistributor: address,
    _rewardFaucet: address,
    _balToken: address,
    _balMinter: address
):
    assert (
        _votingEscrow != empty(address) and
        _rewardDistributor != empty(address) and
        _rewardFaucet != empty(address) and
        _balToken != empty(address) and
        _balMinter != empty(address)
    ), "zero address"

    votingEscrow = _votingEscrow
    rewardDistributor = _rewardDistributor
    rewardFaucet = _rewardFaucet
    balToken = _balToken
    balMinter = _balMinter


@external
def deploy(
    tokenBptAddr: address,
    name: String[64],
    symbol: String[32],
    maxLockTime: uint256,
    rewardDistributorStartTime: uint256,
    admin_unlock_all: address,
    admin_early_unlock: address,
    rewardReceiver: address
) -> (address, address, address):
    """
    @notice Deploys new VotingEscrow, RewardDistributor and RewardFaucet contracts
    @param tokenBptAddr The address of the token to be used for locking
    @param name The name for the new VotingEscrow contract
    @param symbol The symbol for the new VotingEscrow contract
    @param maxLockTime A constraint for the maximum lock time in the new VotingEscrow contract
    @param rewardDistributorStartTime The start time for reward distribution
    @param admin_unlock_all Admin address to enable unlock-all feature in VotingEscrow (zero-address to disable forever)
    @param admin_early_unlock Admin address to enable early-unlock feature in VotingEscrow (zero-address to disable forever)
    @param rewardReceiver The receiver address of claimed BAL-token rewards
    """
    assert(balToken != tokenBptAddr), '!bal'
    newVotingEscrow: address = create_minimal_proxy_to(votingEscrow)
    newRewardDistributor: address = create_minimal_proxy_to(rewardDistributor)
    

    rewardReceiverChangeable: bool = True
    rewardReceiver_: address = rewardReceiver
    if rewardReceiver == empty(address):
        rewardReceiver_ = newRewardDistributor
        rewardReceiverChangeable = False

    IVotingEscrow(newVotingEscrow).initialize(
        tokenBptAddr,
        name,
        symbol,
        msg.sender,
        admin_unlock_all,
        admin_early_unlock,
        maxLockTime,
        balToken,
        balMinter,
        rewardReceiver_,
        rewardReceiverChangeable,
        newRewardDistributor
    )

    newRewardFaucet: address = create_minimal_proxy_to(rewardFaucet)
    
    IRewardDistributor(newRewardDistributor).initialize(
        newVotingEscrow,
        newRewardFaucet,
        rewardDistributorStartTime,
        msg.sender
    )

    IRewardFaucet(newRewardFaucet).initialize(
        newRewardDistributor
    )

    log VESystemCreated(
        tokenBptAddr,
        newVotingEscrow,
        newRewardDistributor,
        newRewardFaucet,
        msg.sender
    )

    return (newVotingEscrow, newRewardDistributor, newRewardFaucet)

Contract ABI

[{"name":"VESystemCreated","inputs":[{"name":"token","type":"address","indexed":true},{"name":"votingEscrow","type":"address","indexed":false},{"name":"rewardDistributor","type":"address","indexed":false},{"name":"rewardFaucet","type":"address","indexed":false},{"name":"admin","type":"address","indexed":false}],"anonymous":false,"type":"event"},{"stateMutability":"nonpayable","type":"constructor","inputs":[{"name":"_votingEscrow","type":"address"},{"name":"_rewardDistributor","type":"address"},{"name":"_rewardFaucet","type":"address"},{"name":"_balToken","type":"address"},{"name":"_balMinter","type":"address"}],"outputs":[]},{"stateMutability":"nonpayable","type":"function","name":"deploy","inputs":[{"name":"tokenBptAddr","type":"address"},{"name":"name","type":"string"},{"name":"symbol","type":"string"},{"name":"maxLockTime","type":"uint256"},{"name":"rewardDistributorStartTime","type":"uint256"},{"name":"admin_unlock_all","type":"address"},{"name":"admin_early_unlock","type":"address"},{"name":"rewardReceiver","type":"address"}],"outputs":[{"name":"","type":"address"},{"name":"","type":"address"},{"name":"","type":"address"}]},{"stateMutability":"view","type":"function","name":"votingEscrow","inputs":[],"outputs":[{"name":"","type":"address"}]},{"stateMutability":"view","type":"function","name":"rewardDistributor","inputs":[],"outputs":[{"name":"","type":"address"}]},{"stateMutability":"view","type":"function","name":"rewardFaucet","inputs":[],"outputs":[{"name":"","type":"address"}]},{"stateMutability":"view","type":"function","name":"balToken","inputs":[],"outputs":[{"name":"","type":"address"}]},{"stateMutability":"view","type":"function","name":"balMinter","inputs":[],"outputs":[{"name":"","type":"address"}]}]

60206106c76000396000518060a01c6106c25760405260206106e76000396000518060a01c6106c25760605260206107076000396000518060a01c6106c25760805260206107276000396000518060a01c6106c25760a05260206107476000396000518060a01c6106c25760c052346106c257604051156100b157606051156100aa57608051156100a35760a0511561009c5760c05115156100b4565b60006100b4565b60006100b4565b60006100b4565b60005b61011757600c60e0527f7a65726f206164647265737300000000000000000000000000000000000000006101005260e05060e0518061010001601f826000031636823750506308c379a060a052602060c052601f19601f60e051011660440160bcfd5b60405161057552606051610595526080516105b55260a0516105d55260c0516105f55261057561014c61000039610615610000f36003361161000c5761055d565b60003560e01c346105635763915c40938118610498576101443610610563576004358060a01c6105635760405260243560040160408135116105635780358060605260208201818160803750505060443560040160208135116105635780358060c05260208201803560e05250505060a4358060a01c610563576101005260c4358060a01c610563576101205260e4358060a01c610563576101405260405160206105d560003960005118610121576004610160527f2162616c000000000000000000000000000000000000000000000000000000006101805261016050610160518061018001601f826000031636823750506308c379a061012052602061014052601f19601f61016051011660440161013cfd5b7f602d3d8160093d39f3363d3d373d3d3d363d730000000000000000000000000061018052602061057560003960005160601b610193527f5af43d82803e903d91602b57fd5bf300000000000000000000000000000000006101a75260366101806000f0801561056357610160527f602d3d8160093d39f3363d3d373d3d3d363d73000000000000000000000000006101a052602061059560003960005160601b6101b3527f5af43d82803e903d91602b57fd5bf300000000000000000000000000000000006101c75260366101a06000f08015610563576101805260016101a052610140516101c0526101405161022257610180516101c05260006101a0525b61016051639bf6abf36101e052610180604051610200528061022052806102000160605180825260208201818183608060045afa5050508051806020830101601f82600003163682375050601f19601f825160200101169050810190508061024052806102000160c0518082526020820160e051815250508051806020830101601f82600003163682375050601f19601f8251602001011690508101905033610260526101005161028052610120516102a0526064356102c05260206105d56000396000516102e05260206105f5600039600051610300526101c051610320526101a05161034052610180516103605250803b156105635760006101e06102246101fc6000855af1610339573d600060003e3d6000fd5b507f602d3d8160093d39f3363d3d373d3d3d363d73000000000000000000000000006102005260206105b560003960005160601b610213527f5af43d82803e903d91602b57fd5bf300000000000000000000000000000000006102275260366102006000f08015610563576101e0526101805163be2030946102005261016051610220526101e05161024052608435610260523361028052803b15610563576000610200608461021c6000855af16103f6573d600060003e3d6000fd5b506101e05163c4d66de8610200526101805161022052803b15610563576000610200602461021c6000855af1610431573d600060003e3d6000fd5b506040517fa1de2bb5131ee0bd88e8ab94ac9f5ecf9e9d0bcea61a294eb7df4bf7c222b641610160516102005261018051610220526101e0516102405233610260526080610200a2610160516102005261018051610220526101e051610240526060610200f35b634f2bfe5b81186104bf576004361061056357602061057560003960005160405260206040f35b63acc2166a81186104e6576004361061056357602061059560003960005160405260206040f35b63397bcd41811861050d57600436106105635760206105b560003960005160405260206040f35b6338d54645811861053457600436106105635760206105d560003960005160405260206040f35b6373f43d6d811861055b57600436106105635760206105f560003960005160405260206040f35b505b60006000fd5b600080fda165767970657283000307000b005b600080fd0000000000000000000000005edfff293207960d472a5f74bf968cb4120585de000000000000000000000000da7cabb5128e7c4922d1ba736bd7c18e9b3938b000000000000000000000000012f16bd86baa4f78e0587807efe6371147219586000000000000000000000000b19382073c7a0addbb56ac6af1808fa49e377b750000000000000000000000001783cd84b3d01854a96b4ed5843753c2ccbd574a

Deployed Bytecode

0x6003361161000c5761055d565b60003560e01c346105635763915c40938118610498576101443610610563576004358060a01c6105635760405260243560040160408135116105635780358060605260208201818160803750505060443560040160208135116105635780358060c05260208201803560e05250505060a4358060a01c610563576101005260c4358060a01c610563576101205260e4358060a01c610563576101405260405160206105d560003960005118610121576004610160527f2162616c000000000000000000000000000000000000000000000000000000006101805261016050610160518061018001601f826000031636823750506308c379a061012052602061014052601f19601f61016051011660440161013cfd5b7f602d3d8160093d39f3363d3d373d3d3d363d730000000000000000000000000061018052602061057560003960005160601b610193527f5af43d82803e903d91602b57fd5bf300000000000000000000000000000000006101a75260366101806000f0801561056357610160527f602d3d8160093d39f3363d3d373d3d3d363d73000000000000000000000000006101a052602061059560003960005160601b6101b3527f5af43d82803e903d91602b57fd5bf300000000000000000000000000000000006101c75260366101a06000f08015610563576101805260016101a052610140516101c0526101405161022257610180516101c05260006101a0525b61016051639bf6abf36101e052610180604051610200528061022052806102000160605180825260208201818183608060045afa5050508051806020830101601f82600003163682375050601f19601f825160200101169050810190508061024052806102000160c0518082526020820160e051815250508051806020830101601f82600003163682375050601f19601f8251602001011690508101905033610260526101005161028052610120516102a0526064356102c05260206105d56000396000516102e05260206105f5600039600051610300526101c051610320526101a05161034052610180516103605250803b156105635760006101e06102246101fc6000855af1610339573d600060003e3d6000fd5b507f602d3d8160093d39f3363d3d373d3d3d363d73000000000000000000000000006102005260206105b560003960005160601b610213527f5af43d82803e903d91602b57fd5bf300000000000000000000000000000000006102275260366102006000f08015610563576101e0526101805163be2030946102005261016051610220526101e05161024052608435610260523361028052803b15610563576000610200608461021c6000855af16103f6573d600060003e3d6000fd5b506101e05163c4d66de8610200526101805161022052803b15610563576000610200602461021c6000855af1610431573d600060003e3d6000fd5b506040517fa1de2bb5131ee0bd88e8ab94ac9f5ecf9e9d0bcea61a294eb7df4bf7c222b641610160516102005261018051610220526101e0516102405233610260526080610200a2610160516102005261018051610220526101e051610240526060610200f35b634f2bfe5b81186104bf576004361061056357602061057560003960005160405260206040f35b63acc2166a81186104e6576004361061056357602061059560003960005160405260206040f35b63397bcd41811861050d57600436106105635760206105b560003960005160405260206040f35b6338d54645811861053457600436106105635760206105d560003960005160405260206040f35b6373f43d6d811861055b57600436106105635760206105f560003960005160405260206040f35b505b60006000fd5b600080fda165767970657283000307000b0000000000000000000000005edfff293207960d472a5f74bf968cb4120585de000000000000000000000000da7cabb5128e7c4922d1ba736bd7c18e9b3938b000000000000000000000000012f16bd86baa4f78e0587807efe6371147219586000000000000000000000000b19382073c7a0addbb56ac6af1808fa49e377b750000000000000000000000001783cd84b3d01854a96b4ed5843753c2ccbd574a

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

0000000000000000000000005edfff293207960d472a5f74bf968cb4120585de000000000000000000000000da7cabb5128e7c4922d1ba736bd7c18e9b3938b000000000000000000000000012f16bd86baa4f78e0587807efe6371147219586000000000000000000000000b19382073c7a0addbb56ac6af1808fa49e377b750000000000000000000000001783cd84b3d01854a96b4ed5843753c2ccbd574a

-----Decoded View---------------
Arg [0] : _votingEscrow (address): 0x5EDfff293207960D472A5f74Bf968Cb4120585dE
Arg [1] : _rewardDistributor (address): 0xda7CAbb5128E7c4922D1bA736bd7c18e9b3938B0
Arg [2] : _rewardFaucet (address): 0x12f16BD86baA4F78E0587807eFE6371147219586
Arg [3] : _balToken (address): 0xb19382073c7A0aDdbb56Ac6AF1808Fa49e377B75
Arg [4] : _balMinter (address): 0x1783Cd84b3d01854A96B4eD5843753C2CcbD574A

-----Encoded View---------------
5 Constructor Arguments found :
Arg [0] : 0000000000000000000000005edfff293207960d472a5f74bf968cb4120585de
Arg [1] : 000000000000000000000000da7cabb5128e7c4922d1ba736bd7c18e9b3938b0
Arg [2] : 00000000000000000000000012f16bd86baa4f78e0587807efe6371147219586
Arg [3] : 000000000000000000000000b19382073c7a0addbb56ac6af1808fa49e377b75
Arg [4] : 0000000000000000000000001783cd84b3d01854a96b4ed5843753c2ccbd574a


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.