Is there a way to combine the framework with my own decorator system?
22 Replies
No shot we actually got someone with the april fools name of the server :omegalul:
Anyway, no there is not. DiscordJS is the only API library we support. Unless I misunderstand what you mean with "system" here
I didnt fall for it, i just wanted to mess with others too
i was working on my decorators
and im trying to get
Command.LoaderContext
this is the command

dont worryu about the "target.prototype"

im trying to figure out how to pass the the context
when thedecorator is used

same with Listener.LoaderContext
GitHub
Kuramisa/src/classes at sapphire · Kuramisa/Kuramisa
Contribute to Kuramisa/Kuramisa development by creating an account on GitHub.
reference
for the classes
If you have any ideas pls @ me, if you dont mind telling me in short when and how does the LoaderContext works, like when it gets passed, is it static, how it works somewhat. you can send me links to the sources, cuz i cant find them properly. i can incorporate it myself if i understand it.
Alright
everything works besides one t hing
For some reason ApplicationCommandRegistry always thinks that there are differences inin the command versus api data
Which causes my bot to hit the ratelimit

and context menus broke too

the problem is that, i also can't pass the builder cuz it gives me errors upon registering the commands

These are the errors

but yeah pls @ me if u have any answers, thank you :3
Anyone?🥺
You can see that we can access the constructor parameters just fine here: https://github.com/sapphiredev/utilities/blob/main/packages/decorators/src/piece-decorators.ts
GitHub
utilities/packages/decorators/src/piece-decorators.ts at main · sa...
Common JavaScript utilities for your TypeScript projects - sapphiredev/utilities
Thats not the problem anymore, i can access them and it works perfectly, but theres a problem of command miscomparison where, passing the builders where i showed above doesnt give commands correct names on the context menus and it g ivecs me the errors i mentiond above
https://discord.com/channels/737141877803057244/759750007087431721/1353374650377175040
No offense, but looking at your code and the code from the sapphire decorator for ApplyOptions, literally both yours and ApplyOptions do the same thing, so I don't see the point of all this
@SlashCommands({})
- creates a constructor based on the options you put in
@ApplyOptions({})
- also creates a constructor based on the options you put in
It's just that your "framework" automatically registers the commands as far as I can see while sapphire gives us the control for thatNo offense taken, but thats not what i asked
Yes, but I don't think anyone can understand what you're trying to do, you're using the
@sapphire/framework
package on your "framework" as far as I understand and you're trying to make it work as you see fit
I don't understand how anyone can help you in the sapphire support channel for your own framework...Im not making my own framework, im using sapphire to integrate my own decorators to sapphire itself
I provided screenshots where it shows the errors and how i register the commands
Its mistakengly says that there are differences between commands versua api data where its not and then spams the API causing me to hit ratelimit
Closing this in favour of #Command comparison bevwuse theres no need to have 2 threads.
thats fine