1
0
Fork 0
mirror of https://github.com/myned/modufur.git synced 2024-12-24 22:27:28 +00:00

Tweaked presence command and added ability to opt out with empty string

This commit is contained in:
Myned 2017-12-01 19:27:42 -05:00
parent 534f8c7b97
commit c4c672d901
2 changed files with 2 additions and 4 deletions

View file

@ -79,7 +79,7 @@ class Bot:
await ctx.send(f'**Game changed to** `{game}`') await ctx.send(f'**Game changed to** `{game}`')
else: else:
await self.bot.change_presence(game=None) await self.bot.change_presence(game=None)
u.config['playing'] = 'None' u.config['playing'] = ''
u.dump(u.config, 'config.json', json=True) u.dump(u.config, 'config.json', json=True)
await ctx.send('**Game changed to** ` `') await ctx.send('**Game changed to** ` `')

View file

@ -77,10 +77,8 @@ async def on_ready():
# bot.loop.create_task(u.clear(booru.temp_urls, 30*60)) # bot.loop.create_task(u.clear(booru.temp_urls, 30*60))
if u.config['playing'] is not 'None': if u.config['playing'] is not '':
await bot.change_presence(game=d.Game(name=u.config['playing'])) await bot.change_presence(game=d.Game(name=u.config['playing']))
else:
await bot.change_presence(game=None)
print('\n> > > > > > > > >\nC O N N E C T E D : {}\n> > > > > > > > >\n'.format(bot.user.name)) print('\n> > > > > > > > >\nC O N N E C T E D : {}\n> > > > > > > > >\n'.format(bot.user.name))
await bot.get_channel(u.config['info_channel']).send('**Started** \N{BLACK SUN WITH RAYS} .') await bot.get_channel(u.config['info_channel']).send('**Started** \N{BLACK SUN WITH RAYS} .')