bevy/crates
Doug Roeper c859eacdc8
Fix bug where events are not being dropped (#11528)
# Objective

Fix an issue where events are not being dropped after being read. I
believe #10077 introduced this issue. The code currently works as
follows:

1. `EventUpdateSignal` is **shared for all event types**
2. During the fixed update phase, `EventUpdateSignal` is set to true
3. `event_update_system`, **unique per event type**, runs to update
Events<T>
4. `event_update_system` reads value of `EventUpdateSignal` to check if
it should update, and then **resets** the value to false

If there are multiple event types, the first `event_update_system` run
will reset the shared `EventUpdateSignal` signal, preventing other
events from being cleared.

## Solution

I've updated the code to have separate signals per event type and added
a shared signal to notify all systems that the time plugin is installed.

## Changelog

- Fixed bug where events were not being dropped
2024-02-02 21:14:54 +00:00
..
bevy_a11y resolve all internal ambiguities (#10411) 2024-01-09 19:08:15 +00:00
bevy_animation Replace the cubic_spline_interpolation macro with a generic function (#11605) 2024-01-29 19:50:30 +00:00
bevy_app Fix bug where events are not being dropped (#11528) 2024-02-02 21:14:54 +00:00
bevy_asset Fix AssetTransformer breaking LabeledAssets (#11626) 2024-02-02 14:57:31 +00:00
bevy_audio Optional override for global spatial scale (#10419) 2024-01-25 16:29:35 +00:00
bevy_core Adding derive Reflect for tick structs (#11641) 2024-02-01 16:11:32 +00:00
bevy_core_pipeline RenderGraph Labelization (#10644) 2024-01-31 14:51:19 +00:00
bevy_derive Reexport winit::platform::android::activity::* in bevy_winit (#11011) 2023-12-19 20:15:03 +00:00
bevy_diagnostic Replace DiagnosticId by DiagnosticPath (#9266) 2024-01-20 15:42:51 +00:00
bevy_dylib Add [lints] table, fix adding #![allow(clippy::type_complexity)] everywhere (#10011) 2023-11-18 20:58:48 +00:00
bevy_dynamic_plugin Mark DynamicPluginLoadError internal error types as source (#11618) 2024-01-30 23:37:00 +00:00
bevy_ecs Fix bug where events are not being dropped (#11528) 2024-02-02 21:14:54 +00:00
bevy_ecs_compile_fail_tests Dynamic queries and builder API (#9774) 2024-01-16 19:16:49 +00:00
bevy_encase_derive Add [lints] table, fix adding #![allow(clippy::type_complexity)] everywhere (#10011) 2023-11-18 20:58:48 +00:00
bevy_gilrs Remove unnecessary path prefixes (#10749) 2023-11-28 23:43:40 +00:00
bevy_gizmos Drawing Primitives with Gizmos (#11072) 2024-02-02 21:13:03 +00:00
bevy_gltf RenderAssetPersistencePolicy → RenderAssetUsages (#11399) 2024-01-30 13:22:10 +00:00
bevy_hierarchy Make the MapEntities trait generic over Mappers, and add a simpler EntityMapper (#11428) 2024-01-28 19:51:46 +00:00
bevy_input Fix cyclic dep (#11523) 2024-01-25 17:44:32 +00:00
bevy_internal Add Accessibility plugin to default plugins docs (#11512) 2024-01-28 10:04:43 +00:00
bevy_log move once from bevy_log to bevy_utils, to allow for it's use in bevy_ecs (#11419) 2024-01-19 06:07:41 +00:00
bevy_macro_utils Bump toml_edit in build-template-pages tool (#11342) 2024-01-16 05:23:18 +00:00
bevy_macros_compile_fail_tests Standardize toml format with taplo (#10594) 2023-11-21 01:04:14 +00:00
bevy_math Drawing Primitives with Gizmos (#11072) 2024-02-02 21:13:03 +00:00
bevy_mikktspace Enable the unsafe_op_in_unsafe_fn lint (#11591) 2024-01-28 23:18:11 +00:00
bevy_pbr Gate diffuse and specular transmission behind shader defs (#11627) 2024-02-02 15:01:56 +00:00
bevy_ptr bevy_ptr: fix unsafe_op_in_unsafe_fn lint (#11610) 2024-01-30 23:37:29 +00:00
bevy_reflect Add the ability to manually create ParsedPaths (+ cleanup) (#11029) 2024-02-01 19:22:40 +00:00
bevy_reflect_compile_fail_tests bevy_reflect: Type parameter bounds (#9046) 2024-01-28 16:24:03 +00:00
bevy_render RenderGraph Labelization (#10644) 2024-01-31 14:51:19 +00:00
bevy_scene Make the MapEntities trait generic over Mappers, and add a simpler EntityMapper (#11428) 2024-01-28 19:51:46 +00:00
bevy_sprite RenderAssetPersistencePolicy → RenderAssetUsages (#11399) 2024-01-30 13:22:10 +00:00
bevy_tasks Fix wrong transmuted type in TaskPool::scope_with_executor_inner (#11455) 2024-01-21 18:08:45 +00:00
bevy_text Subtract 1 from text positions to account for glyph texture padding. (#11662) 2024-02-02 20:01:01 +00:00
bevy_time Fix bug where events are not being dropped (#11528) 2024-02-02 21:14:54 +00:00
bevy_transform return Direction3d from Transform::up and friends (#11604) 2024-02-02 15:05:35 +00:00
bevy_ui RenderGraph Labelization (#10644) 2024-01-31 14:51:19 +00:00
bevy_utils impl Borrow and AsRef for CowArc (#11616) 2024-01-30 14:27:53 +00:00
bevy_window Update cursor.rs (#11617) 2024-01-30 16:34:17 +00:00
bevy_winit Cleanup bevy winit (#11489) 2024-01-28 21:09:23 +00:00