public Text NumberOfLettersText;//for testing only private void Start() { if (_allLetters == null) { _allLetters = new List <string> { "а", "а", "с", "и", "р", "о", "р", "д", "ш", "и", "и", "и", "ц", "е", "н", "а", "т", "щ", "л", "к", "ж", "п", "в", "к", "о", "в", "а", "у", "н", "к", "е", "м", "г", "і", "н", "х", "і", "н", "и", "н", "а", "и", "р", "л", "р", "с", "п", "м", "а", "у", "а", "ю", "м", "с", "б", "в", "я", "м", "т", "ф", "с", "и", "о", "я", "п", "о", "о", "л", "е", "а", "б", "і", "е", "ь", "т", "р", "ґ", "з", "д", "о", "і", "і", "є", "й", "е", "д", "н", "о", "у", "г", "ї", "ч", "о", "о", "о", "к", "т", "н", "в", "т", "з", "'", "*", "*" } } ; CurrentLetters = new List <LetterH>(); _allLetters = _allLetters.OrderBy(letter => letter).ToList(); FreeCoordinates = new List <Vector3>(); _currentFieldH = GameObject.FindGameObjectWithTag("Field").GetComponent <FieldH>(); DistanceBetweenLetters = LetterSize.x; LetterHPrefab.gameObject.GetComponent <RectTransform>().sizeDelta = LetterSize; _xOffset = gameObject.transform.position.x - 2 * DistanceBetweenLetters; var yOffset = gameObject.transform.position.y + DistanceBetweenLetters; _pos = new Vector3(_xOffset, yOffset); ChangeBox(NumberOfLetters); }
public Text NumberOfLettersText;//for testing only private void Start() { if (_allLetters == null) { _allLetters = new List <string> { "ක", "ර", "ක", "ම", "ත", "ත", "ල", "ට", "ක", "ත", "ල", "ව", "හ", "ල", "අ", "බ", "න", "ප", "ඉ", "ර", "ක", "ත", "ල", "ට", "ක", "ර", "ක", "ම" , "ත", "ට", "ත", "ල", "ට", "ච", "ක", "ර", "ක", "ත", "ම", "ල", "ට", "ස", "ය", "ව", "හ", "ල", "අ", "ත", "බ", "න", "ප" } } ; CurrentLetters = new List <LetterH>(); _allLetters = _allLetters.OrderBy(letter => letter).ToList(); FreeCoordinates = new List <Vector3>(); _currentFieldH = GameObject.FindGameObjectWithTag("Field").GetComponent <FieldH>(); DistanceBetweenLetters = LetterSize.x; LetterHPrefab.gameObject.GetComponent <RectTransform>().sizeDelta = LetterSize; _xOffset = gameObject.transform.position.x - 2 * DistanceBetweenLetters; var yOffset = gameObject.transform.position.y + DistanceBetweenLetters; _pos = new Vector3(_xOffset, yOffset); ChangeBox(NumberOfLetters); }
private void Start() { parent = transform.parent.gameObject.GetComponent <FieldH>(); }