Another experimental sound change.

This commit is contained in:
Storm Dragon
2025-09-19 00:44:25 -04:00
parent 6daa243710
commit d364ce28ef
3 changed files with 49 additions and 16 deletions

View File

@@ -476,7 +476,9 @@ def x_powerbar():
leftVolume = (50 - position) / 100
rightVolume = (position + 50) / 100
tone = generate_tone(frequency)
channel = tone.play()
from .sound import get_available_channel
channel = get_available_channel()
channel.play(tone)
channel.set_volume(leftVolume, rightVolume)
# Visual representation
@@ -519,7 +521,9 @@ def y_powerbar():
while True:
frequency = 220 + (power * 5) # Adjust these values to change the pitch range
tone = generate_tone(frequency)
channel = tone.play()
from .sound import get_available_channel
channel = get_available_channel()
channel.play(tone)
# Visual representation
screen.fill((0, 0, 0))