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

Fix volume not being set to zero #12

Merged
merged 2 commits into from
Feb 21, 2022
Merged

Conversation

mooner1022
Copy link
Contributor

The library throws an error when setting the volume to zero, and found out that the negative part of the volume sanity check does not include zero. I'm not sure this is an intended part of the operation, but when I updated the code and set the volume to zero, it worked properly without any error.

@DRSchlaubi
Copy link
Member

The volume command is deprecated anyways, did I forget updating that? You should use applyFilters for that, could you update it there as well?

@mooner1022
Copy link
Contributor Author

I've marked the setVolume() method as deprecated, but the volume parameter on the play command, being sent by playTrack() method, also prints deprecated log on lavalink. Should I update here to unuse the volume parameter as well?

@DRSchlaubi
Copy link
Member

yes

Update player to use filters on controlling volume
@mooner1022
Copy link
Contributor Author

Updated WebsocketPlayer to use filters.volume on getter/setter of the volume, please check if I've done it right.

@DRSchlaubi DRSchlaubi merged commit dc9fdd4 into kordlib:main Feb 21, 2022
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

Successfully merging this pull request may close these issues.

2 participants