Post to bot channel when starting
parent
3633581b61
commit
e678c9e1e3
|
@ -8,6 +8,7 @@ config = configparser.ConfigParser()
|
||||||
config.read("/srv/discord-pocketbot/config.cfg")
|
config.read("/srv/discord-pocketbot/config.cfg")
|
||||||
|
|
||||||
token = config.get("configuration", "token")
|
token = config.get("configuration", "token")
|
||||||
|
bot_channel_id = discord.Object(id=config.get("configuration", "bot_channel_id"))
|
||||||
|
|
||||||
client = discord.Client()
|
client = discord.Client()
|
||||||
|
|
||||||
|
@ -18,6 +19,7 @@ def on_ready():
|
||||||
print(client.user.name)
|
print(client.user.name)
|
||||||
print(client.user.id)
|
print(client.user.id)
|
||||||
print('------')
|
print('------')
|
||||||
|
yield from client.send_message(bot_channel_id, "This isn't Tatooine...")
|
||||||
|
|
||||||
@client.event
|
@client.event
|
||||||
@asyncio.coroutine
|
@asyncio.coroutine
|
||||||
|
|
Loading…
Reference in New Issue