From b1b2ed5f348bb02f25d84dc691d1116547b2fb38 Mon Sep 17 00:00:00 2001 From: yuni Date: Sun, 22 Sep 2024 06:42:56 +0200 Subject: [PATCH] better suit modding descriptions --- src/actor.rs | 2 +- src/menu.rs | 10 ++++------ 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/src/actor.rs b/src/actor.rs index a7bcc44..f5fcde8 100644 --- a/src/actor.rs +++ b/src/actor.rs @@ -25,7 +25,7 @@ pub const POWER_DRAIN_THRUSTER: [f32; 3] = [3e6, 3e6, 0.0]; pub const THRUSTER_BOOST_FACTOR: [f64; 3] = [3.0, 3.0, 0.0]; pub const POWER_DRAIN_FLASHLIGHT: [f32; 4] = [200e3, 1500e3, 2500e3, 10000e3]; pub const FLASHLIGHT_INTENSITY: [f32; 4] = [10e6, 400e6, 2e9, 100e9]; // in lumens -pub const POWER_DRAIN_LIGHTAMP: [f32; 4] = [0.0, 200e3, 400e3, 800e3]; +pub const POWER_DRAIN_LIGHTAMP: [f32; 4] = [0.0, 200e3, 400e3, 1400e3]; pub const POWER_DRAIN_AR: f32 = 300e3; pub const POWER_GAIN_REACTOR: [f32; 3] = [0.0, 2000e3, 10000e3]; diff --git a/src/menu.rs b/src/menu.rs index 26abeb8..4c91c3c 100644 --- a/src/menu.rs +++ b/src/menu.rs @@ -493,10 +493,8 @@ pub fn update_menu( text.sections[i].value = format!("Augmented Reality: {onoff}{kw} [TAB]\n"); } MenuAction::ModLightAmp => { - let n = prefs.light_amp; let p = actor::POWER_DRAIN_LIGHTAMP[prefs.light_amp] / 1e3; - let kw = if p > 0.0 { format!(" ({p}kW)") } else { String::from("") }; - text.sections[i].value = format!("Light Amplification: {n}/3{kw}\n"); + text.sections[i].value = format!("Light Amplification: {p}kW\n"); } MenuAction::ModFlashlightPower => { let p = actor::POWER_DRAIN_FLASHLIGHT[prefs.flashlight_power] / 1e3; @@ -504,7 +502,7 @@ pub fn update_menu( } MenuAction::ModThrusterBoost => { let state = match prefs.thruster_boost { - 0 => "Only when slowing down", + 0 => "For braking", 1 => "Always", 2 => "Off", _ => "ERROR", @@ -516,8 +514,8 @@ pub fn update_menu( MenuAction::ModReactor => { let state = match settings.reactor_state { 0 => "Off", - 1 => "Slow burn", - 2 => "Overload", + 1 => "On", + 2 => "OVERLOAD", _ => "ERROR", }; let p = actor::POWER_GAIN_REACTOR[settings.reactor_state] / 1e3;