update path

This commit is contained in:
Jim 2025-08-24 14:57:37 -04:00
parent 5c923dcf9a
commit 1a65fad218
Signed by: jim
GPG key ID: 3236D2F059A7C0AC

View file

@ -133,11 +133,11 @@ fn pan(
camera.target += (vx + vy) * pan_speed;
}
const INPUT_MAP_PATH: &'static str = "assets/settings/camera.ron";
const SETTINGS_PATH: &'static str = "assets/settings/camera.ron";
fn save(settings: Res<CameraSettings>) {
if settings.is_changed() {
if let Err(e) = settings.save_to_file(INPUT_MAP_PATH) {
if let Err(e) = settings.save_to_file(SETTINGS_PATH) {
error!("Failed to save camera settings: {}", e);
} else {
info!("Camera settings saved successfully");
@ -146,7 +146,7 @@ fn save(settings: Res<CameraSettings>) {
}
fn setup(mut commands: Commands) {
let settings = match CameraSettings::load_from_file(INPUT_MAP_PATH) {
let settings = match CameraSettings::load_from_file(SETTINGS_PATH) {
Ok(settings) => {
info!("Loaded camera settings");
settings