thank you! thats a really unique feature, idk if id have the skill to implement it
I’m not even sure if it would sound good! It might sound silly, but that’s partly why I want to hear it haha
I can think of two ways to implement if you wanted to try.
-
If you are using move_and_slide you should be able to set the pitch_scale of the AudioStreamPlayer based on velocity.length(). You would need to set a min and max pitch though and return to min_pitch when the player isn’t moving.
-
If you are doing the time-based approach you could have a timer reset whenever the player starts moving. Default to sfx.pitch_scale = min_pitch. Based on the timer, increase the pitch in your movement code. Same thing, assigning to pitch_scale the clamped value based on the timer and max_pitch.