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

Add serenity's CommandId to slash commands created with poise. To reference it in the help menu #235

Open
asibahi opened this issue Dec 31, 2023 · 1 comment

Comments

@asibahi
Copy link
Contributor

asibahi commented Dec 31, 2023

Discord allows everyone to type command snowflakes, as shown here. Serenity's CommandId type is the COMMAND_ID being used here, as far as I can tell.

Currently in poise when registering commands this info is discarded and not stored in the Framework. So poise's Command objects lacks this info, so I cannot have my commands linked from the help menu.

tl;dr : this would be nice if I could do it automatically from the help menu. Even if just as a cmd.format_for_discord() method on poise::Command.
image

@asibahi asibahi changed the title Add serenity's CommandId to slash_commands created with poise. For ability to reference it in the help menu Add serenity's CommandId to slash commands created with poise. To reference it in the help menu Dec 31, 2023
@jamesbt365
Copy link
Member

The framework is immutable after its setup and the framework setup function doesn't exist on the serenity-next branch anymore as we migrate. Even still, I'm not sure how much can be mutated there, if at all.

Registers on startup are optional, handled by the user, storing the result in the framework may be challenging, but I'm not sure if this is entirely out of scope.

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

No branches or pull requests

2 participants