generated from tipragot/rust
Add a camera system #69
No reviewers
Labels
No labels
Kind/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Fix
Kind/Security
Kind/Testing
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: fish-cannard/border-wars#69
Loading…
Reference in a new issue
No description provided.
Delete branch "camera"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
closes: #63
@ -0,0 +7,4 @@
use crate::CurrentScene;
/// The speed of camera movement.
const CAMERA_SPEED_MOVEMENT: f32 = 10.;
This should be a resource and the others too
@ -0,0 +56,4 @@
commands.spawn(Camera2dBundle::default());
}
/// Initializes the key movement settings for the camera.
Not only...
@ -0,0 +94,4 @@
}
}
/// Scales the camera with mouse input.
The view not the camera
@ -0,0 +96,4 @@
/// Scales the camera with mouse input.
fn scale_system(
mut scroll_ev: EventReader<MouseWheel>,
Don't use abreviations: https://youtu.be/-J3wNP6u5YU
@ -0,0 +16,4 @@
/// The minimum scale of the camera.
#[derive(Resource)]
struct MinScale(f32);
No abreviations