How to fork a cryptocurrency

1

I have cloned a coin and changed some variable to make it my own coin. I have launched it and have a few mining pools mining my coin. Going through the code I notice I have an error and the reward halving starts over at block 10k. So miners are getting 500 coins per block instead of 250 coins. I believe this sort of change would fork the coin to a new blockchain but I want current holders to keep the same amount of coins on the new fork. How can I change the code and fork the chain to comply with the new info?

https://github.com/DataSaverCoin/DSC/blob/master/src/main.cpp

cfaulk

Posted 2018-05-28T15:05:13.580

Reputation: 11

Question was closed 2018-06-11T17:58:52.573

Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question.Adam 2018-05-28T15:22:27.747

Question has been edited.cfaulk 2018-05-28T16:14:40.350

Answers

0

Compile the code. Release the new client. Old and new version will disagree at some point in the future (block 10k in your case) et voila, you will have a forked chain.

S van Staa

Posted 2018-05-28T15:05:13.580

Reputation: 111

So the old wallet.dat will still work with a newer client? If that's the case I can just force the pools to update their wallet. My biggest concern was that I'd have to regenerate the merkleroot and genesis block and start mining from scratch.cfaulk 2018-05-28T16:48:01.807

I would assume so. You can test it yourself to be sure.S van Staa 2018-05-28T16:51:07.460