Follow-up to the doc rebrand, addressing the previously out-of-scope legacy: - Currency unit: strCurrencyUnits (chainparams.cpp) and CURRENCY_UNIT (amount.cpp) "HUSH" -> "DRAGONX". Both are display-only (RPC help + metrics); no logic comparisons, verified. - depends mirrors: libsodium/boost/utfcpp fetched from git.hush.is/attachments; repointed to canonical upstream (GitHub release / archives.boost.io / GitHub tag) with the existing sha256 hashes verified to match those sources. - Seeds: nodes_main.txt now lists the five node[1-5].dragonx.is IPs (DNS-resolved) instead of Hush nodes; regenerated src/chainparamsseeds.h (was compiling Hush seed IPs as the fixed fallback); generate-seeds.py header now says DragonX; hush_seed_nodes.txt updated to DragonX seeds. - Deleted Hush-history / wrong-for-DragonX files: contrib/snapshot/ (block-500000 Hush airdrop, ~10MB), notary_seeds.txt (Hush notaries; DragonX isn't notarized), and the Hush emission scripts hush_supply, hush_supply_old, hush_halvings, hush_block_subsidy_per_halving (hardcode Hush's 340000/12.5 economics). Kept: hush_scanner (engine invoked by dragonx_scanner) and the "The Hush developers" copyright headers (lineage credit). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
47 lines
1.9 KiB
C++
47 lines
1.9 KiB
C++
// Copyright (c) 2009-2010 Satoshi Nakamoto
|
|
// Copyright (c) 2009-2014 The Bitcoin Core developers
|
|
// Copyright (c) 2016-2024 The Hush developers
|
|
// Distributed under the GPLv3 software license, see the accompanying
|
|
// file COPYING or https://www.gnu.org/licenses/gpl-3.0.en.html
|
|
/******************************************************************************
|
|
* Copyright © 2014-2019 The SuperNET Developers. *
|
|
* *
|
|
* See the AUTHORS, DEVELOPER-AGREEMENT and LICENSE files at *
|
|
* the top-level directory of this distribution for the individual copyright *
|
|
* holder information and the developer policies on copyright and licensing. *
|
|
* *
|
|
* Unless otherwise agreed in a custom licensing agreement, no part of the *
|
|
* SuperNET software, including this file may be copied, modified, propagated *
|
|
* or distributed except according to the terms contained in the LICENSE file *
|
|
* *
|
|
* Removal or modification of this copyright notice is prohibited. *
|
|
* *
|
|
******************************************************************************/
|
|
#include "amount.h"
|
|
#include "tinyformat.h"
|
|
|
|
const std::string CURRENCY_UNIT = "DRAGONX";
|
|
|
|
CFeeRate::CFeeRate(const CAmount& nFeePaid, size_t nSize)
|
|
{
|
|
if (nSize > 0)
|
|
nSatoshisPerK = nFeePaid*1000/nSize;
|
|
else
|
|
nSatoshisPerK = 0;
|
|
}
|
|
|
|
CAmount CFeeRate::GetFee(size_t nSize) const
|
|
{
|
|
CAmount nFee = nSatoshisPerK*nSize / 1000;
|
|
|
|
if (nFee == 0 && nSatoshisPerK > 0)
|
|
nFee = nSatoshisPerK;
|
|
|
|
return nFee;
|
|
}
|
|
|
|
std::string CFeeRate::ToString() const
|
|
{
|
|
return strprintf("%d.%08d %s/kB", nSatoshisPerK / COIN, nSatoshisPerK % COIN, CURRENCY_UNIT);
|
|
}
|