Quest WIndow Scene Events
Quest WIndow Scene Events
Me again! I am looking to hide some aspects of the UI when the Quest Log Window opens. I didn't see anything already in the script to add a scene event to accomplish this. So I looked at the Quest Log Window script, do I need to override the OpenWindow() and CloseWindow()?
Re: Quest WIndow Scene Events
Hi,
The quest log window has OnOpen() and OnClose() UnityEvents. You can hook them up in the inspector or in code. Code example:
The quest log window has OnOpen() and OnClose() UnityEvents. You can hook them up in the inspector or in code. Code example:
Code: Select all
var questLogWindow = GetComponent<QuestLogWindow>();
questLogWindow.onOpen.AddListener(() => { myUIElement.SetActive(false); });
questLogWindow.onClose.AddListener(() => { myUIElement.SetActive(true); });