How could I implement an Inspector Event Mapper like this?
-It has a list of events on the left side
-For each event, it triggers a list of methods from other components from a dropdown.
I’ve tried using Unity Events, but I’m a bit clueless
How could I implement an Inspector Event Mapper like this?
-It has a list of events on the left side
-For each event, it triggers a list of methods from other components from a dropdown.
I’ve tried using Unity Events, but I’m a bit clueless
We did this with ScriptableObjects and we called them AudioEvents… they basically have a handful of settings in them:
Then we just play them by the name of the ScriptableObject.
We also used a grouping system called AudioEventSet which kept bunches of these events together, such as “always loaded” and “level 1” and “level 2” etc.
That sounds good. Didnt thought about putting it on SOs
It worked out pretty nice. We added a custom inspector on it so that there was an “play” button in the actual ScriptableObject inspector window, and it would trigger the behavior (to the extent possible) in editor.
I also got tired of making them every time the audio guy dropped a whole bunch of new WAV files in so I made a menu item that would iterate all audio files in a directory and produce an AudioEvent associated with it, with default values set up, like pointing to the clip, etc. HUGE time saver.