diff --git a/cmd/puppeth/wizard_genesis.go b/cmd/puppeth/wizard_genesis.go index 8f84ec911f..e0e0460aa5 100644 --- a/cmd/puppeth/wizard_genesis.go +++ b/cmd/puppeth/wizard_genesis.go @@ -231,6 +231,14 @@ func (w *wizard) makeGenesis() { genesis.Config.XDPoS.V2.CurrentConfig.CertThreshold = w.readDefaultFloat(0.667) } genesis.Config.XDPoS.V2.CurrentConfig.MaxMasternodes = 108 + //TODO: config to add after rewards upgrade enabled + // genesis.Config.XDPoS.V2.CurrentConfig.MaxProtectornodes + // genesis.Config.XDPoS.V2.CurrentConfig.MaxObservernodes + // genesis.Config.XDPoS.V2.CurrentConfig.MinProtectornodes + // genesis.Config.XDPoS.V2.CurrentConfig.MasternodeReward + // genesis.Config.XDPoS.V2.CurrentConfig.ProtectornodeReward + // genesis.Config.XDPoS.V2.CurrentConfig.ObservernodeReward + genesis.Config.XDPoS.V2.AllConfigs[0] = genesis.Config.XDPoS.V2.CurrentConfig fmt.Println() diff --git a/common/constants.all.go b/common/constants.all.go index cbf664fd5d..9d3425d709 100644 --- a/common/constants.all.go +++ b/common/constants.all.go @@ -128,15 +128,15 @@ func IsInBlacklist(address *Address) bool { // It skips mainnet since the default value is from mainnet. func CopyConstants(chainID uint64) { var c *constant - if chainID == TestnetConstant.chainID { + if chainID == MaintnetConstant.chainID { + return + } else if chainID == TestnetConstant.chainID { c = &TestnetConstant IsTestnet = true } else if chainID == DevnetConstant.chainID { c = &DevnetConstant - } else if chainID == localConstant.chainID { + } else { // local custom chain, it can have any chainID c = &localConstant - } else { - return } MaxMasternodesV2 = c.maxMasternodesV2 diff --git a/common/constants.local.go b/common/constants.local.go index aeec55f669..291d2871de 100644 --- a/common/constants.local.go +++ b/common/constants.local.go @@ -28,9 +28,9 @@ var localConstant = constant{ tipXDCXReceiverDisable: big.NewInt(0), eip1559Block: big.NewInt(0), cancunBlock: big.NewInt(0), - tipUpgradeReward: big.NewInt(0), - tipUpgradePenalty: big.NewInt(0), - tipEpochHalving: big.NewInt(0), + tipUpgradeReward: big.NewInt(999999999), + tipUpgradePenalty: big.NewInt(999999999), + tipEpochHalving: big.NewInt(999999999), trc21IssuerSMC: HexToAddress("0x8c0faeb5C6bEd2129b8674F262Fd45c4e9468bee"), xdcxListingSMC: HexToAddress("0xDE34dD0f536170993E8CFF639DdFfCF1A85D3E53"),