Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improved status command #119

Closed
wants to merge 13 commits into from
Closed

Improved status command #119

wants to merge 13 commits into from

Conversation

CleverSource
Copy link

@CleverSource CleverSource commented Jan 10, 2019

The configuration variable name is kind of weird, no clue if that should be changed. I don't know if I used self.bot.config.get() correct either but based on the code it takes in 2 parameters for the configuration variable to get, and if that configuration variable isn't set it picks a default or the 2nd parameter. This pull request closes #87 and closes #116

Add new configuration variable for "Custom response message for thread creation"
core/config.py Outdated Show resolved Hide resolved
@kyb3r
Copy link
Collaborator

kyb3r commented Jan 10, 2019

Can you increment the bot version and add the changes into the changelog?

@CleverSource
Copy link
Author

Sure thing, I'm going to be working on the ?status command as well for watching, listening, etc.

@kyb3r kyb3r changed the title Allow for "Custom response message for thread creation" Add custom thread creation response and better status command Jan 10, 2019
@kyb3r
Copy link
Collaborator

kyb3r commented Jan 10, 2019

I just realized, we should increment the MINOR version when adding backward-compatible functionality. So can you change the version to 2.1.0

@kyb3r
Copy link
Collaborator

kyb3r commented Jan 10, 2019

You may need to store status_type in the config as well so when the bot starts it will set the correct status type. (on_connect in bot.py)

@ghost
Copy link

ghost commented Jan 10, 2019

Can push now.

@kyb3r
Copy link
Collaborator

kyb3r commented Jan 10, 2019

I don't think in its current state the status command will work.

@CleverSource
Copy link
Author

I'm not fond of the new discord rewrite, I completely broke the status command and haven't really debugged how to fix it.

Copy link
Collaborator

@fourjr fourjr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Status command does not work.

Refer below:

# Setting `Playing ` status
await bot.change_presence(activity=discord.Game(name="a game"))

# Setting `Streaming ` status
await bot.change_presence(activity=discord.Streaming(name="My Stream", url=my_twitch_url))

# Setting `Listening ` status
await bot.change_presence(activity=discord.Activity(type=discord.ActivityType.listening, name="a song"))

# Setting `Watching ` status
await bot.change_presence(activity=discord.Activity(type=discord.ActivityType.watching, name="a movie"))

ActivityType enum: https://github.com/Rapptz/discord.py/blob/rewrite/discord/enums.py#L216-L221
Activity class: https://github.com/Rapptz/discord.py/blob/rewrite/discord/activity.py#L80-L128

@@ -270,18 +270,20 @@ def format_not_found(self, ctx, command):

@commands.command(name='status', aliases=['customstatus', 'presence'])
@commands.has_permissions(administrator=True)
async def _status(self, ctx, *, message):
async def _status(self, ctx, *, statusType, message):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use snake_case

@kyb3r kyb3r changed the title Add custom thread creation response and better status command Improved status command Jan 12, 2019
@kyb3r
Copy link
Collaborator

kyb3r commented Jan 12, 2019

I added the custom thread creation message in #124

@kyb3r
Copy link
Collaborator

kyb3r commented Jan 13, 2019

Closing due to author not being able to finish the PR

@kyb3r kyb3r closed this Jan 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support multiple bot presence activities Custom response message for thread creation
3 participants