Blackcoin Lore

This commit is contained in:
janko33bd
2017-05-30 21:33:31 +02:00
parent 597c9b42e5
commit 2fdd12b2ea
141 changed files with 4385 additions and 3872 deletions

View File

@@ -69,6 +69,7 @@ static bool AppInitRawTx(int argc, char* argv[])
strUsage += HelpMessageOpt("delout=N", _("Delete output N from TX"));
strUsage += HelpMessageOpt("in=TXID:VOUT", _("Add input to TX"));
strUsage += HelpMessageOpt("locktime=N", _("Set TX lock time to N"));
strUsage += HelpMessageOpt("time=N", _("Set TX time to N"));
strUsage += HelpMessageOpt("nversion=N", _("Set TX version to N"));
strUsage += HelpMessageOpt("outaddr=VALUE:ADDRESS", _("Add address-based output to TX"));
strUsage += HelpMessageOpt("outdata=[VALUE:]DATA", _("Add data-based output to TX"));
@@ -175,6 +176,15 @@ static void MutateTxLocktime(CMutableTransaction& tx, const string& cmdVal)
tx.nLockTime = (unsigned int) newLocktime;
}
static void MutateTxTime(CMutableTransaction& tx, const string& cmdVal)
{
int64_t newTime = atoi64(cmdVal);
if (newTime < 0LL || newTime > 0xffffffffLL)
throw runtime_error("Invalid TX time requested");
tx.nTime = (unsigned int) newTime;
}
static void MutateTxAddInput(CMutableTransaction& tx, const string& strInput)
{
// separate TXID:VOUT in string
@@ -497,7 +507,8 @@ static void MutateTx(CMutableTransaction& tx, const string& command,
MutateTxVersion(tx, commandVal);
else if (command == "locktime")
MutateTxLocktime(tx, commandVal);
else if (command == "time")
MutateTxTime(tx, commandVal);
else if (command == "delin")
MutateTxDelInput(tx, commandVal);
else if (command == "in")