mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-12 18:27:23 +01:00
fix: set volume on WaveChannel instead
This commit is contained in:
parent
741f726123
commit
acd16ad9a4
1 changed files with 3 additions and 1 deletions
|
|
@ -334,11 +334,13 @@ public class Fools22 : IDisposable
|
|||
var volume = this.GetSfxVolume();
|
||||
if (volume > 0)
|
||||
{
|
||||
Log.Information("Fools22: Vol {Volume}", volume);
|
||||
|
||||
var waveStream = new WaveFileReader(new MemoryStream(this.soundBytes));
|
||||
var volumeStream = new WaveChannel32(waveStream);
|
||||
volumeStream.Volume = volume;
|
||||
var player = new WaveOutEvent();
|
||||
|
||||
player.Volume = volume;
|
||||
player.Init(volumeStream);
|
||||
player.Play();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue