Speech noise fixies (#8023)

Co-authored-by: metalgearsloth <metalgearsloth@gmail.com>
This commit is contained in:
metalgearsloth
2022-05-08 23:39:51 +10:00
committed by GitHub
parent dc503f3f3f
commit 145c5fdd5b
7 changed files with 36 additions and 70 deletions

View File

@@ -21,12 +21,8 @@ namespace Content.Shared.Speech
private bool _enabled = true;
[ViewVariables(VVAccess.ReadWrite)]
[DataField("playSpeechSound")]
public bool PlaySpeechSound = false;
[ViewVariables(VVAccess.ReadWrite)]
[DataField("speechSoundsId", customTypeSerializer:typeof(PrototypeIdSerializer<SpeechSoundsPrototype>))]
public string SpeechSoundsId { get; set; } = "Alto";
[DataField("speechSounds", customTypeSerializer:typeof(PrototypeIdSerializer<SpeechSoundsPrototype>))]
public string? SpeechSounds;
[DataField("audioParams")]
public AudioParams AudioParams = AudioParams.Default.WithVolume(5f);
@@ -37,12 +33,6 @@ namespace Content.Shared.Speech
public TimeSpan LastTimeSoundPlayed = TimeSpan.Zero;
//Don't use this.
//Cache for SpeechSoundsPrototype to avoid Indexing every single time someone talks.
public SpeechSoundsPrototype? SpeechSoundsCache = null;
public bool Enabled
{
get => _enabled;