get rid of the MessageDistributor module... & update discord, to work with API v10
Added discord commands (issue: as they're running over the event hub, they're processed on the same track as other events. => activity ingame triggers the next run; otherwise there's some delay for responses) relay is a standard module now.
This commit is contained in:
@@ -39,11 +39,11 @@ class OnlineDisplay:
|
||||
if org > 0:
|
||||
postfix.append(f"<notice>Org: {org}</notice>")
|
||||
if priv > 0:
|
||||
postfix.append(f"<highlight>Priv: {priv}</notice>")
|
||||
postfix.append(f"<notice>Priv: {priv}</notice>")
|
||||
if notify > 0:
|
||||
postfix.append(f"<notice>Buddylist: {notify}</notice>")
|
||||
blob = ChatBlob(title, blob, suffix=f" ({f', '.join(postfix)})")
|
||||
return blob
|
||||
return blob if (org+priv+notify) != 0 else "There's nobody online."
|
||||
|
||||
def format_by_channel_main(self, query, params):
|
||||
query += "order by channel_id, main_name, p.name=main_name, p.name, r_id"
|
||||
@@ -161,7 +161,7 @@ class OnlineDisplay:
|
||||
if org_id != temp_blob[key]["id"]:
|
||||
org_id = temp_blob[key]["id"]
|
||||
blob += f"\n<pagebreak><highlight>{temp_blob[key]['name']}</highlight>" \
|
||||
f"<header> ({len(temp_blob[key]['online']): >3} " \
|
||||
f" <header>({len(temp_blob[key]['online']): >3} " \
|
||||
f"| {len(temp_blob[key]['online']) / len(query) * 100:.2f}%)</header>\n"
|
||||
blob += self.format_org(user)
|
||||
return blob, 0, 0, len(query)
|
||||
|
||||
Reference in New Issue
Block a user