JujuAdams / Vinyl

Live updating audio system for GameMaker
https://www.jujuadams.com/Vinyl/
MIT License
43 stars 4 forks source link

Incompatibility with audioExt? #110

Open nekonesse opened 1 month ago

nekonesse commented 1 month ago

Hey! While using vinyl i've encountered an issue using AudioExt by TabularElf, im using it to load .wavs and .oggs easier since my game has a bunch of modding features which include audio modding. but when i try to 'setup' a sound using the runtime function in vinyl, i seem to get this crash.

############################################################################################ ERROR in action number 1 of Create Event for object oPlayer:

Variable .__UpdateSetup(102630, -2147483648) cannot be resolved. at gml_Script_VinylSetupSound (line 27) - struct_get_from_hash(_soundDict, int64(_sound)).__UpdateSetup(_gain, _pitch, _loop, _mixName, _duckerName, _duckPrio, _metadata); ############################################################################################ gml_Script_VinylSetupSound (line 27) gml_Script_init_sounds (line 101) - VinylSetupSound(audioExtSoundGetSoundID(snd)) gml_Script_init_player (line 137) - init_sounds(); gml_Object_oPlayer_Create_0 (line 114) - init_player();

The code im using as an example is this below: this works perfectly fine without the for loop/vinylsetup stuff, and using audio_play_sound instead of VinylPlay also works perfectly. var dir=$"{working_directory}\\_vanilla\\character\\{charmName}\\sfx\\" audioExtWavScan(dir) for (var i=0; i < array_length(sound_list); ++i;) { if file_exists(dir+$"{charmName}{sound_list[i]}.wav") { var snd=audioExtSoundGet($"{charmName}{sound_list[i]}") VinylSetupSound(audioExtSoundGetSoundID(snd)) show_debug_message($"Loaded sound ID: {charmName}{sound_list[i]}") } else { show_debug_message($"Failed to load sound ID: {charmName}{sound_list[i]}, is your file missing?") } }

JujuAdams commented 1 month ago

What version of Vinyl are you using?

nekonesse commented 1 month ago

What version of Vinyl are you using?

Latest build, i had just updated 2 days ago.

JujuAdams commented 1 month ago

Issue is my end insofar that I need to guarantee the creation of a sound pattern when calling VinylSetupSound(). Additionally, documentation needs to call out the necessity of calling VinylSetupSound() when creating new sound assets at runtime.