Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Level 2 블루프린트 이벤트 & 함수 정리 #5

Closed
ggjae opened this issue Jun 24, 2021 · 0 comments
Closed

Level 2 블루프린트 이벤트 & 함수 정리 #5

ggjae opened this issue Jun 24, 2021 · 0 comments

Comments

@ggjae
Copy link
Owner

ggjae commented Jun 24, 2021

Level2에서 사용한 함수와 블루프린트 클래스로부터 연결되어 있는 이벤트들을 정리하기 위한 ISSUE

Level BP
image

블루프린트 클래스(BP_4ColorSwitch)에서 OnAnswerIsRight의 이벤트가 발생하면 레벨 블루프린트는 이것을 확인하고 realDoor를 destory하게끔 설정되어 있다.

블루프린트 클래스(UI)
image

UI 클래스에서 button과 UserInput, Index, Answer를 변수로 설정하여 사용자가 생각한 정답과 게임 내에서의 로직의 정답이 일치하는지 확인하는 알고리즘이 적용되었고 이 때 검증하기 위한 알고리즘의 자료구조로 배열을 선택하였다. 배열의 0,1,2,3 인덱스 4개를 이용하여 사용자가 선택한 정답이 일치하면 Hide UI 함수(뷰포트에서 제거시키고 마우스 커서를 보이지 않게 설정하고 Game Mode Only로 설정 및 Input을 Reset하는 함수)를 호출한다.

블루프린트 클래스(BP_4ColorSwitch)
image

4ColorSwitch와 연동할 UI의 객체를 만들어 switchUI라는 이름을 선택하였고 위젯을 생성하고 On User Answer 이벤트를 만들어 Input과 정답이 일치할때에는 OnAnswerIsRight라는 이벤트 디스패처로 이동하고 일치하지 않으면 OnAnswerIsWrong라는 이벤트 디스패처로 이동함. 박스 트리거를 이용하여 박스 트리거와 충돌이 일어났을때와 일어나지 않았을때로 텍스트 렌더링을 진행시켜주었고 F키를 누르면 뷰포트에 UI를 추가시켜 InputMode로 진행시킨다.

@ggjae ggjae closed this as completed Jul 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant