-
Notifications
You must be signed in to change notification settings - Fork 45
/
Copy pathCueWrapper.cs
62 lines (43 loc) · 1.58 KB
/
CueWrapper.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
// Decompiled with JetBrains decompiler
// Type: StardewValley.CueWrapper
// Assembly: Stardew Valley, Version=1.5.6.22018, Culture=neutral, PublicKeyToken=null
// MVID: BEBB6D18-4941-4529-AC12-B54F0C61CC20
// Assembly location: C:\Program Files (x86)\Steam\steamapps\common\Stardew Valley\Stardew Valley.dll
using Microsoft.Xna.Framework.Audio;
using System;
namespace StardewValley
{
public class CueWrapper : ICue, IDisposable
{
private Cue cue;
public CueWrapper(Cue cue) => this.cue = cue;
public void Play() => this.cue.Play();
public void Pause() => this.cue.Pause();
public void Resume() => this.cue.Resume();
public void Stop(AudioStopOptions options) => this.cue.Stop(options);
public void SetVariable(string var, int val) => this.cue.SetVariable(var, (float) val);
public void SetVariable(string var, float val) => this.cue.SetVariable(var, val);
public float GetVariable(string var) => this.cue.GetVariable(var);
public bool IsStopped => this.cue.IsStopped;
public bool IsStopping => this.cue.IsStopping;
public bool IsPlaying => this.cue.IsPlaying;
public bool IsPaused => this.cue.IsPaused;
public string Name => this.cue.Name;
public void Dispose()
{
this.cue.Dispose();
this.cue = (Cue) null;
}
public float Volume
{
get => this.cue.Volume;
set => this.cue.Volume = value;
}
public float Pitch
{
get => this.cue.Pitch;
set => this.cue.Pitch = value;
}
public bool IsPitchBeingControlledByRPC => this.cue.IsPitchBeingControlledByRPC;
}
}