Gear Schematic HUD
Created in-flight equipment HUD & schematic display
This commit is contained in:
parent
6db7c65961
commit
1e273d691e
253 changed files with 19369 additions and 6296 deletions
|
|
@ -26,6 +26,8 @@ public class Cockpit : IBehavior
|
|||
public ItemManager Context { get; }
|
||||
|
||||
public BehaviorData Data => _data;
|
||||
|
||||
public float Heatstroke { get; private set; }
|
||||
|
||||
public Cockpit(ItemManager context, CockpitData data, Entity entity, EquippedItem item)
|
||||
{
|
||||
|
|
@ -33,10 +35,22 @@ public class Cockpit : IBehavior
|
|||
_data = data;
|
||||
Entity = entity;
|
||||
Item = item;
|
||||
Heatstroke = 0;
|
||||
}
|
||||
|
||||
public bool Update(float delta)
|
||||
{
|
||||
return true;
|
||||
if (Item.Temperature > Context.GameplaySettings.HeatstrokeTemperature)
|
||||
{
|
||||
Heatstroke = saturate(
|
||||
Heatstroke +
|
||||
pow(Item.Temperature - Context.GameplaySettings.HeatstrokeTemperature, Context.GameplaySettings.HeatstrokeExponent) *
|
||||
Context.GameplaySettings.HeatstrokeMultiplier * delta);
|
||||
}
|
||||
else
|
||||
{
|
||||
Heatstroke = saturate(Heatstroke - Context.GameplaySettings.HeatstrokeRecoverySpeed * delta);
|
||||
}
|
||||
return Heatstroke < Context.GameplaySettings.HeatstrokeControlLimit;
|
||||
}
|
||||
}
|
||||
Loading…
Reference in a new issue