Skip to content

Instantly share code, notes, and snippets.

@NathanDai5287
Created January 5, 2024 17:47
Show Gist options
  • Save NathanDai5287/21d15ddffbb0fcb11a42cce6a03305e1 to your computer and use it in GitHub Desktop.
Save NathanDai5287/21d15ddffbb0fcb11a42cce6a03305e1 to your computer and use it in GitHub Desktop.
Increment the Volume by Cube Root 2
#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