[MIRROR] Fixes sensor console (and other overmap consoles) not accepting decimal input when appropriate (#7878)

Co-authored-by: Runa Dacino <dacinoorder@gmail.com>
Co-authored-by: CHOMPStation2 <chompsation2@gmail.com>
This commit is contained in:
CHOMPStation2
2024-03-03 13:58:31 +01:00
committed by GitHub
co-authored by Runa Dacino CHOMPStation2
parent b51b9e0e45
commit 6f4e40c7be
3 changed files with 6 additions and 6 deletions
@@ -62,7 +62,7 @@
. = TRUE
if("set_global_limit")
var/newlim = tgui_input_number(usr, "Input new thrust limit (0..100%)", "Thrust limit", linked.thrust_limit*100, 100, 0)
var/newlim = tgui_input_number(usr, "Input new thrust limit (0..100%)", "Thrust limit", linked.thrust_limit*100, 100, 0, round_value = FALSE)
if(tgui_status(usr, state) != STATUS_INTERACTIVE)
return FALSE
linked.thrust_limit = clamp(newlim/100, 0, 1)
@@ -78,7 +78,7 @@
if("set_limit")
var/datum/ship_engine/E = locate(params["engine"])
var/newlim = tgui_input_number(usr, "Input new thrust limit (0..100)", "Thrust limit", E.get_thrust_limit(), 100, 0)
var/newlim = tgui_input_number(usr, "Input new thrust limit (0..100)", "Thrust limit", E.get_thrust_limit(), 100, 0, round_value = FALSE)
if(tgui_status(usr, state) != STATUS_INTERACTIVE)
return FALSE
var/limit = clamp(newlim/100, 0, 1)
@@ -100,4 +100,4 @@
. = TRUE
if(. && !issilicon(usr))
playsound(src, "terminal_type", 50, 1)
playsound(src, "terminal_type", 50, 1)