Skip to content

Commit

Permalink
fix sprite deps
Browse files Browse the repository at this point in the history
  • Loading branch information
aevyrie committed May 3, 2023
1 parent 85431d6 commit c3c1b8c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ highlight = ["bevy_picking_highlight"]
debug = ["bevy/bevy_text", "bevy/bevy_sprite"]
backend_raycast = ["bevy_picking_raycast"]
backend_rapier = ["bevy_picking_rapier", "bevy_rapier3d"]
backend_sprite = ["bevy_picking_sprite"]
backend_sprite = ["bevy_picking_sprite", "bevy_picking_highlight/sprite"]
backend_bevy_ui = ["bevy_picking_ui"]
backend_egui = ["bevy_picking_egui", "bevy_egui"]

Expand Down
1 change: 1 addition & 0 deletions crates/bevy_picking_highlight/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,4 @@ bevy = { version = "0.10", default-features = false, features = [

[features]
selection = ["bevy_picking_selection"]
sprite = ["bevy/bevy_sprite"]
1 change: 1 addition & 0 deletions crates/bevy_picking_highlight/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ impl Plugin for DefaultHighlightingPlugin {
},
});

#[cfg(feature = "sprite")]
app.add_plugin(HighlightPlugin::<bevy::sprite::ColorMaterial> {
highlighting_default: |mut assets| GlobalHighlight {
hovered: assets.add(Color::rgb(0.35, 0.35, 0.35).into()),
Expand Down

0 comments on commit c3c1b8c

Please sign in to comment.