Compare commits

..

2 Commits

Author SHA1 Message Date
jmjl d0cb0dffa0 Bump pinhook to 1.10 2023-06-26 15:28:18 +00:00
jmjl fcf69686bf Remove a plugin and modify the bot's help. 2023-06-26 15:28:01 +00:00
3 changed files with 2 additions and 32 deletions

View File

@ -1,30 +0,0 @@
import math
import json
import time
from pinhook import plugin as p
with open('emojis.json', 'r', encoding='utf-8') as e:
emojis = json.load(e)
emojis = sorted(emojis.items(), key=lambda x: x[0])
emoji_list = {}
c = 0
for k,v in emojis:
emoji_list[str(c)] = v
c += 1
@p.command('&emojitime')
def emojitime(msg):
e_len = len(emoji_list)
now = int(time.time() * 100)
s = math.floor(now % e_len)
s = emoji_list[str(s)]
m = math.floor((now % e_len**2)/e_len)
m = emoji_list[str(m)]
h = math.floor((now % e_len**3)/e_len**2)
h = emoji_list[str(h)]
return p.message(u':'.join([h,m,s]))

View File

@ -4,5 +4,5 @@ from pinhook import plugin as p
@p.command('!rollcall', help_text="The rollcall command to introduce the bot to newcomers") @p.command('!rollcall', help_text="The rollcall command to introduce the bot to newcomers")
@p.command('&ju', help_text="&ju so people can get infor for this bot specificaly") @p.command('&ju', help_text="&ju so people can get infor for this bot specificaly")
def rollcall(msg): def rollcall(msg):
out = "Beep boop, i'm a bot from jmjl. I currently can show you the date join and leave channels, if you need more, be sure to make a pr on git~town/jmjl/juju. I also have current music but that's broken. -|- News: I'm doing !tilde now as krowbar's bot's offline." out = "Beep boop, i'm a bot from jmjl. If you'd like the command list run &help."
return p.message(out) return p.message(out)

View File

@ -4,7 +4,7 @@ emoji~=0.4.5
geopy~=1.11.0 geopy~=1.11.0
markovify~=0.7.1 markovify~=0.7.1
nltk>~3.4.5 nltk>~3.4.5
pinhook~=1.5 pinhook~=1.10
python-forecastio~=1.3.5 python-forecastio~=1.3.5
requests>~2.20.0 requests>~2.20.0
tvdb-api~=1.10 tvdb-api~=1.10