void Update() { string[] keys = { "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", "-", }; foreach (string key in keys) { if (Input.GetKeyDown(key)) { if (ts.InputKey(key) == 1) { UpdateText(); } break; } } if (ts.isEnded() || compulsionEnd) { dictionary.i++; ts.SetInputString(dictionary.GetRandomWord()); UpdateText(); typingTime.SliderUpdate(); compulsionEnd = false; } }
// Update is called once per frame void Update() { foreach (string key in keys) { if (Input.GetKeyDown(key)) { if (ts.InputKey(key) == 1) { UpdateText(); } break; } } if (ts.isEnded()) { ts.SetInputString(lirycs.GetRandomWord()); UpdateText(); } }
// Update is called once per frame void Update() { string[] keys = { "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", "-", }; foreach (string key in keys) { if (Input.GetKeyDown(key)) { if (ts.InputKey(key) == 1) { UpdateText(); } break; } } if (ts.isEnded()) { ts.SetInputString(dictionary.GetRandomWord()); score.AddScore(10); UpdateText(); } }
// Update is called once per frame void Update() { string[] keys = { "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", "-", ";", ":", "1","2", "3", "4", "5", "6", "7", "8", "9", "0", ",", ".", "/", "@", "[", }; foreach (string key in keys) { if (Input.GetKeyDown(key)) { if (ts.InputKey(key) == 1) { UpdateText(); } break; } } if (ts.isEnded()) { int t = Random.Range(0, i); ts.SetInputString(dictionary.GetRandomWord(t)); Kanzi = dictionary.GetRandomKanziWord(t); UpdateText(); } }