Skip to content

Commit

Permalink
setup new testnet for testing rip01
Browse files Browse the repository at this point in the history
  • Loading branch information
npq7721 committed Mar 22, 2024
1 parent 1de001d commit bf178f2
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 8 deletions.
12 changes: 6 additions & 6 deletions src/chainparams.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -696,7 +696,7 @@ class CTestNetParams : public CChainParams {
consensus.smartnodePaymentFixedBlock = 1;
consensus.nRuleChangeActivationThreshold = 1512; // 75% for testchains
consensus.nMinerConfirmationWindow = 2016; // nPowTargetTimespan / nPowTargetSpacing
consensus.nFutureForkBlock = 1000;
consensus.nFutureForkBlock = 100;
consensus.vDeployments[Consensus::DEPLOYMENT_TESTDUMMY].bit = 28;
consensus.vDeployments[Consensus::DEPLOYMENT_TESTDUMMY].nStartTime = 1199145601; // January 1, 2008
consensus.vDeployments[Consensus::DEPLOYMENT_TESTDUMMY].nTimeout = 1230767999; // December 31, 2008
Expand All @@ -719,13 +719,13 @@ class CTestNetParams : public CChainParams {
pchMessageStart[1] = 0x72; //r
pchMessageStart[2] = 0x74; //t
pchMessageStart[3] = 0x6d; //m
nDefaultPort = 10229;
nDefaultPort = 10230;
nPruneAfterHeight = 1000;
genesis = CreateGenesisBlock(1668574674, 352, 0x20001fff, 4, 5000 * COIN);
genesis = CreateGenesisBlock(1711078237, 971, 0x20001fff, 4, 5000 * COIN);
VerifyGenesisPOW(genesis);

consensus.hashGenesisBlock = genesis.GetHash();
assert(consensus.hashGenesisBlock == uint256S("0x16b418c4e84599ba61836085c5b780c199f90c207f7de189cbb56803e87529eb"));
assert(consensus.hashGenesisBlock == uint256S("0xbbab22066081d3b466abd734de914e8092abf4e959bcd0fff978297c41591b23"));
assert(genesis.hashMerkleRoot == uint256S("0x87a48bc22468acdd72ee540aab7c086a5bbcddc12b51c6ac925717a74c269453"));

vFixedSeeds.clear();
Expand Down Expand Up @@ -768,7 +768,7 @@ class CTestNetParams : public CChainParams {
consensus.nFutureRewardShare = Consensus::FutureRewardShare(0.8,0.2,0.0);

std::vector<FounderRewardStructure> rewardStructures = { {INT_MAX, 5} };// 5% founder/dev fee forever
consensus.nFounderPayment = FounderPayment(rewardStructures, 272200, "rghjACzPtVAN2wydgDbn9Jq1agREu6rH1e");
consensus.nFounderPayment = FounderPayment(rewardStructures, 100, "rghjACzPtVAN2wydgDbn9Jq1agREu6rH1e");

fDefaultConsistencyChecks = false;
fRequireStandard = false;
Expand Down Expand Up @@ -796,7 +796,7 @@ class CTestNetParams : public CChainParams {
};

chainTxData = ChainTxData{
1645942755, // * UNIX timestamp of last known number of transactions (Block 213054)
1, // * UNIX timestamp of last known number of transactions (Block 213054)
0, // * total number of transactions between genesis and that timestamp
// (the tx=... number in the SetBestChain debug.log lines)
0.01 // * estimated number of transactions per second after that timestamp
Expand Down
2 changes: 1 addition & 1 deletion src/chainparamsbase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ std::unique_ptr<CBaseChainParams> CreateBaseChainParams(const std::string& chain
if (chain == CBaseChainParams::MAIN)
return MakeUnique<CBaseChainParams>("", 10225);
else if (chain == CBaseChainParams::TESTNET)
return MakeUnique<CBaseChainParams>("nodetest", 10230);
return MakeUnique<CBaseChainParams>("rip01-testnet", 10231);
else if (chain == CBaseChainParams::DEVNET)
return MakeUnique<CBaseChainParams>(gArgs.GetDevNetName(), 19798);
else if (chain == CBaseChainParams::REGTEST)
Expand Down
3 changes: 2 additions & 1 deletion src/validation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1192,8 +1192,9 @@ CAmount GetBlockSubsidy(int nPrevBits, int nPrevHeight, const Consensus::Params&
const short owlings = 21262; // amount of blocks between 2 owlings
int multiplier; // integer number of owlings
int tempHeight; // number of blocks since last anchor

if (nPrevHeight < 720) {
nSubsidy = 4;
nSubsidy = Params().NetworkIDString().compare("test") == 0 ? 20000 : 4;
} else if ((nPrevHeight > 553531) && (nPrevHeight < 2105657)) {
tempHeight = nPrevHeight - 553532;
multiplier = tempHeight / owlings;
Expand Down

0 comments on commit bf178f2

Please sign in to comment.