From 6015c44604c9a68efd70ebca685a39092f424a6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Denis=20Nu=C8=9Biu?= Date: Sun, 30 Jun 2019 17:26:07 +0300 Subject: [PATCH] Remove joystick and add buttons for mobile movement --- Assets/Prefabs/MobileInputControls.prefab | 734 +++++++++++++++--- Assets/Scenes/SampleScene.unity | 70 ++ Assets/Scripts/src/Player/PlayerController.cs | 22 +- Assets/Scripts/src/Upgrade/TestUpgrade.cs | 2 +- Assets/Sprites/UI.meta | 8 + Assets/Sprites/UI/Controls.meta | 8 + Assets/Sprites/UI/Controls/MoveDown.png | Bin 0 -> 371 bytes Assets/Sprites/UI/Controls/MoveDown.png.meta | 110 +++ Assets/Sprites/UI/Controls/MoveLeft.png | Bin 0 -> 413 bytes Assets/Sprites/UI/Controls/MoveLeft.png.meta | 110 +++ Assets/Sprites/UI/Controls/MoveRight.png | Bin 0 -> 387 bytes Assets/Sprites/UI/Controls/MoveRight.png.meta | 110 +++ Assets/Sprites/UI/Controls/MoveUp.png | Bin 0 -> 361 bytes Assets/Sprites/UI/Controls/MoveUp.png.meta | 110 +++ .../CrossPlatformInputInitialize.cs | 7 +- ProjectSettings/ProjectSettings.asset | 4 +- 16 files changed, 1190 insertions(+), 105 deletions(-) create mode 100644 Assets/Sprites/UI.meta create mode 100644 Assets/Sprites/UI/Controls.meta create mode 100644 Assets/Sprites/UI/Controls/MoveDown.png create mode 100644 Assets/Sprites/UI/Controls/MoveDown.png.meta create mode 100644 Assets/Sprites/UI/Controls/MoveLeft.png create mode 100644 Assets/Sprites/UI/Controls/MoveLeft.png.meta create mode 100644 Assets/Sprites/UI/Controls/MoveRight.png create mode 100644 Assets/Sprites/UI/Controls/MoveRight.png.meta create mode 100644 Assets/Sprites/UI/Controls/MoveUp.png create mode 100644 Assets/Sprites/UI/Controls/MoveUp.png.meta diff --git a/Assets/Prefabs/MobileInputControls.prefab b/Assets/Prefabs/MobileInputControls.prefab index f663540..e3eef22 100644 --- a/Assets/Prefabs/MobileInputControls.prefab +++ b/Assets/Prefabs/MobileInputControls.prefab @@ -1,5 +1,323 @@ %YAML 1.1 %TAG !u! tag:unity3d.com,2011: +--- !u!1 &311312839 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 311312840} + - component: {fileID: 311312842} + - component: {fileID: 311312841} + - component: {fileID: 311312843} + - component: {fileID: 4780998966717423641} + m_Layer: 5 + m_Name: MoveUpButton + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &311312840 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 311312839} + 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_Children: [] + m_Father: {fileID: 2219516564235934920} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.163, y: 0.31100002} + m_AnchorMax: {x: 0.163, y: 0.31100002} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 100, y: 100} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &311312842 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 311312839} + m_CullTransparentMesh: 0 +--- !u!114 &311312841 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 311312839} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, + Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + m_Sprite: {fileID: 21300000, guid: 87cb220e6c20e456a9ecf748e567bb16, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 +--- !u!114 &311312843 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 311312839} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 85bf3be603548374ca46f521a3aa7fda, type: 3} + m_Name: + m_EditorClassIdentifier: + Name: MoveUp +--- !u!114 &4780998966717423641 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 311312839} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -1862395651, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Delegates: + - eventID: 2 + callback: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 311312843} + m_MethodName: SetDownState + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + - m_Target: {fileID: 311312842} + m_MethodName: SetAlpha + m_Mode: 4 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0.8 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + m_TypeName: UnityEngine.EventSystems.EventTrigger+TriggerEvent, UnityEngine.UI, + Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + - eventID: 3 + callback: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 311312843} + m_MethodName: SetUpState + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + - m_Target: {fileID: 311312842} + m_MethodName: SetAlpha + m_Mode: 4 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 1 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + m_TypeName: UnityEngine.EventSystems.EventTrigger+TriggerEvent, UnityEngine.UI, + Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + delegates: [] +--- !u!1 &1533625511004221075 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2794171661481808020} + - component: {fileID: 4417380224599296100} + - component: {fileID: 7270506208529234008} + - component: {fileID: 1533625511004221076} + - component: {fileID: 1533625511004221077} + m_Layer: 5 + m_Name: MoveRightButton + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &2794171661481808020 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1533625511004221075} + 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_Children: [] + m_Father: {fileID: 2219516564235934920} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.2342355, y: 0.2132826} + m_AnchorMax: {x: 0.2342355, y: 0.2132826} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 100, y: 100} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &4417380224599296100 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1533625511004221075} + m_CullTransparentMesh: 0 +--- !u!114 &7270506208529234008 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1533625511004221075} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, + Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + m_Sprite: {fileID: 21300000, guid: f52b08ca7956240dcb3074cf458fa015, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 +--- !u!114 &1533625511004221076 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1533625511004221075} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 85bf3be603548374ca46f521a3aa7fda, type: 3} + m_Name: + m_EditorClassIdentifier: + Name: MoveRight +--- !u!114 &1533625511004221077 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1533625511004221075} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -1862395651, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Delegates: + - eventID: 2 + callback: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1533625511004221076} + m_MethodName: SetDownState + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + - m_Target: {fileID: 4417380224599296100} + m_MethodName: SetAlpha + m_Mode: 4 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0.8 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + m_TypeName: UnityEngine.EventSystems.EventTrigger+TriggerEvent, UnityEngine.UI, + Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + - eventID: 3 + callback: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1533625511004221076} + m_MethodName: SetUpState + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + - m_Target: {fileID: 4417380224599296100} + m_MethodName: SetAlpha + m_Mode: 4 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 1 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + m_TypeName: UnityEngine.EventSystems.EventTrigger+TriggerEvent, UnityEngine.UI, + Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + delegates: [] --- !u!1 &2219516564249810536 GameObject: m_ObjectHideFlags: 0 @@ -31,7 +349,10 @@ RectTransform: m_LocalScale: {x: 0, y: 0, z: 0} m_Children: - {fileID: 2219516564235934924} - - {fileID: 2219516564235934922} + - {fileID: 311312840} + - {fileID: 1067509750367631514} + - {fileID: 2794171661481808020} + - {fileID: 6194349751570614361} m_Father: {fileID: 0} m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} @@ -90,97 +411,6 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 71398ce7fbc3a5b4fa50b50bd54317a7, type: 3} m_Name: m_EditorClassIdentifier: ---- !u!1 &2219516564249810538 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 2219516564235934922} - - component: {fileID: 2219516564236381706} - - component: {fileID: 2219516564256383874} - - component: {fileID: 2219516564256383872} - m_Layer: 5 - m_Name: MobileJoystick - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!224 &2219516564235934922 -RectTransform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 2219516564249810538} - 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_Children: [] - m_Father: {fileID: 2219516564235934920} - m_RootOrder: 1 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0.16000001, y: 0.2} - m_AnchorMax: {x: 0.16000001, y: 0.2} - m_AnchoredPosition: {x: -40, y: -39.999985} - m_SizeDelta: {x: 80, y: 80} - m_Pivot: {x: 0.5, y: 0.5} ---- !u!222 &2219516564236381706 -CanvasRenderer: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 2219516564249810538} - m_CullTransparentMesh: 0 ---- !u!114 &2219516564256383874 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 2219516564249810538} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: -765806418, guid: f5f67c52d1564df4a8936ccd202a3bd8, type: 3} - m_Name: - m_EditorClassIdentifier: - m_Material: {fileID: 0} - m_Color: {r: 1, g: 1, b: 1, a: 1} - m_RaycastTarget: 1 - m_OnCullStateChanged: - m_PersistentCalls: - m_Calls: [] - m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, - Version=1.0.0.0, Culture=neutral, PublicKeyToken=null - m_Sprite: {fileID: 21300000, guid: 9866a92691696b346901281f2b329034, type: 3} - m_Type: 0 - m_PreserveAspect: 0 - m_FillCenter: 1 - m_FillMethod: 4 - m_FillAmount: 1 - m_FillClockwise: 1 - m_FillOrigin: 0 - m_UseSpriteMesh: 0 ---- !u!114 &2219516564256383872 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 2219516564249810538} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 00c3c865782347f41b6358d9fba14b48, type: 3} - m_Name: - m_EditorClassIdentifier: - MovementRange: 100 - axesToUse: 0 - horizontalAxisName: Horizontal - verticalAxisName: Vertical --- !u!1 &2219516564249810540 GameObject: m_ObjectHideFlags: 0 @@ -276,7 +506,7 @@ MonoBehaviour: m_PersistentCalls: m_Calls: - m_Target: {fileID: 2219516564256383882} - m_MethodName: + m_MethodName: SetDownState m_Mode: 1 m_Arguments: m_ObjectArgument: {fileID: 0} @@ -448,3 +678,321 @@ MonoBehaviour: m_EffectColor: {r: 0, g: 0, b: 0, a: 0.1254902} m_EffectDistance: {x: 2, y: -2} m_UseGraphicAlpha: 1 +--- !u!1 &7551096532728223647 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 6194349751570614361} + - component: {fileID: 1369717971988284717} + - component: {fileID: 7585056594013102649} + - component: {fileID: 7551096532728223648} + - component: {fileID: 7551096532728223649} + m_Layer: 5 + m_Name: MoveLeftButton + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &6194349751570614361 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7551096532728223647} + 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_Children: [] + m_Father: {fileID: 2219516564235934920} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.08852906, y: 0.2132826} + m_AnchorMax: {x: 0.08852906, y: 0.2132826} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 100, y: 100} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &1369717971988284717 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7551096532728223647} + m_CullTransparentMesh: 0 +--- !u!114 &7585056594013102649 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7551096532728223647} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, + Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + m_Sprite: {fileID: 21300000, guid: 6c6cbf7ac317d400d8634a23257a03f2, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 +--- !u!114 &7551096532728223648 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7551096532728223647} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -1862395651, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Delegates: + - eventID: 2 + callback: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 7551096532728223649} + m_MethodName: SetDownState + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + - m_Target: {fileID: 1369717971988284717} + m_MethodName: SetAlpha + m_Mode: 4 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0.8 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + m_TypeName: UnityEngine.EventSystems.EventTrigger+TriggerEvent, UnityEngine.UI, + Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + - eventID: 3 + callback: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 7551096532728223649} + m_MethodName: SetUpState + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + - m_Target: {fileID: 1369717971988284717} + m_MethodName: SetAlpha + m_Mode: 4 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 1 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + m_TypeName: UnityEngine.EventSystems.EventTrigger+TriggerEvent, UnityEngine.UI, + Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + delegates: [] +--- !u!114 &7551096532728223649 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7551096532728223647} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 85bf3be603548374ca46f521a3aa7fda, type: 3} + m_Name: + m_EditorClassIdentifier: + Name: MoveLeft +--- !u!1 &8007755715420797612 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1067509750367631514} + - component: {fileID: 3292941157813790793} + - component: {fileID: 4857339152836130214} + - component: {fileID: 8007755715420797613} + - component: {fileID: 8007755715420797614} + m_Layer: 5 + m_Name: MoveDownButton + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1067509750367631514 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 8007755715420797612} + 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_Children: [] + m_Father: {fileID: 2219516564235934920} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.163, y: 0.12164131} + m_AnchorMax: {x: 0.163, y: 0.12164131} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 100, y: 100} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &3292941157813790793 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 8007755715420797612} + m_CullTransparentMesh: 0 +--- !u!114 &4857339152836130214 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 8007755715420797612} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -765806418, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, + Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + m_Sprite: {fileID: 21300000, guid: 2e89ff637e2b14dc4bf0f12f83af972d, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 +--- !u!114 &8007755715420797613 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 8007755715420797612} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 85bf3be603548374ca46f521a3aa7fda, type: 3} + m_Name: + m_EditorClassIdentifier: + Name: MoveDown +--- !u!114 &8007755715420797614 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 8007755715420797612} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: -1862395651, guid: f70555f144d8491a825f0804e09c671c, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Delegates: + - eventID: 2 + callback: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 8007755715420797613} + m_MethodName: SetDownState + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + - m_Target: {fileID: 3292941157813790793} + m_MethodName: SetAlpha + m_Mode: 4 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0.8 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + m_TypeName: UnityEngine.EventSystems.EventTrigger+TriggerEvent, UnityEngine.UI, + Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + - eventID: 3 + callback: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 8007755715420797613} + m_MethodName: SetUpState + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + - m_Target: {fileID: 3292941157813790793} + m_MethodName: SetAlpha + m_Mode: 4 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 1 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 1 + m_TypeName: UnityEngine.EventSystems.EventTrigger+TriggerEvent, UnityEngine.UI, + Version=1.0.0.0, Culture=neutral, PublicKeyToken=null + delegates: [] diff --git a/Assets/Scenes/SampleScene.unity b/Assets/Scenes/SampleScene.unity index 0dc5017..b8d629a 100644 --- a/Assets/Scenes/SampleScene.unity +++ b/Assets/Scenes/SampleScene.unity @@ -762,6 +762,76 @@ PrefabInstance: propertyPath: m_Pivot.y value: 0 objectReference: {fileID: 0} + - target: {fileID: 311312840, guid: 4ca131020414f4b1597dac2e1d292d7f, type: 3} + propertyPath: m_LocalScale.x + value: 1.5 + objectReference: {fileID: 0} + - target: {fileID: 311312840, guid: 4ca131020414f4b1597dac2e1d292d7f, type: 3} + propertyPath: m_LocalScale.y + value: 1.5 + objectReference: {fileID: 0} + - target: {fileID: 311312840, guid: 4ca131020414f4b1597dac2e1d292d7f, type: 3} + propertyPath: m_LocalScale.z + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 311312840, guid: 4ca131020414f4b1597dac2e1d292d7f, type: 3} + propertyPath: m_AnchoredPosition.y + value: 40 + objectReference: {fileID: 0} + - target: {fileID: 311312840, guid: 4ca131020414f4b1597dac2e1d292d7f, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1067509750367631514, guid: 4ca131020414f4b1597dac2e1d292d7f, + type: 3} + propertyPath: m_LocalScale.x + value: 1.5 + objectReference: {fileID: 0} + - target: {fileID: 1067509750367631514, guid: 4ca131020414f4b1597dac2e1d292d7f, + type: 3} + propertyPath: m_LocalScale.y + value: 1.5 + objectReference: {fileID: 0} + - target: {fileID: 2794171661481808020, guid: 4ca131020414f4b1597dac2e1d292d7f, + type: 3} + propertyPath: m_LocalScale.x + value: 1.5 + objectReference: {fileID: 0} + - target: {fileID: 2794171661481808020, guid: 4ca131020414f4b1597dac2e1d292d7f, + type: 3} + propertyPath: m_LocalScale.y + value: 1.5 + objectReference: {fileID: 0} + - target: {fileID: 2794171661481808020, guid: 4ca131020414f4b1597dac2e1d292d7f, + type: 3} + propertyPath: m_AnchoredPosition.x + value: 46 + objectReference: {fileID: 0} + - target: {fileID: 2794171661481808020, guid: 4ca131020414f4b1597dac2e1d292d7f, + type: 3} + propertyPath: m_AnchoredPosition.y + value: 16 + objectReference: {fileID: 0} + - target: {fileID: 6194349751570614361, guid: 4ca131020414f4b1597dac2e1d292d7f, + type: 3} + propertyPath: m_LocalScale.x + value: 1.5 + objectReference: {fileID: 0} + - target: {fileID: 6194349751570614361, guid: 4ca131020414f4b1597dac2e1d292d7f, + type: 3} + propertyPath: m_LocalScale.y + value: 1.5 + objectReference: {fileID: 0} + - target: {fileID: 6194349751570614361, guid: 4ca131020414f4b1597dac2e1d292d7f, + type: 3} + propertyPath: m_AnchoredPosition.x + value: -46 + objectReference: {fileID: 0} + - target: {fileID: 6194349751570614361, guid: 4ca131020414f4b1597dac2e1d292d7f, + type: 3} + propertyPath: m_AnchoredPosition.y + value: 16 + objectReference: {fileID: 0} m_RemovedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: 4ca131020414f4b1597dac2e1d292d7f, type: 3} --- !u!1001 &6843575829779162303 diff --git a/Assets/Scripts/src/Player/PlayerController.cs b/Assets/Scripts/src/Player/PlayerController.cs index 21d749a..f86e907 100644 --- a/Assets/Scripts/src/Player/PlayerController.cs +++ b/Assets/Scripts/src/Player/PlayerController.cs @@ -38,12 +38,28 @@ namespace src.Player private void HandleMovement() { -#if UNITY_EDITOR || UNITY_STANDALONE || UNITY_WEBGL +#if UNITY_STANDALONE || UNITY_WEBGL || UNITY_EDITOR var horizontal = Input.GetAxisRaw("Horizontal"); var vertical = Input.GetAxisRaw("Vertical"); #elif UNITY_IOS || UNITY_ANDROID - var horizontal = CrossPlatformInputManager.GetAxisRaw("Horizontal"); - var vertical = CrossPlatformInputManager.GetAxisRaw("Vertical"); + var horizontal = 0; + var vertical = 0; + if (CrossPlatformInputManager.GetButton("MoveUp")) + { + vertical = 1; + } + if (CrossPlatformInputManager.GetButton("MoveDown")) + { + vertical = -1; + } + if (CrossPlatformInputManager.GetButton("MoveRight")) + { + horizontal = 1; + } + if (CrossPlatformInputManager.GetButton("MoveLeft")) + { + horizontal = -1; + } #elif UNITY_PS4 || UNITY_XBOXONE // // Console movement is not supported yet. #endif diff --git a/Assets/Scripts/src/Upgrade/TestUpgrade.cs b/Assets/Scripts/src/Upgrade/TestUpgrade.cs index 07fb37e..92d8d9b 100644 --- a/Assets/Scripts/src/Upgrade/TestUpgrade.cs +++ b/Assets/Scripts/src/Upgrade/TestUpgrade.cs @@ -7,7 +7,7 @@ namespace src.Upgrade { public class TestUpgrade : UpgradeBase { - public void PerformUpgrade() + public new void PerformUpgrade() { DebugHelper.LogWarning("Test upgrade works!"); } diff --git a/Assets/Sprites/UI.meta b/Assets/Sprites/UI.meta new file mode 100644 index 0000000..5760c60 --- /dev/null +++ b/Assets/Sprites/UI.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ec07b610af29a445ab0462319381d480 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Sprites/UI/Controls.meta b/Assets/Sprites/UI/Controls.meta new file mode 100644 index 0000000..ac7d626 --- /dev/null +++ b/Assets/Sprites/UI/Controls.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0af55ef52f2cc4abf81f3f91188b26f4 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Sprites/UI/Controls/MoveDown.png b/Assets/Sprites/UI/Controls/MoveDown.png new file mode 100644 index 0000000000000000000000000000000000000000..b85d3bcd98c21c3617ce73412d5ea49a42cdcc9d GIT binary patch literal 371 zcmV-(0gV2MP)Px$ElET{R9J=WmcI>xKp4dzhSmTk#>PTJ)Q$mcWd!2@j9_DDVQ1qA3}74qTL+-j z5I0bX1Dq8EkmEiMOf>S!`}5xK`#3m&MveYm3II6k9g7Cs%~JVfU^YtyfXSdAFW9nyCGC)}fYIrFCDnyxZpyV0QyS-Z0NCViG zsTjJ(oi}tX^_{0k>YB~Fw6d2BRZ_2Ewi7ayR|5DNd49k=Kj8juHEQ$|dI4p2h74%P)Px$S4l)cR9J=GSFvrwFc3TjZUfobAPAB&1E^I-5Hf(5aF^aqM(_ZJMzC59;4*;_ z7;qB=uqAi^x-cFP0+IZupDA*!NIw7W@J9jv9n00)&fngx>-!{C;i_&d0JOWkcil~j z;+t)2k6n*r*9X@c?c!D4*kR#Af5Kw^>a3$C0a4EBTKxjQyO!W;5BQ27`crU!Gy`19 zefk5DCge~aG9N)K!8Ll1fz7~X+uH8uo8@wD_W;uaRo&RH&kxR0F@h4%RO3R@J>X%0 zT%M|P!YBihSw4icd*=oI5~CM*d44dnX@=P}6CHM!-D0^~JF|ZbP7jntZh(s%DSZ%> zfY{(d$^y#+Ws#fv$0xBQ9Eh`kJBpKKL0RM?NkWKzl5ygg!$R~ND2v=^u%YrO4ZVtd zET~LEVj_kOwNV@^iFy{$%oxJ=YnCL8Bw3Oy4M~zz=d0li4brqVeN`oX00000NkvXX Hu0mjf3W~DI literal 0 HcmV?d00001 diff --git a/Assets/Sprites/UI/Controls/MoveLeft.png.meta b/Assets/Sprites/UI/Controls/MoveLeft.png.meta new file mode 100644 index 0000000..bc6bbb7 --- /dev/null +++ b/Assets/Sprites/UI/Controls/MoveLeft.png.meta @@ -0,0 +1,110 @@ +fileFormatVersion: 2 +guid: 6c6cbf7ac317d400d8634a23257a03f2 +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 9 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: -1 + mipBias: -100 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 32 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + textureShape: 1 + singleChannelComponent: 0 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - serializedVersion: 2 + buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: 306166f138fb4491aa88d3a8fe561fa7 + vertices: [] + indices: + edges: [] + weights: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Sprites/UI/Controls/MoveRight.png b/Assets/Sprites/UI/Controls/MoveRight.png new file mode 100644 index 0000000000000000000000000000000000000000..66d3c8afd410485f143dda4cf4c75dea6474d779 GIT binary patch literal 387 zcmV-}0et?6P)Px$JxN4CR9J=0mO&1|Koo|5Vk>PWVlBeb0c<&fI6yC9*L^pR-~i$XY#qRoh#P1p z4p0jj84@$^P2Y%r*J#bx@Ab_*;9rwwt14e_s?h5+T{mp^hibb&1Ossb6s1B@D(sGz zAP^1PkNJ92b)xp`I*B99rxWWl+&B%GDM}??5*C1l&>#{3PMx1+Fe6bCwgEE|B_Yw< zEa>>!sAa&6?{`5ardR-;CgN@nv+;oR-(m)Iic;ZvK9OyZ0hZ~aaZ`5|2xa#aH(*Aa zu-RY%a4i7tvm~eiN?M$oshwaZi6a2`+7&DSZu-NKvmMDL;J$qlN2I+#+yHkY5<3g@ z;@tBPx$BS}O-R9J=WmOT!FKoEr=#@3+Tz!)t(fUO?EcmR)JV`pJ!;}JN3@d(&@06H~9 z3map?PdLC@L12YtXP3li_$pX-=e>DD2tZBEFJn6{vmKY|)G$;J9*!sG2O$8U(>5`i zjFoCNR1H*xk^$RslkNe)4??Jpf*e~qdLETgkP_fK=TS+5WFUAwE7_AqIxbQ4Jd{yL zZK8-%O_Xj>5vQ2=`gcI+PN(~rvJ?s*R3R>7B6qP$@iG%y?|>IZ@WM!^#AgCB-N&M< z#oPdZt+i(W&^24ab9pIbZfwV8x9de(m`BD)Z!pAk)KAVQ7oyI~gsDc-Ni;=;sKPOn z(PTCj71E)oc3i&+0O$K7S+q7wZBbq%eZN@mwEiJ$YW|NmV4S4}`-(F600000NkvXX Hu0mjfrA3l7 literal 0 HcmV?d00001 diff --git a/Assets/Sprites/UI/Controls/MoveUp.png.meta b/Assets/Sprites/UI/Controls/MoveUp.png.meta new file mode 100644 index 0000000..22e7631 --- /dev/null +++ b/Assets/Sprites/UI/Controls/MoveUp.png.meta @@ -0,0 +1,110 @@ +fileFormatVersion: 2 +guid: 87cb220e6c20e456a9ecf748e567bb16 +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 9 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: -1 + mipBias: -100 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 32 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + textureShape: 1 + singleChannelComponent: 0 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - serializedVersion: 2 + buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - serializedVersion: 2 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: d9ed11d4d395045e18f7e3ee398afe1b + vertices: [] + indices: + edges: [] + weights: [] + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Standard Assets/Editor/CrossPlatformInput/CrossPlatformInputInitialize.cs b/Assets/Standard Assets/Editor/CrossPlatformInput/CrossPlatformInputInitialize.cs index a830a67..91f1f34 100644 --- a/Assets/Standard Assets/Editor/CrossPlatformInput/CrossPlatformInputInitialize.cs +++ b/Assets/Standard Assets/Editor/CrossPlatformInput/CrossPlatformInputInitialize.cs @@ -1,8 +1,7 @@ -using System; using System.Collections.Generic; using UnityEditor; -namespace UnityStandardAssets.CrossPlatformInput.Inspector +namespace Standard_Assets.Editor.CrossPlatformInput { [InitializeOnLoad] public class CrossPlatformInitialize @@ -32,8 +31,6 @@ namespace UnityStandardAssets.CrossPlatformInput.Inspector { case BuildTarget.Android: case BuildTarget.iOS: - case BuildTarget.PSM: - case BuildTarget.Tizen: case BuildTarget.WSAPlayer: EditorUtility.DisplayDialog("Mobile Input", "You have enabled Mobile Input. You'll need to use the Unity Remote app on a connected device to control your game in the Editor.", @@ -92,8 +89,6 @@ namespace UnityStandardAssets.CrossPlatformInput.Inspector { BuildTargetGroup.Android, BuildTargetGroup.iOS, - BuildTargetGroup.PSM, - BuildTargetGroup.Tizen, BuildTargetGroup.WSA }; diff --git a/ProjectSettings/ProjectSettings.asset b/ProjectSettings/ProjectSettings.asset index 2edde75..fd9ce9d 100644 --- a/ProjectSettings/ProjectSettings.asset +++ b/ProjectSettings/ProjectSettings.asset @@ -55,8 +55,8 @@ PlayerSettings: iosAppInBackgroundBehavior: 0 displayResolutionDialog: 1 iosAllowHTTPDownload: 1 - allowedAutorotateToPortrait: 1 - allowedAutorotateToPortraitUpsideDown: 1 + allowedAutorotateToPortrait: 0 + allowedAutorotateToPortraitUpsideDown: 0 allowedAutorotateToLandscapeRight: 1 allowedAutorotateToLandscapeLeft: 1 useOSAutorotation: 1