diff --git a/src/chainparams.cpp b/src/chainparams.cpp index 54f23b682c0f4..1d506d4e53696 100644 --- a/src/chainparams.cpp +++ b/src/chainparams.cpp @@ -247,7 +247,7 @@ class CMainParams : public CChainParams { nPoolMaxTransactions = 3; nFulfilledRequestExpireTime = 60*60; // fulfilled requests expire in 1 hour - strSporkAddress = "DJ7YjNsc8TYHetDbwsxeNZTzyQzQPKCaxW"; // TODO is Dummy only https://github.com/dashpay/dash/commit/611879aa6d973ab995088647d701a4747d0716d3#diff-64cbe1ad5465e13bc59ee8bb6f3de2e7 + strSporkAddress = "DN8GxA2zrozDSDQYedkTznf4jFC4Ujgddr"; // TODO https://github.com/dashpay/dash/commit/611879aa6d973ab995088647d701a4747d0716d3#diff-64cbe1ad5465e13bc59ee8bb6f3de2e7 checkpointData = (CCheckpointData) { boost::assign::map_list_of diff --git a/src/clientversion.h b/src/clientversion.h index 617cc76a09209..54a0cf72f1840 100644 --- a/src/clientversion.h +++ b/src/clientversion.h @@ -18,8 +18,8 @@ //! These need to be macros, as clientversion.cpp's and dms*-res.rc's voodoo requires it #define CLIENT_VERSION_MAJOR 0 #define CLIENT_VERSION_MINOR 12 -#define CLIENT_VERSION_REVISION 3 -#define CLIENT_VERSION_BUILD 2 +#define CLIENT_VERSION_REVISION 9 +#define CLIENT_VERSION_BUILD 0 //! Set to true for release, false for prerelease or test build #define CLIENT_VERSION_IS_RELEASE true diff --git a/src/validation.cpp b/src/validation.cpp index b0639434538b8..5517c1618f23a 100644 --- a/src/validation.cpp +++ b/src/validation.cpp @@ -1292,13 +1292,17 @@ CAmount GetBlockSubsidy(int nPrevBits, int nPrevHeight, const Consensus::Params& double dDiff; CAmount nSubsidyBase; + /* if (nPrevHeight <= 4500 && Params().NetworkIDString() == CBaseChainParams::MAIN) { - /* a bug which caused diff to not be correctly calculated */ + // Dash: a bug which caused diff to not be correctly calculated dDiff = (double)0x0000ffff / (double)(nPrevBits & 0x00ffffff); } else { dDiff = ConvertBitsToDouble(nPrevBits); } + */ + dDiff = ConvertBitsToDouble(nPrevBits); + /* Dash: if (nPrevHeight < 5465) { // Early ages... // 1111/((x+1)^2) @@ -1318,6 +1322,12 @@ CAmount GetBlockSubsidy(int nPrevBits, int nPrevHeight, const Consensus::Params& if(nSubsidyBase > 25) nSubsidyBase = 25; else if(nSubsidyBase < 5) nSubsidyBase = 5; } + */ + // DMS: CPU mining era, reward 25 - 50 DMS + // 11111/(((x+51)/6)^2) + nSubsidyBase = (11111.0 / (pow((dDiff+51.0)/6.0,2.0))); + if(nSubsidyBase > 50) nSubsidyBase = 50; + else if(nSubsidyBase < 25) nSubsidyBase = 25; // LogPrintf("height %u diff %4.2f reward %d\n", nPrevHeight, dDiff, nSubsidyBase); CAmount nSubsidy = nSubsidyBase * COIN;