Put in check for maximum character size in input strings that can be set with settings.MAX_CHAR_LIMIT.

This commit is contained in:
Tehom 2016-12-13 06:53:35 -05:00
parent 619a9cee57
commit 760c5b41fc
2 changed files with 18 additions and 1 deletions

View file

@ -201,6 +201,14 @@ MAX_CONNECTION_RATE = 2
MAX_COMMAND_RATE = 80
# The warning to echo back to users if they send commands too fast
COMMAND_RATE_WARNING ="You entered commands too fast. Wait a moment and try again."
# Determine how large of a string can be sent to the server in number
# of characters. If they attempt to enter a string over this character
# limit, we stop them and send a message. Set to None by default. To
# change it, just set it to a number of characters - ie, 6000 to be
# roughly two pages of text.
MAX_CHAR_LIMIT = None
# The warning to echo back to users if they enter a very large string
MAX_CHAR_LIMIT_WARNING="You entered a string that was too large. Please break it up into separate commands."
# If this is true, errors and tracebacks from the engine will be
# echoed as text in-game as well as to the log. This can speed up
# debugging. Showing full tracebacks to regular users could be a