From bfd8d4fcbcea4cfc723218c4c984392b4cb696eb Mon Sep 17 00:00:00 2001 From: nexovec Date: Sun, 30 Jan 2022 12:29:47 +0100 Subject: [PATCH] Moving camera --- Assets/Scenes/Vasek.unity | 6 +++--- Assets/Scripts/UiController.cs | 3 +++ 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/Assets/Scenes/Vasek.unity b/Assets/Scenes/Vasek.unity index b72c83f..c3cc2ed 100644 --- a/Assets/Scenes/Vasek.unity +++ b/Assets/Scenes/Vasek.unity @@ -163,7 +163,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 77683431} m_LocalRotation: {x: 0.19051337, y: -0.33824676, z: 0.07012796, w: 0.9188993} - m_LocalPosition: {x: -441.9, y: -700.5, z: 24.4} + m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] @@ -5396,13 +5396,13 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1553744186} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 499.93808, y: 755.19403, z: -21.3553} + m_LocalPosition: {x: 34, y: 31, z: -85} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: - {fileID: 77683432} m_Father: {fileID: 0} - m_RootOrder: 4 + m_RootOrder: 5 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &1802677907 GameObject: diff --git a/Assets/Scripts/UiController.cs b/Assets/Scripts/UiController.cs index 43d58df..e94ac30 100644 --- a/Assets/Scripts/UiController.cs +++ b/Assets/Scripts/UiController.cs @@ -65,6 +65,9 @@ public class UiController : MonoBehaviour oldDistance = distance; } } + public void FixedUpdate(){ + this.menuCamera.transform.position = this.menuCamera.transform.position + Vector3.forward * 0.05f; + } //MENU public void exitGame()