Table of Contents

Class CommandAttribute

Namespace
BSGameLib.Chat.Attributes
Assembly
BSGameLib.Chat.dll

Marks a class that implements ICommand as a command. The keywords are what a player types to run it.

[AttributeUsage(AttributeTargets.Class, AllowMultiple = false)]
public class CommandAttribute : Attribute
Inheritance
CommandAttribute
Derived
Inherited Members

Constructors

CommandAttribute(string, params string[])

Creates the attribute for a command named name, typed with keywords.

public CommandAttribute(string name, params string[] keywords)

Parameters

name string
keywords string[]

Properties

HelpText

The help text shown for the command.

public string HelpText { get; set; }

Property Value

string

Keywords

The words a player types to run the command, matched ignoring case.

public IEnumerable<string> Keywords { get; }

Property Value

IEnumerable<string>

Name

The command's name, a label for code and help. It is typed only if it is also a keyword.

public string Name { get; }

Property Value

string