Add prefix-ignorer. This will identify allow users to target a command using both cmd, @cmd, +cmd etc. If there are two different commands @cmd and cmd, entering @cmd will still explicitly target the former. Single-character commands consisting of only an ignore-character will not be ignored. Configure and turn off using settings.CMD_PREFIX_IGNORE.

This commit is contained in:
Griatch 2016-12-20 22:11:58 +01:00
parent 1b3fb8fca9
commit 596efe4c72
2 changed files with 58 additions and 24 deletions

View file

@ -279,6 +279,13 @@ SEARCH_MULTIMATCH_TEMPLATE = " {number}-{name}{aliases}{info}\n"
# both for command- and object-searches. This allows full control
# over the error output (it uses SEARCH_MULTIMATCH_TEMPLATE by default).
SEARCH_AT_RESULT = "evennia.utils.utils.at_search_result"
# Single characters to ignore at the beginning of a command. When set, e.g.
# cmd, @cmd and +cmd will all find a command "cmd" or one named "@cmd". If
# you have defined two different commands cmd and @cmd you can still enter
# @cmd to exactly target the second one. Single-character commands consisting
# of only a prefix character will not be stripped. Set to the empty
# string ("") to turn off prefix ignore.
CMD_IGNORE_PREFIXES = "@&/+"
# The module holding text strings for the connection screen.
# This module should contain one or more variables
# with strings defining the look of the screen.