mirror of
https://github.com/evennia/evennia.git
synced 2026-03-26 01:36:32 +01:00
Some cleanup. Fixed all examples to match the changes in the states and help systems, also
ran them through pylint to pretty them up. /Griatch
This commit is contained in:
parent
8074617285
commit
84aeabb272
11 changed files with 323 additions and 211 deletions
|
|
@ -383,7 +383,7 @@ def handle(command, ignore_state=False):
|
|||
state_cmd_table = statetable.GLOBAL_STATE_TABLE.get_cmd_table(state)
|
||||
|
||||
if state and state_cmd_table and not ignore_state:
|
||||
# Caller is in a special state.
|
||||
# Caller is in a special state.
|
||||
|
||||
state_allow_exits, state_allow_obj_cmds = \
|
||||
statetable.GLOBAL_STATE_TABLE.get_exec_rights(state)
|
||||
|
|
|
|||
|
|
@ -221,10 +221,10 @@ class EditHelp(object):
|
|||
|
||||
# identify markup and do nice formatting as well as eventual
|
||||
# related entries to the help entries.
|
||||
logger.log_infomsg("auto-help in: %s %s %s %s" % (topicstr, category, entrytext, permissions))
|
||||
#logger.log_infomsg("auto-help in: %s %s %s %s" % (topicstr, category, entrytext, permissions))
|
||||
topics = self.format_help_entry(topicstr, category,
|
||||
entrytext, permissions)
|
||||
logger.log_infomsg("auto-help: %s -> %s" % (topicstr,topics))
|
||||
#logger.log_infomsg("auto-help: %s -> %s" % (topicstr,topics))
|
||||
# create the help entries:
|
||||
if topics:
|
||||
for topic in topics:
|
||||
|
|
|
|||
|
|
@ -891,8 +891,7 @@ class Object(models.Model):
|
|||
script_parent: (string) String pythonic import path of the script parent
|
||||
assuming the python path is game/gamesrc/parents.
|
||||
"""
|
||||
if script_parent != None and scripthandler.scriptlink(self,
|
||||
str(script_parent).strip()):
|
||||
if script_parent != None and scripthandler.scriptlink(self, str(script_parent).strip()):
|
||||
#assigning a custom parent
|
||||
self.script_parent = str(script_parent).strip()
|
||||
self.save()
|
||||
|
|
|
|||
|
|
@ -87,7 +87,6 @@ class StateTable(object):
|
|||
special conditions or clean-up operations before allowing a player
|
||||
to exit (e.g. combat states and text editors), in which case this
|
||||
feature should be turned off and handled by custom exit commands.
|
||||
help_command
|
||||
"""
|
||||
|
||||
state_name = state_name.strip()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue