Tweaked AITarget ranges: now it's possible to evade some monsters by stopping the sub and/or turning off noisy devices, AITarget ranges can be made visible by entering "ShowAITargets" in the console, misc cleanup

This commit is contained in:
Regalis
2016-03-12 21:35:08 +02:00
parent c99f94b1de
commit d713874bd6
11 changed files with 113 additions and 104 deletions
@@ -88,6 +88,11 @@ namespace Barotrauma.Items.Components
Submarine.Loaded.ApplyForce(currForce);
if (item.CurrentHull != null)
{
item.CurrentHull.AiTarget.SoundRange = Math.Max(currForce.Length(), item.CurrentHull.AiTarget.SoundRange);
}
for (int i = 0; i < 5; i++)
{
GameMain.ParticleManager.CreateParticle("bubbles", item.WorldPosition - (Vector2.UnitX * item.Rect.Width/2),