My Player has scripts inside that use the Fire1 and Fire2 for certain activities (exploding, animations..) so when I approach a Hotspot and use the Left Mouse button to activate it ..... it shoots, animates ,etc .
Can I use the classical USE keys like the keyboard key 'e' or 'f' to activate Hotspots instead?
It looks like you're new here. If you want to get involved, click one of these buttons!
Comments
You will have to set your Input method to Keyboard And Controller in order to prevent mouse clicks also being registered by the interaction system.
I can't find "list of available inputs in the setting Manager" In section 2.8 of your manual it mentions InteractionA rather in conjunction with joysticks and not as a possible feature for Hotspots. I find the 'e' or 'f' keys more prominent in games than mouse click to "use" something. Nevertheless I intuited that it was the Edit->Project-> Input Manager the one you meant.
Furthermore in addition to the Keyboard and Controller one has to include also Context Sensitive in the Interface settings otherwise it does not work.
Alverik
Now I understand it. Chris said "You can interact with Hotspots via a triggering of an input named "InteractionA" - see the list of "Available inputs" in the Settings Manager" which for me was insufficient info but your following explanation "To actually set them up you have to go to the Unity's Input manager and create the inputs with the same names as in the list " paved for me a clear way on how to continue defining these inputs.
Nevertheless now it works THANK YOU BOTH
The only way it works is by using exclusively this no other combination therein works :
But the movement is so jerky that the Player cannot point precisely to an object (to shoot or grab) so, alas! I can't use it.
I looked at the Input Manager to see if the joysticks may influence the movement but I see nothing different, one thing which I don't understand is the line in all inputs settings: "Joy Num: Get motion from all Joysticks"
I've tried several 1stPersons (including TinPot) and the difference between using Mouse & Keyboard and Keyboard or Controller is that when I move the mouse a mere millimeter either way with the former it changes 2-3 degrees y the 'y-axis' while the latter it swings to 7-9 degrees.
I've been experimenting with movement settings in Setting manager to no avail also I reduced the sensitivity settings in the Project->Input Horizontal and Vertical Axes (may be Chris means another "sensitivity" settings which I fail to see within the 1st person character)
Movement settings within the 1st person character: 2; 6;6;0;1;7 (corresponding to each line)
and the Movement settings in the Setting manager: "Relative to Camera"; 6.15; 0.303;0
if (InputGetMouseButtonDown (0) || InputGetButtonDown ("InteractionA"))
with:
if (InputGetButtonDown ("InteractionA"))
And line 279:
else if (InputGetMouseButton (0) || InputGetButton ("InteractionA"))
with:
else if (InputGetButton ("InteractionA"))
That will prevent the left-mouse button from having an effect when your Input method is set to Mouse And Keyboard. I will look to make this optional in the next update.
I have been circumventing possible solutions and I found something but it's not so good as the one you propose and I am embracing it !!
I will try it tomorrow and let you know... and thanks!!