<commit_before>﻿using UnityEngine;
using UnityEngine.UI;
using System.Collections;
using UnityEngine.SceneManagement;

namespace UDBase.Components.Scene {
	public class AsyncLoadHelper : MonoBehaviour {

		public void LoadScene(string name) {
			StartCoroutine(LoadSceneCo(name));
		}

		IEnumerator LoadSceneCo(string name) {
			yield return null;
			var text = GameObject.FindObjectOfType<Text>();
			var operation = SceneManager.LoadSceneAsync(name);
			operation.allowSceneActivation = false;
			while (!operation.isDone && operation.progress + Mathf.Epsilon < 0.9f ) {
				if( text ) {
					text.text = operation.progress.ToString();
				}
				yield return null;
			}
			operation.allowSceneActivation = true;
		}
	}
}<commit_msg>Some TODO;<commit_after>﻿using UnityEngine;
using UnityEngine.UI;
using System.Collections;
using UnityEngine.SceneManagement;

namespace UDBase.Components.Scene {
	public class AsyncLoadHelper : MonoBehaviour {

		public void LoadScene(string name) {
			StartCoroutine(LoadSceneCo(name));
		}

		IEnumerator LoadSceneCo(string name) {
			yield return null;
			var text = GameObject.FindObjectOfType<Text>();
			var operation = SceneManager.LoadSceneAsync(name);
			operation.allowSceneActivation = false;
			while (!operation.isDone && operation.progress + Mathf.Epsilon < 0.9f ) {
				// TODO: Make EventSystem
				if( text ) {
					text.text = operation.progress.ToString();
				}
				yield return null;
			}
			operation.allowSceneActivation = true;
		}
	}
}
{'fraction_non_alphanumeric': 0.10287241148964596, 'fraction_numerical': 0.0026720106880427524, 'mean_word_length': 4.165517241379311, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7131148', 'n_tokens_mistral': 522, 'n_tokens_neox': 446, 'n_words': 98}