Skip to content

Commit

Permalink
Fix action diffing (#580)
Browse files Browse the repository at this point in the history
* Unignore failing tests

* Move SummarizedActionState into action_diff.rs

* Tiny release note

* Add set_value and set_axis_pair helper methods

* Add tests for SummarizedActionState

* Use new methods internally

* Add test for sending diffs

* Cleanup generate_axis_action_diffs test

* Add more logging to test

* Missing buttons should not be pressed or just_pressed

* Make naming less whimsical

* Simplify test setup

* Properly differentiate between different input kinds in the tests

* Update release notes

* Add an axis variant for test

* More logging for axis test

* More debugging fanciness

* Don't send empty action diff events

* Add docs to when to use generate_action_diff

* Fix synthetic press logic for action_diff tests

* Clippy

* Fix doc link

* Fix doc links
  • Loading branch information
alice-i-cecile authored Aug 8, 2024
1 parent 4504cb0 commit d75d830
Show file tree
Hide file tree
Showing 5 changed files with 507 additions and 352 deletions.
2 changes: 2 additions & 0 deletions RELEASES.md
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,8 @@ Input processors allow you to create custom logic for axis-like input manipulati
- `DualAxisData` has been removed, and replaced with a simple `Vec2` throughout
- a new type with the `DualAxisData` name has been added, as a parallel to `ButtonData` and `AxisData`
- when no `associated_gamepad` is provided to an input map, `find_gamepad` will be called to attempt to search for a gamepad. Input from *any* gamepad will no longer work
- `SummarizedActionState` is now found in the `action_diff` module
- Axislike and DualAxislike inputs no longer send pressed / released `ActionDiff`s: only `AxisChanged` and `DualAxisChanged` events

## Version 0.14.0

Expand Down
Loading

0 comments on commit d75d830

Please sign in to comment.