From f30d850b749dd7899a369cc7743225fef557f92a Mon Sep 17 00:00:00 2001 From: Rapandrasmus <78219215+Rapandrasmus@users.noreply.github.com> Date: Sat, 7 Oct 2023 19:12:16 +0200 Subject: [PATCH] epic tweaks --- .../Resources/Prefabs/Games/AnimalAcrobat/Elephant.prefab | 2 +- Assets/Scripts/Games/AnimalAcrobat/AcrobatPlayer.cs | 3 ++- Assets/Scripts/Games/AnimalAcrobat/GiraffeInput.cs | 6 +++--- Assets/Scripts/Games/AnimalAcrobat/ObstacleInput.cs | 6 +++--- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/Assets/Resources/Prefabs/Games/AnimalAcrobat/Elephant.prefab b/Assets/Resources/Prefabs/Games/AnimalAcrobat/Elephant.prefab index cadda108e..75c302cfe 100644 --- a/Assets/Resources/Prefabs/Games/AnimalAcrobat/Elephant.prefab +++ b/Assets/Resources/Prefabs/Games/AnimalAcrobat/Elephant.prefab @@ -562,7 +562,7 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: _fullRotRange: 160 - _spawnOffset: 0 + _spawnOffset: -2 _holdLength: 2 _ease: 4 _rotateRoot: {fileID: 2616646720197201304} diff --git a/Assets/Scripts/Games/AnimalAcrobat/AcrobatPlayer.cs b/Assets/Scripts/Games/AnimalAcrobat/AcrobatPlayer.cs index d3dd2f78e..84fcb9cba 100644 --- a/Assets/Scripts/Games/AnimalAcrobat/AcrobatPlayer.cs +++ b/Assets/Scripts/Games/AnimalAcrobat/AcrobatPlayer.cs @@ -8,6 +8,7 @@ namespace HeavenStudio.Games.Scripts_AnimalAcrobat public class AcrobatPlayer : SuperCurveObject { [Header("Values")] + [SerializeField] private float _jumpDistanceStart = 6f; [SerializeField] private float _jumpDistance = 8f; [SerializeField] private float _jumpHeight = 4f; [SerializeField] private float _jumpDistanceGiraffe = 32f; @@ -44,7 +45,7 @@ namespace HeavenStudio.Games.Scripts_AnimalAcrobat var cond = Conductor.instance; yield return new WaitUntil(() => cond.songPositionInBeatsAsDouble >= beat); _anim.DoScaledAnimationAsync("PlayerJump", 0.5f); - Jump(beat, 1, transform.localPosition.x, _jumpDistance, _jumpHeight, transform.localPosition.y); + Jump(beat, 1, transform.localPosition.x, _jumpDistanceStart, _jumpHeight, transform.localPosition.y); } private void Jump(double beat, float length, float startPoint, float distance, float height, float restY) diff --git a/Assets/Scripts/Games/AnimalAcrobat/GiraffeInput.cs b/Assets/Scripts/Games/AnimalAcrobat/GiraffeInput.cs index 1b3f98f53..d58bb531f 100644 --- a/Assets/Scripts/Games/AnimalAcrobat/GiraffeInput.cs +++ b/Assets/Scripts/Games/AnimalAcrobat/GiraffeInput.cs @@ -43,7 +43,7 @@ namespace HeavenStudio.Games.Scripts_AnimalAcrobat { SoundByte.PlayOneShotGame("animalAcrobat/catch"); _monkey.gameObject.SetActive(true); - _monkey.DoScaledAnimationAsync("PlayerHang", 0.75f); + _monkey.DoScaledAnimationAsync("PlayerHang", 1f, 0.4f); _game.PlayerSetActive(false); BeatAction.New(this, new List() { @@ -59,14 +59,14 @@ namespace HeavenStudio.Games.Scripts_AnimalAcrobat { SoundByte.PlayOneShotGame("animalAcrobat/giraffeCatch"); _monkey.gameObject.SetActive(true); - _monkey.DoScaledAnimationAsync("PlayerHang", 0.75f); + _monkey.DoScaledAnimationAsync("PlayerHang", 1f, 0.4f); _game.PlayerSetActive(false); BeatAction.New(this, new List() { new BeatAction.Action(0, delegate {}), new BeatAction.Action(caller.startBeat + caller.timer + 2, delegate { - _monkey.DoScaledAnimationAsync("PlayerHanging", 0.5f); + _monkey.DoScaledAnimationAsync("PlayerHanging", 0.25f); }) }); } diff --git a/Assets/Scripts/Games/AnimalAcrobat/ObstacleInput.cs b/Assets/Scripts/Games/AnimalAcrobat/ObstacleInput.cs index 5d281147d..07e9b3801 100644 --- a/Assets/Scripts/Games/AnimalAcrobat/ObstacleInput.cs +++ b/Assets/Scripts/Games/AnimalAcrobat/ObstacleInput.cs @@ -38,14 +38,14 @@ namespace HeavenStudio.Games.Scripts_AnimalAcrobat { SoundByte.PlayOneShotGame("animalAcrobat/catch"); _monkey.gameObject.SetActive(true); - _monkey.DoScaledAnimationAsync("PlayerHang", 0.75f); + _monkey.DoScaledAnimationAsync("PlayerHang", 1f, 0.4f); _game.PlayerSetActive(false); BeatAction.New(this, new List() { new BeatAction.Action(0, delegate {}), new BeatAction.Action(caller.startBeat + caller.timer + (_holdLength * 0.5), delegate { - _monkey.DoScaledAnimationAsync("PlayerHanging", 0.5f); + _monkey.DoScaledAnimationAsync("PlayerHanging", 0.5f / ((float)_holdLength * 0.5f)); }) }); } @@ -54,7 +54,7 @@ namespace HeavenStudio.Games.Scripts_AnimalAcrobat { SoundByte.PlayOneShotGame("animalAcrobat/giraffeCatch"); _monkey.gameObject.SetActive(true); - _monkey.DoScaledAnimationAsync("PlayerHang", 0.75f); + _monkey.DoScaledAnimationAsync("PlayerHang", 1f, 0.4f); _game.PlayerSetActive(false); BeatAction.New(this, new List() {