(24cde6cae) Add a static sight range. Considerably increase the hull sight ranges.
This commit is contained in:
@@ -15,6 +15,11 @@ namespace Barotrauma
|
||||
private set;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Use as a minimum or static sight range.
|
||||
/// </summary>
|
||||
public static float StaticSightRange = 3000;
|
||||
|
||||
private float soundRange;
|
||||
private float sightRange;
|
||||
|
||||
@@ -110,9 +115,13 @@ namespace Barotrauma
|
||||
SonarLabel = element.GetAttributeString("sonarlabel", "");
|
||||
}
|
||||
|
||||
public AITarget(Entity e, float sightRange = 3000, float soundRange = 0)
|
||||
public AITarget(Entity e, float sightRange = -1, float soundRange = 0)
|
||||
{
|
||||
Entity = e;
|
||||
if (sightRange < 0)
|
||||
{
|
||||
sightRange = StaticSightRange;
|
||||
}
|
||||
SightRange = sightRange;
|
||||
SoundRange = soundRange;
|
||||
List.Add(this);
|
||||
|
||||
Reference in New Issue
Block a user