v1.5.7.0 (Summer Update)
This commit is contained in:
@@ -6,7 +6,7 @@ using Barotrauma.Networking;
|
||||
|
||||
namespace Barotrauma.Items.Components
|
||||
{
|
||||
partial class Engine : Powered, IServerSerializable, IClientSerializable
|
||||
partial class Engine : Powered, IServerSerializable, IClientSerializable, IDeteriorateUnderStress
|
||||
{
|
||||
private float force;
|
||||
|
||||
@@ -76,10 +76,7 @@ namespace Barotrauma.Items.Components
|
||||
set { force = MathHelper.Clamp(value, -100.0f, 100.0f); }
|
||||
}
|
||||
|
||||
public float CurrentVolume
|
||||
{
|
||||
get { return Math.Abs((force / 100.0f) * (MinVoltage <= 0.0f ? 1.0f : Math.Min(prevVoltage, 1.0f))); }
|
||||
}
|
||||
public float CurrentVolume => CurrentStress;
|
||||
|
||||
public float CurrentBrokenVolume
|
||||
{
|
||||
@@ -90,6 +87,8 @@ namespace Barotrauma.Items.Components
|
||||
}
|
||||
}
|
||||
|
||||
public float CurrentStress => Math.Abs((force / 100.0f) * (MinVoltage <= 0.0f ? 1.0f : Math.Min(prevVoltage, 1.0f)));
|
||||
|
||||
private const float TinkeringForceIncrease = 1.5f;
|
||||
|
||||
public Engine(Item item, ContentXElement element)
|
||||
|
||||
Reference in New Issue
Block a user