1

I would like to create a Fork of Monero with a certain number of coins premined.

I have tried to follow How would someone premine a direct fork of monero ( can it be done ) but it is incomplete.

Based on this, I have found on line 92 of src/cryptonote_basic/cryptonote_basic_impl.h

bool get_block_reward(size_t median_size, size_t current_block_size, uint64_t already_generated_coins, uint64_t &reward, uint8_t version);

Lets assume I have a maximum supply of 5000000 coins of which 90% are premined. Where do I modify the Monero code to show this? Also, where do I specify the wallet address for the pre-mined coins to be sent to?

2
  • Why do you want / need to premine?
    – jtgrassie
    Jul 5, 2018 at 1:45
  • i inserted on cryptonote_basic_impl.h but didnt work. maybe is need to be inserted on cpp? i must remove (size_t median_size, size_t current_block_size, uint64_t already_generated_coins, uint64_t &reward, uint8_t version);
    – user9875
    Apr 15, 2019 at 9:29

1 Answer 1

1

You can add this line of code in the first line of the get_block_reward function for premine, set the reward of your choice

 if(already_generated_coins == 0) {
       reward = 4000000;
       return true;
    }

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.