23 lines
673 B
C#
23 lines
673 B
C#
using UnityEngine;
|
|
|
|
public class MiscGUI : MonoBehaviour
|
|
{
|
|
public GUIStyle SubTitle;
|
|
|
|
public RealWater WaterPlane;
|
|
|
|
private float native_width = 1920f;
|
|
|
|
private float native_height = 1080f;
|
|
|
|
private void OnGUI()
|
|
{
|
|
float x = (float)Screen.width / native_width;
|
|
float y = (float)Screen.height / native_height;
|
|
GUI.matrix = Matrix4x4.TRS(new Vector3(0f, 0f, 0f), Quaternion.identity, new Vector3(x, y, 1f));
|
|
GUI.depth = 10;
|
|
GUI.Box(new Rect(38.399998f, 32.399998f, 729.6f, 540f), "");
|
|
GUI.Label(new Rect(57.6f, 108f, 288f, 151.2f), "Quality: " + WaterPlane.quality.ToString() + " (" + WaterPlane.GetRows() + "x" + WaterPlane.GetCols() + ")", SubTitle);
|
|
}
|
|
}
|