// Use this for initialization void Start() { // Start pooling prefabs, like shots, grunts and exploded grunts. ObjectPoolingManager.Instance.CreatePool(m_shot, 100, 100); ObjectPoolingManager.Instance.CreatePool(m_grunt, 100, 100); ObjectPoolingManager.Instance.CreatePool(m_grunt_explodes, 100, 100); ObjectPoolingManager.Instance.CreatePool(m_hulk, 100, 100); ObjectPoolingManager.Instance.CreatePool(m_hulk_explodes, 100, 100); ObjectPoolingManager.Instance.CreatePool(m_player_explodes, 1, 1); m_current_score = 0; m_current_level = 0; m_GamePlay_Screen.FillLives(); m_loading_screen.SetActive(false); m_gameplay_screen.SetActive(false); m_score_screen.SetActive(false); m_youwin_screen.SetActive(false); m_gameover_screen.SetActive(false); m_player.SetActive(true); // Start coroutines. StartCoroutine(NextLevel()); }