Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
tim-blackbird committed Jan 5, 2024
1 parent 4b91e8a commit 5f419c3
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 14 deletions.
11 changes: 2 additions & 9 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,11 @@ license = "MIT OR Apache-2.0"
repository = "https://github.com/irate-devil/irate_transform_gizmo"
documentation = "https://docs.rs/irate_transform_gizmo"

[profile.dev.package."*"]
opt-level = 3

[profile.dev]
opt-level = 1

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
#TODO: Allow disabling bevy_pbr when working with 2D only

[dependencies]
bevy = { version = "0.12", default-features = false, features = [
"bevy_pbr",
"bevy_sprite",
"bevy_pbr"
] }
bevy_mod_picking = { version = "0.17", default-features = false, features = [
"selection",
Expand Down
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,11 @@ Or read [the demo code](/examples/demo.rs) for an example.
* Gizmo always renders on top of the main render pass
* Gizmo is always the same size at it moves closer/further from the camera

# Differences from bevy_transform_gizmo

* Rotating with multiple items selected rotates the objects around the midpoint rather than their individual origins.
* Basic 2D support. Currently uses the same gizmo as 3D but a 2D specific gizmo is coming.

# Usage

This plugin is built on and relies on [`bevy_mod_picking`](https://github.com/aevyrie/bevy_mod_picking) for mouse interaction with the scene.
Expand Down
6 changes: 1 addition & 5 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,13 @@ pub use normalization::Ui3dNormalization;

#[derive(Debug, Hash, PartialEq, Eq, Clone, SystemSet)]
pub enum TransformGizmoSystem {
InputsSet,
MainSet,
RaycastSet,
NormalizeSet,
UpdateSettings,
AdjustViewTranslateGizmo,
Place,
Hover,
Grab,
Drag,
RaycastSet,
}

#[derive(Debug, Clone, Event)]
Expand Down Expand Up @@ -105,7 +102,6 @@ impl Plugin for TransformGizmoPlugin {
PreUpdate,
update_gizmo_settings
.in_set(TransformGizmoSystem::UpdateSettings)
.in_set(TransformGizmoSystem::InputsSet)
.run_if(|settings: Res<TransformGizmoSettings>| settings.enabled),
);

Expand Down

0 comments on commit 5f419c3

Please sign in to comment.