From d13751bf3393594cc65645068c57d35311f144ec Mon Sep 17 00:00:00 2001 From: Joshua Date: Sun, 5 Feb 2023 18:49:37 +1100 Subject: [PATCH] Main level --- Assets/Scenes/Main.unity | 3 +++ Assets/Scenes/Main.unity.meta | 7 +++++++ Assets/Scripts/Route/TileManager.cs | 15 ++++++++++++--- 3 files changed, 22 insertions(+), 3 deletions(-) create mode 100644 Assets/Scenes/Main.unity create mode 100644 Assets/Scenes/Main.unity.meta diff --git a/Assets/Scenes/Main.unity b/Assets/Scenes/Main.unity new file mode 100644 index 0000000..29a2b04 --- /dev/null +++ b/Assets/Scenes/Main.unity @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:846b79708e8bc05663504fcf3619d214a8ae4f1e380a9fb9049fb5084bc80568 +size 65091 diff --git a/Assets/Scenes/Main.unity.meta b/Assets/Scenes/Main.unity.meta new file mode 100644 index 0000000..1f19bdb --- /dev/null +++ b/Assets/Scenes/Main.unity.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: e913910dbb8a03f4aa58bb1712b2e5c2 +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scripts/Route/TileManager.cs b/Assets/Scripts/Route/TileManager.cs index dc661c7..e1009b0 100644 --- a/Assets/Scripts/Route/TileManager.cs +++ b/Assets/Scripts/Route/TileManager.cs @@ -8,7 +8,8 @@ public class TileManager : MonoBehaviour private List m_tileList = new List(); [SerializeField] - private Transform m_camTransform; + private int trackTiles = 10; + private int m_bendProfile = 0; @@ -26,6 +27,13 @@ public class TileManager : MonoBehaviour private void Start() { m_currentTile = FindObjectOfType(); + + for (int i = 0; i < trackTiles; i++) + { + SpawnRandomTile(); + } + + } // Update is called once per frame @@ -43,10 +51,11 @@ public class TileManager : MonoBehaviour } */ - if(Input.GetKeyDown(KeyCode.Space)) + + /*if(Input.GetKeyDown(KeyCode.Space)) { SpawnRandomTile(); - } + }*/ } void SpawnRandomTile()