Fixed Camera Point Added

This commit is contained in:
2022-02-26 15:09:41 +03:00
parent d6c026bd99
commit 1dc131645d
4 changed files with 45 additions and 0 deletions

View File

@@ -13,6 +13,8 @@ namespace Level
private GameObject instance = null;
private bool needsRestart = true;
public Transform FixedCameraPoint { get; private set; } = null;
public void SetLevel(int levelNumber)
{
LevelNumber = levelNumber;
@@ -36,6 +38,8 @@ namespace Level
instance = Instantiate(prefab, transform.position, Quaternion.identity, transform);
StartingPoint = instance.transform.Find("Starting Point");
FixedCameraPoint = instance.transform.Find("Fixed Camera Point");
gameObject.SetActive(false);
needsRestart = false;
}

View File

@@ -36,6 +36,7 @@ namespace Level
}
private Level currentLevel = null;
public Level CurrentLevel => currentLevel;
private void Awake()
{