commands package

Submodules

Module contents

Provides server, client, and say command functionality.

class commands.Command

Bases: instance

__init__((object)arg1) None
tokenize((Command)arg1, (str)arg2) bool
property arg_string

Return the argument string for the command (does not include the command itself).

property command_string

Return the entire command string including the command itself.

max_command_length = 511
class commands.CommandReturn

Bases: enum

BLOCK = _commands.CommandReturn.BLOCK
CONTINUE = _commands.CommandReturn.CONTINUE
names = {'BLOCK': _commands.CommandReturn.BLOCK, 'CONTINUE': _commands.CommandReturn.CONTINUE}
values = {0: _commands.CommandReturn.BLOCK, 1: _commands.CommandReturn.CONTINUE}
class commands.ConCommand

Bases: ConCommandBase

__init__()

Raises an exception This class cannot be instantiated from Python

dispatch((ConCommand)arg1, (Command)arg2) None :

Execute the command.

class commands.ConCommandBase

Bases: instance

__init__((object)arg1) None

__init__( (object)arg1, (str)arg2 [, (str)arg3 [, (_engines._sound.Channel)arg4]]) -> None

add_flags((ConCommandBase)arg1, (_engines._sound.Channel)flag) None :

Adds the given flags to the ConVar.

is_command((ConCommandBase)arg1) bool :

Returns whether it’s a command.

is_flag_set((ConCommandBase)arg1, (_engines._sound.Channel)flag) bool :

Returns whether the given flag is set or not.

is_registered((ConCommandBase)arg1) bool :

Returns wheter the ConCommandBase instance is registered.

remove_flags((ConCommandBase)arg1, (_engines._sound.Channel)flag) None :

Removes the given flags from the ConVar.

property dll_identifier

Returns the DLL identifier.

property flags

Returns its flags.

property help_text

Returns the help text.

property name

Returns its name.

property next

Returns the next ConCommandBase instance.

commands.get_command_index() int :

Returns the index of the player that issued the current command.