// Start is called before the first frame update void Start() { next_level = GameObject.Find("Goal"); nl = next_level.GetComponent <Next_Level>(); les_anim = GetComponent <Les_animations>(); pm = GetComponent <PlayerMovement>(); player_health = 5; number_of_hearts = player_health; }
void Find_Next_Level() { found_players = true; next_level = GameObject.Find("Goal"); nl = next_level.GetComponent <Next_Level>(); nl.level_count = 1; //nl.current_coin_count = 0; if (ph.has_restarted) { nl.first_offset = 24f; nl.transform.position = new Vector2(8, -.5f); } }