diff --git a/Dalamud/Interface/Animation/Easing.cs b/Dalamud/Interface/Animation/Easing.cs
index a48300a22..edab25149 100644
--- a/Dalamud/Interface/Animation/Easing.cs
+++ b/Dalamud/Interface/Animation/Easing.cs
@@ -43,15 +43,9 @@ public abstract class Easing
public bool IsInverse { get; set; }
///
- /// Gets the current value of the animation, from 0 to 1.
+ /// Gets or sets the current value of the animation, from 0 to 1.
///
- public double Value => Math.Clamp(this.ValueUnclamped, 0, 1);
-
- ///
- /// Gets or sets the current value of the animation, not limited to a range of 0 to 1.
- /// Will return numbers outside of this range if accessed beyond animation time.
- ///
- public double ValueUnclamped
+ public double Value
{
get
{
diff --git a/Dalamud/Interface/Animation/EasingFunctions/InCirc.cs b/Dalamud/Interface/Animation/EasingFunctions/InCirc.cs
index d94e9fc9f..c467104c5 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/InCirc.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/InCirc.cs
@@ -19,6 +19,6 @@ public class InCirc : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = 1 - Math.Sqrt(1 - Math.Pow(p, 2));
+ this.Value = 1 - Math.Sqrt(1 - Math.Pow(p, 2));
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/InCubic.cs b/Dalamud/Interface/Animation/EasingFunctions/InCubic.cs
index 64ebc5ba3..78f6774ac 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/InCubic.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/InCubic.cs
@@ -19,6 +19,6 @@ public class InCubic : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = p * p * p;
+ this.Value = p * p * p;
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/InElastic.cs b/Dalamud/Interface/Animation/EasingFunctions/InElastic.cs
index 2e834e41c..c53c3d587 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/InElastic.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/InElastic.cs
@@ -21,10 +21,10 @@ public class InElastic : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = p == 0
- ? 0
- : p == 1
- ? 1
- : -Math.Pow(2, (10 * p) - 10) * Math.Sin(((p * 10) - 10.75) * Constant);
+ this.Value = p == 0
+ ? 0
+ : p == 1
+ ? 1
+ : -Math.Pow(2, (10 * p) - 10) * Math.Sin(((p * 10) - 10.75) * Constant);
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/InOutCirc.cs b/Dalamud/Interface/Animation/EasingFunctions/InOutCirc.cs
index a63ab648a..71a598dfb 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/InOutCirc.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/InOutCirc.cs
@@ -19,8 +19,8 @@ public class InOutCirc : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = p < 0.5
- ? (1 - Math.Sqrt(1 - Math.Pow(2 * p, 2))) / 2
- : (Math.Sqrt(1 - Math.Pow((-2 * p) + 2, 2)) + 1) / 2;
+ this.Value = p < 0.5
+ ? (1 - Math.Sqrt(1 - Math.Pow(2 * p, 2))) / 2
+ : (Math.Sqrt(1 - Math.Pow((-2 * p) + 2, 2)) + 1) / 2;
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/InOutCubic.cs b/Dalamud/Interface/Animation/EasingFunctions/InOutCubic.cs
index 4083265b7..07bcfa28d 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/InOutCubic.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/InOutCubic.cs
@@ -19,6 +19,6 @@ public class InOutCubic : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = p < 0.5 ? 4 * p * p * p : 1 - (Math.Pow((-2 * p) + 2, 3) / 2);
+ this.Value = p < 0.5 ? 4 * p * p * p : 1 - (Math.Pow((-2 * p) + 2, 3) / 2);
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/InOutElastic.cs b/Dalamud/Interface/Animation/EasingFunctions/InOutElastic.cs
index f27726038..f78f9f336 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/InOutElastic.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/InOutElastic.cs
@@ -21,12 +21,12 @@ public class InOutElastic : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = p == 0
- ? 0
- : p == 1
- ? 1
- : p < 0.5
- ? -(Math.Pow(2, (20 * p) - 10) * Math.Sin(((20 * p) - 11.125) * Constant)) / 2
- : (Math.Pow(2, (-20 * p) + 10) * Math.Sin(((20 * p) - 11.125) * Constant) / 2) + 1;
+ this.Value = p == 0
+ ? 0
+ : p == 1
+ ? 1
+ : p < 0.5
+ ? -(Math.Pow(2, (20 * p) - 10) * Math.Sin(((20 * p) - 11.125) * Constant)) / 2
+ : (Math.Pow(2, (-20 * p) + 10) * Math.Sin(((20 * p) - 11.125) * Constant) / 2) + 1;
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/InOutQuint.cs b/Dalamud/Interface/Animation/EasingFunctions/InOutQuint.cs
index e08129b25..64ab98b16 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/InOutQuint.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/InOutQuint.cs
@@ -19,6 +19,6 @@ public class InOutQuint : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = p < 0.5 ? 16 * p * p * p * p * p : 1 - (Math.Pow((-2 * p) + 2, 5) / 2);
+ this.Value = p < 0.5 ? 16 * p * p * p * p * p : 1 - (Math.Pow((-2 * p) + 2, 5) / 2);
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/InOutSine.cs b/Dalamud/Interface/Animation/EasingFunctions/InOutSine.cs
index cb940d87d..2f347ff80 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/InOutSine.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/InOutSine.cs
@@ -19,6 +19,6 @@ public class InOutSine : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = -(Math.Cos(Math.PI * p) - 1) / 2;
+ this.Value = -(Math.Cos(Math.PI * p) - 1) / 2;
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/InQuint.cs b/Dalamud/Interface/Animation/EasingFunctions/InQuint.cs
index 827e0e21b..a5ab5a22c 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/InQuint.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/InQuint.cs
@@ -19,6 +19,6 @@ public class InQuint : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = p * p * p * p * p;
+ this.Value = p * p * p * p * p;
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/InSine.cs b/Dalamud/Interface/Animation/EasingFunctions/InSine.cs
index 61affa10a..fa079baad 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/InSine.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/InSine.cs
@@ -19,6 +19,6 @@ public class InSine : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = 1 - Math.Cos((p * Math.PI) / 2);
+ this.Value = 1 - Math.Cos((p * Math.PI) / 2);
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/OutCirc.cs b/Dalamud/Interface/Animation/EasingFunctions/OutCirc.cs
index 980e29a81..b0d3b895a 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/OutCirc.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/OutCirc.cs
@@ -19,6 +19,6 @@ public class OutCirc : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = Math.Sqrt(1 - Math.Pow(p - 1, 2));
+ this.Value = Math.Sqrt(1 - Math.Pow(p - 1, 2));
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/OutCubic.cs b/Dalamud/Interface/Animation/EasingFunctions/OutCubic.cs
index e1a79c35b..9c1bb57dc 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/OutCubic.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/OutCubic.cs
@@ -19,6 +19,6 @@ public class OutCubic : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = 1 - Math.Pow(1 - p, 3);
+ this.Value = 1 - Math.Pow(1 - p, 3);
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/OutElastic.cs b/Dalamud/Interface/Animation/EasingFunctions/OutElastic.cs
index 1f525b404..6a4fcd6dc 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/OutElastic.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/OutElastic.cs
@@ -21,10 +21,10 @@ public class OutElastic : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = p == 0
- ? 0
- : p == 1
- ? 1
- : (Math.Pow(2, -10 * p) * Math.Sin(((p * 10) - 0.75) * Constant)) + 1;
+ this.Value = p == 0
+ ? 0
+ : p == 1
+ ? 1
+ : (Math.Pow(2, -10 * p) * Math.Sin(((p * 10) - 0.75) * Constant)) + 1;
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/OutQuint.cs b/Dalamud/Interface/Animation/EasingFunctions/OutQuint.cs
index 24a2255d3..a3174e762 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/OutQuint.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/OutQuint.cs
@@ -19,6 +19,6 @@ public class OutQuint : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = 1 - Math.Pow(1 - p, 5);
+ this.Value = 1 - Math.Pow(1 - p, 5);
}
}
diff --git a/Dalamud/Interface/Animation/EasingFunctions/OutSine.cs b/Dalamud/Interface/Animation/EasingFunctions/OutSine.cs
index a376d7f57..ba82232b3 100644
--- a/Dalamud/Interface/Animation/EasingFunctions/OutSine.cs
+++ b/Dalamud/Interface/Animation/EasingFunctions/OutSine.cs
@@ -19,6 +19,6 @@ public class OutSine : Easing
public override void Update()
{
var p = this.Progress;
- this.ValueUnclamped = Math.Sin((p * Math.PI) / 2);
+ this.Value = Math.Sin((p * Math.PI) / 2);
}
}
diff --git a/Dalamud/Interface/Internal/Windows/TitleScreenMenuWindow.cs b/Dalamud/Interface/Internal/Windows/TitleScreenMenuWindow.cs
index c63efca64..979f68bf8 100644
--- a/Dalamud/Interface/Internal/Windows/TitleScreenMenuWindow.cs
+++ b/Dalamud/Interface/Internal/Windows/TitleScreenMenuWindow.cs
@@ -252,7 +252,7 @@ internal class TitleScreenMenuWindow : Window, IDisposable
this.fadeOutEasing.Update();
- using (ImRaii.PushStyle(ImGuiStyleVar.Alpha, (float)this.fadeOutEasing.Value))
+ using (ImRaii.PushStyle(ImGuiStyleVar.Alpha, (float)Math.Max(this.fadeOutEasing.Value, 0)))
{
var i = 0;
foreach (var entry in entries)
@@ -393,7 +393,7 @@ internal class TitleScreenMenuWindow : Window, IDisposable
if (overrideAlpha)
{
- ImGui.PushStyleVar(ImGuiStyleVar.Alpha, showText ? (float)logoEasing.Value : 0f);
+ ImGui.PushStyleVar(ImGuiStyleVar.Alpha, showText ? (float)Math.Min(logoEasing.Value, 1) : 0f);
}
// Drop shadow