Invector Integration Journal Button
Invector Integration Journal Button
Hi, when I put a journal button on a separate canvas like in the invector integration demo the j button works to spawn the journal but I am unable to click with the mouse. Now I want it how when you press the I key and the inventory main window comes up. I put a button on that main window panel in hopes that I can click the journal button and the journal comes up but it doesn't work like that at all. Does anyone know how I would be able to achieve this? The quest button meant to open up the journal but it doesn't work.
- Attachments
-
- QuestButton.JPG (23.4 KiB) Viewed 1988 times
Re: Invector Integration Journal Button
Hi,
Your Invector UI canvas(es) may be covering the journal button if it's on a separate canvas. If you want to use a separate canvas, try increasing its Sort Order so it's on top of Invector's canvases. This way Invector's canvases won't block your mouse clicks.
If you want to add the button to Invector's Inventory UI > Main Window, it's instantiated at runtime. This means you can't hook it up to the Quest Journal component that already exists in the scene. Instead, add a small script to find the Quest Journal and toggle it on and off:
ShowHideQuestJournal.cs
Add this script to the UI button, and configure the button's OnClick() to call ShowHideQuestJournal.ToggleQuestJournal.
Your Invector UI canvas(es) may be covering the journal button if it's on a separate canvas. If you want to use a separate canvas, try increasing its Sort Order so it's on top of Invector's canvases. This way Invector's canvases won't block your mouse clicks.
If you want to add the button to Invector's Inventory UI > Main Window, it's instantiated at runtime. This means you can't hook it up to the Quest Journal component that already exists in the scene. Instead, add a small script to find the Quest Journal and toggle it on and off:
ShowHideQuestJournal.cs
Code: Select all
public class ShowHideQuestJournal : UnityEngine.MonoBehaviour
{
public void ToggleQuestJournal()
{
FindObjectOfType<PixelCrushers.QuestMachine.QuestJournal>().ToggleJournalUI();
}
}
Re: Invector Integration Journal Button
That worked part of the way but now when I close the journal I lose my mouse to click on anything else. and when I do the hotkey which on mine is returned it will come up but will disappear really quick without clicking on any button. I wanted it similar to the other windows when the items come up the three buttons will disappear and when you exit the window the button will reappear. The selector has worked for me and my lack of coding is getting in the way of this working. I wanted that nice touch to the game instead of just using a plain old hotkey which will be J for journal.
Re: Invector Integration Journal Button
Hi,
I'll take a look in the morning and let you know what steps will take care of the mouse cursor. I have a feeling it's possible without having to do any scripting.
I'll take a look in the morning and let you know what steps will take care of the mouse cursor. I have a feeling it's possible without having to do any scripting.
Re: Invector Integration Journal Button
Hi,
A short script makes the setup much simpler. Here's the updated QM Invector Support package:
QM_InvectorSupport_2019-06-16.unitypackage
Inside it is another unitypackage in the Examples / Extras folder. If you import this, it will create a folder "Quest Machine Examples" with an example scene, script, and brief instructions.
A short script makes the setup much simpler. Here's the updated QM Invector Support package:
QM_InvectorSupport_2019-06-16.unitypackage
Inside it is another unitypackage in the Examples / Extras folder. If you import this, it will create a folder "Quest Machine Examples" with an example scene, script, and brief instructions.
Re: Invector Integration Journal Button
You have gone above and beyond thank you so much.
Re: Invector Integration Journal Button
Glad to help! I figure it will be useful to almost everyone who is using Invector with Quest Machine, so it was nice to be able to add the feature.
Re: Invector Integration Journal Button
This would be an added bonus if it is included in the next release, it works great.
Re: Invector Integration Journal Button
I already packed it into the Invector Support package in preparation for the next release.
Re: Invector Integration Journal Button
Hey I just Downloaded and am having the same problem but your download fix is not available?