Add UI click sounds (#22410)

* Add UI click sounds

* tweaks

* Significant cleanup

* Audio options and numerous fixes

* Fix the remaining UI elements

* new click sound

---------

Co-authored-by: Kara <lunarautomaton6@gmail.com>
This commit is contained in:
metalgearsloth
2023-12-29 15:43:36 +11:00
committed by GitHub
parent 5f7e92a2d7
commit 4023134cf0
19 changed files with 179 additions and 21 deletions

View File

@@ -1,15 +1,18 @@
using Content.Shared.Audio;
using Content.Shared.CCVar;
using Content.Shared.GameTicking;
using Robust.Client.GameObjects;
using Robust.Shared;
using Robust.Shared.Audio;
using Robust.Client.Audio;
using Robust.Client.ResourceManagement;
using Robust.Client.UserInterface;
using AudioComponent = Robust.Shared.Audio.Components.AudioComponent;
namespace Content.Client.Audio;
public sealed partial class ContentAudioSystem : SharedContentAudioSystem
{
[Dependency] private readonly IAudioManager _audioManager = default!;
[Dependency] private readonly IResourceCache _cache = default!;
[Dependency] private readonly IUserInterfaceManager _uiManager = default!;
// Need how much volume to change per tick and just remove it when it drops below "0"
private readonly Dictionary<EntityUid, float> _fadingOut = new();
@@ -32,6 +35,7 @@ public sealed partial class ContentAudioSystem : SharedContentAudioSystem
public const float AmbienceMultiplier = 3f;
public const float AmbientMusicMultiplier = 3f;
public const float LobbyMultiplier = 3f;
public const float InterfaceMultiplier = 2f;
public override void Initialize()
{