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
|
|
@ -6,6 +6,8 @@ using System;
|
|||
using System.Linq;
|
||||
using MessagePack;
|
||||
using Newtonsoft.Json;
|
||||
using Unity.Mathematics;
|
||||
using static Unity.Mathematics.math;
|
||||
|
||||
[InspectableField, MessagePackObject, JsonObject(MemberSerialization.OptIn), Order(-10), RuntimeInspectable]
|
||||
public class CooldownData : BehaviorData
|
||||
|
|
@ -19,7 +21,7 @@ public class CooldownData : BehaviorData
|
|||
}
|
||||
}
|
||||
|
||||
public class Cooldown : IBehavior, IAlwaysUpdatedBehavior
|
||||
public class Cooldown : IBehavior, IAlwaysUpdatedBehavior, IProgressBehavior
|
||||
{
|
||||
private CooldownData _data;
|
||||
public BehaviorData Data => _data;
|
||||
|
|
@ -30,6 +32,8 @@ public class Cooldown : IBehavior, IAlwaysUpdatedBehavior
|
|||
|
||||
private float _cooldown; // Normalized
|
||||
|
||||
public float Progress => saturate(_cooldown);
|
||||
|
||||
public Cooldown(ItemManager context, CooldownData data, Entity entity, EquippedItem item)
|
||||
{
|
||||
_data = data;
|
||||
|
|
|
|||
Loading…
Reference in a new issue