Hey everyone, I'm currently trying to resize my GUIText dynamically for different aspect ratios using the following code in OnGUI().
float width = Screen.width / 1920.0f;
float height = Screen.height / 1080.0f;
GUI.matrix = Matrix4x4.TRS (new Vector3(0, 0, 0), Quaternion.identity, new Vector3 (width, height, 1));
However this is not affecting the text at all and it stays the same size. Is there anything I'm doing wrong or what I can do to make the GUIText be affected by this matrix change?
↧