Move target status fill band into runtime render settings
This commit is contained in:
parent
3ad8da5640
commit
eaa3f0e6ed
3 changed files with 13 additions and 3 deletions
|
|
@ -1829,6 +1829,7 @@ static void RequireDaemonRenderQueryAuthority(string root)
|
|||
"public double NormalizeDetectionProgress(double infoGathered)",
|
||||
"public double NormalizeTargetVisibilityFill(double infoGathered)",
|
||||
"public double NormalizeVisibilityToTargetFill(double infoGathered)",
|
||||
"public double NormalizeTargetStatusFill(double normalizedValue)",
|
||||
"public double ResolveLockIndicatorNoiseAmplitude(double lockProgress)",
|
||||
"public double ResolveLockIndicatorNoiseFrequency(double lockProgress)",
|
||||
"public double ResolveLockSpinSpeed(double lockProgress)",
|
||||
|
|
@ -2192,6 +2193,7 @@ static void RequireDaemonRenderQueryAuthority(string root)
|
|||
"renderSettings.NormalizeSevereHeatstrokePost(",
|
||||
"renderSettings.NormalizeTargetVisibilityFill(",
|
||||
"renderSettings.NormalizeVisibilityToTargetFill(",
|
||||
"renderSettings.NormalizeTargetStatusFill(",
|
||||
"renderSettings.ResolveLockIndicatorNoiseAmplitude(",
|
||||
"renderSettings.ResolveLockIndicatorNoiseFrequency(",
|
||||
"renderSettings.ResolveLockSpinSpeed(",
|
||||
|
|
@ -2217,7 +2219,8 @@ static void RequireDaemonRenderQueryAuthority(string root)
|
|||
"Settings.GameplaySettings.SevereHeatstrokeRiskThreshold",
|
||||
"Settings.GameplaySettings.LockIndicatorNoiseAmplitude",
|
||||
"Settings.GameplaySettings.LockIndicatorFrequency",
|
||||
"Settings.GameplaySettings.LockSpinSpeed"
|
||||
"Settings.GameplaySettings.LockSpinSpeed",
|
||||
"Mathf.Lerp(.25f, .75f,"
|
||||
};
|
||||
var renderLoopHits = FindMethodScopedLineHits(actionGameManager, forbiddenRenderLoopSymbols)
|
||||
.Where(hit => hit.MethodName is "Update" or "UpdateTargetIndicators")
|
||||
|
|
|
|||
|
|
@ -3717,8 +3717,10 @@ public class ActionGameManager : MonoBehaviour
|
|||
var targetMaxDurability = targetHull?.Durability > 0
|
||||
? (float)targetHull.Durability
|
||||
: Math.Max(target.Hull.Durability, 1f);
|
||||
TargetHitpointsFill.fillAmount = Mathf.Lerp(.25f, .75f, target.Hull.Durability / targetMaxDurability);
|
||||
TargetShieldsFill.fillAmount = target.Shield == null ? 0 : Mathf.Lerp(.25f, .75f, target.Shield.Progress);
|
||||
TargetHitpointsFill.fillAmount = (float)renderSettings.NormalizeTargetStatusFill(target.Hull.Durability / targetMaxDurability);
|
||||
TargetShieldsFill.fillAmount = target.Shield == null
|
||||
? 0
|
||||
: (float)renderSettings.NormalizeTargetStatusFill(target.Shield.Progress);
|
||||
}
|
||||
|
||||
var tractorPower = Input.Player.TractorBeam.ReadValue<float>();
|
||||
|
|
|
|||
|
|
@ -128,6 +128,11 @@ namespace GameCult.Aetheria.State.Verse
|
|||
return Lerp(0.25, 0.75, NormalizeDetectionProgress(infoGathered));
|
||||
}
|
||||
|
||||
public double NormalizeTargetStatusFill(double normalizedValue)
|
||||
{
|
||||
return Lerp(0.25, 0.75, normalizedValue);
|
||||
}
|
||||
|
||||
public double ResolveLockIndicatorNoiseAmplitude(double lockProgress)
|
||||
{
|
||||
return LockIndicatorNoiseAmplitude * (1.0 - Saturate(lockProgress));
|
||||
|
|
|
|||
Loading…
Reference in a new issue