Good afternoon!
I'm sorry to take your time with this, but I haven't been able to find what is giving this issue. I made a scene with Dialogue System working, made a mock quest, all was great. Then I imported Inventory Pro (IP) and Behavior Designer into my files, added the integration from Inventory Pro's tool, and the additional Lua codes found in the Third Party Support folder. Tested without actually adding anything to the scene, all good!
So I did the quick set up with Inventory Pro, and I can't talk to people anymore. It just doesn't do anything. One empty scene later, quick set up with Dialogue System, works. Add Inventory Pro managers, and bam! Can't talk anymore.
Disabling or deleting the managers doesn't make it work again. I think narrowed it down to the Selector script not staying on, but I'm not sure how to fix it. When I hit play, the reticle/nameplate flashes on-then-off as it loads. The script itself stays enabled in the inspector.
I tried giving IP its own Canvas instead of the Dialogue System's Canvas, but that didn't work. I'm at a complete loss.
I'm not sure if it'd be helpful, but here's a bare list of scripts on each item, and the item hierarchy.
Items in Scene:
Dialogue Manager:
IP's Managers:
Mock Player:
I really hope that I'm just missing something simple. Thank you for your time.
Selector Issue after adding Inventory Pro
Re: Selector Issue after adding Inventory Pro
Hi,
What are the settings on your Selector?
If you're selecting using the mouse, it's possible that IP's canvas is blocking everything. To test this, edit Selector.cs (the one in Scripts, not in Wrappers), and comment out this line:
so it looks like this:
This lets the Selector target things that are underneath UI objects.
If it works, watch the scene's EventSystem in the Inspector view. As you move the mouse, check what it reports for "pointerEnter". This may be what's blocking the Selector.
(Side note: You can add a 'Selector Use Standard UI Elements' component to your player. This tells it to use the Standard UI Selector Elements that the Dialogue Manager instantiates. Otherwise the Standard UI Selector Elements will just sit there unused, and the Selector will use legacy Unity GUI.)
What are the settings on your Selector?
If you're selecting using the mouse, it's possible that IP's canvas is blocking everything. To test this, edit Selector.cs (the one in Scripts, not in Wrappers), and comment out this line:
Code: Select all
// Exit if using mouse selection and is over a UI element:
if ((selectAt == SelectAt.MousePosition) && (UnityEngine.EventSystems.EventSystem.current != null) && UnityEngine.EventSystems.EventSystem.current.IsPointerOverGameObject()) return;
Code: Select all
// Exit if using mouse selection and is over a UI element:
//if ((selectAt == SelectAt.MousePosition) && (UnityEngine.EventSystems.EventSystem.current != null) && UnityEngine.EventSystems.EventSystem.current.IsPointerOverGameObject()) return;
If it works, watch the scene's EventSystem in the Inspector view. As you move the mouse, check what it reports for "pointerEnter". This may be what's blocking the Selector.
(Side note: You can add a 'Selector Use Standard UI Elements' component to your player. This tells it to use the Standard UI Selector Elements that the Dialogue Manager instantiates. Otherwise the Standard UI Selector Elements will just sit there unused, and the Selector will use legacy Unity GUI.)
Re: Selector Issue after adding Inventory Pro
Thank you so much for responding so quickly!
Mouse Position was the selector setting. I was able to initialize dialog with the specified line commented out. I looked at the EventSystem with the line commented out and not, and pointerEnter showed as the same items. Sphere when over the Sphere, and Terrain everywhere else.
I'll look into the 'Selector Use Standard UI Elements' component! I did a cursory test in the test center, but it still only worked with the one line commented out. Going to see what it does in my other scene that's not all defaults.
Edit// Unfortunately, commenting out the code didn't work on initializing dialog my main scene. It did let the names pop up at least, so there's that! The pointerEnter was the same on commented out and not as well.
Mouse Position was the selector setting. I was able to initialize dialog with the specified line commented out. I looked at the EventSystem with the line commented out and not, and pointerEnter showed as the same items. Sphere when over the Sphere, and Terrain everywhere else.
I'll look into the 'Selector Use Standard UI Elements' component! I did a cursory test in the test center, but it still only worked with the one line commented out. Going to see what it does in my other scene that's not all defaults.
Edit// Unfortunately, commenting out the code didn't work on initializing dialog my main scene. It did let the names pop up at least, so there's that! The pointerEnter was the same on commented out and not as well.
Re: Selector Issue after adding Inventory Pro
After having it work in one scene and not the other... I slow put the Player from my main scene into the Test Center. Didn't work when I switched de-activated my mock-dummy and activated the one from main.. My mock guy still worked though, so I just slowly moved everything over.
The settings were identical between the two, so I'm going to file this under Unity being weird (and that commented line!)
Thank you very much, for your time and help!
The settings were identical between the two, so I'm going to file this under Unity being weird (and that commented line!)
Thank you very much, for your time and help!
Re: Selector Issue after adding Inventory Pro
Glad to help! If any problems pop up, and it wasn't Unity being weird, just let me know.