How can I add my own options to command like permissionLevel?
^
21 Replies
Is it just extending Command class?
OK
Any progress yet?
But then, in
messageCommandError
command parameter is MessageCommand
type
so is there any way I can make it fully type safe right wayCreate a ticket and direct your issues directly to the support team above for adequate guidance and support mate @čamdžić
@Boomeravna not sure what that is but it doesn’t look legit to my eyes
Scam
But I didn't wanted to ping favna
s!ban @MAROW --days=7 scam bot
:greenTick: Created case 174 |
@marow235
.
With the reason of: scam botalways ping staff for scam bots 😉
@Boomeravna any way you could help me this ? ^
1. extend class
1. (optional): add module augmention if you need the properly to be available in command store gets
2. use extended class
3. ??
4. profit
https://github.com/skyra-project/skyra/blob/main/src/lib/structures/commands/SkyraCommand.ts
GitHub
skyra/src/lib/structures/commands/SkyraCommand.ts at main · skyra-...
A multipurpose Discord Bot designed to carry out most of your server's needs with great performance and stability. - skyra-project/skyra
Wdym by this:
(optional): add module augmention if you need the properly to be available in command store gets
If you're adding custom properties to your Client class and you want them to be accessible when accessing the client through something like
this.container.client
you'll have to add module augmentation:
https://gist.github.com/Favna/26ed5b2df82d424203b71b9ffbce85c4
For more information on module augmentation see: https://www.typescriptlang.org/docs/handbook/declaration-merging.htmlyea but what do I augment
Command with my custom command ?
if you dont need it dont worry about it
well I kinda need it
in help command I fetch everything from store
and I check is
hidden
property true
but in store it would still be Command from sapphiredo you even need a help command? slash commands have lots of description space already
I use message commands so yea I need it
:/
ew but ok.
hmm
shouldnt it be Command.Options xd
idk that's on you to specify