void OnGUI() { if (Skin == null) { Skin = StyleConverter.Convert(GUI.skin); } }
/// <summary> /// Get Unity skin - only accessible in OnGUI /// </summary> void OnGUI() { if (GamePaused && !ShowUI) { return; } if (CommonWindowProperties.UnitySkin == null) { CommonWindowProperties.UnitySkin = StyleConverter.Convert(GUI.skin); // Load Unity skin, if it was saved in the config if (Configuration.Skin == 1) { CommonWindowProperties.ActiveSkin = CommonWindowProperties.UnitySkin; CommonWindowProperties.RefreshStyles(); } } }