본문 바로가기
Study/error 삽질

[Unity] InvalidOperationException: You are trying to read Input using the UnityEngine.Input class, but you have switched active Input handling to Input System package in Player Settings. 해결 방법

by 코딩여걸 2023. 2. 3.
728x90

유니티 스크롤을 페이지 단위로 처리하는 것을 YouTube 영상을 보면서 만들고 실행을 시켜봤는데

InvalidOperationException: You are trying to read Input using the UnityEngine.Input class, but you have switched active Input handling to Input System package in Player Settings.

이런 에러가 발생했다.

 

 

< 해결 방법 >

에러를 찾아본 끝에 해결책을 찾았다.

 

1. File > Build Settings 클릭

 

2. Player Settings... 클릭

 

3. Player > Other Settings에서 밑으로 내려보면

 

4. Active Input Handling* 이 Input System Package (New)로 되어있을 것이다. (아니면 말고)

 

5. Active Input Handling*을 Input System Package (New) 에서 Both로 바꿔주자!

 

6. Apply 클릭 -> Unity 창이 잠깐 닫혔다가 다시 열릴것이다.

 

7. Both로 바뀐 것 확인

 

8. Console창이 이렇게 되면서 프로그램을 다시 실행하면 오류 없이 잘 동작할 것이다.

728x90

댓글