private void Awake() { level = lm.Level; levelState = lm.State; text = GetComponent <Text>(); anim = GetComponent <Animator>(); }
// Update is called once per frame void Update() { if (levelState != lm.State) { levelState = lm.State; } // Update Text }
private void UpdateState() { state = lm.State; if (state == LevelManager.LevelState.Playing) { anim.SetBool("OnScreen", true); } else { anim.SetBool("OnScreen", false); } }
// Update is called once per frame void Update() { if (level != lm.Level) { level = lm.Level; text.text = level.ToString(); } if (levelState != lm.State) { levelState = lm.State; } }
// Update is called once per frame void Update() { if (lmState != lm.State) { lmState = lm.State; // } /*if(lm.State == LevelManager.LevelState.Transition) * { * // We only accept inputs during this state * * if(Input.anyKeyDown) * { * lm.State = LevelManager.LevelState.TransitionOut; * } * }*/ }
private void Awake() { lmState = lm.State; }
private void Awake() { anim = GetComponent <Animator>(); state = lm.State; }