Created
January 5, 2024 17:47
-
-
Save NathanDai5287/21d15ddffbb0fcb11a42cce6a03305e1 to your computer and use it in GitHub Desktop.
Increment the Volume by Cube Root 2
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#SingleInstance Force | |
round(volume) { | |
if (volume > 42 and volume < 57) { | |
return 50 | |
} else { | |
return volume | |
} | |
} | |
$Volume_Up:: | |
SoundGet, volume | |
Send {Volume_Up} | |
SoundSet, round(volume * (2 ** (1/3))) | |
Return | |
$Volume_Down:: | |
SoundGet, volume | |
Send {Volume_Down} | |
SoundSet, round(volume / (2 ** (1/3))) | |
Return |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment