|
@@ -1,4 +1,5 @@
|
|
|
import logging
|
|
|
+import random
|
|
|
from functools import wraps
|
|
|
|
|
|
import requests
|
|
@@ -23,8 +24,8 @@ def with_error_handle(f):
|
|
|
def fmt_list(nicks):
|
|
|
if len(nicks) == 0:
|
|
|
return "No one in teamspeak!"
|
|
|
- if len(nicks) == 1:
|
|
|
- return "Only " + nicks[0]
|
|
|
+ if len(nicks):
|
|
|
+ return ("Only " if random.randint(0, 1) == 0 else "Oops all ") + nicks[0]
|
|
|
return "I see the following people: " + ", ".join(nicks)
|
|
|
|
|
|
|
|
@@ -34,6 +35,7 @@ def teamspeak():
|
|
|
nicks = requests.get(TS3_QUERY).json()["users"]
|
|
|
return fmt_list(nicks)
|
|
|
|
|
|
+
|
|
|
@as_plugin
|
|
|
@with_error_handle
|
|
|
def teemspeem():
|
|
@@ -43,6 +45,7 @@ def teemspeem():
|
|
|
fmtd = fmtd.replace(v, "e").replace(v.upper(), "E")
|
|
|
return fmtd.replace("k", "m").replace("K", "M")
|
|
|
|
|
|
+
|
|
|
@as_plugin
|
|
|
@with_error_handle
|
|
|
def speamteek():
|