Filters
Hi everyone,
I’m currently trying to understand the documentation and implement a filter command. However, I’m finding it quite challenging and could use some help. I’ve tried searching for posts about it but haven’t found anything useful yet.
I’m not very familiar with how filters work and other related concepts. Any assistance or resources would be greatly appreciated. Thanks!
23 Replies
Hello everything is fine?
equal-aquaOP•2y ago
yes can u help me?
Yes, I just wanted to understand your question better.
Like, do you want to understand the parameters inside the filters?
equal-aquaOP•2y ago
no i don't currently
and i don't know how to apply the filters also
To access the filters, go to the player
<moonlink>.players.get('id').filters
equal-aquaOP•2y ago
ok then what are the parameters i need
player.filters() right
Almost
filters and a class
It has several parameters for different filters you want to apply
equal-aquaOP•2y ago
i tried one of them which would be tremolo so player.filters("tremolo")
GG @Quantum, you just advanced to level 1!
equal-aquaOP•2y ago
Im sorry if im like dumb or something but its just the filters im having a problem till now siince i dont really understand the docs
player.filters.setVolume(number)
player.filters.setTremolo(object)
equal-aquaOP•2y ago
ahhhhhh
thats way more clear thank you so much
You're welcome, if you have any other questions, you can come here and I'll be happy to clarify your doubts.
equal-aquaOP•2y ago
hey again so i think i applied the filter correctly but i get this
\node_modules\moonlink.js\dist\src@Rest\MoonlinkFilters.js:136
await this.rest.update(dataToUpdate);
^
TypeError: Cannot read properties of undefined (reading 'update')
at MoonlinkFilters.updateFiltersFromRest (C:\Users\Administrator\Documents\GitHub\Vibrancy\node_modules\moonlink.js\dist\src@Rest\MoonlinkFilters.js:136:25)
at MoonlinkFilters.setTremolo (C:\Users\Administrator\Documents\GitHub\Vibrancy\node_modules\moonlink.js\dist\src@Rest\MoonlinkFilters.js:62:14)
at Object.execute (C:\Users\Administrator\Documents\GitHub\Vibrancy\commands\music\filters.js:19:24)
at Object.execute (C:\Users\Administrator\Documents\GitHub\Vibrancy\events\interactionCreate.js:16:18)
at Client.<anonymous> (C:\Users\Administrator\Documents\GitHub\Vibrancy\index.js:76:46)
at Client.emit (node:events:517:28)
at InteractionCreateAction.handle (C:\Users\Administrator\Documents\GitHub\Vibrancy\node_modules\discord.js\src\client\actions\InteractionCreate.js:97:12)
at module.exports [as INTERACTION_CREATE] (C:\Users\Administrator\Documents\GitHub\Vibrancy\node_modules\discord.js\src\client\websocket\handlers\INTERACTION_CREATE.js:4:36)
at WebSocketManager.handlePacket (C:\Users\Administrator\Documents\GitHub\Vibrancy\node_modules\discord.js\src\client\websocket\WebSocketManager.js:355:31)
at WebSocketManager.<anonymous> (C:\Users\Administrator\Documents\GitHub\Vibrancy\node_modules\discord.js\src\client\websocket\WebSocketManager.js:239:12)
Node.js v18.18.1
i applied it like this
player.filters.setTremolo({
frequency: 10,
depth: 0.5
});
I'll check the package I may not have updated something
As soon as I get my lavalink
equal-aquaOP•2y ago
Alright thanks
One question is the player playing?
equal-aquaOP•2y ago
yes it is
The new update fixes this issue
Hope it helps you, have a great day
equal-aquaOP•2y ago
So i dont get any moonlink problem anymore but i get a lavalink error instead
so its playing the song i use the filters command and the song gets that error ig and tries to play another since i have autoplay on
equal-aquaOP•2y ago
equal-aquaOP•2y ago
im using the latest lavalink version 4.0.0-beta.4
Thank you very much for reporting, yesterday I couldn't look properly
But it probably must be an error in lavalink
I will analyze further
As soon as I can see if the problem is in the package or in lavalink I will let you know.
java.lang.IllegalArgumentException: Volume > 5.0
I'll see if that's it