How do I increase the token amount? (BEP20)

138 views Asked by At

I created BEP20 token via remix, now I want to increase this token amount. How can I make 100 thousand tokens 200 thousand?

1

There are 1 answers

3
zaneeeeel On

you need add a mint function, like this blow

function issue(uint amount) public onlyOwner {
    require(_totalSupply + amount > _totalSupply);
    require(balances[owner] + amount > balances[owner]);

    balances[owner] += amount;
    _totalSupply += amount;
    Issue(amount);
}