2018년 9월 24일 월요일

[Unity] android 기기버튼 처리

유니티에서 android 기기버튼 (뒤로가기, 홈, 메뉴) 처리하기



#if UNITY_ANDROID
        if (Input.GetKeyDown(KeyCode.Escape))
        {
           //뒤로가기 버튼
        }
        else if (Input.GetKeyDown(KeyCode.Menu))
        {
           //메뉴버튼
        }
        else if (Input.GetKeyDown(KeyCode.Home))
        {
           //홈버튼
        }
#endif

댓글 없음:

댓글 쓰기