Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ---- Sound Profiles V1 Proposal (Draft 2) ----
- 0. Introduction
- Right now, our audio behavior is spread across scripts, scenes, and project
- settings. That makes it harder to change, easier to break unintentionally, and
- difficult to predict how one tweak will affect other gameplay states. It also
- forces designers to rely on programmers for even small adjustments, like trying
- a new mix, swapping a preset, or rewiring an audio asset, because those changes
- often require touching scene files or code.
- Sound Profiles solve this by introducing a clear, centralized layer of
- abstraction for audio. Instead of editing scenes or code, the team can iterate
- on audio behavior safely in one place, reducing risk to scene integrity and
- keeping changes consistent, controlled, and easy to maintain.
- 1. Overview
- A Sound Profile is a self-contained JSON-based format describing how audio
- should behave within specific game contexts, without modifying scenes, scripts,
- or assets directly. The schema's main goal is to provide an abstraction layer
- for defining audio behavior separately from script behavior, while being
- accessible enough for non-technical team members to comfortably create and edit.
- These profiles can be layered and swapped based on any kind of game state or
- condition, all with minimal coordination necessary between the technical and
- non-technical team members, hereon referred to as "programmers" and "designers"
- respectively.
- 1.1 Pain Points Addressed / Why This System Exists
- Without Sound Profiles:
- * Audio behavior is scattered between scripts, scenes, or project settings,
- which makes modification more difficult and unpredictable.
- * Changing settings relevant to one state often risks unintentionally
- affecting others.
- * Designers would need programmers to tweak even the simplest of audio logic
- or asset wiring, as trying new mixes, presets, etc. requires touching scene
- files or code directly.
- With Sound Profiles:
- * Audio behavior is centralized to two file types (excluding whatever form
- sound categories and IDs take) that are external to any script or scene data.
- * Any designer or programmer can adjust audio behavior in isolation, making
- its definitions predictable and testable.
- * The extent to which coordination is necessary between designers and
- programmers is greatly reduced, and is mostly limited to agreeing on what
- profiles(s) a given context(s) is relevant to and vice versa, as well as
- their name and use case.
- * Global accessibility mixes or effect chains become simple, if not one-line swaps.
- * Context-based mixing becomes trivial: transitions, menus, cutscenes, etc.
- * Future dynamic systems (ducking, RTPCs, property interpolation),
- get a stable backbone.
- * Schema allows for future, interactive authoring tools to be integrated.
- 2. Sound Profiles
- A single Sound Profile can do any number of things. However, limiting each one
- individually to serve 1-3 purposes is ideal in order to maximize modularity and
- reusability. For example, within a single profile, you could define an audio
- effect chain that can be used in multiple *Profile Contexts* (see next section),
- where any change to that profile's settings would apply to any associated
- contexts, like a macro of sorts.
- 2.1 Profile Contexts
- In order to separate audio pipeline behavior from anything implementation or
- game design-specific, profiles are instead attached to Profile *Contexts*.
- These are named identifiers that can represent *any* game state, such as:
- * Scene transitions
- * Menu screens
- * Map mode vs. NPC mode
- * Accessibility modes (e.g., "Soft Mix")
- * Any arbitrary state/tag/event the game defines later
- This abstraction allows the underlying profile format to remain stable, even
- if the game's notion of "state" evolves or expands.
- One Profile Context can theoretically contain multiple profiles to be applied
- all at once, and each profile can theoretically be attached to multiple contexts.
- In future versions, it should be possible to bind certain parameters within
- a context to more specific states, like attenuating the game's volume globally
- whenever the game window goes out of focus, for example.
- 2.2 Context Definitions
- Profile Contexts are defined in a separate JSON file that contains a context
- ID, followed by an (optional) "priority" index (see next section), followed by
- references to profile IDs in an array. Each profile's load order is determined
- by their placement in that array.
- A context ID simply maps a name (e.g., "UI_MAINMENU", "CTX_CUTSCENE") to a
- profile (or profiles) that will be considered active while that context is live.
- 2.2 Global Contexts
- Some profiles must always be applied before or after any other context or only
- a select number of contexts, such as:
- * Accessibility mixes (e.g., Soft Mix vs. Normal Mix)
- * System-level music selection rules
- * Baseline gain adjustments
- These profiles' load order is determined by the previously mentioned "priority"
- index, which is 0 by default. Values lower than a given priority will result in
- that context being applied *before* the other, whereas values higher than a given
- priority will result in it being applied *after* the other. For example,
- a priority of -1 will be applied before a priority of 0, which will too go before
- a priority of 1, and so on.
- This lets the team swap global mixes dynamically (e.g., toggling Low-Intensity
- mode) without altering any other Profile Context.
Advertisement
Add Comment
Please, Sign In to add comment