유니티 C# 베터리 잔량 가져오기 Battery 간단 사용법


유니티 C# 베터리 잔량 가져오기 Battery 간단 사용법

코드 작성 using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.UI; public class Example : MonoBehaviour { private void Start() { float number = SystemInfo.batteryLevel; // 베터리 충전량 가져오기 (0 ~ 1); Debug.Log(SystemInfo.batteryLevel); switch(SystemInfo.batteryStatus) //베터리 상태 가져오기 { case BatteryStatus.Unknown: Debug.Log("충전 상태를 알 수 없음"); break; case BatteryStat..


원문링크 : 유니티 C# 베터리 잔량 가져오기 Battery 간단 사용법