From b5140d10b1e9c6f54d5b01764f4f485de209a3b5 Mon Sep 17 00:00:00 2001 From: Rapandrasmus <78219215+Rapandrasmus@users.noreply.github.com> Date: Sat, 7 Oct 2023 22:33:50 +0200 Subject: [PATCH] Enough. Tweaking. --- Assets/Resources/Games/animalAcrobat.prefab | 1 + .../Resources/Prefabs/Games/AnimalAcrobat/Giraffe.prefab | 5 ++--- .../Prefabs/Games/AnimalAcrobat/WhiteMonkey.prefab | 7 +++---- .../Prefabs/Games/AnimalAcrobat/WhiteMonkeys.prefab | 9 ++++----- Assets/Scripts/Games/AnimalAcrobat/AcrobatObstacle.cs | 3 --- Assets/Scripts/Games/AnimalAcrobat/AnimalAcrobat.cs | 3 ++- 6 files changed, 12 insertions(+), 16 deletions(-) diff --git a/Assets/Resources/Games/animalAcrobat.prefab b/Assets/Resources/Games/animalAcrobat.prefab index 7b91de810..abace587b 100644 --- a/Assets/Resources/Games/animalAcrobat.prefab +++ b/Assets/Resources/Games/animalAcrobat.prefab @@ -528,6 +528,7 @@ MonoBehaviour: _jumpDistance: 8 _jumpDistanceGiraffe: 32 _jumpStartCameraDistance: 3 + _jumpStartDistance: -1.25 _giraffeCameraZoom: 12 --- !u!1 &9154566379104488428 GameObject: diff --git a/Assets/Resources/Prefabs/Games/AnimalAcrobat/Giraffe.prefab b/Assets/Resources/Prefabs/Games/AnimalAcrobat/Giraffe.prefab index b400bfe0e..31590f38d 100644 --- a/Assets/Resources/Prefabs/Games/AnimalAcrobat/Giraffe.prefab +++ b/Assets/Resources/Prefabs/Games/AnimalAcrobat/Giraffe.prefab @@ -303,7 +303,6 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: _fullRotRange: 160 - _spawnOffset: -1 _holdLength: 4 _ease: 4 _rotateRoot: {fileID: 4208995891253938729} @@ -361,7 +360,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 3911272779464478738} m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: 2.659, y: 0.68099976, z: 0} + m_LocalPosition: {x: 2.459, y: 0.68099976, z: 0} m_LocalScale: {x: 0.75091, y: 0.75091, z: 0.75091} m_ConstrainProportionsScale: 0 m_Children: [] @@ -562,7 +561,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 5674205584559157106} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 2.6, y: 0.8, z: 0} + m_LocalPosition: {x: 2.4, y: 0.8, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: diff --git a/Assets/Resources/Prefabs/Games/AnimalAcrobat/WhiteMonkey.prefab b/Assets/Resources/Prefabs/Games/AnimalAcrobat/WhiteMonkey.prefab index bbe023f2b..f4dbe60a6 100644 --- a/Assets/Resources/Prefabs/Games/AnimalAcrobat/WhiteMonkey.prefab +++ b/Assets/Resources/Prefabs/Games/AnimalAcrobat/WhiteMonkey.prefab @@ -108,7 +108,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1326311291227833683} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: -1.9, z: 0} + m_LocalPosition: {x: 0, y: -1.5, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] @@ -141,7 +141,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1656536018348746482} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalPosition: {x: 1, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: @@ -162,7 +162,6 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: _fullRotRange: 160 - _spawnOffset: 0 _holdLength: 1 _ease: 4 _rotateRoot: {fileID: 2068126119450832752} @@ -373,7 +372,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 7319071693544032937} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0.49, z: 0} + m_LocalPosition: {x: 1.25, y: 0.49, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: diff --git a/Assets/Resources/Prefabs/Games/AnimalAcrobat/WhiteMonkeys.prefab b/Assets/Resources/Prefabs/Games/AnimalAcrobat/WhiteMonkeys.prefab index 25b8fb24e..32d200ecc 100644 --- a/Assets/Resources/Prefabs/Games/AnimalAcrobat/WhiteMonkeys.prefab +++ b/Assets/Resources/Prefabs/Games/AnimalAcrobat/WhiteMonkeys.prefab @@ -649,7 +649,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 3530077400513613063} m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: 0.8995676, y: 0.44255477, z: 0.13394769} + m_LocalPosition: {x: 1.649568, y: 0.44255477, z: 0.13394769} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: @@ -1116,7 +1116,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 5202088941643817628} m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: 0.9, y: 0.53, z: 0.13394769} + m_LocalPosition: {x: 1.65, y: 0.53, z: 0.13394769} m_LocalScale: {x: 0.75091, y: 0.75091, z: 0.75091} m_ConstrainProportionsScale: 0 m_Children: [] @@ -1933,7 +1933,6 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: _fullRotRange: 160 - _spawnOffset: 0 _holdLength: 3 _ease: 4 _rotateRoot: {fileID: 3903953954711634507} @@ -1993,7 +1992,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 8302616130811808557} m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: 1.164, y: 1.959, z: 0.13394769} + m_LocalPosition: {x: 1.914, y: 1.959, z: 0.13394769} m_LocalScale: {x: 0.75091, y: 0.75091, z: 0.75091} m_ConstrainProportionsScale: 0 m_Children: [] @@ -2160,7 +2159,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 9082431704919230402} m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: 0, y: -8.6, z: 0} + m_LocalPosition: {x: 0, y: -8.3, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] diff --git a/Assets/Scripts/Games/AnimalAcrobat/AcrobatObstacle.cs b/Assets/Scripts/Games/AnimalAcrobat/AcrobatObstacle.cs index 191bdf7e1..0bc9ee029 100644 --- a/Assets/Scripts/Games/AnimalAcrobat/AcrobatObstacle.cs +++ b/Assets/Scripts/Games/AnimalAcrobat/AcrobatObstacle.cs @@ -13,7 +13,6 @@ namespace HeavenStudio.Games.Scripts_AnimalAcrobat [Header("Values")] [SerializeField] private float _fullRotRange; - [SerializeField] private float _spawnOffset; [SerializeField] private double _holdLength; [SerializeField] private EasingFunction.Ease _ease = EasingFunction.Ease.EaseInOutQuad; @@ -22,8 +21,6 @@ namespace HeavenStudio.Games.Scripts_AnimalAcrobat private float _halfRotRange; private EasingFunction.Function _func; - public float SpawnOffset => _spawnOffset; - [Header("Components")] [SerializeField] private Transform _rotateRoot; [SerializeField] private Transform _gripPoint; diff --git a/Assets/Scripts/Games/AnimalAcrobat/AnimalAcrobat.cs b/Assets/Scripts/Games/AnimalAcrobat/AnimalAcrobat.cs index 58d76008e..e14e8b5b9 100644 --- a/Assets/Scripts/Games/AnimalAcrobat/AnimalAcrobat.cs +++ b/Assets/Scripts/Games/AnimalAcrobat/AnimalAcrobat.cs @@ -68,6 +68,7 @@ namespace HeavenStudio.Games [SerializeField] private float _jumpDistance = 8; [SerializeField] private float _jumpDistanceGiraffe = 16; [SerializeField] private float _jumpStartCameraDistance = 4; + [SerializeField] private float _jumpStartDistance = -1; [SerializeField] private float _giraffeCameraZoom = 5; private List _pooledElephants = new(), _pooledGiraffes = new(), _pooledMonkeysLong = new(), _pooledMonkeysShort = new(); @@ -250,7 +251,7 @@ namespace HeavenStudio.Games }; var animal = pooledObstacles.Find(x => x.IsAvailableAtBeat(currentAnimal.startBeat)); - if (_animalPoolIndex == 0) _animalSummatedDistance = animal.SpawnOffset; + if (_animalPoolIndex == 0) _animalSummatedDistance = _jumpStartDistance; animal.gameObject.SetActive(true); double expBeat = currentAnimal.startBeat + currentAnimal.length;