Table of Contents

Method RegisterCommands

Namespace
DSharpPlus.SlashCommands
Assembly
DSharpPlus.SlashCommands.dll

RegisterCommands<T>(ulong?)

Registers a command class.

public void RegisterCommands<T>(ulong? guildId = null) where T : ApplicationCommandModule

Parameters

guildId ulong?

The guild id to register it on. If you want global commands, leave it null.

Type Parameters

T

The command class to register.

RegisterCommands(Type, ulong?)

Registers a command class.

public void RegisterCommands(Type type, ulong? guildId = null)

Parameters

type Type

The Type of the command class to register.

guildId ulong?

The guild id to register it on. If you want global commands, leave it null.

RegisterCommands(Assembly, ulong?)

Registers all command classes from a given assembly.

public void RegisterCommands(Assembly assembly, ulong? guildId = null)

Parameters

assembly Assembly

Assembly to register command classes from.

guildId ulong?

The guild id to register it on. If you want global commands, leave it null.