// Start is called before the first frame update void Start() { xpBeforeGame = XPManager.GetStoredXP(); xpAfterGame = xpBeforeGame + XPManager.GetEarnedXP(); XPManager.StoreEarnedXP(); round = SessionManager.currentRound; SceneManager.sceneLoaded += OnLevelLoad; DontDestroyOnLoad(gameObject); }
// Start is called before the first frame update void Start() { switch (progressionType) { case XpTypes.Maps: boundary = XPManager.MAP_XP_BOUNDARIES; break; case XpTypes.Skins: boundary = XPManager.SKIN_XP_BOUNDARIES; break; } int level = XPManager.CalculateLevel(XPManager.GetStoredXP(), boundary); for (int i = 0; i < progression.Length; ++i) { progression[i].item.gameObject.SetActive(level >= i); if (progression[i].lockedPlaceholder != null) { progression[i].lockedPlaceholder.gameObject.SetActive(level < i); } } }