Addition of a re-usable CommandTable class. We still have two global command tables that are now instances of this class. Game developers will use methods on CommandTable to add their own commands without modifying the base server code.

This is also in preparation of allowing commands to be present on objects via their script parents.
This commit is contained in:
Greg Taylor 2008-12-14 01:49:37 +00:00
parent d38f2bd2f8
commit 37d66093cc
3 changed files with 116 additions and 76 deletions

View file

@ -15,6 +15,14 @@ def log_errmsg(errormsg):
"""
log.err('ERROR: %s' % (errormsg,))
def log_warnmsg(warnmsg):
"""
Prints/logs any warnings that aren't critical but should be noted.
warnmsg: (string) The message to be logged.
"""
log.msg('WARNING: %s' % (warnmsg,))
def log_infomsg(infomsg):
"""
Prints any generic debugging/informative info that should appear in the log.