Added Heights Level

This commit is contained in:
Zoe J committed 2022-02-25 19:52:26 -06:00
1 parent 4954204e99
commit edcc7df8f6
9 files changed
+2456 -27

No files matched your search

+37
View File
@@ -0,0 +1,37 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class BeatHeights : MonoBehaviour
{
public int currentLevel;
// Start is called before the first frame update
void Start()
{
currentLevel = PlayerPrefs.GetInt("CurrentLevel");
}
// Update is called once per frame
/*void Update()
{
if (Input.GetButtonDown("Jump"))
{
BeatLevel();
}
}*/
void BeatLevel()
{
if (currentLevel == 1)
{
PlayerPrefs.SetInt("CurrentLevel", 2);
SceneManager.LoadScene("Real World");
}
else
{
SceneManager.LoadScene("Real World");
}
}
}