From 1f950de22ebb7c25b23e3dbf0a265f0078f00f54 Mon Sep 17 00:00:00 2001 From: Azumgi <4zumgi@gmail.com> Date: Tue, 1 Jan 2019 08:42:51 +0300 Subject: [PATCH] [VMF Options View] Fix clamping decimal numbers Numeric widget no longer removes 0 at the end of decimal part. --- vmf/scripts/mods/vmf/modules/ui/options/vmf_options_view.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/vmf/scripts/mods/vmf/modules/ui/options/vmf_options_view.lua b/vmf/scripts/mods/vmf/modules/ui/options/vmf_options_view.lua index b33c4f5..d182d6a 100644 --- a/vmf/scripts/mods/vmf/modules/ui/options/vmf_options_view.lua +++ b/vmf/scripts/mods/vmf/modules/ui/options/vmf_options_view.lua @@ -3594,7 +3594,8 @@ VMFOptionsView.callback_draw_numeric_menu = function (self, widget_content) -- Lua, pls! Sometimes "tostring" returns something like "1337.5999999999999" instead of "1337.6", -- so I have to convert number to string this way - new_value = new_value_number .. "" + -- UPD(bi) 01.01.19 I commented out following string. Rething this whole block later. Seems like it can be just removed. + -- new_value = new_value_number .. "" end else -- if entered string is not convertable, change its color to red