How we handle audio
This 82th Godot Wild Jam was my fourth with Tilca, our composer and sound designer, and I must admit we progressed a lot on the audio side since Celestial Settlers.
In our first gamejam projects, we just did things in the most natural way when using Godot: add AudioStreamPlayer3Ds wherever sound had to happen. But this makes it necessary for the sound designer, either to navigate the whole project to add sounds and tweak volumes, or to team up with a developer (or the developper, in a small gamejam team) for doing so.
Starting with Lord of the Rum, I wrote a few scripts that make it possible to:
- declare all sounds and their associated volumes in a dictionary
- play any sound (using its key in the table) in any Node3D. This just allocates an AudioStreamPlayer3D, places it inside the Node3D, and plays the sound. When the sound is finished, the audio stream player is removed from the scene tree and stored in a pool.
At that point we had a working solution and used it as is for Little Shadow. But the number of sounds increased significantly, and we decided that organizing sounds in a tree structure would be a lot more convenient.
So I rewrote the user interface so sounds can be declared in a tree view and configured easily (bus, volume, pitch shift, volume randomness, attenuation parameters) by the sound designer. All this in a new panel named TRAudio (Tilca and Rod's Audio plugin).
And on the developer's side, quite a few ways of playing sounds by name are available:
- Just programmatically: TRAudio.play_sound("sfx/player/footstep")
This method has (of course) 2D and 3D counterparts and automatically allocates audio stream players when needed and inserts them in the node tree. - By using a TRAudioStreamPlayer (or 2D or 3D versions) and calling the play_sound method. This method is similar to "standard" Godot usage, so it's an easy way to update an old Godot project. It is also well suited if you want to trigger sounds in an animation: just replace the audio playback tracks with method call tracks, and call the "play sound" method to play a sound.
- By using a TRSoundPlayer, that is a mix between both solutions above: allocates audio stream players when needed, but anchored in the node tree, so they can be driven by an animation. Since they allocate audio stream players, they can play several sounds simultaneously.
So this is what we used in Little Shadow and Delicious Neighbors, and now we saved a lot of time using all this, it's time for us to share. You will find the TRAudio add-on for Godot on Github, under the MIT License. Please don't hesitate to contact us if you need help using it (it's the very first version, and documentation is probably not as complete as it could).
Get Little Shadow
Little Shadow
A game made for Godot Wild Jam 82. Avoid the light and rescue your friends!
Status | In development |
Authors | RodZilla, ChooChooRayk, Mesh_Manticore, Kouck, Tilca, Cularo Games |
Genre | Adventure, Action |
Tags | 3D, Cute, Dark Fantasy, Fantasy, Godot, Mystery, Non violent, Puzzle-Platformer, Third Person |
Languages | English |
More posts
- Preparing the first post-jam releaseJun 28, 2025
- FL Studio - Timelapse Video Game music. Sweet FantasyJun 26, 2025
Comments
Log in with itch.io to leave a comment.
Great add-on! Definitely will be trying the add-on for projects with lots of sfx.
By the way, please consider editing the image so the background behind the text is plain and high contrast. It's kind of hard to read and an accessibility issue.
Sure, we added a background, it should be better now.
This is neat. I rolled my own sound plugin which I like but think you've done some really neat things here with collaboration. I'm curious if you've integrated this with AudioStreamRandomizer or AudioStreamPlaylist nodes?
No, we did not use the complex audio streams provided by Godot. But you can use them: just uncheck "Show properties", and you'll have an inspector-like interface to define your sounds.
This is such an useful addon, you guys. Really really fantastic! Thanks for sharing it
It's a first version and probably needs more doc. Any feedback is welcome.