Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


batteryStatus

Returns the current status of the device's battery (Read Only).
Read time 1 minuteLast updated 6 days ago

Definition

  • Type: Property
  • Namespace: UnityEngine
  • Assembly: UnityEngine.CoreModule
public static BatteryStatus batteryStatus { get; }

Remarks

See the BatteryStatus enumeration for possible values.
The battery status includes information about whether the device is plugged in to a power source and whether the battery is charging. If battery status is not available on your target platform, this property returns BatteryStatus.Unknown.
Additional Resources: SystemInfo.batteryLevel.