Unstable v0.1300.0.2
This commit is contained in:
@@ -30,6 +30,12 @@ namespace Barotrauma.Sounds
|
||||
AlMuffledBuffer = 0;
|
||||
}
|
||||
|
||||
public static void ClearPool()
|
||||
{
|
||||
bufferPool.ForEach(b => Al.DeleteBuffer(b));
|
||||
bufferPool.Clear();
|
||||
}
|
||||
|
||||
public bool RequestAlBuffers()
|
||||
{
|
||||
if (AlBuffer != 0) { return false; }
|
||||
|
||||
@@ -798,6 +798,8 @@ namespace Barotrauma.Sounds
|
||||
}
|
||||
sourcePools[(int)SourcePoolIndex.Default]?.Dispose();
|
||||
sourcePools[(int)SourcePoolIndex.Voice]?.Dispose();
|
||||
|
||||
SoundBuffers.ClearPool();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
|
||||
@@ -1054,7 +1054,7 @@ namespace Barotrauma
|
||||
|
||||
if (GameMain.GameSession != null)
|
||||
{
|
||||
if (Submarine.Loaded != null && Level.Loaded != null && Submarine.MainSub != null && Submarine.MainSub.AtEndPosition)
|
||||
if (Submarine.Loaded != null && Level.Loaded != null && Submarine.MainSub != null && Submarine.MainSub.AtEndExit)
|
||||
{
|
||||
return "levelend";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user