From bc9fae7e2a168e3df9ab2f24f48987732d6e306a Mon Sep 17 00:00:00 2001 From: fu-majime Date: Thu, 4 Apr 2024 21:09:27 +0900 Subject: [PATCH] Preliminary stage of sorting according to the equation --- .../A Button Podium Thing.controller | 33 +- .../Games/BouncyRoad/Animations/A Podium.anim | 202 ++++++---- .../Animations/D-Pad Podium Thing.controller | 33 +- .../BouncyRoad/Animations/D-Pad Podium.anim | 380 ++++++++++-------- .../BouncyRoad/Animations/Thing Podium.anim | 58 +-- .../BouncyRoad/Animations/Thing.controller | 33 +- .../Games/BouncyRoad/Bouncy Road.png.meta | 6 +- Assets/Scripts/Games/BouncyRoad/Ball.cs | 65 +++ Assets/Scripts/Games/BouncyRoad/Ball.cs.meta | 11 + Assets/Scripts/Games/BouncyRoad/BouncyRoad.cs | 83 ++-- 10 files changed, 616 insertions(+), 288 deletions(-) create mode 100644 Assets/Scripts/Games/BouncyRoad/Ball.cs create mode 100644 Assets/Scripts/Games/BouncyRoad/Ball.cs.meta diff --git a/Assets/Resources/Sprites/Games/BouncyRoad/Animations/A Button Podium Thing.controller b/Assets/Resources/Sprites/Games/BouncyRoad/Animations/A Button Podium Thing.controller index 3321642e3..90be977d1 100644 --- a/Assets/Resources/Sprites/Games/BouncyRoad/Animations/A Button Podium Thing.controller +++ b/Assets/Resources/Sprites/Games/BouncyRoad/Animations/A Button Podium Thing.controller @@ -34,6 +34,9 @@ AnimatorStateMachine: - serializedVersion: 1 m_State: {fileID: 4679629724993699466} m_Position: {x: 200, y: 0, z: 0} + - serializedVersion: 1 + m_State: {fileID: 5840402754634895428} + m_Position: {x: 280, y: 90, z: 0} m_ChildStateMachines: [] m_AnyStateTransitions: [] m_EntryTransitions: [] @@ -43,7 +46,7 @@ AnimatorStateMachine: m_EntryPosition: {x: 50, y: 120, z: 0} m_ExitPosition: {x: 800, y: 120, z: 0} m_ParentStateMachinePosition: {x: 800, y: 20, z: 0} - m_DefaultState: {fileID: 4679629724993699466} + m_DefaultState: {fileID: 5840402754634895428} --- !u!1102 &4679629724993699466 AnimatorState: serializedVersion: 6 @@ -51,7 +54,7 @@ AnimatorState: m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_Name: A Podium + m_Name: podium m_Speed: 1 m_CycleOffset: 0 m_Transitions: [] @@ -70,3 +73,29 @@ AnimatorState: m_MirrorParameter: m_CycleOffsetParameter: m_TimeParameter: +--- !u!1102 &5840402754634895428 +AnimatorState: + serializedVersion: 6 + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: idle + m_Speed: 1 + m_CycleOffset: 0 + m_Transitions: [] + m_StateMachineBehaviours: [] + m_Position: {x: 50, y: 50, z: 0} + m_IKOnFeet: 0 + m_WriteDefaultValues: 1 + m_Mirror: 0 + m_SpeedParameterActive: 0 + m_MirrorParameterActive: 0 + m_CycleOffsetParameterActive: 0 + m_TimeParameterActive: 0 + m_Motion: {fileID: 0} + m_Tag: + m_SpeedParameter: + m_MirrorParameter: + m_CycleOffsetParameter: + m_TimeParameter: diff --git a/Assets/Resources/Sprites/Games/BouncyRoad/Animations/A Podium.anim b/Assets/Resources/Sprites/Games/BouncyRoad/Animations/A Podium.anim index 3c43350ef..c420fe146 100644 --- a/Assets/Resources/Sprites/Games/BouncyRoad/Animations/A Podium.anim +++ b/Assets/Resources/Sprites/Games/BouncyRoad/Animations/A Podium.anim @@ -20,63 +20,63 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: {x: 0.4, y: -2.65, z: 0} - inSlope: {x: 0, y: 0, z: 0} - outSlope: {x: 0, y: 0, z: 0} + value: {x: 0, y: -0.175, z: 0} + inSlope: {x: Infinity, y: 0, z: 0} + outSlope: {x: Infinity, y: 0, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.033333335 - value: {x: 0.4, y: -2.7, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} + value: {x: 0, y: -0.23, z: 0} + inSlope: {x: Infinity, y: Infinity, z: 0} + outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 - weightedMode: 3 + weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.06666667 - value: {x: 0.4, y: -2.95, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} + value: {x: 0, y: -0.5, z: 0} + inSlope: {x: Infinity, y: Infinity, z: 0} + outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.1 - value: {x: 0.4, y: -3.05, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} + value: {x: 0, y: -0.625, z: 0} + inSlope: {x: Infinity, y: Infinity, z: 0} + outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.13333334 - value: {x: 0.4, y: -3.12, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} + value: {x: 0, y: -0.7, z: 0} + inSlope: {x: Infinity, y: Infinity, z: 0} + outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.16666667 - value: {x: 0.4, y: -3.2, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: 0, z: 0} + value: {x: 0, y: -0.8, z: 0} + inSlope: {x: Infinity, y: Infinity, z: 0} + outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.25 - value: {x: 0.4, y: -3.2, z: 0} - inSlope: {x: 0, y: 0, z: 0} - outSlope: {x: 0, y: 0, z: 0} + value: {x: 0, y: -0.8, z: 0} + inSlope: {x: Infinity, y: Infinity, z: 0} + outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} @@ -84,42 +84,51 @@ AnimationClip: m_PreInfinity: 2 m_PostInfinity: 2 m_RotationOrder: 4 - path: A Button Thing + path: Thing - curve: serializedVersion: 2 m_Curve: - serializedVersion: 3 time: 0 - value: {x: 0.3, y: -0.25, z: 0} - inSlope: {x: 0, y: 0, z: 0} - outSlope: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0.125, z: 0} + inSlope: {x: 0, y: Infinity, z: 0} + outSlope: {x: 0, y: Infinity, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.033333335 - value: {x: 0.3, y: -0.3, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} + value: {x: 0, y: 0.075, z: 0} + inSlope: {x: Infinity, y: Infinity, z: Infinity} + outSlope: {x: Infinity, y: Infinity, z: Infinity} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.06666667 - value: {x: 0.3, y: -0.35, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} + value: {x: 0, y: 0.025, z: 0} + inSlope: {x: Infinity, y: Infinity, z: Infinity} + outSlope: {x: Infinity, y: Infinity, z: Infinity} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.1 - value: {x: 0.3, y: -0.375, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} + value: {x: 0, y: 0, z: 0} + inSlope: {x: Infinity, y: Infinity, z: Infinity} + outSlope: {x: Infinity, y: Infinity, z: Infinity} + tangentMode: 0 + weightedMode: 0 + inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} + outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} + - serializedVersion: 3 + time: 0.25 + value: {x: 0, y: 0, z: 0} + inSlope: {x: Infinity, y: Infinity, z: Infinity} + outSlope: {x: Infinity, y: Infinity, z: Infinity} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} @@ -127,7 +136,7 @@ AnimationClip: m_PreInfinity: 2 m_PostInfinity: 2 m_RotationOrder: 4 - path: A Button Thing Top + path: Thing Top m_ScaleCurves: [] m_FloatCurves: [] m_PPtrCurves: [] @@ -139,14 +148,14 @@ AnimationClip: m_ClipBindingConstant: genericBindings: - serializedVersion: 2 - path: 921841747 + path: 2592932743 attribute: 1 script: {fileID: 0} typeID: 4 customType: 0 isPPtrCurve: 0 - serializedVersion: 2 - path: 1279304544 + path: 3030146205 attribute: 1 script: {fileID: 0} typeID: 4 @@ -163,7 +172,7 @@ AnimationClip: m_Level: 0 m_CycleOffset: 0 m_HasAdditiveReferencePose: 0 - m_LoopTime: 1 + m_LoopTime: 0 m_LoopBlend: 0 m_LoopBlendOrientation: 0 m_LoopBlendPositionY: 0 @@ -179,19 +188,19 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: 0.4 - inSlope: 0 - outSlope: 0 - tangentMode: 136 + value: 0 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 weightedMode: 0 inWeight: 0.33333334 outWeight: 0.33333334 - serializedVersion: 3 time: 0.25 - value: 0.4 - inSlope: 0 - outSlope: 0 - tangentMode: 136 + value: 0 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 weightedMode: 0 inWeight: 0.33333334 outWeight: 0.33333334 @@ -199,7 +208,7 @@ AnimationClip: m_PostInfinity: 2 m_RotationOrder: 4 attribute: m_LocalPosition.x - path: A Button Thing + path: Thing classID: 4 script: {fileID: 0} - curve: @@ -207,7 +216,7 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: -2.65 + value: -0.175 inSlope: 0 outSlope: 0 tangentMode: 136 @@ -216,25 +225,25 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.033333335 - value: -2.7 + value: -0.23 inSlope: Infinity outSlope: Infinity - tangentMode: 103 - weightedMode: 3 + tangentMode: 1 + weightedMode: 0 inWeight: 0.33333334 outWeight: 0.33333334 - serializedVersion: 3 time: 0.06666667 - value: -2.95 + value: -0.5 inSlope: Infinity outSlope: Infinity - tangentMode: 103 + tangentMode: 97 weightedMode: 0 inWeight: 0.33333334 outWeight: 0.33333334 - serializedVersion: 3 time: 0.1 - value: -3.05 + value: -0.625 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -243,7 +252,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.13333334 - value: -3.12 + value: -0.7 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -252,7 +261,16 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.16666667 - value: -3.2 + value: -0.8 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 0.25 + value: -0.8 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -263,7 +281,7 @@ AnimationClip: m_PostInfinity: 2 m_RotationOrder: 4 attribute: m_LocalPosition.y - path: A Button Thing + path: Thing classID: 4 script: {fileID: 0} - curve: @@ -291,7 +309,7 @@ AnimationClip: m_PostInfinity: 2 m_RotationOrder: 4 attribute: m_LocalPosition.z - path: A Button Thing + path: Thing classID: 4 script: {fileID: 0} - curve: @@ -299,16 +317,44 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: -0.25 + value: 0 inSlope: 0 outSlope: 0 tangentMode: 136 weightedMode: 0 inWeight: 0.33333334 outWeight: 0.33333334 + - serializedVersion: 3 + time: 0.25 + value: 0 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + attribute: m_LocalPosition.x + path: Thing Top + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0.125 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 - serializedVersion: 3 time: 0.033333335 - value: -0.3 + value: 0.075 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -317,7 +363,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.06666667 - value: -0.35 + value: 0.025 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -326,7 +372,16 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.1 - value: -0.375 + value: 0 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 0.25 + value: 0 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -337,7 +392,7 @@ AnimationClip: m_PostInfinity: 2 m_RotationOrder: 4 attribute: m_LocalPosition.y - path: A Button Thing Top + path: Thing Top classID: 4 script: {fileID: 0} - curve: @@ -345,18 +400,27 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: 0.3 + value: 0 inSlope: 0 outSlope: 0 tangentMode: 136 weightedMode: 0 - inWeight: 0 - outWeight: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 0.25 + value: 0 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 m_PreInfinity: 2 m_PostInfinity: 2 m_RotationOrder: 4 - attribute: m_LocalPosition.x - path: A Button Thing Top + attribute: m_LocalPosition.z + path: Thing Top classID: 4 script: {fileID: 0} m_EulerEditorCurves: [] diff --git a/Assets/Resources/Sprites/Games/BouncyRoad/Animations/D-Pad Podium Thing.controller b/Assets/Resources/Sprites/Games/BouncyRoad/Animations/D-Pad Podium Thing.controller index a629dceb4..ba898a287 100644 --- a/Assets/Resources/Sprites/Games/BouncyRoad/Animations/D-Pad Podium Thing.controller +++ b/Assets/Resources/Sprites/Games/BouncyRoad/Animations/D-Pad Podium Thing.controller @@ -12,6 +12,9 @@ AnimatorStateMachine: - serializedVersion: 1 m_State: {fileID: 3657983181684331831} m_Position: {x: 200, y: 0, z: 0} + - serializedVersion: 1 + m_State: {fileID: -774459235572963157} + m_Position: {x: 260, y: 100, z: 0} m_ChildStateMachines: [] m_AnyStateTransitions: [] m_EntryTransitions: [] @@ -21,7 +24,33 @@ AnimatorStateMachine: m_EntryPosition: {x: 50, y: 120, z: 0} m_ExitPosition: {x: 800, y: 120, z: 0} m_ParentStateMachinePosition: {x: 800, y: 20, z: 0} - m_DefaultState: {fileID: 3657983181684331831} + m_DefaultState: {fileID: -774459235572963157} +--- !u!1102 &-774459235572963157 +AnimatorState: + serializedVersion: 6 + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: idle + m_Speed: 1 + m_CycleOffset: 0 + m_Transitions: [] + m_StateMachineBehaviours: [] + m_Position: {x: 50, y: 50, z: 0} + m_IKOnFeet: 0 + m_WriteDefaultValues: 1 + m_Mirror: 0 + m_SpeedParameterActive: 0 + m_MirrorParameterActive: 0 + m_CycleOffsetParameterActive: 0 + m_TimeParameterActive: 0 + m_Motion: {fileID: 0} + m_Tag: + m_SpeedParameter: + m_MirrorParameter: + m_CycleOffsetParameter: + m_TimeParameter: --- !u!91 &9100000 AnimatorController: m_ObjectHideFlags: 0 @@ -51,7 +80,7 @@ AnimatorState: m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_Name: D-Pad Podium + m_Name: podium m_Speed: 1 m_CycleOffset: 0 m_Transitions: [] diff --git a/Assets/Resources/Sprites/Games/BouncyRoad/Animations/D-Pad Podium.anim b/Assets/Resources/Sprites/Games/BouncyRoad/Animations/D-Pad Podium.anim index 0b7b26b57..80c2ea19d 100644 --- a/Assets/Resources/Sprites/Games/BouncyRoad/Animations/D-Pad Podium.anim +++ b/Assets/Resources/Sprites/Games/BouncyRoad/Animations/D-Pad Podium.anim @@ -20,106 +20,63 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: {x: -1.558, y: -0.25, z: 0} - inSlope: {x: 0, y: 0, z: 0} - outSlope: {x: 0, y: 0, z: 0} + value: {x: 0, y: -0.175, z: 0} + inSlope: {x: Infinity, y: 0, z: 0} + outSlope: {x: Infinity, y: 0, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.033333335 - value: {x: -1.558, y: -0.3, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} + value: {x: 0, y: -0.23, z: 0} + inSlope: {x: Infinity, y: Infinity, z: 0} + outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.06666667 - value: {x: -1.558, y: -0.35, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} + value: {x: 0, y: -0.5, z: 0} + inSlope: {x: Infinity, y: Infinity, z: 0} + outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.1 - value: {x: -1.558, y: -0.375, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} - tangentMode: 0 - weightedMode: 0 - inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - m_PreInfinity: 2 - m_PostInfinity: 2 - m_RotationOrder: 4 - path: D-Pad Thing Top - - curve: - serializedVersion: 2 - m_Curve: - - serializedVersion: 3 - time: 0 - value: {x: -1.6, y: -2.65, z: 0} - inSlope: {x: 0, y: 0, z: 0} - outSlope: {x: 0, y: 0, z: 0} - tangentMode: 0 - weightedMode: 0 - inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - - serializedVersion: 3 - time: 0.033333335 - value: {x: -1.6, y: -2.7, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} - tangentMode: 0 - weightedMode: 0 - inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - - serializedVersion: 3 - time: 0.06666667 - value: {x: -1.6, y: -2.95, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} - tangentMode: 0 - weightedMode: 0 - inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - - serializedVersion: 3 - time: 0.1 - value: {x: -1.6, y: -3.05, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} + value: {x: 0, y: -0.625, z: 0} + inSlope: {x: Infinity, y: Infinity, z: 0} + outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.13333334 - value: {x: -1.6, y: -3.12, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: Infinity, z: 0} + value: {x: 0, y: -0.7, z: 0} + inSlope: {x: Infinity, y: Infinity, z: 0} + outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.16666667 - value: {x: -1.6, y: -3.2, z: 0} - inSlope: {x: 0, y: Infinity, z: 0} - outSlope: {x: 0, y: 0, z: 0} + value: {x: 0, y: -0.8, z: 0} + inSlope: {x: Infinity, y: Infinity, z: 0} + outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.25 - value: {x: -1.6, y: -3.2, z: 0} - inSlope: {x: 0, y: 0, z: 0} - outSlope: {x: 0, y: 0, z: 0} + value: {x: 0, y: -0.8, z: 0} + inSlope: {x: Infinity, y: Infinity, z: 0} + outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 weightedMode: 0 inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} @@ -127,7 +84,59 @@ AnimationClip: m_PreInfinity: 2 m_PostInfinity: 2 m_RotationOrder: 4 - path: D-Pad Thing + path: Thing + - curve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: {x: 0, y: 0.125, z: 0} + inSlope: {x: 0, y: Infinity, z: 0} + outSlope: {x: 0, y: Infinity, z: 0} + tangentMode: 0 + weightedMode: 0 + inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} + outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} + - serializedVersion: 3 + time: 0.033333335 + value: {x: 0, y: 0.075, z: 0} + inSlope: {x: Infinity, y: Infinity, z: Infinity} + outSlope: {x: Infinity, y: Infinity, z: Infinity} + tangentMode: 0 + weightedMode: 0 + inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} + outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} + - serializedVersion: 3 + time: 0.06666667 + value: {x: 0, y: 0.025, z: 0} + inSlope: {x: Infinity, y: Infinity, z: Infinity} + outSlope: {x: Infinity, y: Infinity, z: Infinity} + tangentMode: 0 + weightedMode: 0 + inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} + outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} + - serializedVersion: 3 + time: 0.1 + value: {x: 0, y: 0, z: 0} + inSlope: {x: Infinity, y: Infinity, z: Infinity} + outSlope: {x: Infinity, y: Infinity, z: Infinity} + tangentMode: 0 + weightedMode: 0 + inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} + outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} + - serializedVersion: 3 + time: 0.25 + value: {x: 0, y: 0, z: 0} + inSlope: {x: Infinity, y: Infinity, z: Infinity} + outSlope: {x: Infinity, y: Infinity, z: Infinity} + tangentMode: 0 + weightedMode: 0 + inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} + outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + path: Thing Top m_ScaleCurves: [] m_FloatCurves: [] m_PPtrCurves: [] @@ -139,14 +148,14 @@ AnimationClip: m_ClipBindingConstant: genericBindings: - serializedVersion: 2 - path: 2859641909 + path: 2592932743 attribute: 1 script: {fileID: 0} typeID: 4 customType: 0 isPPtrCurve: 0 - serializedVersion: 2 - path: 4250676200 + path: 3030146205 attribute: 1 script: {fileID: 0} typeID: 4 @@ -163,7 +172,7 @@ AnimationClip: m_Level: 0 m_CycleOffset: 0 m_HasAdditiveReferencePose: 0 - m_LoopTime: 1 + m_LoopTime: 0 m_LoopBlend: 0 m_LoopBlendOrientation: 0 m_LoopBlendPositionY: 0 @@ -179,93 +188,19 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: -1.558 - inSlope: 0 - outSlope: 0 - tangentMode: 136 - weightedMode: 0 - inWeight: 0.33333334 - outWeight: 0.33333334 - m_PreInfinity: 2 - m_PostInfinity: 2 - m_RotationOrder: 4 - attribute: m_LocalPosition.x - path: D-Pad Thing Top - classID: 4 - script: {fileID: 0} - - curve: - serializedVersion: 2 - m_Curve: - - serializedVersion: 3 - time: 0 - value: -0.25 - inSlope: 0 - outSlope: 0 - tangentMode: 136 - weightedMode: 0 - inWeight: 0.33333334 - outWeight: 0.33333334 - - serializedVersion: 3 - time: 0.033333335 - value: -0.3 + value: 0 inSlope: Infinity outSlope: Infinity tangentMode: 103 weightedMode: 0 inWeight: 0.33333334 outWeight: 0.33333334 - - serializedVersion: 3 - time: 0.06666667 - value: -0.35 - inSlope: Infinity - outSlope: Infinity - tangentMode: 103 - weightedMode: 0 - inWeight: 0.33333334 - outWeight: 0.33333334 - - serializedVersion: 3 - time: 0.1 - value: -0.375 - inSlope: Infinity - outSlope: Infinity - tangentMode: 103 - weightedMode: 0 - inWeight: 0.33333334 - outWeight: 0.33333334 - m_PreInfinity: 2 - m_PostInfinity: 2 - m_RotationOrder: 4 - attribute: m_LocalPosition.y - path: D-Pad Thing Top - classID: 4 - script: {fileID: 0} - - curve: - serializedVersion: 2 - m_Curve: - - serializedVersion: 3 - time: 0 - value: -1.6 - inSlope: 0 - outSlope: 0 - tangentMode: 136 - weightedMode: 0 - inWeight: 0.33333334 - outWeight: 0.33333334 - - serializedVersion: 3 - time: 0.033333335 - value: -1.6 - inSlope: 0 - outSlope: 0 - tangentMode: 136 - weightedMode: 0 - inWeight: 0.33333334 - outWeight: 0.33333334 - serializedVersion: 3 time: 0.25 - value: -1.6 - inSlope: 0 - outSlope: 0 - tangentMode: 136 + value: 0 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 weightedMode: 0 inWeight: 0.33333334 outWeight: 0.33333334 @@ -273,7 +208,7 @@ AnimationClip: m_PostInfinity: 2 m_RotationOrder: 4 attribute: m_LocalPosition.x - path: D-Pad Thing + path: Thing classID: 4 script: {fileID: 0} - curve: @@ -281,7 +216,7 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: -2.65 + value: -0.175 inSlope: 0 outSlope: 0 tangentMode: 136 @@ -290,25 +225,25 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.033333335 - value: -2.7 + value: -0.23 inSlope: Infinity outSlope: Infinity - tangentMode: 103 + tangentMode: 1 weightedMode: 0 inWeight: 0.33333334 outWeight: 0.33333334 - serializedVersion: 3 time: 0.06666667 - value: -2.95 + value: -0.5 inSlope: Infinity outSlope: Infinity - tangentMode: 103 + tangentMode: 97 weightedMode: 0 inWeight: 0.33333334 outWeight: 0.33333334 - serializedVersion: 3 time: 0.1 - value: -3.05 + value: -0.625 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -317,7 +252,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.13333334 - value: -3.12 + value: -0.7 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -326,7 +261,16 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.16666667 - value: -3.2 + value: -0.8 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 0.25 + value: -0.8 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -337,12 +281,21 @@ AnimationClip: m_PostInfinity: 2 m_RotationOrder: 4 attribute: m_LocalPosition.y - path: D-Pad Thing + path: Thing classID: 4 script: {fileID: 0} - curve: serializedVersion: 2 m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 136 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 - serializedVersion: 3 time: 0.25 value: 0 @@ -356,7 +309,118 @@ AnimationClip: m_PostInfinity: 2 m_RotationOrder: 4 attribute: m_LocalPosition.z - path: D-Pad Thing + path: Thing + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 136 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 0.25 + value: 0 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + attribute: m_LocalPosition.x + path: Thing Top + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0.125 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 0.033333335 + value: 0.075 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 0.06666667 + value: 0.025 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 0.1 + value: 0 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 0.25 + value: 0 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + attribute: m_LocalPosition.y + path: Thing Top + classID: 4 + script: {fileID: 0} + - curve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 0 + value: 0 + inSlope: 0 + outSlope: 0 + tangentMode: 136 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + - serializedVersion: 3 + time: 0.25 + value: 0 + inSlope: Infinity + outSlope: Infinity + tangentMode: 103 + weightedMode: 0 + inWeight: 0.33333334 + outWeight: 0.33333334 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + attribute: m_LocalPosition.z + path: Thing Top classID: 4 script: {fileID: 0} m_EulerEditorCurves: [] diff --git a/Assets/Resources/Sprites/Games/BouncyRoad/Animations/Thing Podium.anim b/Assets/Resources/Sprites/Games/BouncyRoad/Animations/Thing Podium.anim index 1ced18d80..67e9fa3ce 100644 --- a/Assets/Resources/Sprites/Games/BouncyRoad/Animations/Thing Podium.anim +++ b/Assets/Resources/Sprites/Games/BouncyRoad/Animations/Thing Podium.anim @@ -20,7 +20,7 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: {x: 2, y: -0.25, z: 0} + value: {x: 0, y: 0.125, z: 0} inSlope: {x: 0, y: Infinity, z: 0} outSlope: {x: 0, y: Infinity, z: 0} tangentMode: 0 @@ -29,7 +29,7 @@ AnimationClip: outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.033333335 - value: {x: 2, y: -0.3, z: 0} + value: {x: 0, y: 0.075, z: 0} inSlope: {x: Infinity, y: Infinity, z: Infinity} outSlope: {x: Infinity, y: Infinity, z: Infinity} tangentMode: 0 @@ -38,7 +38,7 @@ AnimationClip: outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.06666667 - value: {x: 2, y: -0.35, z: 0} + value: {x: 0, y: 0.025, z: 0} inSlope: {x: Infinity, y: Infinity, z: Infinity} outSlope: {x: Infinity, y: Infinity, z: Infinity} tangentMode: 0 @@ -47,7 +47,7 @@ AnimationClip: outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.1 - value: {x: 2, y: -0.375, z: 0} + value: {x: 0, y: 0, z: 0} inSlope: {x: Infinity, y: Infinity, z: Infinity} outSlope: {x: Infinity, y: Infinity, z: Infinity} tangentMode: 0 @@ -56,7 +56,7 @@ AnimationClip: outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.25 - value: {x: 2, y: -0.375, z: 0} + value: {x: 0, y: 0, z: 0} inSlope: {x: Infinity, y: Infinity, z: Infinity} outSlope: {x: Infinity, y: Infinity, z: Infinity} tangentMode: 0 @@ -72,7 +72,7 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: {x: 2.02, y: -0.55, z: 0} + value: {x: 0, y: -0.175, z: 0} inSlope: {x: Infinity, y: 0, z: 0} outSlope: {x: Infinity, y: 0, z: 0} tangentMode: 0 @@ -81,7 +81,7 @@ AnimationClip: outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.033333335 - value: {x: 2.02, y: -0.6, z: 0} + value: {x: 0, y: -0.225, z: 0} inSlope: {x: Infinity, y: Infinity, z: 0} outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 @@ -90,7 +90,7 @@ AnimationClip: outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.06666667 - value: {x: 2.02, y: -0.85, z: 0} + value: {x: 0, y: -0.475, z: 0} inSlope: {x: Infinity, y: Infinity, z: 0} outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 @@ -99,7 +99,7 @@ AnimationClip: outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.1 - value: {x: 2.02, y: -0.95, z: 0} + value: {x: 0, y: -0.575, z: 0} inSlope: {x: Infinity, y: Infinity, z: 0} outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 @@ -108,7 +108,7 @@ AnimationClip: outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.13333334 - value: {x: 2.02, y: -1.02, z: 0} + value: {x: 0, y: -0.645, z: 0} inSlope: {x: Infinity, y: Infinity, z: 0} outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 @@ -117,7 +117,7 @@ AnimationClip: outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.16666667 - value: {x: 2.02, y: -1.1, z: 0} + value: {x: 0, y: -0.725, z: 0} inSlope: {x: Infinity, y: Infinity, z: 0} outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 @@ -126,7 +126,7 @@ AnimationClip: outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334} - serializedVersion: 3 time: 0.25 - value: {x: 2.01, y: -1.1, z: 0} + value: {x: 0, y: -0.725, z: 0} inSlope: {x: Infinity, y: Infinity, z: 0} outSlope: {x: Infinity, y: Infinity, z: 0} tangentMode: 0 @@ -172,7 +172,7 @@ AnimationClip: m_Level: 0 m_CycleOffset: 0 m_HasAdditiveReferencePose: 0 - m_LoopTime: 1 + m_LoopTime: 0 m_LoopBlend: 0 m_LoopBlendOrientation: 0 m_LoopBlendPositionY: 0 @@ -188,7 +188,7 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: 2 + value: 0 inSlope: 0 outSlope: 0 tangentMode: 136 @@ -197,7 +197,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.25 - value: 2 + value: 0 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -216,7 +216,7 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: -0.25 + value: 0.125 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -225,7 +225,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.033333335 - value: -0.3 + value: 0.075 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -234,7 +234,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.06666667 - value: -0.35 + value: 0.025 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -243,7 +243,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.1 - value: -0.375 + value: 0 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -252,7 +252,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.25 - value: -0.375 + value: 0 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -299,7 +299,7 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: 2.02 + value: 0 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -308,7 +308,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.25 - value: 2.01 + value: 0 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -327,7 +327,7 @@ AnimationClip: m_Curve: - serializedVersion: 3 time: 0 - value: -0.55 + value: -0.175 inSlope: 0 outSlope: 0 tangentMode: 136 @@ -336,7 +336,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.033333335 - value: -0.6 + value: -0.225 inSlope: Infinity outSlope: Infinity tangentMode: 1 @@ -345,7 +345,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.06666667 - value: -0.85 + value: -0.475 inSlope: Infinity outSlope: Infinity tangentMode: 97 @@ -354,7 +354,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.1 - value: -0.95 + value: -0.575 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -363,7 +363,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.13333334 - value: -1.02 + value: -0.645 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -372,7 +372,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.16666667 - value: -1.1 + value: -0.725 inSlope: Infinity outSlope: Infinity tangentMode: 103 @@ -381,7 +381,7 @@ AnimationClip: outWeight: 0.33333334 - serializedVersion: 3 time: 0.25 - value: -1.1 + value: -0.725 inSlope: Infinity outSlope: Infinity tangentMode: 103 diff --git a/Assets/Resources/Sprites/Games/BouncyRoad/Animations/Thing.controller b/Assets/Resources/Sprites/Games/BouncyRoad/Animations/Thing.controller index f17d5217f..27481af01 100644 --- a/Assets/Resources/Sprites/Games/BouncyRoad/Animations/Thing.controller +++ b/Assets/Resources/Sprites/Games/BouncyRoad/Animations/Thing.controller @@ -7,7 +7,7 @@ AnimatorState: m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_Name: Thing + m_Name: podium m_Speed: 1 m_CycleOffset: 0 m_Transitions: [] @@ -48,6 +48,32 @@ AnimatorController: m_IKPass: 0 m_SyncedLayerAffectsTiming: 0 m_Controller: {fileID: 9100000} +--- !u!1102 &408660084763059348 +AnimatorState: + serializedVersion: 6 + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: idle + m_Speed: 1 + m_CycleOffset: 0 + m_Transitions: [] + m_StateMachineBehaviours: [] + m_Position: {x: 50, y: 50, z: 0} + m_IKOnFeet: 0 + m_WriteDefaultValues: 1 + m_Mirror: 0 + m_SpeedParameterActive: 0 + m_MirrorParameterActive: 0 + m_CycleOffsetParameterActive: 0 + m_TimeParameterActive: 0 + m_Motion: {fileID: 0} + m_Tag: + m_SpeedParameter: + m_MirrorParameter: + m_CycleOffsetParameter: + m_TimeParameter: --- !u!1107 &4295628780135985117 AnimatorStateMachine: serializedVersion: 6 @@ -60,6 +86,9 @@ AnimatorStateMachine: - serializedVersion: 1 m_State: {fileID: -2871036576465587584} m_Position: {x: 200, y: 0, z: 0} + - serializedVersion: 1 + m_State: {fileID: 408660084763059348} + m_Position: {x: 270, y: 70, z: 0} m_ChildStateMachines: [] m_AnyStateTransitions: [] m_EntryTransitions: [] @@ -69,4 +98,4 @@ AnimatorStateMachine: m_EntryPosition: {x: 50, y: 120, z: 0} m_ExitPosition: {x: 800, y: 120, z: 0} m_ParentStateMachinePosition: {x: 800, y: 20, z: 0} - m_DefaultState: {fileID: -2871036576465587584} + m_DefaultState: {fileID: 408660084763059348} diff --git a/Assets/Resources/Sprites/Games/BouncyRoad/Bouncy Road.png.meta b/Assets/Resources/Sprites/Games/BouncyRoad/Bouncy Road.png.meta index 228435c04..711b40825 100644 --- a/Assets/Resources/Sprites/Games/BouncyRoad/Bouncy Road.png.meta +++ b/Assets/Resources/Sprites/Games/BouncyRoad/Bouncy Road.png.meta @@ -171,10 +171,10 @@ TextureImporter: name: Ball rect: serializedVersion: 2 - x: 1017 + x: 1018 y: 1354 - width: 122 - height: 127 + width: 124 + height: 124 alignment: 0 pivot: {x: 0.5, y: 0.5} border: {x: 0, y: 0, z: 0, w: 0} diff --git a/Assets/Scripts/Games/BouncyRoad/Ball.cs b/Assets/Scripts/Games/BouncyRoad/Ball.cs new file mode 100644 index 000000000..a9978cfd4 --- /dev/null +++ b/Assets/Scripts/Games/BouncyRoad/Ball.cs @@ -0,0 +1,65 @@ +using System; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using NaughtyBezierCurves; + +namespace HeavenStudio.Games.Scripts_BouncyRoad +{ + using HeavenStudio.Util; + public class Ball : MonoBehaviour + { + [System.NonSerialized] public double startBeat, lengthBeat; + private double currentBeat; + + private BezierCurve3D currentCurve; + + private BouncyRoad game; + + public void Init() + { + game = BouncyRoad.instance; + + currentBeat = startBeat; + Bounce(); + } + void Update() + { + var cond = Conductor.instance; + + if (currentCurve is not null) + { + float curveProg = cond.GetPositionFromBeat(currentBeat, lengthBeat); + transform.position = currentCurve.GetPoint(curveProg); + } + } + + private void Bounce() + { + var sounds = new List(); + for (int i = 0; i < 12 ; i++) + { + sounds.Add(new MultiSound.Sound("bouncyRoad/ballBounce", startBeat + i * lengthBeat)); + } + sounds.Add(new MultiSound.Sound("bouncyRoad/ballRight", startBeat + 12 * lengthBeat)); + sounds.Add(new MultiSound.Sound("bouncyRoad/ballLeft", startBeat + 13 * lengthBeat)); + sounds.Add(new MultiSound.Sound("bouncyRoad/goal", startBeat + 14 * lengthBeat)); + MultiSound.Play(sounds.ToArray()); + + var actions = new List(); + for (int i = 0; i < 15 ; i++) + { + int currentItr = i; + actions.Add(new BeatAction.Action(startBeat + currentItr * lengthBeat, delegate { + game.ThingsAnim[currentItr].Play("podium", 0, 0); + currentCurve = game.curve[currentItr]; + currentBeat = startBeat + currentItr * lengthBeat; + })); + } + actions.Add(new BeatAction.Action(startBeat + 15 * lengthBeat, delegate { + Destroy(gameObject); + })); + BeatAction.New(game, actions); + } + } +} \ No newline at end of file diff --git a/Assets/Scripts/Games/BouncyRoad/Ball.cs.meta b/Assets/Scripts/Games/BouncyRoad/Ball.cs.meta new file mode 100644 index 000000000..d46a33477 --- /dev/null +++ b/Assets/Scripts/Games/BouncyRoad/Ball.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 632739a1ddc985249adeaeccbd66de58 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scripts/Games/BouncyRoad/BouncyRoad.cs b/Assets/Scripts/Games/BouncyRoad/BouncyRoad.cs index 78c443605..1ba5f4a89 100644 --- a/Assets/Scripts/Games/BouncyRoad/BouncyRoad.cs +++ b/Assets/Scripts/Games/BouncyRoad/BouncyRoad.cs @@ -3,7 +3,7 @@ using System.Linq; using System.Collections; using System.Collections.Generic; using UnityEngine; -// using GhostiGuy's Insanity +using NaughtyBezierCurves; using HeavenStudio.Util; using HeavenStudio.InputSystem; @@ -26,7 +26,11 @@ namespace HeavenStudio.Games.Loaders defaultLength = 1f, resizable = true, }, - } + }, + new List() { "agb", "normal" }, + "agbbouncy", "en", + new List() { }, + chronologicalSortKey: 24 ); } } @@ -34,10 +38,18 @@ namespace HeavenStudio.Games.Loaders namespace HeavenStudio.Games { + using Scripts_BouncyRoad; public class BouncyRoad : Minigame { + [SerializeField] GameObject baseBall; + [SerializeField] GameObject baseBounceCurve; + + [SerializeField] Transform ThingsTrans; + [System.NonSerialized] public Animator[] ThingsAnim; + [System.NonSerialized] public BezierCurve3D[] curve; + [SerializeField] BezierCurve3D PosCurve; + public static BouncyRoad instance; - [SerializeField] Animator[] Things; const int IALeft = 0; const int IARight = 1; @@ -74,6 +86,34 @@ namespace HeavenStudio.Games void Awake() { instance = this; + + ThingsAnim = new Animator[ThingsTrans.childCount]; + int childIndex = 0; + foreach (Transform child in ThingsTrans) + { + // var prog = (float)childIndex/(ThingsTrans.childCount-1); + // child.transform.localPosition = PosCurve.GetPoint(prog); + ThingsAnim[childIndex++] = child.GetComponent(); + } + + curve = new BezierCurve3D[ThingsTrans.childCount]; + for (var i = 0; i < ThingsAnim.Length; ++i) + { + var prog1 = (float)i/(ThingsTrans.childCount-1); + var prog2 = (float)(i+1)/(ThingsTrans.childCount-1); + var pos1 = PosCurve.GetPoint(prog1); + var pos2 = PosCurve.GetPoint(prog2); + float angle = Mathf.Atan2(pos1.z - pos2.z, pos1.x - pos2.x) * Mathf.Rad2Deg; + + var newCurve = Instantiate(baseBounceCurve, transform).transform; + + newCurve.GetChild(0).transform.localPosition = pos1; + newCurve.GetChild(0).transform.localEulerAngles = new Vector3(0, -angle, 0); + newCurve.GetChild(1).transform.localPosition = pos2; + newCurve.GetChild(1).transform.localEulerAngles = new Vector3(0, -angle, 0); + + curve[i] = newCurve.GetComponent(); + } } void Update() @@ -83,35 +123,32 @@ namespace HeavenStudio.Games if (PlayerInput.GetIsAction(InputAction_Right) && !IsExpectingInputNow(InputAction_Right)) { - Things[12].Play("podium", 0, 0); + ThingsAnim[12].Play("podium", 0, 0); } if (PlayerInput.GetIsAction(InputAction_Left) && !IsExpectingInputNow(InputAction_Left)) { - Things[13].Play("podium", 0, 0); + ThingsAnim[13].Play("podium", 0, 0); } } public void SpawnBall(double beat, double length) { - var sounds = new List(); - for (int i = 0; i < 12 ; i++) - { - sounds.Add(new MultiSound.Sound("bouncyRoad/ballBounce", beat + i * length)); - } - sounds.Add(new MultiSound.Sound("bouncyRoad/ballRight", beat + 12 * length)); - sounds.Add(new MultiSound.Sound("bouncyRoad/ballLeft", beat + 13 * length)); - sounds.Add(new MultiSound.Sound("bouncyRoad/goal", beat + 14 * length)); - MultiSound.Play(sounds.ToArray()); - var actions = new List(); - for (int i = 0; i < 15 ; i++) + var newBall = Instantiate(baseBall, transform).GetComponent(); + + newBall.startBeat = beat; + newBall.lengthBeat = length; + + BeatAction.New(instance, new List() { - int currentItr = i; - actions.Add(new BeatAction.Action(beat + i * length, delegate { - Things[currentItr].Play("podium", 0, 0); - })); - } - BeatAction.New(instance, actions); - } + new BeatAction.Action(beat, delegate + { + newBall.Init(); + newBall.gameObject.SetActive(true); + }) + }); + + + } } }