Invector/Dialogue System mouse conflict?
Invector/Dialogue System mouse conflict?
Can you please suggest anything that might help me. I've totally run out of ideas now. I've attached 6 screen shots that show Invector and DS setups that may affect the mouse. Can you see what I'm doing wrong?
- Attachments
-
- 5DialogueInputDevice.jpg (111.14 KiB) Viewed 1748 times
-
- 4DialogueInputSettings.jpg (133.05 KiB) Viewed 1748 times
-
- 3InvectorItemManagerEvents.jpg (127.42 KiB) Viewed 1748 times
-
- 2PlayerSetup.jpg (151.86 KiB) Viewed 1748 times
Re: Invector/Dialogue System mouse conflict?
For some reason I couldn't add the 6th screenshot so here it is here.
- Attachments
-
- 6DemoMenuSettings.jpg (142.21 KiB) Viewed 1747 times
Re: Invector/Dialogue System mouse conflict?
Hi,
The DemoMenu script was really only written to drive the demo scene. You might have an easier time with the simpler SaveSystemTestMenu script. It's also only for testing, not a release-quality menu system. But its mouse handling is a bit more straightforward. Ultimately you'll want to remove both and use a real menu system of your own design. In the meantime, if you want to set up the SaveSystemTestMenu:
The DemoMenu script was really only written to drive the demo scene. You might have an easier time with the simpler SaveSystemTestMenu script. It's also only for testing, not a release-quality menu system. But its mouse handling is a bit more straightforward. Ultimately you'll want to remove both and use a real menu system of your own design. In the meantime, if you want to set up the SaveSystemTestMenu:
- Remove the DemoMenu script and add a SaveSystemTestMenu instead and tick Pause While Open and Allow Cursor While Open.
- On the Dialogue Manager, tick the Input Device Manager's Detect Mouse Control, but leave the other checkboxes that you changed unticked.
Re: Invector/Dialogue System mouse conflict?
Thank you so much once again. It's all working now. I had to fiddle with the mouse settings a little but in the end it was pretty much the way you suggested.
I do understand that it would be best to make my own menu but at this stage of my learning curve it's a bit beyond me. I just wanted something simple that would do the job until I get round to looking at all the UI assets I've bought and never used. I really want a stage by stage YouTube tutorial on how to make a menu system using Invector and Dialogue System.
But for now your Test Menu is just what I needed.
Thank you.
I do understand that it would be best to make my own menu but at this stage of my learning curve it's a bit beyond me. I just wanted something simple that would do the job until I get round to looking at all the UI assets I've bought and never used. I really want a stage by stage YouTube tutorial on how to make a menu system using Invector and Dialogue System.
But for now your Test Menu is just what I needed.
Thank you.
Re: Invector/Dialogue System mouse conflict?
Glad to help!
Re: Invector/Dialogue System mouse conflict?
Just one little extra thing. Sorry to be a nuisance.
I was still getting a small problem in that the mouse would persist after clicking the save button in the Test menu. I sort of solved it by editing the script and adding "Cursor.visible = false:" at the end of the save game sequence. I don't really know what I'm doing but it seemed to fix it. However, later I noticed the mouse would randomly persist after a dialogue had ended. I tried all the events, but it kept happening so I thought I would try a bit of Lua code in the script section at the end of a conversation branch. But I can't find the Lua equivalent of "Cursor.visible = false:"
Can you tell me what that might be? And also the Lua code for turning the cursor back on?
Just as a side note, I added the C# script instead of Lua and the interpreter got so confused banging out the error messages it quite forgot to show the mouse...so that fixed that. Every cloud eh? But if you could give me those Lua code lines I would be most grateful.
I was still getting a small problem in that the mouse would persist after clicking the save button in the Test menu. I sort of solved it by editing the script and adding "Cursor.visible = false:" at the end of the save game sequence. I don't really know what I'm doing but it seemed to fix it. However, later I noticed the mouse would randomly persist after a dialogue had ended. I tried all the events, but it kept happening so I thought I would try a bit of Lua code in the script section at the end of a conversation branch. But I can't find the Lua equivalent of "Cursor.visible = false:"
Can you tell me what that might be? And also the Lua code for turning the cursor back on?
Just as a side note, I added the C# script instead of Lua and the interpreter got so confused banging out the error messages it quite forgot to show the mouse...so that fixed that. Every cloud eh? But if you could give me those Lua code lines I would be most grateful.
Re: Invector/Dialogue System mouse conflict?
Hi,
There is no Lua code to hide the mouse cursor. (Side note: A programmer could write a C# method and register it with Lua, but nothing is built in.)
Don't rely on side effects to make things work. Try this:
1. Make a copy of SaveSystemTestMenu.cs (the one in the Common/Scripts folder) and rename it to something like MyTestMenu.cs.
2. Edit the script.
There is no Lua code to hide the mouse cursor. (Side note: A programmer could write a C# method and register it with Lua, but nothing is built in.)
Don't rely on side effects to make things work. Try this:
1. Make a copy of SaveSystemTestMenu.cs (the one in the Common/Scripts folder) and rename it to something like MyTestMenu.cs.
2. Edit the script.
- On line 13, change "public class SaveSystemTestMenu" to the name of the script -- for example: "public class MyTestMenu".
- Change lines 84-85 to:
Code: Select all
Cursor.visible = false; Cursor.lockState = CursorLockMode.Locked;
Re: Invector/Dialogue System mouse conflict?
Wow! Thank you so much. I did all that you said and then dragged my new save script into the Dialogue Manager. With the events you suggested set on conversation end everything worked perfectly. For the first time I was able to play through my project level without errors.
You really are the best.
You really are the best.
Re: Invector/Dialogue System mouse conflict?
Glad to help!