fix(chat): consolidated-review fixes — retail /help Detail extraction, seam wiring test
SHOULD-FIX 1: RetailClientCommandCatalog's ~45 catalog leaf verbs were showing acdream-authored Summary text for /help <verb> instead of retail's own Detail_HelpType(2) text. Byte-swept every Help* handler against the PDB-paired acclient.exe (verified MATCH), confirmed each Detail/Summary branch by reading the actual decompiled if/else shape (address order and string length both proved unreliable alone), and fixed a sweep_weenie_strings.py 800-char truncation bug that silently dropped several longer Detail branches. Resolved every ambiguous CmdHashData-registered verb (hor/hr/hom/hoa/alh/ah/friends_add/ friends_remove/squelch/unsquelch) by reading for Binary Ninja's nullptr-4th-arg decompiler artifact instead of trusting it. Coverage: 42 of 47 distinct catalog Definitions verbatim-extracted, 4 confirmed-null (index/clist/on/off register with a genuinely null help pointer — DoHelp falls to UnknownCommand for these, now reproduced), 1 honest UNVERIFIED (messagetypes builds its text from a runtime enum table, not a static string). ChatCommandRouter now prefers retail Detail text over the catalog summary; RetailCommandHelpTable's class doc no longer overclaims its own scope. SHOULD-FIX 2: extracted the a5a7eb4f-class OnInterfaceText wiring into a testable CreateChatViewModel method and added ComposedChatViewModelWiresOnInterfaceTextToSpewBox, which the prior FakeFactory-based test suite could never exercise. SHOULD-FIX 3: retires register row AP-113. DoLifestone/DoMarketplace print their own 0x1A refusal text (byte-recovered, UTF-16LE) instead of falling through to the generic 0x26 fallback; ChatCommandRouter's comment corrected to state the fallback's real scope. SHOULD-FIX 4: corrected the divergence register's stale AP section header sentence about AP-190's opacity default (refuted bycc582899). NITs: (a) HeadlessStaticStateAudit routes through the injected HeadlessDiagnosticWriter instead of Console.WriteLine; (b) a bounded 300-pump liveness diagnostic on the IsQuiescent conductor gate (no retry, no behavior change); (c) fixed the #365 hydration test's doc comment contradiction against diagnosis §8; (d) the 0x26 fallback dispatches on WeenieErrorMessages' own Type instead of hardcoding ClientLocal. Full Release suite: 12,553 passed / 4 skipped / 0 failed (baseline03404b71: 12,542/4/0; net +11 tests, zero regressions). Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
parent
03404b7121
commit
f7a6f46ba0
15 changed files with 947 additions and 85 deletions
|
|
@ -419,6 +419,33 @@ internal sealed class RetailInteractionRetainedUiCompositionFactory
|
|||
incrementBusy: itemInteraction.IncrementBusyCount,
|
||||
canSend: () => late.Session.IsInWorld);
|
||||
|
||||
/// <summary>
|
||||
/// Consolidated-review round (2026-08-10), SHOULD-FIX 2: extracted out
|
||||
/// of <see cref="CreateRetainedUi"/> so this specific wiring — the
|
||||
/// composed <see cref="ChatVM.OnInterfaceText"/> hook that routes
|
||||
/// <c>ChatCommandRouter</c>'s <c>0x1A</c> refusals to
|
||||
/// <see cref="RuntimeCommunicationState.AddText"/>/SpewBox — is
|
||||
/// independently testable without the rest of <see cref="CreateRetainedUi"/>'s
|
||||
/// GPU/dat/UiHost dependencies (all null-safe in a pure unit test; this
|
||||
/// method only touches <see cref="InteractionRetainedUiDependencies.Communication"/>).
|
||||
/// The a5a7eb4f defect class (a composed hook wired but never
|
||||
/// transferred) is exactly what this seam existing untested let slip
|
||||
/// through — see <c>InteractionRetainedUiCompositionTests.ComposedChatViewModelWiresOnInterfaceTextToSpewBox</c>.
|
||||
/// </summary>
|
||||
internal static ChatVM CreateChatViewModel(InteractionRetainedUiDependencies d) =>
|
||||
new ChatVM(
|
||||
d.Communication.Chat,
|
||||
displayLimit: 200,
|
||||
commandTargets: d.Communication.CommandTargets)
|
||||
{
|
||||
// Issue #363 / #367: routes ChatCommandRouter's 0x1A
|
||||
// (ClientLocal) command refusals to the same SpewBox
|
||||
// chokepoint every other interface-text producer uses,
|
||||
// instead of the chat scroll.
|
||||
OnInterfaceText = text =>
|
||||
d.Communication.AddText(text, RetailLogTextType.ClientLocal),
|
||||
};
|
||||
|
||||
public RetainedUiComposition CreateRetainedUi(
|
||||
InteractionRetainedUiDependencies d,
|
||||
InteractionUiLateBindings late,
|
||||
|
|
@ -559,18 +586,7 @@ internal sealed class RetailInteractionRetainedUiCompositionFactory
|
|||
|
||||
host.Root.Width = d.Window.Size.X;
|
||||
host.Root.Height = d.Window.Size.Y;
|
||||
var chat = new ChatVM(
|
||||
d.Communication.Chat,
|
||||
displayLimit: 200,
|
||||
commandTargets: d.Communication.CommandTargets)
|
||||
{
|
||||
// Issue #363 / #367: routes ChatCommandRouter's 0x1A
|
||||
// (ClientLocal) command refusals to the same SpewBox
|
||||
// chokepoint every other interface-text producer uses,
|
||||
// instead of the chat scroll.
|
||||
OnInterfaceText = text =>
|
||||
d.Communication.AddText(text, RetailLogTextType.ClientLocal),
|
||||
};
|
||||
var chat = CreateChatViewModel(d);
|
||||
AcDream.UI.Abstractions.Panels.Settings.SettingsStore? layoutStore =
|
||||
d.Settings.LayoutStore;
|
||||
RetailUiPersistenceBindings? persistence = layoutStore is null
|
||||
|
|
|
|||
|
|
@ -42,10 +42,14 @@ internal sealed class HeadlessProcessHost : IDisposable
|
|||
throw new HeadlessConfigurationException(
|
||||
"Direct credentials require exactly one configured session.");
|
||||
}
|
||||
HeadlessStaticStateAudit.ValidateProcessIsolation(
|
||||
configuration.Sessions.Count);
|
||||
|
||||
// Consolidated-review round (2026-08-10), NIT (a): construct the
|
||||
// diagnostics writer BEFORE the audit call so its single-session
|
||||
// "probes enabled" line routes through the same structured stream
|
||||
// every other headless diagnostic uses, instead of a bare
|
||||
// Console.WriteLine that bypassed it.
|
||||
_diagnostics = new HeadlessDiagnosticWriter(diagnostics);
|
||||
HeadlessStaticStateAudit.ValidateProcessIsolation(
|
||||
configuration.Sessions.Count, _diagnostics);
|
||||
var credentials = new HeadlessCredentialResolver(
|
||||
standardInput,
|
||||
paths.ConfigDirectory);
|
||||
|
|
|
|||
|
|
@ -675,7 +675,14 @@ internal sealed class HeadlessSessionHost : IDisposable
|
|||
Runtime,
|
||||
content,
|
||||
_firstEntryDrive,
|
||||
_acceptedPositionDrive);
|
||||
_acceptedPositionDrive,
|
||||
// Consolidated-review round (2026-08-10), NIT (b): the
|
||||
// SAME session-labelled diagnostics stream every other
|
||||
// producer in this class writes into.
|
||||
onNonQuiescentStall: message => _diagnostics.Message(
|
||||
_descriptor.Id,
|
||||
message,
|
||||
Runtime.Generation.Value));
|
||||
_worldProjection = projection;
|
||||
worldProjection = projection;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -617,18 +617,34 @@ internal sealed class HeadlessSessionWorldProjection
|
|||
/// resolves promptly.
|
||||
/// </summary>
|
||||
private readonly RuntimeAcceptedPositionDriveController? _acceptedPositionDrive;
|
||||
private readonly Action<string>? _onNonQuiescentStall;
|
||||
private uint _requestedLocalPlayerCell;
|
||||
|
||||
/// <summary>
|
||||
/// Consolidated-review round (2026-08-10), NIT (b): a purely
|
||||
/// diagnostic trip-wire, not a behavior change. At the host's per-tick
|
||||
/// pump cadence this is on the order of many seconds — generous enough
|
||||
/// that no legitimate multi-tick collision-generation sequence should
|
||||
/// ever cross it, so crossing it means something is genuinely stuck
|
||||
/// (a publication that never seals, an admission that never clears).
|
||||
/// </summary>
|
||||
private const int NonQuiescentStallPumpThreshold = 300;
|
||||
|
||||
private int _nonQuiescentPumpCount;
|
||||
private bool _reportedNonQuiescentStall;
|
||||
|
||||
internal HeadlessSessionWorldProjection(
|
||||
GameRuntime runtime,
|
||||
HeadlessProcessContentOwner.HeadlessProcessContentLease content,
|
||||
RuntimeFirstEntryDriveController? firstEntry = null,
|
||||
RuntimeAcceptedPositionDriveController? acceptedPositionDrive = null)
|
||||
RuntimeAcceptedPositionDriveController? acceptedPositionDrive = null,
|
||||
Action<string>? onNonQuiescentStall = null)
|
||||
: this(
|
||||
runtime,
|
||||
new HeadlessCollisionNeighborhood(runtime, content),
|
||||
firstEntry,
|
||||
acceptedPositionDrive)
|
||||
acceptedPositionDrive,
|
||||
onNonQuiescentStall)
|
||||
{
|
||||
}
|
||||
|
||||
|
|
@ -636,7 +652,8 @@ internal sealed class HeadlessSessionWorldProjection
|
|||
GameRuntime runtime,
|
||||
IHeadlessCollisionNeighborhood collision,
|
||||
RuntimeFirstEntryDriveController? firstEntry = null,
|
||||
RuntimeAcceptedPositionDriveController? acceptedPositionDrive = null)
|
||||
RuntimeAcceptedPositionDriveController? acceptedPositionDrive = null,
|
||||
Action<string>? onNonQuiescentStall = null)
|
||||
{
|
||||
_runtime = runtime
|
||||
?? throw new ArgumentNullException(nameof(runtime));
|
||||
|
|
@ -644,6 +661,7 @@ internal sealed class HeadlessSessionWorldProjection
|
|||
?? throw new ArgumentNullException(nameof(collision));
|
||||
_firstEntry = firstEntry;
|
||||
_acceptedPositionDrive = acceptedPositionDrive;
|
||||
_onNonQuiescentStall = onNonQuiescentStall;
|
||||
}
|
||||
|
||||
public void ProjectSpawn(
|
||||
|
|
@ -776,7 +794,23 @@ internal sealed class HeadlessSessionWorldProjection
|
|||
// publication work each tick (its own mutating side effect), so
|
||||
// gating it too would make the neighborhood itself never converge.
|
||||
if (!_collision.IsQuiescent)
|
||||
{
|
||||
// NIT (b): diagnostic-only trip-wire, no retry and no behavior
|
||||
// change -- the gate above keeps refusing to drive the
|
||||
// conductor exactly as it always has. Fires ONCE per stall
|
||||
// episode so a hang shows up in the diagnostics stream instead
|
||||
// of reading as "still working" indefinitely.
|
||||
if (++_nonQuiescentPumpCount >= NonQuiescentStallPumpThreshold
|
||||
&& !_reportedNonQuiescentStall)
|
||||
{
|
||||
_reportedNonQuiescentStall = true;
|
||||
_onNonQuiescentStall?.Invoke(FormattableString.Invariant(
|
||||
$"collision neighborhood non-quiescent for {_nonQuiescentPumpCount} pumps, requested landblock=0x{_requestedLocalPlayerCell:X8}"));
|
||||
}
|
||||
return;
|
||||
}
|
||||
_nonQuiescentPumpCount = 0;
|
||||
_reportedNonQuiescentStall = false;
|
||||
_firstEntry?.DriveAll();
|
||||
_acceptedPositionDrive?.Advance();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
using System.Reflection;
|
||||
using AcDream.Core.Physics;
|
||||
using AcDream.Headless.Configuration;
|
||||
using AcDream.Headless.Diagnostics;
|
||||
|
||||
namespace AcDream.Headless.Hosting;
|
||||
|
||||
|
|
@ -22,8 +23,18 @@ namespace AcDream.Headless.Hosting;
|
|||
/// </remarks>
|
||||
internal static class HeadlessStaticStateAudit
|
||||
{
|
||||
internal static void ValidateProcessIsolation(int sessionCount)
|
||||
/// <summary>
|
||||
/// Consolidated-review round (2026-08-10), NIT (a): <paramref name="diagnostics"/>
|
||||
/// is the SAME structured writer every other headless diagnostic uses
|
||||
/// (<see cref="HeadlessProcessHost"/>'s <c>_diagnostics</c> field, now
|
||||
/// constructed before this call rather than after it) — the raw
|
||||
/// <c>Console.WriteLine</c> this replaced bypassed the session-labelled
|
||||
/// JSON stream every other producer writes into.
|
||||
/// </summary>
|
||||
internal static void ValidateProcessIsolation(
|
||||
int sessionCount, HeadlessDiagnosticWriter diagnostics)
|
||||
{
|
||||
ArgumentNullException.ThrowIfNull(diagnostics);
|
||||
var enabled = new List<string>();
|
||||
foreach (PropertyInfo property in typeof(PhysicsDiagnostics)
|
||||
.GetProperties(BindingFlags.Public | BindingFlags.Static)
|
||||
|
|
@ -53,8 +64,10 @@ internal static class HeadlessStaticStateAudit
|
|||
|
||||
if (sessionCount == 1)
|
||||
{
|
||||
Console.WriteLine(FormattableString.Invariant(
|
||||
$"[headless-audit] single-session process — process-global physics probes enabled: {string.Join(", ", enabled)}"));
|
||||
diagnostics.Message(
|
||||
sessionId: "process",
|
||||
eventName: FormattableString.Invariant(
|
||||
$"headless-audit: single-session process — process-global physics probes enabled: {string.Join(", ", enabled)}"));
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -54,21 +54,44 @@ public static class ChatCommandRouter
|
|||
{
|
||||
// #363 / register row AP-183: retail's bad-args refusal is
|
||||
// ALWAYS 0x1A (ClientLocal / SpewBox-only) — verified
|
||||
// against five decompiled handlers (DoDie, DoChannelList/
|
||||
// On/Off, DoAllegiance, DoHouseAvailableList). A Definition
|
||||
// with its own InvalidArgumentsText is the handler's own
|
||||
// bespoke refusal string, printed before it returns
|
||||
// "handled" (1) so retail's generic fallback never fires
|
||||
// for it. A Definition with none falls to that generic
|
||||
// fallback: ClientCommunicationSystem::DoCommand
|
||||
// @0x0057E46D calls HandleFailureEvent(0x26) when a
|
||||
// registered handler returns 0 (bad args) —
|
||||
// against seven decompiled handlers (DoDie, DoChannelList/
|
||||
// On/Off, DoAllegiance, DoHouseAvailableList, and — added at
|
||||
// the consolidated-review round 2026-08-10, retiring
|
||||
// register row AP-113 — DoLifestone/DoMarketplace). A
|
||||
// Definition with its own InvalidArgumentsText is the
|
||||
// handler's own bespoke refusal string (byte-recovered from
|
||||
// the PDB-paired acclient.exe; Binary Ninja mis-attributes
|
||||
// both DoLifestone's and DoMarketplace's own literal to an
|
||||
// unrelated vtable-slot symbol, the same class of artifact
|
||||
// this file already documents for the Help* family),
|
||||
// printed before the handler returns "handled" (1) so
|
||||
// retail's generic fallback never fires for it. The 0x26
|
||||
// fallback below therefore covers ONLY verbs with no
|
||||
// bespoke retail refusal of their own — not every bad-args
|
||||
// case, and not a placeholder pending more extraction:
|
||||
// ClientCommunicationSystem::DoCommand @0x0057E46D calls
|
||||
// HandleFailureEvent(0x26) when a registered handler
|
||||
// returns 0 (bad args) with no bespoke string, resolving to
|
||||
// "That is not a valid command." (WeenieErrorMessages
|
||||
// [0x026]) — never the acdream-invented "Usage: {Usage}"
|
||||
// line this branch used to synthesize.
|
||||
vm.ShowInterfaceText(clientCommand.InvalidArgumentsText
|
||||
?? WeenieErrorMessages.Resolve(0x026u, null).Text
|
||||
?? "That is not a valid command.");
|
||||
// line this branch used to synthesize. Consolidated-review
|
||||
// NIT (d): dispatches on the resolved entry's own Type
|
||||
// rather than assuming ShowInterfaceText's hardcoded
|
||||
// ClientLocal is correct for it.
|
||||
if (clientCommand.InvalidArgumentsText is { } bespokeRefusal)
|
||||
{
|
||||
vm.ShowInterfaceText(bespokeRefusal);
|
||||
}
|
||||
else
|
||||
{
|
||||
(string? text, RetailLogTextType type) fallback =
|
||||
WeenieErrorMessages.Resolve(0x026u, null);
|
||||
string fallbackText = fallback.text ?? "That is not a valid command.";
|
||||
if (fallback.type == RetailLogTextType.ClientLocal)
|
||||
vm.ShowInterfaceText(fallbackText);
|
||||
else
|
||||
vm.ShowSystemMessage(fallbackText);
|
||||
}
|
||||
return SubmitOutcome.ClientHandled;
|
||||
}
|
||||
|
||||
|
|
@ -261,6 +284,24 @@ public static class ChatCommandRouter
|
|||
/// <see cref="RetailCommandHelpTable.UnknownCommand"/> text instead of
|
||||
/// an acdream-invented "No help available" message.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Consolidated-review round (2026-08-10), SHOULD-FIX 1: lookup order
|
||||
/// is now (1) <see cref="RetailCommandHelpTable.CatalogVerbsWithNoRetailHelp"/>
|
||||
/// — a catalog leaf verb retail itself registers with a NULL help
|
||||
/// pointer (index/clist/on/off) goes straight to
|
||||
/// <see cref="RetailCommandHelpTable.UnknownCommand"/>, matching
|
||||
/// retail's own <c>DoHelp</c> exactly, and must never reach either
|
||||
/// text source below; (2)
|
||||
/// <see cref="RetailCommandHelpTable.TryGetCatalogVerbDetailText"/> —
|
||||
/// retail's OWN Detail_HelpType text, byte-swept from the retail
|
||||
/// binary, for the 42 catalog leaf verbs it covers; (3)
|
||||
/// <see cref="RetailClientCommandCatalog.TryGetHelpText"/> — the
|
||||
/// catalog's acdream-authored summary, now purely the fallback for
|
||||
/// catalog verbs not yet extracted (currently only messagetypes and
|
||||
/// its 3 aliases); (4) <see cref="RetailCommandHelpTable.TryGetHelpText"/>
|
||||
/// — chat-alias/channel verbs and the group-topic nodes, a disjoint key
|
||||
/// space from the catalog so this reordering changes nothing for them.
|
||||
/// </remarks>
|
||||
private static void EmitVerbHelp(string verb, ChatVM vm)
|
||||
{
|
||||
if (verb.Length == 0)
|
||||
|
|
@ -270,6 +311,25 @@ public static class ChatCommandRouter
|
|||
}
|
||||
|
||||
string normalized = verb.TrimStart('/', '@');
|
||||
|
||||
if (RetailCommandHelpTable.CatalogVerbsWithNoRetailHelp.Contains(
|
||||
normalized.TrimEnd(',')))
|
||||
{
|
||||
// Retail types this 0x1A (ClientLocal) -> SpewBox-only, the
|
||||
// SAME fallback an unregistered verb gets — DoHelp's help-
|
||||
// pointer-null guard skips its callback branch entirely. See
|
||||
// RetailCommandHelpTable.CatalogVerbsWithNoRetailHelp's remarks.
|
||||
vm.ShowInterfaceText(RetailCommandHelpTable.UnknownCommand);
|
||||
return;
|
||||
}
|
||||
|
||||
if (RetailCommandHelpTable.TryGetCatalogVerbDetailText(normalized, out string retailDetailText))
|
||||
{
|
||||
vm.ShowSystemMessage(RetailCommandHelpTable.HelpPrefixNote);
|
||||
vm.ShowSystemMessage(RetailCommandHelpTable.ForMoreInformationPrefix + retailDetailText);
|
||||
return;
|
||||
}
|
||||
|
||||
if (RetailClientCommandCatalog.TryGetHelpText(normalized, out string catalogText))
|
||||
{
|
||||
vm.ShowSystemMessage(RetailCommandHelpTable.HelpPrefixNote);
|
||||
|
|
|
|||
|
|
@ -29,16 +29,36 @@ public static class RetailClientCommandCatalog
|
|||
bool HasValidArguments,
|
||||
string? InvalidArgumentsText);
|
||||
|
||||
// ClientCommunicationSystem::DoLifestone @ 0x0056FC70. Consolidated
|
||||
// review round (2026-08-10), SHOULD-FIX 3: retires register row
|
||||
// AP-113. DoLifestone's own bad-args branch prints ITS OWN 0x1A string
|
||||
// and returns 1 — retail never reaches the generic HandleFailureEvent
|
||||
// (0x26) fallback for it. Binary Ninja mis-attributes the literal to
|
||||
// an unrelated vtable-slot symbol
|
||||
// (ClientCommunicationSystem::`vftable'.RecvNotice_AddItemToTrade,
|
||||
// the classic pooled-string artifact); recovered byte-exact by reading
|
||||
// the raw `push imm32` operand at 0x0056fc84 and decoding the UTF-16LE
|
||||
// string at data VA 0x007d0578 directly against the PDB-paired
|
||||
// C:\Users\erikn\Downloads\acclient.exe (verified MATCH).
|
||||
private static readonly Definition Lifestone = new(
|
||||
ClientCommandId.LifestoneRecall,
|
||||
Usage: "/lifestone",
|
||||
HelpText: "/lifestone (/lif, /ls) - Returns you to the last lifestone you used without killing you.",
|
||||
ValidateArguments: static arguments => arguments.Length == 0);
|
||||
ValidateArguments: static arguments => arguments.Length == 0,
|
||||
InvalidArgumentsText: "Please see @help lifestone for more information on how to use this command.");
|
||||
|
||||
private static readonly Definition Marketplace = NoArguments(
|
||||
// ClientCommunicationSystem::DoMarketplace @ 0x0056FCE0. Same
|
||||
// methodology and same vtable-mislabeling artifact as Lifestone above
|
||||
// (mis-attributed to RecvNotice_UpdateToolbarSelectionDisplay);
|
||||
// operand at 0x0056fcf4, data VA 0x007d0610. Not a previously-filed
|
||||
// register row — Marketplace was never flagged as diverging — this is
|
||||
// a plain accuracy improvement alongside Lifestone's AP-113 retirement.
|
||||
private static readonly Definition Marketplace = new(
|
||||
ClientCommandId.MarketplaceRecall,
|
||||
"/marketplace",
|
||||
"/marketplace (/mar, /mp) - Teleports you to the Marketplace of Dereth.");
|
||||
Usage: "/marketplace",
|
||||
HelpText: "/marketplace (/mar, /mp) - Teleports you to the Marketplace of Dereth.",
|
||||
ValidateArguments: static arguments => arguments.Length == 0,
|
||||
InvalidArgumentsText: "Please see @help marketplace for more information on how to use this command.");
|
||||
|
||||
private static readonly Definition PkArena = NoArguments(
|
||||
ClientCommandId.PkArenaRecall,
|
||||
|
|
|
|||
|
|
@ -4,14 +4,24 @@ namespace AcDream.UI.Abstractions.Panels.Chat;
|
|||
|
||||
/// <summary>
|
||||
/// Campaign CH slice CH4 (2026-08-09): <c>/help <verb></c> text for
|
||||
/// every retail-registry verb <see cref="RetailClientCommandCatalog"/>
|
||||
/// doesn't dispatch directly — chat aliases and channel verbs
|
||||
/// every retail-registry verb — originally chat aliases and channel verbs
|
||||
/// (<see cref="ChatInputParser"/>), the null-func help-only nodes (retail
|
||||
/// registers these with NO handler; typing them bare reaches the server,
|
||||
/// only <c>@help <verb></c> shows anything locally), and the
|
||||
/// allegiance/house command overviews (the per-subcommand detail lives
|
||||
/// here too, even though most subcommands are not yet locally executed —
|
||||
/// see TS-68).
|
||||
/// see TS-68). <b>Corrected at the consolidated-review round
|
||||
/// (2026-08-10), SHOULD-FIX 1:</b> the sentence above previously claimed
|
||||
/// this table covers only verbs <see cref="RetailClientCommandCatalog"/>
|
||||
/// "doesn't dispatch directly" — that framing is now FALSE and was itself
|
||||
/// an overclaim-by-omission: <see cref="CatalogVerbDetailByVerb"/> (see
|
||||
/// its own remarks, and the "Catalog leaf-verb Detail extraction" region
|
||||
/// below) supplies retail Detail_HelpType text for 42 of the catalog's OWN
|
||||
/// dispatched leaf verbs too, which <c>ChatCommandRouter</c> now prefers
|
||||
/// over the catalog's acdream-authored summaries. This table is the single
|
||||
/// <c>/help <verb></c> retail-text source for BOTH catalog-dispatched
|
||||
/// and non-catalog verbs; <see cref="RetailClientCommandCatalog.TryGetHelpText"/>
|
||||
/// is now purely the fallback for the catalog verbs not yet extracted.
|
||||
///
|
||||
/// <para>
|
||||
/// The named constants above <see cref="ByVerb"/> (<see cref="Tell"/>,
|
||||
|
|
@ -193,13 +203,27 @@ public static class RetailCommandHelpTable
|
|||
public const string Motd =
|
||||
"@allegiance motd - Displays the message of the day for your allegiance. @allegiance motd set <text> - Sets the MOTD. Can only be used by monarchs. @allegiance motd clear - Clears the MOTD. Can only be used by monarchs. NOT YET IMPLEMENTED in acdream (TS-68) — the command reaches the server as literal text.";
|
||||
|
||||
// Split out of AllegianceOverview's own data block (data_0x7dfb58) at
|
||||
// the consolidated review round (2026-08-10) so the const declaration
|
||||
// order matches use; see the class remarks on AllegianceOverview below.
|
||||
public const string AllegianceWarningLine =
|
||||
" WARNING! Officers banning or booting a character by account could wind up in a situation where they are no longer in the allegiance if they boot a character that is above them in the hierarchy.\n";
|
||||
|
||||
// acclient_2013_pseudo_c.txt:1031234 (data_7e03d4) plus the full
|
||||
// per-subcommand block at 1031210-1031230 (data_7dfb58).
|
||||
// per-subcommand block at 1031210-1031230 (data_7dfb58). Consolidated
|
||||
// review round (2026-08-10), SHOULD-FIX 1 byproduct: a fresh full-length
|
||||
// byte sweep of HelpAllegiance @0x0057ae10 (0x57ae10-0x57aef0, no
|
||||
// max_chars truncation this time) turned up the " WARNING! Officers
|
||||
// banning..." line between "ban list" and "info" that the original
|
||||
// extraction dropped — confirmed present in the SAME data block
|
||||
// (data_0x7dfb58) this const already cites, not a new source. Restored
|
||||
// verbatim, including the retail leading space.
|
||||
public const string AllegianceOverview =
|
||||
"@allegiance - Commands to help manage your allegiance.\n"
|
||||
+ "@allegiance boot [-account] <name> - Removes a character from your allegiance.\n"
|
||||
+ "@allegiance ban <add/remove> <name> - Bans all characters on the given character's account from your allegiance (and boots them too!)\n"
|
||||
+ "@allegiance ban list - List the characters whose accounts are banned from your allegiance.\n"
|
||||
+ AllegianceWarningLine
|
||||
+ "@allegiance info <name> - Requests information on a member of your allegiance. [IMPLEMENTED]\n"
|
||||
+ "@allegiance chat <on/off> - Turn allegiance chat on and off.\n"
|
||||
+ "@allegiance chat kick <name>[, <reason>] - Kick a player temporarily from the allegiance chat room.\n"
|
||||
|
|
@ -416,6 +440,287 @@ public static class RetailCommandHelpTable
|
|||
+ "@help text - Commands that help you manage your text window.\n"
|
||||
+ CommandsGroupSummary + "\n";
|
||||
|
||||
// ── Catalog leaf-verb Detail extraction (consolidated review round,
|
||||
// 2026-08-10, SHOULD-FIX 1) ─────────────────────────────────────────
|
||||
//
|
||||
// RetailClientCommandCatalog's 47 top-level Definitions each carry an
|
||||
// acdream-authored HelpText — a SUMMARY-shaped one-liner, not retail's
|
||||
// Detail_HelpType(2) text. DoHelp @0x0057F9E0 calls a resolved verb's
|
||||
// OWN registered help callback with Detail_HelpType for /help <verb>
|
||||
// (the class remarks above trace this call precisely) — retail never
|
||||
// shows the Summary text there. Every Help* handler below was located
|
||||
// by name in acclient_2013_pseudo_c.txt, its exact byte extent (this
|
||||
// function's start VA to the next function's start VA, read from the
|
||||
// pseudo-C's own function-header addresses) swept for `push imm32`
|
||||
// string literals against the PDB-paired
|
||||
// C:\Users\erikn\Downloads\acclient.exe (verified MATCH via
|
||||
// check_exe_pdb.py), and the resulting branch assignment confirmed by
|
||||
// reading the actual decompiled if/else shape rather than guessing
|
||||
// from string length or address order — those two heuristics
|
||||
// DISAGREED between HelpDie (Detail at the higher address) and
|
||||
// HelpCorpse (Detail at the LOWER address), so neither is trustworthy
|
||||
// alone. sweep_weenie_strings.py's stock 800-char cap silently dropped
|
||||
// several longer Detail branches (HelpConsent 978 chars, HelpFillComponents
|
||||
// 1036, HelpEndurance 2459) as a `None` result with no error — a custom
|
||||
// unbounded-length pass (same PE-parsing logic, no cap) recovered them;
|
||||
// this is a tool limitation worth fixing generally, not specific to
|
||||
// this sweep.
|
||||
//
|
||||
// <b>CmdHashData help-pointer verification.</b> Several verbs the
|
||||
// catalog dispatches (hor/hr, hom/hoa, friends_add, friends_remove,
|
||||
// squelch, unsquelch, alh/ah) have no distinctly-NAMED Help* function of
|
||||
// their own. `ClientCommunicationSystem::InitializeCommands
|
||||
// @0x00581970`'s per-verb block ALWAYS shows the registered help
|
||||
// pointer as a literal `nullptr` 4th argument to
|
||||
// `CmdHashData::CmdHashData(...)` in Binary Ninja's rendering — a
|
||||
// confirmed, systematic decompiler artifact, not per-verb truth: the
|
||||
// REAL help pointer is instead stored to a throwaway local
|
||||
// (`uint8_t (__stdcall* var_3c_NN)(...) = ClientCommunicationSystem::HelpXxx;`)
|
||||
// immediately before the constructor call, which Binary Ninja fails to
|
||||
// thread through as the actual argument. Presence of that typed
|
||||
// function-pointer local (not a plain `int32_t var_3c_NN = 0;`) is the
|
||||
// ground truth: hor/hr/hom/hoa share `HelpHouse` (the SAME function
|
||||
// "house"/"hou" use — <see cref="HouseOverview"/> already covers it),
|
||||
// friends_add/friends_remove share `HelpFriends` (same as "friends"),
|
||||
// squelch/unsquelch share `HelpSquelch`, and alh/ah share
|
||||
// `HelpAllegiance` (the SAME function "allegiance"/"all" use — <see
|
||||
// cref="AllegianceOverview"/> already covers it). Four verbs
|
||||
// (index/clist/on/off) genuinely DO have a plain `int32_t var_3c_NN = 0;`
|
||||
// local with no preceding Help-pointer assignment — CONFIRMED NULL,
|
||||
// not merely undecoded: retail's own `DoHelp` skips straight to its
|
||||
// "Unknown command" fallback for these (the `if (eax_35 != 0)` guard
|
||||
// around the help-pointer call), even though the verb itself dispatches
|
||||
// fine. <see cref="CatalogVerbsWithNoRetailHelp"/> names them so
|
||||
// <c>ChatCommandRouter</c> can reproduce that exact behavior instead of
|
||||
// falling back to the catalog's invented summary.
|
||||
//
|
||||
// <c>messagetypes</c>/<c>message_types</c>/<c>msgtypes</c>/<c>msg_types</c>
|
||||
// are the one leaf verb NOT extracted this round:
|
||||
// `HelpMessageTypes @0x0056e5d0` calls
|
||||
// `gmCCommunicationSystem::GetListofSquelchChannels(arg4)` to build its
|
||||
// text from a live enum table at runtime — there is no static string to
|
||||
// sweep. It keeps its acdream summary, honestly UNVERIFIED rather than
|
||||
// guessed at.
|
||||
//
|
||||
// Coverage this round: 42 of the 47 catalog Definitions got a verbatim
|
||||
// Detail override (<see cref="CatalogVerbDetailByVerb"/>, several
|
||||
// sharing one extraction per the CmdHashData note above), 4 are
|
||||
// CONFIRMED-NULL (<see cref="CatalogVerbsWithNoRetailHelp"/>), and 1
|
||||
// (messagetypes and its 3 aliases) remains an honest acdream summary —
|
||||
// <c>RetailClientCommandHelpCoverageTests</c> pins these counts so a
|
||||
// future extraction pass (or an accidental regression) is caught.
|
||||
public const string LifestoneDetail =
|
||||
"@lifestone - Returns you to the last lifestone you used without killing you.\n";
|
||||
|
||||
public const string MarketplaceDetail =
|
||||
"@marketplace - Teleports you to the Marketplace of Dereth.\n";
|
||||
|
||||
public const string PkArenaDetail =
|
||||
"@pkarena - Teleports you to the PK Arena. You must be PK to use this command.\n";
|
||||
|
||||
public const string PkLiteArenaDetail =
|
||||
"@pklarena - Teleports you to the PKL Arena. You must be PKL to use this command.\n";
|
||||
|
||||
public const string PkLiteDetail =
|
||||
"@pklite - Sets your status to Player Killer Lite (PK Lite). PK Lite characters can attack other PK Lite characters. They cannot, however, attack Player Killer (PK) characters. PK Lite characters operate under the same combat rules as PK characters, except that if you are killed in a PK Lite battle, you will not accrue vitae and you will not drop any coins or items. Only Non-Player Killers may use this command to enter PK Lite. Dying in a PK Lite battle and logging off will restore your status to Non-Player Killer.\n";
|
||||
|
||||
public const string AgeDetail =
|
||||
"@age - Displays your total gameplay time.\n";
|
||||
|
||||
public const string BirthDetail =
|
||||
"@birth - Displays when your character was created.\n";
|
||||
|
||||
public const string FrameRateDetail =
|
||||
"@framerate - Toggles the framerate display.\n";
|
||||
|
||||
public const string LockUiDetail =
|
||||
"@lockui - Toggles the locked state of the UI layout.\n";
|
||||
|
||||
public const string VersionDetail =
|
||||
"@version - Tells you what version of the software you are using.\n";
|
||||
|
||||
public const string LocDetail =
|
||||
"@loc - Displays your current position in your chat window. Use this information when you wish to submit a bug report.\n";
|
||||
|
||||
public const string CorpseDetail =
|
||||
"@corpse - Displays the location of your last outdoor death. Even if your corpse has disappeared or if you have subsequently died indoors, typing this command will display your last outdoor corpse location.\n";
|
||||
|
||||
public const string DieDetail =
|
||||
"@die - If you wish to kill your character and leave a corpse, you may use the @die command. This will result in your character's death, you will leave behind a corpse with some of your items, and you will appear at your lifestone. If you wish to travel to your lifestone without leaving behind a corpse, you may use the @lifestone command.\n";
|
||||
|
||||
public const string ClearDetail =
|
||||
"@clear - Clears the chat box of all text.\n";
|
||||
|
||||
public const string SaveUiDetail =
|
||||
"@saveui <filename> - Saves the current user interface layout to disk using the provided file name. If no file name is provided the layout is saved with a name that is unique for your server, character and resolution.\n";
|
||||
|
||||
public const string LoadUiDetail =
|
||||
"@loadui <filename> - Loads a previously saved user interface layout from disk using the provided file name";
|
||||
|
||||
public const string SaveAutoUiDetail =
|
||||
"@saveautoui - Stores the current layout to a character and resolution specific file. This layout will automatically be used when the resolution changes for this character to the current size.\n";
|
||||
|
||||
public const string LoadAutoUiDetail =
|
||||
"@loadautoui - Forces a previously saved layout to load for this user and resolution.";
|
||||
|
||||
public const string AfkDetail =
|
||||
"@afk - Turns on AFK (away-from-keyboard) mode. When set to AFK, other players that send you directed chatyou will receive a customizable message that your are not currently at the keyboard.\n@afk on - Turns on AFK mode. When set to AFK, other players that send you directed chatyou will receive a customizable message that your are not currently at the keyboard.\n@afk off - Turn off AFK mode.\n@afk msg <message> - Set the message that will be sent to players that send you directed chat while you are in AFK mode. Issuing \"@afk msg\" with no message will set your AFK message back to the default. Your custom AFK message is limited to 192 characters.\n";
|
||||
|
||||
public const string ConsentDetail =
|
||||
"The @consent commands allow you to display and manage your corpse-looting consent list. This list lets you control whether others may permit you to loot their corpse and also allows you to monitor who has given you permission. You may have a maximum of 20 separate permissions at any given time. You will not be able to loot a corpse that was the victim of a player killer, even if its owner has given you permission. Also, players who have squelched you are not able to permit you to loot their corpse. Note that you can toggle your consent on/off via the Character Options panel as well as through these commands.\n@consent on - Turns on your ability to accept permissions from other players.\n@consent off - Turns off your ability to accept permissions from other players.\n@consent who - Lists those who have given you permission to loot their corpses.\n@consent remove <name> - Removes the permission a player granted to you.\n@consent clear - Clears your entire consent list.\n\n";
|
||||
|
||||
public const string EmoteDetail =
|
||||
"The @emote command causes your character to emote some text, by performing an action in the third person. For example, if you typed the following while logged in as a character named Arville:\n @emote looks around the town curiously.\nthen the chat windows of everyone around you would display:\n Arville looks around the town curiously.\nYou can use any of these shorter forms of the command as well:\n @e <text>\n @em <text>\n ; <text>\n : <text>\n\nYou can also use a variety of standard emotes. These emotes come with special animations as well as text. Type @emotes to see a list.\n\n";
|
||||
|
||||
public const string EmoteListDetail =
|
||||
"Standard Emotes:\nNote: These commands should be bound on either side by asterisks. (Example: *wave*)\nShakeFist; Beckon; BeSeeingYou; BlowKiss; BowDeep; ClapHands; Cry; Laugh; Nod; Point; Shrug; Wave; Akimbo; HeartyLaugh; Salute; TapFoot; WaveHigh; WaveLow; Yawn; Stretch; Cringe; Kneel; Plead; Shiver; Shoo; Slouch; Spit; Surrender; Woah; Winded; YMCA; Eat; Drink; Teapot; Pray; Mock; Cheer; Helper; Warm Hands; Scratch Head; Shake Head\n\n";
|
||||
|
||||
public const string FriendsDetail =
|
||||
"Every time someone on your friends list logs in or out, you will receive notification. In addition, you can query the online status of your friends list at any time. Your friends list can contain up to 50 characters.\n@friends - Shows all your current friends and indicates if any of them are online.\n@friends online - Shows your current online friends.\n@friends add <name> - Adds a character to your friends list.\n@friends remove <name> - Removes a character from your friends list.\n@friends remove -all - Clears your friends list.\n@friends old - Shows the characters who were on your old-style friends list prior to the January 2006 update, so you can move them to your new-style friends list if necessary.\n";
|
||||
|
||||
public const string SquelchDetail =
|
||||
"The @squelch commands let you block out messages from specific characters or players. The @unsquelch commands lets squelched messages reach you again. Use the options on these commands to squelch all message types or just some types of messages; one character or an entire account. You may have up to 32 players squelched at once. Note that NPCs cannot be permanently squelched.\n\n@squelch - Shows the current list of squelched characters.\n@squelch [-account] <name> - Squelches all messages from a character. With the account flag, this command also stops everything except normal chat coming from the target's other characters.\n@squelch [-message_type] <character> - This will filter out all text messages of a certain type from a specific character. For example, the following will filter out all tell messages from Oswald:\n Example: @squelch -tell Oswald.\n@squelch -reply [-account] [-message_type] - This filters out all text messages from whoever last tell'd you. You may also use the -account flag and/or limit the squelch by indicating specific message types. For example, this will filter out all tell messages from the account of Oswald, assuming that Oswald was the last person who sent you an @tell:\n Example: @squelch -reply -account -tell\n\n@unsquelch - Shows the current list of squelched characters.\n@unsquelch <name> - Removes all squelches from a character, including account squelch.\n@unsquelch [-message_type] <character> : This allows text messages of type message_type to come from a squelched character. For example the following allows assessment messages from a character name Oswald:\n Example: @unsquelch -assessment Oswald\n@unsquelch -reply [-account] [-message_type] : This allows text messages of type message_type from whoever last sent you an @tell. For example, the following will allow any character on Oswald's account to once again send you @tells, assuming that Oswald was the last person who sent you an @tell:\n Example: @squelch -reply -account -tell\n\nType @messagetypes for a complete list of message types.\n";
|
||||
|
||||
public const string FilterDetail =
|
||||
"The @filter commands filter out all incoming messages of a certain type. Type @messagetypes to see a list of the message types that you can filter.\n@filter - List all the filters currently in place.\n@filter <-message_type> - Filters out all incoming messages of a specific type. For example, the following will filter out all spellcasting text: \n Example: @filter -spellcasting\n@filter -all - Filters out all incoming messages of all types.\n\n";
|
||||
|
||||
public const string UnfilterDetail =
|
||||
"The @unfilter commands remove specific filters from your incoming messages. For a complete list of message types that you can filter, type @help messagetypes.\n@unfilter <-message_type> - Removes filters on incoming messages of a specific type. For example, the following allows spellcasting text to resume:\n Example: @unfilter -spellcasting\n@unfilter -all - Removes all filters on incoming messages of all types.\n";
|
||||
|
||||
public const string FillCompsDetail =
|
||||
"The @fillcomps command assists in the bulk purchase of spell components. It is the sole interface for filling the buy list, which is the column of red zeros to the right in your components panel. To designate which components you would like to buy, change the zeros to the number of each component you would like to buy. The types of components you can buy are scarabs, herbs, powders, potions, and talismans.\n\nThis is the proper syntax: @fillcomps <component type> <pyreal value>\n\n@fillcomps - Fills the buy list with all of the components that are desired.\n@fillcomps <component type> - Fills the buy list with all of the components of the given type.\n@fillcomps <pyreal value> - Fills the buy list with all of the components until the total price of the components exceeds the given value.\n@fillcomps <component type> <pyreal value> - Fills the buy list with all of the components of the given type until the total price of components exceeds the given value.\n@fillcomps clear - Sets the requested amount for all components to zero.\n";
|
||||
|
||||
public const string EnduranceDetail =
|
||||
"The endurance attribute has a number of abilities tied to it.\nFirst, some combination of strength and endurance (with endurance being more important) now allows one to regenerate hit points at a faster rate the higher one's endurance is. This bonus is in addition to any regeneration spells one may have placed upon themselves. This endurance regeneration bonus caps at around 110%.\nSecond, the higher a player's Endurance, the less stamina one uses while attacking. This benefit is tied to Endurance only, and it caps out at around 50% less stamina used per attack. The minimum stamina used per attack remains one.\nThird, the higher a player's Endurance, the more likely they are not to use a point of stamina to successfully evade a missile or melee attack. A player is required to have Melee Defense for melee attacks or Missile Defense for missile attacks trained or specialized in order for this specific ability to work. This benefit is tied to Endurance only, and it caps out at around a 75% chance to avoid losing a point of stamina per successful evasion.\nFourth, some combination of strength and endurance (the two are roughly of equivalent importance) now allows one to partially resist drain and harm attacks, up to a maximum of roughly 50%.\nFifth, some combination of strength and endurance (the two are roughly of equivalent importance) now allows one to have a level of \"natural resistances\" to the 7 damage types, the same as a certain level of life protections. This caps out at a 50% resistance (the equivalent to level 5 life prots) to these damage types. This resistance is not additive to life protections: higher level life protections will overwrite these natural resistances, although life vulns will take these natural resistances into account, if the player does not have a higher level life protection cast upon him.\nThe natural resistances, drain resistances, and regeneration rate info are now visible on the Character Information Panel, in what was once the Burden panel. This panel now displays the above three Endurance benefits, the burden info, as well as information about your age, birth date, and number of deaths.\nThe 5 categories for the endurance benefits are, in order from lowest benefit to highest: Poor, Mediocre, Hardy, Resilient, and Indomitable, with each range of benefits divided up equally amongst the 5 (e.g. Poor describes having anywhere from 1-10% resistance against drain health attacks, etc.).\n";
|
||||
|
||||
public const string SpeakerDetail =
|
||||
"@speaker - No longer used, see @allegiance officer for a similar command.\n";
|
||||
|
||||
public const string TitleDetail =
|
||||
"@title <new title> - Sets the title of the popup chat window.\n";
|
||||
|
||||
public const string ChatToggleDetail =
|
||||
"@chat <on/off> - Sets whether or not you receive normal chat. When set to \"off\", you will no longer receive any spoken speech (normal chat). However, you will still receive tells.\n";
|
||||
|
||||
public const string NoTellDetail =
|
||||
"@notell <on/off> - Sets whether or not you receive @tells. When set to \"on\", you will not receive any tells.\n";
|
||||
|
||||
public const string JoinChatDetail =
|
||||
"@join <channel tag> - Allows you to hear and speak on the given channel.\n";
|
||||
|
||||
public const string LeaveChatDetail =
|
||||
"@leave <channel tag> - Prevents you from hearing or speaking on the given channel.\n";
|
||||
|
||||
public const string PermitDetail =
|
||||
"The @permit command gives or revokes corpse-looting permissions to other players. You can permit other players to loot any one of your corpses. You may not @permit a player again until he or she has looted your corpse. Permissions expire either after one hour or when the permitted player logs off. If you were killed by a player killer, no one can loot your corpse except you or your killer, even if you give someone else permission.\n@permit add <name> - Allows another player to loot your corpse.\n@permit remove <name> - Removes permission to access your corpse from the named character.\nType @help consent for more details on corpse looting.\n";
|
||||
|
||||
public const string HslistDetail =
|
||||
"@hslist <house type> - Lists the number and, if appropriate, positions of houses currently available for purchase. Types include: Apartment, Cottage, Villa, Mansion\n";
|
||||
|
||||
private static readonly FrozenDictionary<string, string> CatalogVerbDetailByVerb =
|
||||
new Dictionary<string, string>(StringComparer.OrdinalIgnoreCase)
|
||||
{
|
||||
["lifestone"] = LifestoneDetail,
|
||||
["lif"] = LifestoneDetail,
|
||||
["ls"] = LifestoneDetail,
|
||||
["marketplace"] = MarketplaceDetail,
|
||||
["mar"] = MarketplaceDetail,
|
||||
["mp"] = MarketplaceDetail,
|
||||
["pkarena"] = PkArenaDetail,
|
||||
["pka"] = PkArenaDetail,
|
||||
["pklarena"] = PkLiteArenaDetail,
|
||||
["pla"] = PkLiteArenaDetail,
|
||||
["pklite"] = PkLiteDetail,
|
||||
["pkl"] = PkLiteDetail,
|
||||
// hor/hr/hom/hoa share HelpHouse with "house"/"hou" — see the
|
||||
// CmdHashData note in the class remarks above.
|
||||
["hor"] = HouseOverview,
|
||||
["hr"] = HouseOverview,
|
||||
["hom"] = HouseOverview,
|
||||
["hoa"] = HouseOverview,
|
||||
["age"] = AgeDetail,
|
||||
["birth"] = BirthDetail,
|
||||
["framerate"] = FrameRateDetail,
|
||||
["lockui"] = LockUiDetail,
|
||||
["version"] = VersionDetail,
|
||||
["loc"] = LocDetail,
|
||||
["corpse"] = CorpseDetail,
|
||||
["cor"] = CorpseDetail,
|
||||
["die"] = DieDetail,
|
||||
["clear"] = ClearDetail,
|
||||
["saveui"] = SaveUiDetail,
|
||||
["loadui"] = LoadUiDetail,
|
||||
["saveautoui"] = SaveAutoUiDetail,
|
||||
["loadautoui"] = LoadAutoUiDetail,
|
||||
["afk"] = AfkDetail,
|
||||
["consent"] = ConsentDetail,
|
||||
["e"] = EmoteDetail,
|
||||
["em"] = EmoteDetail,
|
||||
["emote"] = EmoteDetail,
|
||||
["me"] = EmoteDetail,
|
||||
["emotes"] = EmoteListDetail,
|
||||
// friends/friends_add/friends_remove share HelpFriends — see the
|
||||
// CmdHashData note in the class remarks above.
|
||||
["friends"] = FriendsDetail,
|
||||
["friends_add"] = FriendsDetail,
|
||||
["friends_remove"] = FriendsDetail,
|
||||
// squelch/unsquelch share HelpSquelch (and its own concatenated
|
||||
// HelpAdvancedSquelch/HelpAdvancedUnSquelch delegation) — see
|
||||
// the CmdHashData note in the class remarks above.
|
||||
["squelch"] = SquelchDetail,
|
||||
["unsquelch"] = SquelchDetail,
|
||||
["filter"] = FilterDetail,
|
||||
["unfilter"] = UnfilterDetail,
|
||||
// messagetypes/message_types/msgtypes/msg_types intentionally
|
||||
// absent — HelpMessageTypes builds its text from a live enum
|
||||
// table at runtime (GetListofSquelchChannels), not a static
|
||||
// string; see the class remarks above.
|
||||
["fillcomps"] = FillCompsDetail,
|
||||
["endurance"] = EnduranceDetail,
|
||||
["speaker"] = SpeakerDetail,
|
||||
["title"] = TitleDetail,
|
||||
["chat"] = ChatToggleDetail,
|
||||
["notell"] = NoTellDetail,
|
||||
["join"] = JoinChatDetail,
|
||||
["leave"] = LeaveChatDetail,
|
||||
["permit"] = PermitDetail,
|
||||
["hslist"] = HslistDetail,
|
||||
// alh/ah share HelpAllegiance with "allegiance"/"all" — see the
|
||||
// CmdHashData note in the class remarks above.
|
||||
["alh"] = AllegianceOverview,
|
||||
["ah"] = AllegianceOverview,
|
||||
}.ToFrozenDictionary(StringComparer.OrdinalIgnoreCase);
|
||||
|
||||
/// <summary>
|
||||
/// Retail-registered catalog leaf verbs confirmed (via the CmdHashData
|
||||
/// help-pointer note in the class remarks above) to register with a
|
||||
/// NULL help function pointer. Retail's own <c>DoHelp</c> skips its
|
||||
/// help-callback branch entirely for these and falls straight to the
|
||||
/// generic <see cref="UnknownCommand"/> text — the SAME text an
|
||||
/// unregistered verb gets — even though the verb dispatches normally
|
||||
/// for ordinary (non-help) use. <c>ChatCommandRouter</c> must check
|
||||
/// this BEFORE consulting either <see cref="CatalogVerbDetailByVerb"/>
|
||||
/// or the catalog's own summary, or it would show acdream-invented
|
||||
/// help text retail never displays.
|
||||
/// </summary>
|
||||
public static readonly FrozenSet<string> CatalogVerbsWithNoRetailHelp =
|
||||
new HashSet<string>(StringComparer.OrdinalIgnoreCase) { "index", "clist", "on", "off" }
|
||||
.ToFrozenSet(StringComparer.OrdinalIgnoreCase);
|
||||
|
||||
/// <summary>
|
||||
/// Retail Detail_HelpType(2) text for a <see cref="RetailClientCommandCatalog"/>
|
||||
/// leaf verb — see the class remarks' "Catalog leaf-verb Detail
|
||||
/// extraction" section for the recovery method and coverage count.
|
||||
/// Callers should check <see cref="CatalogVerbsWithNoRetailHelp"/>
|
||||
/// FIRST (a confirmed-null verb must never reach this lookup, since a
|
||||
/// stale entry here would silently show text retail never displays for
|
||||
/// it), then this method, then fall back to
|
||||
/// <see cref="RetailClientCommandCatalog.TryGetHelpText"/> for the
|
||||
/// verbs not yet extracted.
|
||||
/// </summary>
|
||||
public static bool TryGetCatalogVerbDetailText(string verb, out string detailText) =>
|
||||
CatalogVerbDetailByVerb.TryGetValue(verb.TrimEnd(','), out detailText!);
|
||||
|
||||
private static readonly FrozenDictionary<string, string> ByVerb =
|
||||
new Dictionary<string, string>(StringComparer.OrdinalIgnoreCase)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue