Gas price index on a 7-day cycle

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
ZHU MINCHAOandClaude Opus 5.5 committed 2026-11-03 23:32:50 +08:00
1 parent dbba8b4376
commit 50c119697e
9 files changed
+32 -6

No files matched your search

+3
View File
@@ -80,6 +80,9 @@ namespace Decentralized
/// <summary>链上的夜间事件:网络拥堵、地址投毒的 0 币转入、钓鱼公告。</summary>
private static void ChainNight(SaveData d, int day)
{
if (d.GasPhase < 0) d.GasPhase = d.Rng.Range(0, Tuning.TxGasPeriod - 1);
d.Gas = TxRules.Gas(day + 1, d.GasPhase, d.Rng);
Log.Info($"明天 gas ×{d.Gas:0.00}");
if (day >= d.CongestedUntil && d.Rng.Chance(Tuning.TxCongestionChance))
{
d.CongestedFrom = day + 1;