Godot Version
v4.6.stable.official [89cea1439]
Question
TLDR: How to improve Editor experience when defining a large mapping between ID and resource?
Recently, I’ve been working on a sound manager for godot, inspired by [resonate]) Widgit Gaming / Godot / Resonate · GitLab ).
The basic underlying idea is that you define all of your SFX inside of resources, including stuff like the stream(s) to use, pitch, volume and bus control. Then in your gameplay code, you refer to these sounds by ID (or rather, a combination of LibraryID:SoundID).
After getting quite far with my idea, I’ve come to the realization that neither of Godots exported containers are really that suitable for organizing this quantity of data.
Dictionaries
The obvious choice, but it has so many drawbacks. You cannot edit the keys of exported dictionaries, and you also cannot search or filter on dictionary keys. Actually editing all of your SFX this way would be a nightmare.
Arrays
If you inline the ID of the sound into a property on the resource, then technically you can define your sounds in a big array. But the discoverability here is even worse… re-finding a specific sound effect to edit will be nearly impossible unless you save all of them to disk.
Custom Property Editor
I’ve actually explored this, and it seems somewhat workable, but it’s so finicky to implement. The primary concern, is that I want users to be able to define their SFX as resources. And re-implementing the entire resource workflow just seems kinda tough. You can kinda get there with a combination of EditorInspector and EditorResourcePicker, but I just fear I would be building myself into a corner.
Any ideas?
Since it’s a plugin, I don’t neccesarily want users to have to use any other plugin to make my plugin usable. e.g., stuff like Edit Resources as Table 2 - Godot Asset Library . So I’m feeling a bit stick.
Suprisingly, all of the issues I have with the properties panel have open issues on Godot Proposals, but the activity has primarily died down. So I don’t think waiting on engine changes makes sense.