Version: 2017.3

SystemInfo.operatingSystemFamily

Switch to Manual
public static OperatingSystemFamily operatingSystemFamily ;

Description

Returns the operating system family the game is running on (Read Only).

This API is used by UI code to distinguish between desktop OS families with different UI conventions. For all non-desktop platforms it will currently return OperatingSystemFamily.Other.

using UnityEngine;

public class ExampleClass : MonoBehaviour { void Start() { if (SystemInfo.operatingSystemFamily == OperatingSystemFamily.MacOSX) Debug.Log("Do something special here"); } }

See Also: OperatingSystemFamily enum, SystemInfo class.