From af4f84eae58eb4445f20d2da1447cf7e26152788 Mon Sep 17 00:00:00 2001 From: Selim Nahimi Date: Sat, 9 Sep 2023 13:31:32 +0200 Subject: [PATCH] Update vaulting - Bezier curve is adjusted for vault onto high --- code/pawn/PawnController.Vaulting.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/code/pawn/PawnController.Vaulting.cs b/code/pawn/PawnController.Vaulting.cs index 605d4de..8d725b4 100644 --- a/code/pawn/PawnController.Vaulting.cs +++ b/code/pawn/PawnController.Vaulting.cs @@ -40,10 +40,15 @@ void ProgressVault() { // TODO: make smoother + // TODO: put this into a class or something + var startCurveSize = Vaulting == VaultType.OntoHigh ? 10f : 30f; + var endCurveSize = Vaulting == VaultType.OntoHigh ? -70f : 30f; + Vector3 pos = Bezier.Approach( start: VaultStartPos, end: VaultTargetPos, - curveSize: 30f, + startCurveSize: startCurveSize, + endCurveSize: endCurveSize, t: bezierCounter );