void InitGUI() { if (!initGUI) { gui = new GUIContent(TimeString(100.0f, 1000)); size = DebugUI.DebugStyle(TextAnchor.MiddleLeft, 14).CalcSize(gui); initGUI = true; } }
static void InitGUI() { if (!initGUI) { dtGUI = new GUIContent("Jan 31, 100000 [12:12]"); dtSize = DebugUI.DebugStyle(TextAnchor.MiddleLeft, 14).CalcSize(dtGUI); initGUI = true; } }
static void OnDateTimeGUI() { InitGUI(); dtGUI.text = dateString + " [" + timeOfDayString + "]"; GUI.Box(new Rect(Screen.width - dtSize.x, 32, dtSize.x, dtSize.y), dtGUI, DebugUI.DebugStyle(TextAnchor.MiddleLeft, 14)); }