LANTERN purge B7: rename CharacterId -> FrameKind (frame terminology)
Enum renamed in StatIds.cs (byte values unchanged - serialized definitions/saves never re-mean); all call sites + doc mentions swept (ClassTraits, PlayerAuthoring, CharacterStatsDefinition field type, menu/UI, tests). CharacterStatsDefinition SO CLASS name kept (asset-binding risk; deferred per plan). 390 green. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -37,7 +37,7 @@ namespace ProjectM.Client
|
||||
public static void Kill() => Send(DebugOp.KillPlayer);
|
||||
/// <summary>Set the <see cref="ProjectM.Simulation.TuningKnob"/> knob to value (server-applied, x1000 fixed-point; MC-0).</summary>
|
||||
public static void SetTuning(byte knob, float value) => Send(DebugOp.SetTuning, knob, Mathf.RoundToInt(value * 1000f));
|
||||
/// <summary>Swap the sender's class to <paramref name="classId"/> (a <see cref="ProjectM.Simulation.CharacterId"/> byte); server-authoritative (class-switch dev tool).</summary>
|
||||
/// <summary>Swap the sender's class to <paramref name="classId"/> (a <see cref="ProjectM.Simulation.FrameKind"/> byte); server-authoritative (class-switch dev tool).</summary>
|
||||
public static void SetClass(byte classId) => Send(DebugOp.SetClass, classId);
|
||||
public static void SetWarrior() => SetClass(ClassTraits.WarriorClass);
|
||||
public static void SetRanger() => SetClass(ClassTraits.RangerClass);
|
||||
|
||||
@@ -68,7 +68,7 @@ namespace ProjectM.Client
|
||||
switch (idx)
|
||||
{
|
||||
case 0: // Controls (chosen class)
|
||||
bool ranger = WorldLauncher.SelectedClass == (byte)CharacterId.Ranger;
|
||||
bool ranger = WorldLauncher.SelectedClass == (byte)FrameKind.Ranger;
|
||||
Head(c, ranger ? "CLASS: Ranger (ranged anchor)" : "CLASS: Warrior (melee anchor)");
|
||||
Body(c, "Move — WASD / Left Stick");
|
||||
Body(c, "Aim — Mouse cursor / Right Stick");
|
||||
|
||||
@@ -99,8 +99,8 @@ namespace ProjectM.Client
|
||||
var classRow = new VisualElement();
|
||||
classRow.style.flexDirection = FlexDirection.Row;
|
||||
classRow.style.justifyContent = Justify.Center;
|
||||
classRow.Add(MenuUi.Button("Warrior", () => SelectClass((byte)CharacterId.Warrior)));
|
||||
classRow.Add(MenuUi.Button("Ranger", () => SelectClass((byte)CharacterId.Ranger)));
|
||||
classRow.Add(MenuUi.Button("Warrior", () => SelectClass((byte)FrameKind.Warrior)));
|
||||
classRow.Add(MenuUi.Button("Ranger", () => SelectClass((byte)FrameKind.Ranger)));
|
||||
card.Add(classRow);
|
||||
|
||||
card.Add(MenuUi.Button("Single Player", () => Launch(SessionMode.Single, false)));
|
||||
@@ -149,7 +149,7 @@ namespace ProjectM.Client
|
||||
if (_classLabel != null) _classLabel.text = ClassName(classId);
|
||||
}
|
||||
|
||||
static string ClassName(byte classId) => classId == (byte)CharacterId.Ranger ? "CLASS: Ranger (ranged)" : "CLASS: Warrior (melee)";
|
||||
static string ClassName(byte classId) => classId == (byte)FrameKind.Ranger ? "CLASS: Ranger (ranged)" : "CLASS: Warrior (melee)";
|
||||
|
||||
void ShowSettings()
|
||||
{
|
||||
|
||||
@@ -28,8 +28,8 @@ namespace ProjectM.Client
|
||||
|
||||
public static bool Busy { get; private set; }
|
||||
|
||||
/// <summary>Slice 2: the class chosen in the menu (a CharacterId byte), seeded into the client world at session start.</summary>
|
||||
public static byte SelectedClass = (byte)CharacterId.Warrior;
|
||||
/// <summary>Slice 2: the frame chosen in the menu (a FrameKind byte), seeded into the client world at session start.</summary>
|
||||
public static byte SelectedClass = (byte)FrameKind.Warrior;
|
||||
|
||||
/// <summary>The mode of the most recently started session — the HUD's outcome banner branches on it
|
||||
/// (single: PLAY AGAIN restarts; co-op: the honest exit is a clean teardown for everyone).</summary>
|
||||
|
||||
Reference in New Issue
Block a user