controller title screen nav

This commit is contained in:
minenice55 2023-12-24 23:12:25 -05:00
parent 2d57217a6a
commit 5b2b793b66
6 changed files with 641 additions and 89 deletions

View file

@ -154,7 +154,7 @@ RectTransform:
m_ConstrainProportionsScale: 0 m_ConstrainProportionsScale: 0
m_Children: [] m_Children: []
m_Father: {fileID: 551511482} m_Father: {fileID: 551511482}
m_RootOrder: 15 m_RootOrder: 16
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5}
@ -482,7 +482,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 530.49994, y: -10.576233} m_AnchoredPosition: {x: 551, y: -14.409576}
m_SizeDelta: {x: 1149.1, y: 139.9575} m_SizeDelta: {x: 1149.1, y: 139.9575}
m_Pivot: {x: 0.5, y: 1} m_Pivot: {x: 0.5, y: 1}
--- !u!114 &75677143 --- !u!114 &75677143
@ -704,11 +704,11 @@ RectTransform:
m_ConstrainProportionsScale: 1 m_ConstrainProportionsScale: 1
m_Children: [] m_Children: []
m_Father: {fileID: 1592423196} m_Father: {fileID: 1592423196}
m_RootOrder: 1 m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0.5} m_AnchorMin: {x: 0, y: 0.5}
m_AnchorMax: {x: 0, y: 0.5} m_AnchorMax: {x: 0, y: 0.5}
m_AnchoredPosition: {x: 50, y: 0} m_AnchoredPosition: {x: 196, y: 0}
m_SizeDelta: {x: 56, y: 56} m_SizeDelta: {x: 56, y: 56}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &124423117 --- !u!114 &124423117
@ -1249,12 +1249,12 @@ MonoBehaviour:
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
m_Navigation: m_Navigation:
m_Mode: 3 m_Mode: 4
m_WrapAround: 0 m_WrapAround: 0
m_SelectOnUp: {fileID: 0} m_SelectOnUp: {fileID: 1336149019}
m_SelectOnDown: {fileID: 0} m_SelectOnDown: {fileID: 2079077664}
m_SelectOnLeft: {fileID: 0} m_SelectOnLeft: {fileID: 2098364310}
m_SelectOnRight: {fileID: 0} m_SelectOnRight: {fileID: 1433046564}
m_Transition: 1 m_Transition: 1
m_Colors: m_Colors:
m_NormalColor: {r: 1, g: 1, b: 1, a: 1} m_NormalColor: {r: 1, g: 1, b: 1, a: 1}
@ -1663,11 +1663,11 @@ RectTransform:
m_ConstrainProportionsScale: 1 m_ConstrainProportionsScale: 1
m_Children: [] m_Children: []
m_Father: {fileID: 1923523151} m_Father: {fileID: 1923523151}
m_RootOrder: 1 m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0.5} m_AnchorMin: {x: 0, y: 0.5}
m_AnchorMax: {x: 0, y: 0.5} m_AnchorMax: {x: 0, y: 0.5}
m_AnchoredPosition: {x: 50, y: 0} m_AnchoredPosition: {x: 196, y: 0}
m_SizeDelta: {x: 56, y: 56} m_SizeDelta: {x: 56, y: 56}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &462262275 --- !u!114 &462262275
@ -1911,6 +1911,7 @@ RectTransform:
- {fileID: 1399472975} - {fileID: 1399472975}
- {fileID: 53800014} - {fileID: 53800014}
- {fileID: 39837708} - {fileID: 39837708}
- {fileID: 1437246958}
- {fileID: 1865546492} - {fileID: 1865546492}
- {fileID: 921231848} - {fileID: 921231848}
- {fileID: 1482915177} - {fileID: 1482915177}
@ -2026,8 +2027,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 1191.7499, y: 0} m_AnchoredPosition: {x: 1222.5, y: 0}
m_SizeDelta: {x: 794.49994, y: 445} m_SizeDelta: {x: 815, y: 456.49997}
m_Pivot: {x: 0.5, y: 1} m_Pivot: {x: 0.5, y: 1}
--- !u!114 &594751226 --- !u!114 &594751226
MonoBehaviour: MonoBehaviour:
@ -2300,7 +2301,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 530.49994, y: -171.68622} m_AnchoredPosition: {x: 551, y: -183.18622}
m_SizeDelta: {x: 1136, y: 372.6375} m_SizeDelta: {x: 1136, y: 372.6375}
m_Pivot: {x: 0.5, y: 1} m_Pivot: {x: 0.5, y: 1}
--- !u!114 &684958158 --- !u!114 &684958158
@ -2465,7 +2466,7 @@ MonoBehaviour:
m_OnCullStateChanged: m_OnCullStateChanged:
m_PersistentCalls: m_PersistentCalls:
m_Calls: [] m_Calls: []
m_Sprite: {fileID: 21300000, guid: 348825b5c77b9d143961119fc008e631, type: 3} m_Sprite: {fileID: 21300000, guid: 3d580e6535635714a9e8b5d2c426f6d6, type: 3}
m_Type: 0 m_Type: 0
m_PreserveAspect: 0 m_PreserveAspect: 0
m_FillCenter: 1 m_FillCenter: 1
@ -2897,7 +2898,7 @@ PrefabInstance:
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 1612412234317559814, guid: 0254202fd7d5ca84c8cf0950a645230b, type: 3} - target: {fileID: 1612412234317559814, guid: 0254202fd7d5ca84c8cf0950a645230b, type: 3}
propertyPath: m_RootOrder propertyPath: m_RootOrder
value: 8 value: 9
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 1612412234317559814, guid: 0254202fd7d5ca84c8cf0950a645230b, type: 3} - target: {fileID: 1612412234317559814, guid: 0254202fd7d5ca84c8cf0950a645230b, type: 3}
propertyPath: m_LocalScale.x propertyPath: m_LocalScale.x
@ -3559,6 +3560,82 @@ Animator:
m_AllowConstantClipSamplingOptimization: 1 m_AllowConstantClipSamplingOptimization: 1
m_KeepAnimatorStateOnDisable: 0 m_KeepAnimatorStateOnDisable: 0
m_WriteDefaultValuesOnDisable: 0 m_WriteDefaultValuesOnDisable: 0
--- !u!1 &896543860
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 896543861}
- component: {fileID: 896543863}
- component: {fileID: 896543862}
m_Layer: 0
m_Name: ButtonIcon
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &896543861
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 896543860}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1437246958}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 1, y: 0}
m_AnchorMax: {x: 1, y: 0}
m_AnchoredPosition: {x: 0.000030517578, y: 0}
m_SizeDelta: {x: 64, y: 64}
m_Pivot: {x: 0.5, y: 0}
--- !u!114 &896543862
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 896543860}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 2100000, guid: 0035f9ee73a3659488de4969ea48d035, type: 2}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 0
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_Sprite: {fileID: 8406874011085310447, guid: 149c162f840b9e9428b96653dd8e40ba, type: 3}
m_Type: 0
m_PreserveAspect: 1
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!222 &896543863
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 896543860}
m_CullTransparentMesh: 1
--- !u!1 &906174734 --- !u!1 &906174734
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -3686,7 +3763,7 @@ MonoBehaviour:
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
m_Navigation: m_Navigation:
m_Mode: 3 m_Mode: 0
m_WrapAround: 0 m_WrapAround: 0
m_SelectOnUp: {fileID: 0} m_SelectOnUp: {fileID: 0}
m_SelectOnDown: {fileID: 0} m_SelectOnDown: {fileID: 0}
@ -3893,7 +3970,7 @@ RectTransform:
m_ConstrainProportionsScale: 0 m_ConstrainProportionsScale: 0
m_Children: [] m_Children: []
m_Father: {fileID: 551511482} m_Father: {fileID: 551511482}
m_RootOrder: 16 m_RootOrder: 17
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5}
@ -4273,8 +4350,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 794.49994, y: -667.5} m_AnchoredPosition: {x: 815, y: -684.74994}
m_SizeDelta: {x: 1588.9999, y: 445} m_SizeDelta: {x: 1630, y: 456.49997}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1101280658 --- !u!114 &1101280658
MonoBehaviour: MonoBehaviour:
@ -4425,7 +4502,7 @@ RectTransform:
m_Children: m_Children:
- {fileID: 526126132} - {fileID: 526126132}
m_Father: {fileID: 551511482} m_Father: {fileID: 551511482}
m_RootOrder: 10 m_RootOrder: 11
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 28.405} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 28.405}
m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5}
@ -4531,6 +4608,82 @@ BoxCollider2D:
m_CorrespondingSourceObject: {fileID: 6291913669464459655, guid: 0254202fd7d5ca84c8cf0950a645230b, type: 3} m_CorrespondingSourceObject: {fileID: 6291913669464459655, guid: 0254202fd7d5ca84c8cf0950a645230b, type: 3}
m_PrefabInstance: {fileID: 869323822} m_PrefabInstance: {fileID: 869323822}
m_PrefabAsset: {fileID: 0} m_PrefabAsset: {fileID: 0}
--- !u!1 &1284552964
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1284552965}
- component: {fileID: 1284552967}
- component: {fileID: 1284552966}
m_Layer: 0
m_Name: ButtonIcon
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &1284552965
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1284552964}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1592423196}
m_RootOrder: 2
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0.5}
m_AnchorMax: {x: 0, y: 0.5}
m_AnchoredPosition: {x: 16, y: 0}
m_SizeDelta: {x: 64, y: 64}
m_Pivot: {x: 0, y: 0.5}
--- !u!114 &1284552966
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1284552964}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 2100000, guid: 0035f9ee73a3659488de4969ea48d035, type: 2}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_Sprite: {fileID: 111238229322356548, guid: 149c162f840b9e9428b96653dd8e40ba, type: 3}
m_Type: 0
m_PreserveAspect: 1
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!222 &1284552967
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1284552964}
m_CullTransparentMesh: 1
--- !u!1 &1284889615 --- !u!1 &1284889615
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -4562,7 +4715,7 @@ RectTransform:
m_ConstrainProportionsScale: 0 m_ConstrainProportionsScale: 0
m_Children: [] m_Children: []
m_Father: {fileID: 551511482} m_Father: {fileID: 551511482}
m_RootOrder: 17 m_RootOrder: 18
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 1, y: 0} m_AnchorMin: {x: 1, y: 0}
m_AnchorMax: {x: 1, y: 0} m_AnchorMax: {x: 1, y: 0}
@ -4704,7 +4857,7 @@ RectTransform:
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 0, y: 0} m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 794.49994, y: 445} m_SizeDelta: {x: 815, y: 456.49997}
m_Pivot: {x: 0, y: 1} m_Pivot: {x: 0, y: 1}
--- !u!114 &1285225122 --- !u!114 &1285225122
MonoBehaviour: MonoBehaviour:
@ -4744,6 +4897,82 @@ CanvasRenderer:
m_PrefabAsset: {fileID: 0} m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1285225120} m_GameObject: {fileID: 1285225120}
m_CullTransparentMesh: 1 m_CullTransparentMesh: 1
--- !u!1 &1305960736
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1305960737}
- component: {fileID: 1305960739}
- component: {fileID: 1305960738}
m_Layer: 0
m_Name: ButtonIcon
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &1305960737
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1305960736}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1923523151}
m_RootOrder: 2
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0.5}
m_AnchorMax: {x: 0, y: 0.5}
m_AnchoredPosition: {x: 16, y: 0}
m_SizeDelta: {x: 64, y: 64}
m_Pivot: {x: 0, y: 0.5}
--- !u!114 &1305960738
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1305960736}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 2100000, guid: 0035f9ee73a3659488de4969ea48d035, type: 2}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_Sprite: {fileID: 8406874011085310447, guid: 149c162f840b9e9428b96653dd8e40ba, type: 3}
m_Type: 0
m_PreserveAspect: 1
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!222 &1305960739
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1305960736}
m_CullTransparentMesh: 1
--- !u!1 &1328299793 --- !u!1 &1328299793
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -4775,7 +5004,7 @@ RectTransform:
m_ConstrainProportionsScale: 0 m_ConstrainProportionsScale: 0
m_Children: [] m_Children: []
m_Father: {fileID: 1923523151} m_Father: {fileID: 1923523151}
m_RootOrder: 0 m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0.5} m_AnchorMin: {x: 0, y: 0.5}
m_AnchorMax: {x: 1, y: 0.5} m_AnchorMax: {x: 1, y: 0.5}
@ -4935,10 +5164,10 @@ MonoBehaviour:
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
m_Navigation: m_Navigation:
m_Mode: 3 m_Mode: 4
m_WrapAround: 0 m_WrapAround: 0
m_SelectOnUp: {fileID: 0} m_SelectOnUp: {fileID: 2079077664}
m_SelectOnDown: {fileID: 0} m_SelectOnDown: {fileID: 348029483}
m_SelectOnLeft: {fileID: 0} m_SelectOnLeft: {fileID: 0}
m_SelectOnRight: {fileID: 0} m_SelectOnRight: {fileID: 0}
m_Transition: 1 m_Transition: 1
@ -5190,8 +5419,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 0, y: -445} m_AnchoredPosition: {x: 0, y: -456.49997}
m_SizeDelta: {x: 794.49994, y: 445} m_SizeDelta: {x: 815, y: 456.49997}
m_Pivot: {x: 0, y: 0} m_Pivot: {x: 0, y: 0}
--- !u!114 &1348032093 --- !u!114 &1348032093
MonoBehaviour: MonoBehaviour:
@ -5425,7 +5654,7 @@ RectTransform:
m_Children: m_Children:
- {fileID: 637834698} - {fileID: 637834698}
m_Father: {fileID: 551511482} m_Father: {fileID: 551511482}
m_RootOrder: 12 m_RootOrder: 13
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 109.833} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 109.833}
m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5}
@ -5607,12 +5836,12 @@ MonoBehaviour:
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
m_Navigation: m_Navigation:
m_Mode: 3 m_Mode: 4
m_WrapAround: 0 m_WrapAround: 0
m_SelectOnUp: {fileID: 0} m_SelectOnUp: {fileID: 1336149019}
m_SelectOnDown: {fileID: 0} m_SelectOnDown: {fileID: 2079077664}
m_SelectOnLeft: {fileID: 0} m_SelectOnLeft: {fileID: 348029483}
m_SelectOnRight: {fileID: 0} m_SelectOnRight: {fileID: 2098364310}
m_Transition: 1 m_Transition: 1
m_Colors: m_Colors:
m_NormalColor: {r: 1, g: 1, b: 1, a: 1} m_NormalColor: {r: 1, g: 1, b: 1, a: 1}
@ -5864,6 +6093,83 @@ Canvas:
m_SortingLayerID: 805687615 m_SortingLayerID: 805687615
m_SortingOrder: 1 m_SortingOrder: 1
m_TargetDisplay: 0 m_TargetDisplay: 0
--- !u!1 &1437246957
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1437246958}
- component: {fileID: 1437246960}
- component: {fileID: 1437246961}
m_Layer: 0
m_Name: SelectableOver
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 0
--- !u!224 &1437246958
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1437246957}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 896543861}
m_Father: {fileID: 551511482}
m_RootOrder: 7
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: 400, y: 0}
m_SizeDelta: {x: 100, y: 100}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &1437246960
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1437246957}
m_CullTransparentMesh: 1
--- !u!114 &1437246961
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1437246957}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 0
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_Sprite: {fileID: 21300000, guid: f9232c079e126cd48a7344b23eaf42a5, type: 3}
m_Type: 1
m_PreserveAspect: 0
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!1 &1449891558 --- !u!1 &1449891558
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -5901,8 +6207,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 794.49994, y: -222.5} m_AnchoredPosition: {x: 815, y: -228.25}
m_SizeDelta: {x: 1588.9999, y: 445} m_SizeDelta: {x: 1630, y: 456.49997}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1449891560 --- !u!114 &1449891560
MonoBehaviour: MonoBehaviour:
@ -5969,7 +6275,7 @@ RectTransform:
m_Children: m_Children:
- {fileID: 422033008} - {fileID: 422033008}
m_Father: {fileID: 551511482} m_Father: {fileID: 551511482}
m_RootOrder: 9 m_RootOrder: 10
m_LocalEulerAnglesHint: {x: 0, y: 0, z: -25.01} m_LocalEulerAnglesHint: {x: 0, y: 0, z: -25.01}
m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5}
@ -6117,7 +6423,7 @@ RectTransform:
m_ConstrainProportionsScale: 0 m_ConstrainProportionsScale: 0
m_Children: [] m_Children: []
m_Father: {fileID: 551511482} m_Father: {fileID: 551511482}
m_RootOrder: 13 m_RootOrder: 14
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5}
@ -6228,14 +6534,15 @@ RectTransform:
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 1 m_ConstrainProportionsScale: 1
m_Children: m_Children:
- {fileID: 1880104640}
- {fileID: 124423116} - {fileID: 124423116}
- {fileID: 1880104640}
- {fileID: 1284552965}
m_Father: {fileID: 429465179} m_Father: {fileID: 429465179}
m_RootOrder: 0 m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 272.00003, y: -64} m_AnchoredPosition: {x: 272, y: -64}
m_SizeDelta: {x: 256, y: 128} m_SizeDelta: {x: 256, y: 128}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1592423197 --- !u!114 &1592423197
@ -6251,7 +6558,7 @@ MonoBehaviour:
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
m_Navigation: m_Navigation:
m_Mode: 3 m_Mode: 0
m_WrapAround: 0 m_WrapAround: 0
m_SelectOnUp: {fileID: 0} m_SelectOnUp: {fileID: 0}
m_SelectOnDown: {fileID: 0} m_SelectOnDown: {fileID: 0}
@ -6609,8 +6916,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 1191.7499, y: -445} m_AnchoredPosition: {x: 1222.5, y: -456.49997}
m_SizeDelta: {x: 794.49994, y: 445} m_SizeDelta: {x: 815, y: 456.49997}
m_Pivot: {x: 0.5, y: 0} m_Pivot: {x: 0.5, y: 0}
--- !u!114 &1697728242 --- !u!114 &1697728242
MonoBehaviour: MonoBehaviour:
@ -6686,7 +6993,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 530.49994, y: -604.45} m_AnchoredPosition: {x: 551, y: -623.6166}
m_SizeDelta: {x: 1140.8, y: 77.9475} m_SizeDelta: {x: 1140.8, y: 77.9475}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1756042649 --- !u!114 &1756042649
@ -6971,6 +7278,15 @@ MonoBehaviour:
chartTitleText: {fileID: 2077947577} chartTitleText: {fileID: 2077947577}
chartMapperText: {fileID: 128923927} chartMapperText: {fileID: 128923927}
chartDescText: {fileID: 177207008} chartDescText: {fileID: 177207008}
mainSelectables:
- {fileID: 2079077664}
- {fileID: 1336149019}
- {fileID: 348029483}
- {fileID: 1433046564}
- {fileID: 2098364310}
defaultSelectable: {fileID: 2079077664}
selectedDisplayRect: {fileID: 1437246958}
selectedDisplayIcon: {fileID: 896543860}
--- !u!82 &1811344143 --- !u!82 &1811344143
AudioSource: AudioSource:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -7119,7 +7435,7 @@ RectTransform:
m_Children: m_Children:
- {fileID: 496851852} - {fileID: 496851852}
m_Father: {fileID: 551511482} m_Father: {fileID: 551511482}
m_RootOrder: 7 m_RootOrder: 8
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5}
@ -7254,7 +7570,7 @@ RectTransform:
m_ConstrainProportionsScale: 0 m_ConstrainProportionsScale: 0
m_Children: [] m_Children: []
m_Father: {fileID: 1592423196} m_Father: {fileID: 1592423196}
m_RootOrder: 0 m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0.5} m_AnchorMin: {x: 0, y: 0.5}
m_AnchorMax: {x: 1, y: 0.5} m_AnchorMax: {x: 1, y: 0.5}
@ -7391,7 +7707,7 @@ RectTransform:
m_ConstrainProportionsScale: 0 m_ConstrainProportionsScale: 0
m_Children: [] m_Children: []
m_Father: {fileID: 551511482} m_Father: {fileID: 551511482}
m_RootOrder: 14 m_RootOrder: 15
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5}
@ -7502,14 +7818,15 @@ RectTransform:
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 1 m_ConstrainProportionsScale: 1
m_Children: m_Children:
- {fileID: 1328299794}
- {fileID: 462262274} - {fileID: 462262274}
- {fileID: 1328299794}
- {fileID: 1305960737}
m_Father: {fileID: 429465179} m_Father: {fileID: 429465179}
m_RootOrder: 1 m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1} m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 816.0001, y: -64} m_AnchoredPosition: {x: 816, y: -64}
m_SizeDelta: {x: 256, y: 128} m_SizeDelta: {x: 256, y: 128}
m_Pivot: {x: 0.5, y: 0.5} m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1923523152 --- !u!114 &1923523152
@ -7525,7 +7842,7 @@ MonoBehaviour:
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
m_Navigation: m_Navigation:
m_Mode: 3 m_Mode: 0
m_WrapAround: 0 m_WrapAround: 0
m_SelectOnUp: {fileID: 0} m_SelectOnUp: {fileID: 0}
m_SelectOnDown: {fileID: 0} m_SelectOnDown: {fileID: 0}
@ -8103,7 +8420,7 @@ RectTransform:
m_Children: m_Children:
- {fileID: 1809456927} - {fileID: 1809456927}
m_Father: {fileID: 551511482} m_Father: {fileID: 551511482}
m_RootOrder: 11 m_RootOrder: 12
m_LocalEulerAnglesHint: {x: 0, y: 0, z: -10.113} m_LocalEulerAnglesHint: {x: 0, y: 0, z: -10.113}
m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5}
@ -8469,10 +8786,10 @@ MonoBehaviour:
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
m_Navigation: m_Navigation:
m_Mode: 3 m_Mode: 4
m_WrapAround: 0 m_WrapAround: 0
m_SelectOnUp: {fileID: 0} m_SelectOnUp: {fileID: 348029483}
m_SelectOnDown: {fileID: 0} m_SelectOnDown: {fileID: 1336149019}
m_SelectOnLeft: {fileID: 0} m_SelectOnLeft: {fileID: 0}
m_SelectOnRight: {fileID: 0} m_SelectOnRight: {fileID: 0}
m_Transition: 1 m_Transition: 1
@ -8692,12 +9009,12 @@ MonoBehaviour:
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
m_Navigation: m_Navigation:
m_Mode: 3 m_Mode: 4
m_WrapAround: 0 m_WrapAround: 0
m_SelectOnUp: {fileID: 0} m_SelectOnUp: {fileID: 1336149019}
m_SelectOnDown: {fileID: 0} m_SelectOnDown: {fileID: 2079077664}
m_SelectOnLeft: {fileID: 0} m_SelectOnLeft: {fileID: 1433046564}
m_SelectOnRight: {fileID: 0} m_SelectOnRight: {fileID: 348029483}
m_Transition: 1 m_Transition: 1
m_Colors: m_Colors:
m_NormalColor: {r: 1, g: 1, b: 1, a: 1} m_NormalColor: {r: 1, g: 1, b: 1, a: 1}

View file

@ -151,7 +151,7 @@ namespace HeavenStudio.InputSystem
public override int GetLastActionDown() public override int GetLastActionDown()
{ {
for (int i = 0; i < BINDS_MAX; i++) for (int i = 0; i < currentBindings.Pad.Length; i++)
{ {
if (Input.GetKeyDown((KeyCode)currentBindings.Pad[i])) if (Input.GetKeyDown((KeyCode)currentBindings.Pad[i]))
return i; return i;

View file

@ -272,9 +272,9 @@ namespace HeavenStudio.InputSystem
public override int GetLastActionDown() public override int GetLastActionDown()
{ {
for (int i = 0; i < BINDS_MAX; i++) for (int i = 0; i < currentBindings.Touch.Length; i++)
{ {
if (Input.GetKeyDown((KeyCode)currentBindings.Pad[i])) if (Input.GetKeyDown((KeyCode)currentBindings.Touch[i]))
return i; return i;
} }
return -1; return -1;

View file

@ -107,14 +107,14 @@ namespace HeavenStudio.InputSystem
//buttons used in Heaven Studio gameplay ("Form Baton" / WiiMote Style) //buttons used in Heaven Studio gameplay ("Form Baton" / WiiMote Style)
public enum ActionsBaton : int public enum ActionsBaton : int
{ {
South = 0, //-- all these... North = 0, //-- all these...
East = 1, // | South = 1, // |
West = 2, // | West = 2, // |
North = 3, //-- East = 3, //--
Face = 4, // < ...are also equivalent to this, but with added directionality Trigger = 4, // < ...are also equivalent to this, but with added directionality
Trigger = 5, // should never be used alone, but still bindable separately (controller logic should handle confirming & timestamping face + trigger input) Face = 5,
Up = 6, // Wiimote 1 Down = 6, // Wiimote 1
Down = 7, // Wiimote 2 Up = 7, // Wiimote 2
Pause = 8, Pause = 8,
} }

View file

@ -45,12 +45,6 @@ namespace HeavenStudio
} }
} }
//Clockwise
public const int UP = 0;
public const int RIGHT = 1;
public const int DOWN = 2;
public const int LEFT = 3;
public static InputController.ControlStyles CurrentControlStyle = InputController.ControlStyles.Pad; public static InputController.ControlStyles CurrentControlStyle = InputController.ControlStyles.Pad;
static List<InputController> inputDevices; static List<InputController> inputDevices;

View file

@ -5,6 +5,7 @@ using UnityEngine.UI;
using UnityEngine; using UnityEngine;
using HeavenStudio.Util; using HeavenStudio.Util;
using HeavenStudio.Common; using HeavenStudio.Common;
using HeavenStudio.InputSystem;
using Starpelly; using Starpelly;
using System.Linq; using System.Linq;
@ -45,6 +46,11 @@ namespace HeavenStudio
[SerializeField] private TMP_Text chartMapperText; [SerializeField] private TMP_Text chartMapperText;
[SerializeField] private TMP_Text chartDescText; [SerializeField] private TMP_Text chartDescText;
[SerializeField] private Selectable[] mainSelectables;
[SerializeField] private Selectable defaultSelectable;
[SerializeField] private RectTransform selectedDisplayRect;
[SerializeField] private GameObject selectedDisplayIcon;
private AudioSource musicSource; private AudioSource musicSource;
private double songPosBeat; private double songPosBeat;
@ -61,9 +67,12 @@ namespace HeavenStudio
private bool logoRevealed; private bool logoRevealed;
private bool menuMode, snsRevealed, exiting; private bool menuMode, snsRevealed, playMenuRevealed, exiting, firstPress, usingMouse;
private Animator menuAnim; private Animator menuAnim;
private Selectable currentSelectable, mouseSelectable;
private RectTransform currentSelectableRect, lastSelectableRect;
private float selectableLerpTimer;
private void Start() private void Start()
{ {
@ -74,6 +83,7 @@ namespace HeavenStudio
startTime = Time.realtimeSinceStartupAsDouble; startTime = Time.realtimeSinceStartupAsDouble;
var _rand = new System.Random(); var _rand = new System.Random();
starAnims = starAnims.OrderBy(_ => _rand.Next()).ToList(); starAnims = starAnims.OrderBy(_ => _rand.Next()).ToList();
selectedDisplayRect.gameObject.SetActive(false);
#if UNITY_EDITOR #if UNITY_EDITOR
versionText.text = "EDITOR"; versionText.text = "EDITOR";
@ -101,14 +111,19 @@ namespace HeavenStudio
songPosBeat = SecsToBeats(songPos); songPosBeat = SecsToBeats(songPos);
var controllers = PlayerInput.GetInputControllers(); if (logoRevealed && !menuMode)
foreach (var newController in controllers)
{ {
if (newController.GetLastButtonDown(true) > 0) var controllers = PlayerInput.GetInputControllers();
foreach (var newController in controllers)
{ {
if (logoRevealed && !menuMode) if (newController.GetLastButtonDown(true) > 0)
{ {
menuMode = true; menuMode = true;
firstPress = true;
currentSelectable = defaultSelectable;
SetSelectableRectTarget(currentSelectable);
selectableLerpTimer = 1;
menuAnim.Play("Revealed", 0, 0); menuAnim.Play("Revealed", 0, 0);
pressAnyKeyAnim.Play("PressKeyFadeOut", 0, 0); pressAnyKeyAnim.Play("PressKeyFadeOut", 0, 0);
SoundByte.PlayOneShot("ui/UIEnter"); SoundByte.PlayOneShot("ui/UIEnter");
@ -120,16 +135,19 @@ namespace HeavenStudio
{ {
lastController.SetPlayer(null); lastController.SetPlayer(null);
newController.SetPlayer(1); newController.SetPlayer(1);
PlayerInput.CurrentControlStyle = newController.GetDefaultStyle();
usingMouse = PlayerInput.CurrentControlStyle == InputController.ControlStyles.Touch;
selectedDisplayIcon.SetActive(!usingMouse);
if ((lastController as InputSystem.InputJoyshock) != null) if ((lastController as InputJoyshock) != null)
{ {
(lastController as InputSystem.InputJoyshock)?.UnAssignOtherHalf(); (lastController as InputJoyshock)?.UnAssignOtherHalf();
} }
if ((newController as InputSystem.InputJoyshock) != null) if ((newController as InputJoyshock) != null)
{ {
newController.OnSelected(); newController.OnSelected();
(newController as InputSystem.InputJoyshock)?.UnAssignOtherHalf(); (newController as InputJoyshock)?.UnAssignOtherHalf();
} }
} }
} }
@ -177,11 +195,232 @@ namespace HeavenStudio
altBop = !altBop; altBop = !altBop;
} }
targetBopBeat += 1; targetBopBeat += 1;
// if ((!settingsPanel.IsOpen) && logoRevealed && logoHoverCollider.OverlapPoint(Camera.main.ScreenToWorldPoint(Input.mousePosition)))
// {
// SoundByte.PlayOneShot("metronome");
// }
} }
if (menuMode && !(exiting || GlobalGameManager.IsShowingDialog))
{
var controller = PlayerInput.GetInputController(1);
if (playMenuRevealed)
{
switch (controller.GetLastActionDown())
{
case (int) InputController.ActionsPad.East:
PlayPanelAccept();
break;
case (int) InputController.ActionsPad.South:
PlayPanelBack();
break;
}
}
else if (snsRevealed)
{
if (controller.GetLastActionDown() == (int)InputController.ActionsPad.South)
{
SocialsClose();
}
}
else
{
UpdateSelectable(controller);
}
}
}
void UpdateSelectable(InputController controller)
{
selectableLerpTimer += Time.deltaTime;
if (selectableLerpTimer < 0.2f)
{
float prog = Mathf.Clamp01(selectableLerpTimer / 0.2f);
prog = 1f - Mathf.Pow(1f - prog, 3);
selectedDisplayRect.position = Vector3.Lerp(lastSelectableRect.position, currentSelectableRect.position, prog);
selectedDisplayRect.sizeDelta = Vector2.Lerp(lastSelectableRect.sizeDelta, currentSelectableRect.sizeDelta, prog);
}
else
{
selectedDisplayRect.position = currentSelectableRect.position;
selectedDisplayRect.sizeDelta = currentSelectableRect.sizeDelta;
}
switch (PlayerInput.CurrentControlStyle)
{
case InputController.ControlStyles.Pad:
if (controller.GetActionUp(InputController.ControlStyles.Pad, (int)InputController.ActionsPad.East, out _))
{
if (firstPress)
{
firstPress = false;
}
else if (currentSelectable != null && !usingMouse)
{
SoundByte.PlayOneShot("ui/UIPromptUp");
currentSelectable.GetComponent<Button>()?.onClick.Invoke();
}
}
break;
case InputController.ControlStyles.Baton:
if (controller.GetActionUp(InputController.ControlStyles.Baton, (int)InputController.ActionsBaton.Face, out _))
{
if (firstPress)
{
firstPress = false;
}
else if (currentSelectable != null && !usingMouse)
{
SoundByte.PlayOneShot("ui/UIPromptUp");
currentSelectable.GetComponent<Button>()?.onClick.Invoke();
}
}
break;
default:
break;
}
if (PlayerInput.CurrentControlStyle != InputController.ControlStyles.Touch)
{
switch (controller.GetLastActionDown())
{
case (int)InputController.ActionsPad.East:
if ((currentSelectable != null) && !firstPress)
{
if (usingMouse)
{
usingMouse = false;
selectedDisplayIcon.SetActive(true);
}
SoundByte.PlayOneShot("ui/UIPromptDown");
}
break;
case (int)InputController.ActionsPad.Up:
if (firstPress)
{
firstPress = false;
}
else if (currentSelectable != null)
{
if (currentSelectable.FindSelectableOnUp() != null)
{
usingMouse = false;
selectedDisplayIcon.SetActive(true);
currentSelectable = currentSelectable.FindSelectableOnUp();
currentSelectable.Select();
SetSelectableRectTarget(currentSelectable);
SoundByte.PlayOneShot("ui/UIOption");
}
else
{
// SoundByte.PlayOneShot("ui/UISelect");
}
}
break;
case (int)InputController.ActionsPad.Down:
if (firstPress)
{
firstPress = false;
}
else if (currentSelectable != null)
{
if (currentSelectable.FindSelectableOnDown() != null)
{
usingMouse = false;
selectedDisplayIcon.SetActive(true);
currentSelectable = currentSelectable.FindSelectableOnDown();
currentSelectable.Select();
SetSelectableRectTarget(currentSelectable);
SoundByte.PlayOneShot("ui/UIOption");
}
else
{
// SoundByte.PlayOneShot("ui/UISelect");
}
}
break;
case (int)InputController.ActionsPad.Left:
if (firstPress)
{
firstPress = false;
}
else if (currentSelectable != null)
{
if (currentSelectable.FindSelectableOnLeft() != null)
{
usingMouse = false;
selectedDisplayIcon.SetActive(true);
currentSelectable = currentSelectable.FindSelectableOnLeft();
currentSelectable.Select();
SetSelectableRectTarget(currentSelectable);
SoundByte.PlayOneShot("ui/UIOption");
}
else
{
// SoundByte.PlayOneShot("ui/UISelect");
}
}
break;
case (int)InputController.ActionsPad.Right:
if (firstPress)
{
firstPress = false;
}
else if (currentSelectable != null)
{
if (currentSelectable.FindSelectableOnRight() != null)
{
usingMouse = false;
selectedDisplayIcon.SetActive(true);
currentSelectable = currentSelectable.FindSelectableOnRight();
currentSelectable.Select();
SetSelectableRectTarget(currentSelectable);
SoundByte.PlayOneShot("ui/UIOption");
}
else
{
// SoundByte.PlayOneShot("ui/UISelect");
}
}
break;
}
}
foreach (var selectable in mainSelectables)
{
// get button the mouse is hovering over
if (RectTransformUtility.RectangleContainsScreenPoint(selectable.GetComponent<RectTransform>(), Input.mousePosition, Camera.main))
{
if (mouseSelectable != selectable)
{
mouseSelectable = selectable;
usingMouse = true;
selectedDisplayIcon.SetActive(false);
}
if (currentSelectable != selectable && usingMouse)
{
currentSelectable = selectable;
SetSelectableRectTarget(currentSelectable);
SoundByte.PlayOneShot("ui/UIOption");
break;
}
}
}
}
void SetSelectableRectTarget(Selectable selectable)
{
if (selectable == null)
{
selectedDisplayRect.gameObject.SetActive(false);
return;
}
selectedDisplayRect.gameObject.SetActive(true);
lastSelectableRect = currentSelectableRect;
currentSelectableRect = selectable.GetComponent<RectTransform>();
if (lastSelectableRect == null)
{
lastSelectableRect = currentSelectableRect;
}
selectedDisplayRect.position = lastSelectableRect.position;
selectedDisplayRect.sizeDelta = lastSelectableRect.sizeDelta;
selectableLerpTimer = 0;
} }
public double SecsToBeats(double s) public double SecsToBeats(double s)
@ -245,6 +484,7 @@ namespace HeavenStudio
chartDescText.text = beatmap["remixdesc"]; chartDescText.text = beatmap["remixdesc"];
playPanel.SetActive(true); playPanel.SetActive(true);
playMenuRevealed = true;
SoundByte.PlayOneShot("ui/UISelect"); SoundByte.PlayOneShot("ui/UISelect");
} }
catch (System.Exception e) catch (System.Exception e)
@ -270,6 +510,7 @@ namespace HeavenStudio
RiqFileHandler.ClearCache(); RiqFileHandler.ClearCache();
SoundByte.PlayOneShot("ui/UICancel"); SoundByte.PlayOneShot("ui/UICancel");
playPanel.SetActive(false); playPanel.SetActive(false);
playMenuRevealed = false;
} }
public void SocialsPressed() public void SocialsPressed()