Skip to content

Commit

Permalink
Merge pull request #5 from proyecto-chaucha/PMC1
Browse files Browse the repository at this point in the history
PMC 1
  • Loading branch information
César Vásquez C committed Mar 6, 2018
2 parents ed6cbc0 + 6b266b5 commit d7f3135
Show file tree
Hide file tree
Showing 12 changed files with 58 additions and 47 deletions.
4 changes: 2 additions & 2 deletions configure.ac
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
dnl require autoconf 2.60 (AS_ECHO/AS_ECHO_N)
AC_PREREQ([2.60])
define(_CLIENT_VERSION_MAJOR, 2)
define(_CLIENT_VERSION_MINOR, 0)
define(_CLIENT_VERSION_MINOR, 1)
define(_CLIENT_VERSION_REVISION, 0)
define(_CLIENT_VERSION_BUILD, 3)
define(_CLIENT_VERSION_BUILD, 0)
define(_CLIENT_VERSION_IS_RELEASE, true)
define(_COPYRIGHT_YEAR, 2018)
define(_COPYRIGHT_HOLDERS,[The %s developers])
Expand Down
2 changes: 1 addition & 1 deletion src/amount.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ extern const std::string CURRENCY_UNIT;
* critical; in unusual circumstances like a(nother) overflow bug that allowed
* for the creation of coins out of thin air modification could lead to a fork.
* */
static const CAmount MAX_MONEY = 123456789 * COIN;
static const CAmount MAX_MONEY = 10800000 * COIN;
inline bool MoneyRange(const CAmount& nValue) { return (nValue >= 0 && nValue <= MAX_MONEY); }

/**
Expand Down
12 changes: 10 additions & 2 deletions src/chainparams.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ class CMainParams : public CChainParams {
public:
CMainParams() {
strNetworkID = "main";
consensus.nSubsidyHalvingInterval = 1051200;
consensus.nSubsidyHalvingInterval = 2628000;
consensus.nMajorityEnforceBlockUpgrade = 750;
consensus.nMajorityRejectBlockOutdated = 950;
consensus.nMajorityWindow = 1000;
Expand All @@ -90,6 +90,9 @@ class CMainParams : public CChainParams {
/** DarkGravityWell v3 Fork Params - Humwerthuz @ 30/12/2017 **/
consensus.nPowDGWHeight = 147000; //DGW on starting from block 147.000

// Propuestas de Mejora para Chaucha (PMC)
consensus.PMC1 = 220000;

// Deployment of BIP68, BIP112, and BIP113.
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].bit = 0;
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].nStartTime = 1515726001; // January 12, 2018
Expand Down Expand Up @@ -165,7 +168,7 @@ class CTestNetParams : public CChainParams {
public:
CTestNetParams() {
strNetworkID = "test";
consensus.nSubsidyHalvingInterval = 1051200;
consensus.nSubsidyHalvingInterval = 250;
consensus.nMajorityEnforceBlockUpgrade = 750;
consensus.nMajorityRejectBlockOutdated = 950;
consensus.nMajorityWindow = 1000;
Expand All @@ -185,6 +188,9 @@ class CTestNetParams : public CChainParams {
/** DarkGravityWell v3 Fork Params - Humwerthuz @ 30/12/2017 **/
consensus.nPowDGWHeight = 200; //DGW always on

// Propuestas de Mejora para Chaucha (PMC)
consensus.PMC1 = 235;

// Deployment of BIP68, BIP112, and BIP113.
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].bit = 0;
consensus.vDeployments[Consensus::DEPLOYMENT_CSV].nStartTime = 1485561600; // January 28, 2017
Expand Down Expand Up @@ -220,6 +226,8 @@ class CTestNetParams : public CChainParams {
// nodes with support for servicebits filtering should be at the top
vSeeds.push_back(CDNSSeedData("fn1.cha.harc.cl", "fn1.cha.harc.cl"));
vSeeds.push_back(CDNSSeedData("fn2.cha.harc.cl", "fn2.cha.harc.cl"));
// PMC1 testnet
vSeeds.push_back(CDNSSeedData("testnet.chaucha.party", "testnet.chaucha.party"));


base58Prefixes[PUBKEY_ADDRESS] = std::vector<unsigned char>(1,65);
Expand Down
8 changes: 4 additions & 4 deletions src/clientversion.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@
*/

//! These need to be macros, as clientversion.cpp's and bitcoin*-res.rc's voodoo requires it
#define CLIENT_VERSION_MAJOR 0
#define CLIENT_VERSION_MINOR 13
#define CLIENT_VERSION_REVISION 3
#define CLIENT_VERSION_MAJOR 2
#define CLIENT_VERSION_MINOR 1
#define CLIENT_VERSION_REVISION 0
#define CLIENT_VERSION_BUILD 0

//! Set to true for release, false for prerelease or test build
Expand All @@ -26,7 +26,7 @@
* Copyright year (2009-this)
* Todo: update this when changing our copyright comments in the source
*/
#define COPYRIGHT_YEAR 2016
#define COPYRIGHT_YEAR 2018

#endif //HAVE_CONFIG_H

Expand Down
3 changes: 3 additions & 0 deletions src/consensus/params.h
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,9 @@ struct Params {

/** DarkGravityWell v3 Fork Params - Humwerthuz @ 30/12/2017 **/
int nPowDGWHeight;

// Propuestas de Mejora para Chaucha
int PMC1;
};
} // namespace Consensus

Expand Down
9 changes: 6 additions & 3 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1723,17 +1723,20 @@ CAmount GetBlockSubsidy(int nHeight, const Consensus::Params& consensusParams)
{
int halvings = nHeight / consensusParams.nSubsidyHalvingInterval;
// Force block reward to zero when right shift is undefined.
if (halvings >= 64)
if (halvings >= 25)
return 0;

CAmount nSubsidy = 10 * COIN;

// 50000 primer bloque, 10 hacia adelante, variable desde el 2834 hasta el 50000, luego fijo a 10 denuevo
if (nHeight == 1)
nSubsidy = 50000 * COIN;
nSubsidy = 50000 * COIN;

if (nHeight > 2834 && nHeight <= 50000) //En realidad partio desde el 2835.
nSubsidy = (50000/nHeight + 10) * COIN;
nSubsidy = (50000/nHeight + 10) * COIN;

if (nHeight >= consensusParams.PMC1)
nSubsidy = 1.5 * COIN;

// Subsidy is cut in half every 210,000 blocks which will occur approximately every 4 years.
nSubsidy >>= halvings;
Expand Down
65 changes: 31 additions & 34 deletions src/qt/locale/bitcoin_es_CL.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,19 @@
</message>
<message>
<source>&amp;New</source>
<translation>y nueva</translation>
<translation>Nueva</translation>
</message>
<message>
<source>Copy the currently selected address to the system clipboard</source>
<translation>Copia la dirección seleccionada al portapapeles</translation>
</message>
<message>
<source>&amp;Copy</source>
<translation>y copiar</translation>
<translation>Copiar</translation>
</message>
<message>
<source>C&amp;lose</source>
<translation>C y perder</translation>
<translation>Cerrar</translation>
</message>
<message>
<source>Delete the currently selected address from the list</source>
Expand All @@ -35,11 +35,11 @@
</message>
<message>
<source>&amp;Export</source>
<translation>y exportar</translation>
<translation>Exportar</translation>
</message>
<message>
<source>&amp;Delete</source>
<translation>&amp;Borrar</translation>
<translation>Borrar</translation>
</message>
</context>
<context>
Expand All @@ -49,7 +49,7 @@
<name>AskPassphraseDialog</name>
<message>
<source>Enter passphrase</source>
<translation>Introduce contraseña actual </translation>
<translation>Introduce contraseña actual</translation>
</message>
<message>
<source>New passphrase</source>
Expand All @@ -67,7 +67,7 @@
<name>BitcoinGUI</name>
<message>
<source>Sign &amp;message...</source>
<translation>Firmar &amp;Mensaje...</translation>
<translation>Firmar Mensaje...</translation>
</message>
<message>
<source>Synchronizing with network...</source>
Expand All @@ -91,19 +91,19 @@
</message>
<message>
<source>E&amp;xit</source>
<translation>&amp;Salir</translation>
<translation>Salir</translation>
</message>
<message>
<source>Quit application</source>
<translation>Salir del programa</translation>
</message>
<message>
<source>&amp;About %1</source>
<translation>S&amp;obre %1</translation>
<translation>Acerca de %1</translation>
</message>
<message>
<source>About &amp;Qt</source>
<translation>Acerca de</translation>
<translation>Acerca de Qt</translation>
</message>
<message>
<source>Show information about Qt</source>
Expand All @@ -127,15 +127,15 @@
</message>
<message>
<source>&amp;Sending addresses...</source>
<translation>Mandando direcciones</translation>
<translation>Direcciones de salida</translation>
</message>
<message>
<source>&amp;Receiving addresses...</source>
<translation>Recibiendo direcciones</translation>
<translation>Direcciones de entrada</translation>
</message>
<message>
<source>Open &amp;URI...</source>
<translation>Abrir y url...</translation>
<translation>Abrir URI...</translation>
</message>
<message>
<source>Reindexing blocks on disk...</source>
Expand Down Expand Up @@ -175,15 +175,15 @@
</message>
<message>
<source>&amp;Send</source>
<translation>&amp;Envía</translation>
<translation>Enviar</translation>
</message>
<message>
<source>&amp;Receive</source>
<translation>y recibir</translation>
<translation>Recibir</translation>
</message>
<message>
<source>&amp;Show / Hide</source>
<translation>&amp;Mostrar/Ocultar</translation>
<translation>&amp;Mostrar / Ocultar</translation>
</message>
<message>
<source>Sign messages with your Chaucha addresses to prove you own them</source>
Expand Down Expand Up @@ -219,7 +219,7 @@
</message>
<message>
<source>Warning</source>
<translation>Atención</translation>
<translation>Advertencia</translation>
</message>
<message>
<source>Information</source>
Expand Down Expand Up @@ -262,8 +262,7 @@
</message>
<message>
<source>Fee:</source>
<translation>comisión:
</translation>
<translation>comisión:</translation>
</message>
<message>
<source>Amount</source>
Expand Down Expand Up @@ -353,7 +352,7 @@
</message>
<message>
<source>Reset all client options to default.</source>
<translation>Reestablece todas las opciones.</translation>
<translation>Reestablecer todas las opciones.</translation>
</message>
<message>
<source>&amp;Network</source>
Expand Down Expand Up @@ -389,8 +388,7 @@
</message>
<message>
<source>&amp;Window</source>
<translation>y windows
</translation>
<translation>Ventana</translation>
</message>
<message>
<source>Show only a tray icon after minimizing the window.</source>
Expand All @@ -406,7 +404,7 @@
</message>
<message>
<source>&amp;Display</source>
<translation>&amp;Mostrado</translation>
<translation>Visualización</translation>
</message>
<message>
<source>&amp;Unit to show amounts in:</source>
Expand All @@ -422,7 +420,7 @@
</message>
<message>
<source>&amp;Cancel</source>
<translation>&amp;Cancela</translation>
<translation>&amp;Cancelar</translation>
</message>
<message>
<source>default</source>
Expand Down Expand Up @@ -551,7 +549,7 @@
</message>
<message>
<source>Copy &amp;Address</source>
<translation>&amp;Copia dirección</translation>
<translation>&amp;Copiar dirección</translation>
</message>
<message>
<source>&amp;Save Image...</source>
Expand Down Expand Up @@ -581,12 +579,11 @@
</message>
<message>
<source>Fee:</source>
<translation>comisión:
</translation>
<translation>comisión:</translation>
</message>
<message>
<source>Transaction Fee:</source>
<translation>Comisión transacción:</translation>
<translation>Comisión de transacción:</translation>
</message>
<message>
<source>normal</source>
Expand All @@ -602,11 +599,11 @@
</message>
<message>
<source>Add &amp;Recipient</source>
<translation>&amp;Agrega destinatario</translation>
<translation>Agregar destinatario</translation>
</message>
<message>
<source>Clear &amp;All</source>
<translation>&amp;Borra todos</translation>
<translation>Borrar todo</translation>
</message>
<message>
<source>Balance:</source>
Expand All @@ -618,7 +615,7 @@
</message>
<message>
<source>S&amp;end</source>
<translation>&amp;Envía</translation>
<translation>Enviar</translation>
</message>
</context>
<context>
Expand Down Expand Up @@ -698,15 +695,15 @@
</message>
<message>
<source>Clear &amp;All</source>
<translation>&amp;Borra todos</translation>
<translation>Restablecer</translation>
</message>
<message>
<source>&amp;Verify Message</source>
<translation>&amp;Firmar Mensaje</translation>
<translation>Verificar Mensaje</translation>
</message>
<message>
<source>Verify &amp;Message</source>
<translation>&amp;Firmar Mensaje</translation>
<translation>Verificar Mensaje</translation>
</message>
</context>
<context>
Expand Down
Binary file modified src/qt/res/icons/bitcoin.ico
Binary file not shown.
Binary file modified src/qt/res/icons/bitcoin.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/qt/res/icons/bitcoin_testnet.ico
Binary file not shown.
Binary file modified src/qt/res/icons/bitcoin_testnet.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/script/standard.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class CScriptID : public uint160
CScriptID(const uint160& in) : uint160(in) {}
};

static const unsigned int MAX_OP_RETURN_RELAY = 83; //!< bytes (+1 for OP_RETURN, +2 for the pushdata opcodes)
static const unsigned int MAX_OP_RETURN_RELAY = 259; //!< bytes (+1 for OP_RETURN, +2 for the pushdata opcodes)
extern bool fAcceptDatacarrier;
extern unsigned nMaxDatacarrierBytes;

Expand Down

0 comments on commit d7f3135

Please sign in to comment.