Quest machine hide cursor when accepting quest

Grannyboy

Active member
I have Quest machine integrated with my TPC and everything works great. For example if I click Accept on a quest or closing any UI panel the cursor is still visible until I aim or shoot.

See video attached.

I manually went in to the script that the Accept button calls and coded the cursor to hide but still wont work until i aim or shoot:
1642433344052.png

Worth to mention is that I use UIS for controlling the enable / disable cursor:
1642433412494.png

If this is a UIS issue please move the topic!
 
With the Dialogue System integration there is a converse ability that disables and enables the mouse cursor, I believe there is an ability for Quest Machine, does it have something similar? You set a State (in this case "Conversing" that disables the cursor on th eUnityInput component.


I am pretty certain that the QM integration is similar to the UCC, I set it up years ago and seem to remember them being very similar. hope this helps
 
With the Dialogue System integration there is a converse ability that disables and enables the mouse cursor, I believe there is an ability for Quest Machine, does it have something similar? You set a State (in this case "Conversing" that disables the cursor on th eUnityInput component.


I am pretty certain that the QM integration is similar to the UCC, I set it up years ago and seem to remember them being very similar. hope this helps
Thank you for this comment, I really appreciate it! You are absolutely right there is an ability called "Greet quest giver" and as I mentioned it works properly.
1642541312743.png


But in the video you can see after I accepted the quest, the cursor is still visible. It only disappears as soon as I aim of shoot, I want it to disappear when I press accept or decline button.


I tried achieving that with the code provided in first picture but the cursor is still visible. Is there any other way of hiding a cursor with the UCC, UIS or quest machine asset?
 
Are you by any chance using the escape button in any of that process, in the video?

If not, I’d suggest messaging Tony, either on the Pixel Crishers Discord or forum. He’s usually like “oh, just do this…” and it works.
 
Hi! Did you add a GreetingQuestGiver state to the the player's Unity Input component and place it at the top of the States list?

Is the GreetQuestGiver fairly high in the player's Abilities list so it doesn't get overridden by higher states?

The Quest Giver Interactable Target component starts Quest Machine dialogue with the GameObject that's tagged Player. Is your player tagged Player, and does it have a Quest Journal component?

Are there any errors or warnings in the Console window?
 
Thank you everyone for the help! Really appreciate it. I believe I finally got all the pieces together and for anyone in the future who has similar issues, here is how I solved it:
Both @nathanj and @Tony Li mentioned the GreetQuestGiver state that enables the cursor when talking to a quest giver. My issue was that the cursor was still visible after I accepted the quest and the UI got deactivated.
All I did was to add a exact same state but I disable the cursor instead, then activated the state with the accept button with this code:
1642700654695.png

Now it works perfectly!

Thank you all again
 
If you want to investigate further, just let me know. When the GreetQuestGiver state ends (i.e., dialogue window closes), it will deactivate the GreetingQuestGiver input state, which should automatically hide the mouse.
 
Top