Module prelude

Source
Expand description

Common imports

Re-exports§

pub use crate::debug::DebugPickingMode;
pub use crate::debug::DebugPickingPlugin;
pub use crate::backends;
pub use crate::*;

Structs§

AvianBackend
Adds the avian3d raycasting picking backend to your app.
AvianBackendSettings
Runtime settings for the AvianBackend.
AvianPickable
Optional. Marks cameras and target entities that should be used in the avian picking backend. Only needed if AvianBackendSettings::require_markers is set to true.
BevyUiBackend
Adds picking support for bevy_ui.
Click
Fires when a pointer sends a pointer down event followed by a pointer up event, with the same target entity for both events.
DefaultHighlightingPlugin
Adds the StandardMaterial and ColorMaterial highlighting plugins.
Deselect
Fires when an entity has been deselected
Down
Fires when a pointer button is pressed over the target entity.
Drag
Fires while the target entity is being dragged.
DragEnd
Fires when a pointer is dragging the target entity and a pointer up event is received.
DragEnter
Fires when a pointer dragging the dragged entity enters the target entity.
DragLeave
Fires when a pointer dragging the dragged entity leaves the target entity.
DragOver
Fires while the dragged entity is being dragged over the target entity.
DragStart
Fires when the target entity receives a pointer down event followed by a pointer move event.
Drop
Fires when a pointer drops the dropped entity onto the target entity.
EguiBackend
Adds picking support for bevy_egui, by ensuring that egui blocks other entities from being picked.
EventListenerPlugin
Adds event listening and bubbling support for event E.
GlobalHighlight
Resource that defines the global default highlighting assets to use. This can be overridden per-entity with the Highlight component.
Highlight
Overrides the global highlighting material for an entity. See PickHighlight.
HighlightPlugin
A highlighting plugin, generic over any asset that might be used for rendering the different highlighting states.
HighlightPluginSettings
A resource used to enable or disable picking highlighting.
InputPlugin
Adds mouse and touch inputs for picking pointers to your app. This is a default input plugin, that you can replace with your own plugin as needed.
InputPluginSettings
A resource used to enable and disable features of the InputPlugin.
ListenerInput
Data from an event that triggered an On<Event> listener, and is currently bubbling through the entity hierarchy.
Move
Fires while a pointer is moving over the target entity.
NoDeselect
Marker struct used to mark pickable entities for which you don’t want to trigger a deselection event when picked. This is useful for gizmos or other pickable UI entities.
On
An event listener with a callback that is triggered when an EntityEvent bubbles past or targets this entity.
Out
Fires when a the pointer crosses out of the bounds of the target entity.
Over
Fires when a the pointer crosses into the bounds of the target entity.
PickHighlight
Makes an entity highlightable with any Asset. See DefaultHighlightingPlugin for details.
PickSelection
Tracks the current selection state of the entity.
Pickable
An optional component that overrides default picking behavior for an entity, allowing you to make an entity non-hoverable, or allow items below it to be hovered. See the documentation on the fields for more details.
Pointer
Stores the common data needed for all PointerEvents.
PointerInteraction
Holds a list of entities this pointer is currently interacting with, sorted from nearest to farthest.
PointerLocation
Component that tracks a pointer’s current Location.
PointerMap
A resource that maps each PointerId to their Entity for easy lookups.
PointerMultiselect
A component for pointers that defines whether or not the multiselect button is active. This is often the Ctrl or Shift keys.
PointerPress
Tracks the state of the pointer’s buttons in response to InputPresss.
RapierBackend
Adds the rapier raycasting picking backend to your app.
RapierBackendSettings
Runtime settings for the RapierBackend.
RapierPickable
Optional. Marks cameras and target entities that should be used in the rapier picking backend. Only needed if RapierBackendSettings::require_markers is set to true.
RaycastBackend
Adds the raycasting picking backend to your app.
Select
Fires when an entity has been selected
SelectionPlugin
Adds multiselect picking support to your app.
SpriteBackend
Adds picking support for bevy_sprite.
Up
Fires when a pointer button is released over the target entity.
XpbdBackend
Adds the xpbd_3d raycasting picking backend to your app.
XpbdBackendSettings
Runtime settings for the XpbdBackend.
XpbdPickable
Optional. Marks cameras and target entities that should be used in the xpbd picking backend. Only needed if XpbdBackendSettings::require_markers is set to true.

Enums§

HighlightKind
Used to override each highlighting state in Highlight.
PickingInteraction
A component that aggregates picking interaction state of this entity across all pointers.
PointerButton
The button that was just pressed or released
PointerId
Identifies a unique pointer entity. Mouse and Touch pointers are automatically spawned.

Traits§

EntityEvent
An event that targets a specific entity, and should support event listeners and bubbling.

Type Aliases§

Listener
A SystemParam used to get immutable access the the ListenerInput for this callback.
ListenerMut
A SystemParam used to get mutable access the the ListenerInput for this callback.

Derive Macros§

EntityEvent