Initial PegsCC implementation (#27)

This commit is contained in:
Mihailo Milenkovic
2019-07-04 11:23:55 +02:00
committed by GitHub
parent 0c6c4a9501
commit 1f013df156
22 changed files with 1581 additions and 89 deletions

View File

@@ -323,6 +323,13 @@ CBlockTemplate* CreateNewBlock(CPubKey _pk,const CScript& _scriptPubKeyIn, int32
BOOST_FOREACH(const CTxIn& txin, tx.vin)
{
if (tx.IsPegsImport() && txin.prevout.n==10e8)
{
CAmount nValueIn = GetCoinImportValue(tx); // burn amount
nTotalIn += nValueIn;
dPriority += (double)nValueIn * 1000; // flat multiplier... max = 1e16.
continue;
}
// Read prev transaction
if (!view.HaveCoins(txin.prevout.hash))
{