Skip to content

Commit 5fc13df

Browse files
adjust help system
1 parent 82bd0ef commit 5fc13df

4 files changed

Lines changed: 646 additions & 602 deletions

File tree

Code/MethodSystem/MethodIndex.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ namespace SER.Code.MethodSystem;
1010

1111
public static class MethodIndex
1212
{
13-
private static readonly Dictionary<string, Method> NameToMethodIndex = [];
13+
public static readonly Dictionary<string, Method> NameToMethodIndex = [];
1414
private static readonly Dictionary<FrameworkBridge.Type, List<Method>> FrameworkDependentMethods = [];
1515

1616
/// <summary>

Code/Plugin/Commands/HelpSystem/DocsCommand.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
using System.Text;
22
using CommandSystem;
3+
using JetBrains.Annotations;
34
using LabApi.Features.Permissions;
45
using SER.Code.Exceptions;
56
using SER.Code.Plugin.Commands.Interfaces;
@@ -8,6 +9,7 @@ namespace SER.Code.Plugin.Commands.HelpSystem;
89

910
[CommandHandler(typeof(GameConsoleCommandHandler))]
1011
[CommandHandler(typeof(RemoteAdminCommandHandler))]
12+
[UsedImplicitly]
1113
public class DocsCommand : ICommand, IUsePermissions
1214
{
1315
public bool Execute(ArraySegment<string> arguments, ICommandSender sender, out string response)
@@ -23,7 +25,7 @@ public bool Execute(ArraySegment<string> arguments, ICommandSender sender, out s
2325
var helpOptions = Enum.GetValues(typeof(HelpOption)).Cast<HelpOption>();
2426
foreach (var helpOption in helpOptions)
2527
{
26-
if (!HelpCommand.GeneralOptions.TryGetValue(helpOption, out var generalOption))
28+
if (!DocsProvider.GeneralOptions.TryGetValue(helpOption, out var generalOption))
2729
{
2830
throw new AndrzejFuckedUpException(
2931
$"Option {helpOption} is not registered in the help command.");

0 commit comments

Comments
 (0)