add C++, Typescript and more stuff

This commit is contained in:
2026-10-28 00:15:08 +01:00
parent e99e6386e8
commit ea0f475cae
108 changed files with 2488 additions and 980 deletions
@@ -0,0 +1,38 @@
using System;
namespace KernelPanic.Combat
{
public enum NixGovernorSwitchBlockReason
{
None,
InvalidGovernor,
Inactive,
AlreadySelected,
AlreadySwitchedThisRound,
InsufficientCycles,
SwitchingInProgress,
TutorialActive,
OutsideExecutePhase,
CombatUnavailable,
NoLivingTarget
}
public static class NixGovernorSwitchFeedback
{
public static string GetMessage(this NixGovernorSwitchBlockReason reason) => reason switch
{
NixGovernorSwitchBlockReason.None => null,
NixGovernorSwitchBlockReason.InvalidGovernor => "unknown governor",
NixGovernorSwitchBlockReason.Inactive => "CPU governors are unavailable for this wave",
NixGovernorSwitchBlockReason.AlreadySelected => "this governor is already active",
NixGovernorSwitchBlockReason.AlreadySwitchedThisRound => "already switched governor this turn",
NixGovernorSwitchBlockReason.InsufficientCycles => "not enough Cycles to switch governor",
NixGovernorSwitchBlockReason.SwitchingInProgress => "a governor switch is resolving",
NixGovernorSwitchBlockReason.TutorialActive => "governor switching is unavailable during the tutorial",
NixGovernorSwitchBlockReason.OutsideExecutePhase => "governors can only be switched during Execute",
NixGovernorSwitchBlockReason.CombatUnavailable => "governor switching is unavailable while combat is resolving or inactive",
NixGovernorSwitchBlockReason.NoLivingTarget => "performance requires a living enemy for its specialisation",
_ => throw new ArgumentOutOfRangeException(nameof(reason), reason, "Unknown switch rejection reason.")
};
}
}