Make scripts/objects lists use EvMore. Change EvMore to not justify by default.

This commit is contained in:
Griatch 2020-01-11 15:49:12 +01:00
parent b5aee2c41e
commit 69d85bd184
221 changed files with 2190 additions and 6810 deletions

View file

@ -70,9 +70,7 @@ WEBSERVER_INTERFACES = settings.WEBSERVER_INTERFACES
GUEST_ENABLED = settings.GUEST_ENABLED
# server-channel mappings
WEBSERVER_ENABLED = (
settings.WEBSERVER_ENABLED and WEBSERVER_PORTS and WEBSERVER_INTERFACES
)
WEBSERVER_ENABLED = settings.WEBSERVER_ENABLED and WEBSERVER_PORTS and WEBSERVER_INTERFACES
IRC_ENABLED = settings.IRC_ENABLED
RSS_ENABLED = settings.RSS_ENABLED
GRAPEVINE_ENABLED = settings.GRAPEVINE_ENABLED
@ -126,9 +124,7 @@ def _server_maintenance():
if _MAINTENANCE_COUNT == 1:
# first call after a reload
_GAMETIME_MODULE.SERVER_START_TIME = now
_GAMETIME_MODULE.SERVER_RUNTIME = ServerConfig.objects.conf(
"runtime", default=0.0
)
_GAMETIME_MODULE.SERVER_RUNTIME = ServerConfig.objects.conf("runtime", default=0.0)
else:
_GAMETIME_MODULE.SERVER_RUNTIME += 60.0
# update game time and save it across reloads
@ -267,9 +263,7 @@ class Evennia(object):
)
)
mismatches = [
i
for i, tup in enumerate(settings_compare)
if tup[0] and tup[1] and tup[0] != tup[1]
i for i, tup in enumerate(settings_compare) if tup[0] and tup[1] and tup[0] != tup[1]
]
if len(
mismatches
@ -281,9 +275,7 @@ class Evennia(object):
# from evennia.accounts.models import AccountDB
for i, prev, curr in (
(i, tup[0], tup[1])
for i, tup in enumerate(settings_compare)
if i in mismatches
(i, tup[0], tup[1]) for i, tup in enumerate(settings_compare) if i in mismatches
):
# update the database
INFO_DICT["info"] = (
@ -435,22 +427,13 @@ class Evennia(object):
else:
if mode == "reset":
# like shutdown but don't unset the is_connected flag and don't disconnect sessions
yield [
o.at_server_shutdown() for o in ObjectDB.get_all_cached_instances()
]
yield [
p.at_server_shutdown() for p in AccountDB.get_all_cached_instances()
]
yield [o.at_server_shutdown() for o in ObjectDB.get_all_cached_instances()]
yield [p.at_server_shutdown() for p in AccountDB.get_all_cached_instances()]
if self.amp_protocol:
yield self.sessions.all_sessions_portal_sync()
else: # shutdown
yield [
_SA(p, "is_connected", False)
for p in AccountDB.get_all_cached_instances()
]
yield [
o.at_server_shutdown() for o in ObjectDB.get_all_cached_instances()
]
yield [_SA(p, "is_connected", False) for p in AccountDB.get_all_cached_instances()]
yield [o.at_server_shutdown() for o in ObjectDB.get_all_cached_instances()]
yield [
(p.unpuppet_all(), p.at_server_shutdown())
for p in AccountDB.get_all_cached_instances()
@ -629,8 +612,7 @@ application = service.Application("Evennia")
if "--nodaemon" not in sys.argv:
# custom logging, but only if we are not running in interactive mode
logfile = logger.WeeklyLogFile(
os.path.basename(settings.SERVER_LOG_FILE),
os.path.dirname(settings.SERVER_LOG_FILE),
os.path.basename(settings.SERVER_LOG_FILE), os.path.dirname(settings.SERVER_LOG_FILE)
)
application.setComponent(ILogObserver, logger.ServerLogObserver(logfile).emit)