Update audio.py

This commit is contained in:
Anthony Samms
2025-11-21 22:48:27 -05:00
parent 4e255d9099
commit cb023c6671

View File

@@ -207,7 +207,7 @@ class AudioEngine:
sound = lib.load_sound(file_path_str) # type: ignore sound = lib.load_sound(file_path_str) # type: ignore
if not lib.is_sound_valid(sound): # type: ignore if not lib.is_sound_valid(sound): # type: ignore
file_path_str = str(file_path).encode('utf-8') file_path_str = str(file_path).encode('utf-16')
sound = lib.load_sound(file_path_str) # type: ignore sound = lib.load_sound(file_path_str) # type: ignore
if lib.is_sound_valid(sound): # type: ignore if lib.is_sound_valid(sound): # type: ignore
@@ -333,7 +333,7 @@ class AudioEngine:
music = lib.load_music_stream(file_path_str) # type: ignore music = lib.load_music_stream(file_path_str) # type: ignore
if not lib.is_music_valid(music): # type: ignore if not lib.is_music_valid(music): # type: ignore
file_path_str = str(file_path).encode('utf-8') file_path_str = str(file_path).encode('utf-16')
music = lib.load_music_stream(file_path_str) # type: ignore music = lib.load_music_stream(file_path_str) # type: ignore
if lib.is_music_valid(music): # type: ignore if lib.is_music_valid(music): # type: ignore