mirror of
https://github.com/evennia/evennia.git
synced 2026-04-04 06:57:16 +02:00
Moving some of the login tasks out of sessions.py and into the BasicPlayer script parent. Also, added seconds to the 'time' command, which I apparently forgot.
This commit is contained in:
parent
b12ba45cc7
commit
cf18029be1
7 changed files with 69 additions and 23 deletions
|
|
@ -198,6 +198,15 @@ def get_cwho_list(channel_name, return_muted=False):
|
|||
"""
|
||||
sess_list = session_mgr.get_session_list()
|
||||
return [sess for sess in sess_list if plr_has_channel(sess, channel_name, return_muted)]
|
||||
|
||||
def load_object_channels(pobject):
|
||||
"""
|
||||
Parse JSON dict of a user's channel list from their CHANLIST attribute.
|
||||
"""
|
||||
chan_list = pobject.get_attribute_value("__CHANLIST")
|
||||
if chan_list:
|
||||
session = session_mgr.session_from_object(pobject)
|
||||
session.channels_subscribed = simplejson.loads(chan_list)
|
||||
|
||||
def send_cmessage(channel_name, message):
|
||||
"""
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue