Hello everyone,
I'm using a custom 3rd person controller with a vicinity hotspot detector and it's working well however if I had multiple interactions to a hotspot it only shows the icon for the first. Am I missing something? Do I need a cycle button or something and they don't show up until I cycle them? I'm using select hotspot then interaction method.
Another thing is that if I interact with a hotspot so that the interaction option appears and I then walk away from the hotspot so it's no longer in my vicinity the interact icon stays on screen.
Cheers.
Comments
A cycle button may be necessary depending on your chosen options, but if so it'll be listed in the "Available inputs" box in the Settings Manager. You may also need to ensure your Interaction Menu is equipped to display your icons - this won't necessarily be the case by default if you're using your own UI, or created new icons in the Cursor Manager.
Also, temporarily switch to the Demo game's Player, Tin Pot, so that there's no influence from the custom scripts - the first step will be to get everything working with "vanilla" AC.
I cannot recreate the issue - things work using the same settings in the Demo game. If you're using Unity UI, switch your Menu's Source back to Adventure Creator and re-test. When testing with Tin Pot, also switch your Movement method back to Direct - let me know the results.
Set your Movement method to Direct. More options show beneath the Hotspot settings panel in the Settings Manager - it may be that you need to tweak them to get what you want. While this issue is ongoing, rely on AC for movement so that we can discount any custom script influence.
Please let me know the results of the tests I mentioned previously. Switch back to the Demo_MenuManager asset, and rely on Adventure Creator for your Interaction Menu's Source. Are they now correctly working (or even just highlighting)? Again, remove your own custom script from the scene so that we can work from common ground. Once things are working with the default interface in vanilla AC, we can work to bring everything else back in.
When it comes to cursor control, Unity UI's base Event System doesn't allow for a cursor that isn't controlled by the mouse to interact with UI elements. There is a discussion on writing a custom event system here - and a custom Event System prefab can be supplied to the Menu Manager.
However, since you're locking the cursor on start, I'm guessing that you don't actually want to rely on the cursor to select interactions. In that case, you can use the other options for the Select Interactions by field - namely Cycling Menu And Clicking Hotspot and Cycling Cursor And Clicking Hotspot.
These options rely on the CycleInteractions and CycleCursors inputs respectively - though be aware that with the first option, you must make the Menu ignores cursor clicks so that a click to the Hotspot gets registered if the cursor is over it.
It's also the case that a Unity UI-based Interaction menu will not currently highlight the selected icon when using Cycling Menu and Clicking Hotspot mode. I shall see if such a feature can be added.
Controller-based Menus work when the game is paused because AC can make the assumption that you don't want a cursor at this time.
To get what you want, you have two options:
1)
The Cycling Menu And Clicking Hotspot option should give you what you're looking for - you can map an axis to CycleInteractions, or separate buttons to CycleInteractionsLeft and CycleInteractionsRight. You won't be controlling the UI directly, but will be changing the selected cursor icon through AC, and AC will update the UI accordingly.
Again, the selected icon is not currently highlighted in Unity UI, but I shall add this feature in the next release. I recommend using this method, as the second is more complex:
2)
You can manually enable controller-driven Menus at any time with the Engine: Manage systems Action. What you'll want to do is run this Action twice - once to enable this feature when the Interaction Menu is turned on, and again to disable it when turned off.
You can create ActionLists that run when any Menu is turned on/off via the Menu Manager. You will also have to: