-
Notifications
You must be signed in to change notification settings - Fork 7
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
Handle discord commands like laravel commands #10
Comments
I'd be very interested to see that implementation. Anything that can appropriately/efficiently "laravel-ize" things in this package are welcome. |
Am I allowed to bump the php version to at least 8.1? |
if it's absolutely necessary, sure. however there is a small percentage of installs of this package on 7.4, so ideally it still supports that far back (despite being EOL, we all know how PHP upgrades in the wild usually go 😂 ) |
It turns out I don't have that much time right now. I tinkered around with an extension but it would require some changes in your codebase. Namely it lacks the ability to send responses directly from a command (https://discord.com/developers/docs/interactions/receiving-and-responding#edit-original-interaction-response). class MyCommand extends SlashCommand {
protected string $name = 'MyName';
protected string $description = 'MyDescription';
public function handle(): void {
doSomething();
// Until now it would show the loading bar as the whole command gets pushed to the queue
$this->sendResponse(new Message('content', $embeds, $components));
$this->sendFollowUp(new Message('content'));
}
} |
Hello,
I started to work on a discord bot after I found your package lacking too much functionality. However, after the 1.0.0 update I am blown away by the functionality it offers right now. Great work!
I would like to extend the package to have Commands which look like Laravel's artisan commands.
Would you be willing to merge such a PR?
Thank you in advance.
The text was updated successfully, but these errors were encountered: