Fix audio pitch

This commit is contained in:
2025-09-05 14:08:34 -07:00
parent 7f092dc977
commit e781b3138d

View File

@@ -396,8 +396,7 @@ public class GamePlayer : MonoBehaviour
{ {
foreach (AudioSource audio in FindObjectsByType<AudioSource>(FindObjectsSortMode.None)) foreach (AudioSource audio in FindObjectsByType<AudioSource>(FindObjectsSortMode.None))
{ {
if (speedyLeft != 0 && audio.pitch == 1f) audio.pitch = 1.3f; audio.pitch = speedyLeft > 0f ? 1.3f : 1f;
if (speedyLeft == 0 && audio.pitch == 1.3f) audio.pitch = 1f;
} }
if (BazookaManager.Instance.GetSettingShowFPS() && Time.time > nextUpdate) if (BazookaManager.Instance.GetSettingShowFPS() && Time.time > nextUpdate)
{ {