Stage 9.2: mixer operator Tumbler storyline with key drive item
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
62bd641283
commit
a5f9639970
15 files changed
+386
-6
No files matched your search
@@ -24,6 +24,11 @@ namespace Decentralized.Domain
|
||||
/// <summary>SPARK 每晚额外乘的倍数,还剩几晚。</summary>
|
||||
public double SparkPush = 1;
|
||||
public int SparkPushNights;
|
||||
/// <summary>混币器:手续费、匿名集(NPC 混币量)、跑路概率的倍率;被举报后永久关闭(在途的照常提回,不能再存)。</summary>
|
||||
public double MixerFee = 1, MixerVolume = 1, MixerRug = 1;
|
||||
public bool MixerClosed;
|
||||
/// <summary>本 mod 自己的剧情线:混币器运营者 Tumbler。</summary>
|
||||
public Tumbler Tumbler = new Tumbler();
|
||||
|
||||
public bool Has(string key) => Applied.Contains(key);
|
||||
|
||||
@@ -71,6 +76,15 @@ namespace Decentralized.Domain
|
||||
case "lun_arrested":
|
||||
LunUntil = day + Tuning.StoryLunDays;
|
||||
break;
|
||||
case "tumbler_kept":
|
||||
MixerFee *= Tuning.TumblerKeptFee; MixerVolume *= Tuning.TumblerKeptVolume;
|
||||
break;
|
||||
case "tumbler_reported":
|
||||
MixerClosed = true;
|
||||
break;
|
||||
case "tumbler_sold":
|
||||
MixerFee *= Tuning.TumblerSoldFee; MixerRug *= Tuning.TumblerSoldRug;
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
@@ -85,4 +99,45 @@ namespace Decentralized.Domain
|
||||
SparkPushNights = n;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 混币器运营者 Tumbler 的剧情线:解锁混币器、第 <see cref="Tuning.TumblerMinDay"/> 天起开始,四次上门。
|
||||
/// 1 自我介绍 → 2 说治安部在追查混币器(当晚混币器被制裁)→ 3 求你藏密钥盘(三选一:藏 / 举报 / 卖给黑市)→ 4 结局。
|
||||
/// 只记进度,对话和物品在接入层。
|
||||
/// </summary>
|
||||
public sealed class Tumbler
|
||||
{
|
||||
public const int Hide = 1, Report = 2, Sell = 3;
|
||||
public int StartDay = -1, Stage, Choice, VisitedDay = -1;
|
||||
public bool Done;
|
||||
|
||||
/// <summary>第几次上门在哪一天(相对开始日)。</summary>
|
||||
public static readonly int[] Offsets = { 0, 3, 5, 9 };
|
||||
|
||||
public int NextVisitDay => StartDay < 0 || Stage >= Offsets.Length ? -1 : StartDay + Offsets[Stage];
|
||||
|
||||
/// <summary>每天开门时问:是否开始(明天第一次上门)。</summary>
|
||||
public bool TryStart(int day, bool mixerUnlocked)
|
||||
{
|
||||
if (StartDay >= 0 || Done || !mixerUnlocked || day < Tuning.TumblerMinDay) return false;
|
||||
StartDay = day + 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
/// <summary>今天该上门的是第几次(1–4),没有就返回 0(第 4 次举报过的话由接入层改成新闻:他被抓了)。</summary>
|
||||
public int Due(int day)
|
||||
{
|
||||
if (Done || StartDay < 0 || Stage >= Offsets.Length || VisitedDay == day) return 0;
|
||||
if (day < NextVisitDay) return 0;
|
||||
return Stage + 1;
|
||||
}
|
||||
|
||||
/// <summary>这一次上门已经安排了。</summary>
|
||||
public void Visited(int day)
|
||||
{
|
||||
VisitedDay = day;
|
||||
Stage++;
|
||||
Done = Stage >= Offsets.Length;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user