Reading Assets from folders was only possible in Editor over LoadAssetFromPath. Now I'm using asset bundles for ScriptedObjects and Audio Prefabs, when the project is built.
When in Editor the folders are still used for convenience (can make changes to assets without rebuilding asset bundles)
Every sound in the game is now a ManageableAudio prefab.
The prefabs are picked up in an audio library automatically and other game objects
can get the sound they need from the AudioManager.
They obtain a ManageableAudio instance which offers various
methods to interact with the AudioSource.
Depending on how they request the ManageableAudio, the AudioSource
is attached to the requesting GameObject, to the Scene or the global management Scene.
This provides options to play sounds spatially, globally and scene independent.
The prefabs are identified by a tag and an ID, so it is easy to swap out sounds globally, by just replacing the prefab.
This can be seen as the initial state of the project after the released demo.
The changes include:
- New ship models
- Singleton manager structure to keep project scaleable in the future
- Managing players, their settings, character choices, statistics, match setups, controls etc. in a separate decoupled scene
- Main menu with transitions to the arena scene
- Beginnings of a custom audio solution
- Logging with Log4Net
It is really a complete overhaul of the projects structure and management.