From ea12766cf7f02af64acfd2924f9731a1d56bb095 Mon Sep 17 00:00:00 2001 From: AlexanderT Date: Fri, 7 Nov 2025 17:21:38 +0100 Subject: [PATCH] Fixed button issue --- Assets/Prefabs/Managers/PlayerHUD.prefab | 22 +++++- .../Prefabs/UI/AppSwitcher/AppSwitcher.prefab | 78 ++++++++++++++++++- Assets/Scripts/UI/AppSwitcher.cs | 3 + 3 files changed, 101 insertions(+), 2 deletions(-) diff --git a/Assets/Prefabs/Managers/PlayerHUD.prefab b/Assets/Prefabs/Managers/PlayerHUD.prefab index eb70d6d3..437ddd35 100644 --- a/Assets/Prefabs/Managers/PlayerHUD.prefab +++ b/Assets/Prefabs/Managers/PlayerHUD.prefab @@ -1062,10 +1062,30 @@ PrefabInstance: m_RemovedComponents: [] m_RemovedGameObjects: [] m_AddedGameObjects: [] - m_AddedComponents: [] + m_AddedComponents: + - targetCorrespondingSourceObject: {fileID: 6784053660381911346, guid: ccd858c7962d48147b0233c1bf1382f5, type: 3} + insertIndex: -1 + addedObject: {fileID: 1247411094983283289} m_SourcePrefab: {fileID: 100100000, guid: ccd858c7962d48147b0233c1bf1382f5, type: 3} --- !u!224 &3194400469127591113 stripped RectTransform: m_CorrespondingSourceObject: {fileID: 1315170081792486277, guid: ccd858c7962d48147b0233c1bf1382f5, type: 3} m_PrefabInstance: {fileID: 4473383355500896076} m_PrefabAsset: {fileID: 0} +--- !u!1 &6931438578476385918 stripped +GameObject: + m_CorrespondingSourceObject: {fileID: 6784053660381911346, guid: ccd858c7962d48147b0233c1bf1382f5, type: 3} + m_PrefabInstance: {fileID: 4473383355500896076} + m_PrefabAsset: {fileID: 0} +--- !u!114 &1247411094983283289 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6931438578476385918} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 494d0aedce9744308499355006071138, type: 3} + m_Name: + m_EditorClassIdentifier: AppleHillsScripts::UI.DummyInput diff --git a/Assets/Prefabs/UI/AppSwitcher/AppSwitcher.prefab b/Assets/Prefabs/UI/AppSwitcher/AppSwitcher.prefab index 1b89d4d5..25da66bf 100644 --- a/Assets/Prefabs/UI/AppSwitcher/AppSwitcher.prefab +++ b/Assets/Prefabs/UI/AppSwitcher/AppSwitcher.prefab @@ -634,6 +634,81 @@ MonoBehaviour: m_OnClick: m_PersistentCalls: m_Calls: [] +--- !u!1 &4404111907760364827 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 4136733570236406132} + - component: {fileID: 102352512179716898} + - component: {fileID: 3911817807614671446} + m_Layer: 5 + m_Name: BackgroundOverlay + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &4136733570236406132 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 4404111907760364827} + 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: 6108475066390421500} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &102352512179716898 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 4404111907760364827} + m_CullTransparentMesh: 1 +--- !u!114 &3911817807614671446 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 4404111907760364827} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: UnityEngine.UI::UnityEngine.UI.Image + m_Material: {fileID: 0} + m_Color: {r: 0, g: 0, b: 0, a: 0.5019608} + 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: 0} + m_Type: 0 + 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 &5189738780074141096 GameObject: m_ObjectHideFlags: 0 @@ -784,7 +859,8 @@ RectTransform: m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 - m_Children: [] + m_Children: + - {fileID: 4136733570236406132} m_Father: {fileID: 1315170081792486277} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} diff --git a/Assets/Scripts/UI/AppSwitcher.cs b/Assets/Scripts/UI/AppSwitcher.cs index 7bfb0faa..bba0a220 100644 --- a/Assets/Scripts/UI/AppSwitcher.cs +++ b/Assets/Scripts/UI/AppSwitcher.cs @@ -26,10 +26,13 @@ public class AppSwitcher : MonoBehaviour iconPlayer = icon.GetComponentInChildren(); rainbowPlayer = rainbow.GetComponentInChildren(); animator = GetComponent(); + rainbow.SetActive(false); } public void OpenAppSwitcher() { + + rainbow.SetActive(true); //Activate players rainbow.SetActive(true); gameLayoutContainer.SetActive(true);