New pump & railguncont sprites, saving fixes (disappearing items fixed?), moving LightManager.ViewPos to railgun when aiming, generating waypoints outside sub, easier wire node editing, characters stand when using a controller, shiftsummary crew status scrolling, stuff
This commit is contained in:
@@ -65,7 +65,7 @@ namespace Barotrauma
|
||||
|
||||
public int AlBufferId
|
||||
{
|
||||
get { return oggSound.AlBufferId; }
|
||||
get { return oggSound==null ? -1 : oggSound.AlBufferId; }
|
||||
}
|
||||
|
||||
public static void Init()
|
||||
@@ -260,7 +260,7 @@ namespace Barotrauma
|
||||
//System.Diagnostics.Debug.WriteLine("Removing sound " + filePath + " (buffer id" + AlBufferId + ")");
|
||||
|
||||
SoundManager.ClearAlSource(AlBufferId);
|
||||
oggSound.Dispose();
|
||||
if (oggSound!=null) oggSound.Dispose();
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -240,7 +240,7 @@ namespace Barotrauma
|
||||
{
|
||||
suitableMusic = musicClips.Where(x => x != null && x.type == OverrideMusicType).ToList();
|
||||
}
|
||||
else if (Submarine.Loaded!=null && Submarine.Loaded.Position.Y<SubmarineBody.DamageDepth+10000.0f)
|
||||
else if (Submarine.Loaded!=null && Submarine.Loaded.AtDamageDepth)
|
||||
{
|
||||
suitableMusic = musicClips.Where(x => x != null && x.type == "deep").ToList();
|
||||
}
|
||||
@@ -302,17 +302,8 @@ namespace Barotrauma
|
||||
|
||||
int selectedSound = Rand.Int(sounds.Count());
|
||||
|
||||
int i = 0;
|
||||
foreach (var s in sounds)
|
||||
{
|
||||
if (i == selectedSound)
|
||||
{
|
||||
s.sound.Play(1.0f, range, position);
|
||||
Debug.WriteLine("playing: " + s.sound);
|
||||
return;
|
||||
}
|
||||
i++;
|
||||
}
|
||||
sounds[selectedSound].sound.Play(1.0f, range, position);
|
||||
Debug.WriteLine("playing: " + sounds[selectedSound].sound);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user