Godot Version
4.3 (steam)
Question
Hello there! I need complete master help for next case:
We have 3 main event handlings:
- _gui_input
- _unhandled_input
- _input
Which accept events from some categories of input (as I may know):
- _gui_input accept event when mouse clicked on a gui item (event not continue handlings and not catched by _input/_unhandled)
- _unahndled_input accept event if some input called but not _gui_event & _input event not accept them
- _input accept ANY Input event as main handler
Ok, if Im wrong from steps above - please guide me! Thank you very Much!
Next:
My current architect for the game looks like:
In HUD I have main GUI for player/esc pressed (settings window) and etc…
The main screen scene is changed to game scenes (tilemaplayers, players, monsters, interactive_game_objects and etc…)
Video of trouble:
Problem description:
IF character NOT get any inputs in (_unhandled_input) mouse clicks on skill-panel - is work fine.
IF character GET any inputs parallel mouse clicks on skill-panel - he handle in _unhandled_input the character attack button
What I’ve expect: when player GET any inputs in _unhandled_input and mouse is interract with any GUI - character not handle MOUSE_INPUT at all.
The question is: why this happen? how you correctly setup your _unhandled_input/_input/_gui_input and how to fix my trouble? with examples if you can.
And please, sorry for my bad english!
Thank you very much for help!
P.S. code parts of Player with inputs (gui skill_panel doesnt have any overrided _unhandle_input/_gui_input etc…)
little part of main scene of all GUI - HUD:
P.S2:
I need help explaining how you set up your Input systems more than I need help with a piece of code. I read the Input documentation before coming here, but I don’t seem to understand it very well.