Closed colinator27 closed 8 years ago
But I do know that it is a script in Undertale because of the transition between GM8 and GM:S
You are correct that audio_play_sound is right, however, Toby uses snd_play all though his game so this is why I put it in there. This part of the code is only to decode the arguments that are indexes to their text name equivalent.
If you look at the decompiled code of Undertale, you will notice, in the script folder, there is a script called "snd_play" that just calls audio_play_sound. I assume that Game Maker creates this function when someone uses snd_play instead of the studio equivalent for backward compatibility.
In either case I do need to add audio_play_sound in there. I was using those values for debugging and I have yet to implement any kind of instance tracking to do this all automatically.
I just updated the code to included both of those functions but haven't built a release yet.
Oh, and just tested the snd_play being created in GameMaker's compiler but all it did was give me a compiler error. I believe Toby did that himself, along with the Caster functions. Maybe we could ask him, but he probably wouldn't answer.
snd_play is toby's script, caster is an extension for game maker to allow advanced control of audio such as pitch bending.
Caster no longer needed a purpose when the switch to GM:S was made. For some reason, I think Toby got rid of it and made his own caster functions. Look in the scripts.
Take a look here: https://github.com/WarlockD/GMdsam/blob/master/GMdsam/Writers/CodeWriter.cs#L233-L234
snd_play(); should be audio_play_sound(); (or sound_play();)
snd_isplaying(); should be audio_is_playing(); (or sound_isplaying();)
I don't know, you should take a look at this.