summaryrefslogtreecommitdiffstats
path: root/core/input
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #84445 from Rubonnek/add-const-references-clang-tidyRémi Verschelde2024-01-042-3/+3
|\ | | | | | | Add const references detected by clang-tidy
| * Add const references detected by clang-tidyWilson E. Alvarez2023-12-162-3/+3
| |
* | Fix missing autocompletion for inheriting classesMicky2024-01-031-0/+1
|/
* Add bindings for setting and getting emulation mouse from touch and touch ↵CaTaTo2023-12-131-0/+6
| | | | from mouse in input
* Rework action pressed state to support multiple controllersGilles Roudière2023-12-042-102/+111
|
* Rework input actions to be reliablekobewi2023-11-104-59/+102
|
* Sync controller mappings DB with SDL2 community repoRémi Verschelde2023-10-231-1/+11
| | | | | | Synced with gabomdq/SDL_GameControllerDB@eb831f75abb5c796fb2f2843c3e055d2b8cba29b Fixes #83552.
* Merge pull request #81322 from johnnyw/android_fix_joypad_trigger_rangeRémi Verschelde2023-10-202-4/+6
|\ | | | | | | Android: Fix joypad trigger value range
| * Android: Fix joypad trigger value rangeJohn Watson2023-10-202-4/+6
| | | | | | | | | | | | `Input::joy_axis` converts trigger values to be between 0.0f to 1.0f by default. This is not needed for Android, as values are already within that range, as per Android documentation: https://developer.android.com/reference/android/view/MotionEvent#AXIS_RTRIGGER This patch prevents this conversion on Android, which caused L2 and R2 triggers to get stuck pressed. https://github.com/godotengine/godot/issues/79263
* | Fix `Input.is_action_just_pressed` flicker on joypad axesErezShahaf2023-10-161-8/+7
| | | | | | | | | | | | | | | | | | Pressed tick assignments were in the wrong scope, resulting in updating `pressed_frame` even when it shouldn't and therefore the `just_pressed` would return true every time that the strength changes and not only when there's a new valid press. Fixes #81975.
* | Merge pull request #82203 from KoBeWi/shortcuts_under_pressureRémi Verschelde2023-09-242-0/+6
|\ \ | | | | | | | | | Make InputEventShortcut always pressed
| * | Make InputEventShortcut always pressedkobewi2023-09-232-0/+6
| | |
* | | Sync controller mappings DB with SDL2 community repoRémi Verschelde2023-09-241-47/+152
|/ / | | | | | | Synced with gabomdq/SDL_GameControllerDB@fc4b33c87239865487a3d956f7540a8d420066f5
* | Merge pull request #81170 from KoBeWi/step_inputRémi Verschelde2023-09-112-5/+27
|\ \ | | | | | | | | | Prevent axis-based actions from getting stuck
| * | Prevent axis-based actions from getting stuckkobewi2023-09-042-5/+27
| |/
* / UWP: Remove platform port, needs to be redone from scratch for 4.xRémi Verschelde2023-09-072-4/+0
|/ | | | | | | | | | | The UWP platform port was never ported to the Godot 4.0+ API, and it's now accumulating bitrot as it doesn't compile, and thus we no longer propagate platform changes in it. So we finally remove to acknowledge this state. There's still some interest in reviving the UWP port eventually, especially as support for Direct3D 12 will soon be merged, but when that happens it will be easiest to redo it from scratch.
* Remove debug printkobewi2023-08-291-2/+0
|
* Merge pull request #80859 from KoBeWi/prepare_for_action_and_make_it_doubleRémi Verschelde2023-08-292-22/+37
|\ | | | | | | Fix action state when multiple events are assigned
| * Fix action state when multiple events are assignedkobewi2023-08-252-22/+37
| |
* | Context aware MIDI event printingalcomposer2023-08-281-1/+21
|/
* Ensure `joy_connection_changed` is emitted on the main threadRicardo Subtil2023-08-091-1/+2
|
* Add the ability to get per-platform information for joypads.Álex Román Núñez2023-08-022-2/+11
| | | | | | This adds the ability for games to obtain platform-specific information about joypads such as their vendor/product ID, their XInput gamepad index or the real name of the device before it gets swapped out by the gamecontrollerdb's name. This PR also includes a rebased version of #76045, this is because this PR is intended to be mainly to help people implementing Steam Input, as having the gamepad index is essential.
* Merge pull request #76045 from Eoin-ONeill-Yokai/steaminput-fixYuri Sizov2023-07-122-0/+31
|\ | | | | | | Prevent double input events on gamepad when running through steam input
| * Prevent double input events on gamepad when running through steam inputEoin O'Neill2023-07-102-0/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | During GDC and general testing on Steam Deck units, we found that single gamepads would often register inputs twice under certain circumstances. This was caused by SteamInput creating a new virtual device, which Godot registers as a second gamepad. This resulted in two gamepad devices reporting the same button presses, often leading to buggy input response on games with no multi-device logic and other-wise could cause intended Steam rebindings to not work as intended (for example, swapping o and x on a playstation pad if that feature isn't supported by the game.) SDL gets around this by taking in a list of devices that are to be ignored. When valve sees a controller that wants to be rebound via SteamInput, they push a new VID/PID entry onto the environment variable `SDL_GAMECONTROLLER_IGNORE_DEVICES` for the original gamepad so that all game inputs can be read from the virtual gamepad instead. This leverages the same logic as we are already using SDL gamepad related HID mappings.
* | Mention Xbox menu button by name in Start button descriptionHugo Locurcio2023-06-261-1/+1
|/ | | | | | Microsoft officially calls it the Menu button: https://support.xbox.com/en-US/help/hardware-network/controller/get-to-know-your-xbox-series-x-s-controller
* Fix various typos with codespellRémi Verschelde2023-06-161-1/+1
| | | | And ignore some false positives introduced by recent versions of codespell.
* Merge pull request #75438 from ronyeh/typoRémi Verschelde2023-06-151-2/+2
|\ | | | | | | Fix typo on "autoremapping".
| * Fix typo on "autoremapping".Ron B. Yeh2023-03-281-2/+2
| | | | | | | | Update warning strings to be consistent with the rest of the code base, which uses "Command or Control".
* | Merge pull request #77055 from lawnjelly/input_just_pressed_4Rémi Verschelde2023-06-122-29/+47
|\ \ | | | | | | | | | Input - fix just pressed and released with short presses
| * | Input - fix just pressed and released with short presseslawnjelly2023-06-122-29/+47
| | | | | | | | | | | | | | | | | | Previously if an action was both pressed and released on the same tick or frame, `is_action_just_pressed()` would return false, resulting in missed input. This PR separately the timestamp for pressing and releasing so each can be tested independently.
* | | Merge pull request #77748 from DevanOBoyle/fix/ignore_false_button_errorRémi Verschelde2023-06-121-2/+3
|\ \ \ | |/ / |/| | | | | Skip error messages for buttons that don't exist
| * | Skip error messages for buttons that don't existDevan OBoyle2023-06-111-2/+3
| | |
* | | Merge pull request #63168 from Levrault/masterRémi Verschelde2023-06-053-0/+15
|\ \ \ | |/ / |/| | | | | Fix: InputEventJoypadMotion should trigger only once on a vslider
| * | feat(gamepad): improve gamepad behavior with slider and popup_menuLuc-Frédéric Langis2023-06-053-0/+15
| | |
* | | Merge pull request #76719 from m4gr3d/add_input_event_cancelled_state_mainRémi Verschelde2023-05-173-62/+53
|\ \ \ | | | | | | | | | | | | Augment the `InputEvent` class with a `CANCELED` state
| * | | Augment the `InputEvent` class with a `CANCELED` stateFredia Huya-Kouadio2023-05-153-62/+53
| | | | | | | | | | | | | | | | | | | | | | | | The `InputEvent` class currently supports the `pressed` and `released` states, which given the binary nature, is represented by a `bool` field. This commit introduced the `CANCELED` state, which signals that an ongoing input event has been canceled. To represent all the states, the `InputEventState` enum is added and the `InputEvent` logic is refactored accordingly.
* | | | Follow up to https://github.com/godotengine/godot/pull/76399 to fix input ↵Fredia Huya-Kouadio2023-05-111-0/+1
| | | | | | | | | | | | | | | | ANR in the Godot Android editor
* | | | Fix various errors when running the unit testsRedworkDE2023-05-091-1/+4
|/ / / | | | | | | | | | Co-authored-by: bruvzg <7645683+bruvzg@users.noreply.github.com>
* / / Allow concurrent buffering and dispatch of input eventsPedro J. Estébanez2023-05-081-1/+24
|/ /
* | [Web] Detect host OS and use macOS keys on mac hosts.bruvzg2023-04-111-17/+18
| |
* | Merge pull request #73200 from 0xafbf/fix-guide-button-winRémi Verschelde2023-04-031-1/+1
|\ \ | |/ |/| | | Fix guide button detection with XInput and Xbox Series controllers
| * Added guide button to controller db, changed to use secret XInput function.Andrés Botero2023-02-151-1/+1
| |
* | Merge pull request #73651 from hakro/editor-freelook-physical-shortcutsRémi Verschelde2023-03-032-3/+8
|\ \ | | | | | | | | | Use physical shortcuts for freelook navigation in the editor
| * | Use physical shortcuts for freelook navigation in the editorHakim2023-02-212-3/+8
| | |
* | | Sync controller mappings DB with SDL2 community repoRémi Verschelde2023-02-271-17/+31
|/ / | | | | | | Synced with gabomdq/SDL_GameControllerDB@436c7e3d54a57189ea0ab44d05f36b7cc7ea496c
* | [macOS] Replace all `Alt/Option+Letter/Number` default shortcuts to avoid ↵bruvzg2023-02-201-0/+4
| | | | | | | | conflicts with special character input.
* | Revert `Input.get_vector()` back to checking raw strengthMichael Alexsander2023-02-191-2/+2
| |
* | Merge pull request #73254 from j8r/fix-standard-gamepad-triggersRémi Verschelde2023-02-191-1/+1
|\ \ | | | | | | | | | Fix Standard Gamepad Mapping triggers
| * | Fix Standard Gamepad Mapping triggersJulien Reichardt2023-02-131-1/+1
| | |
* | | Merge pull request #73195 from timothyqiu/weblate-commentsRémi Verschelde2023-02-171-1/+1
|\ \ \ | |/ / |/| | | | | Improvements and fixes based on Weblate comments