From 719610ccebc023a4b21b5b8c716e73c2fe563c6d Mon Sep 17 00:00:00 2001 From: hop311 Date: Wed, 8 May 2024 00:27:20 +0100 Subject: Updated number formatting functions --- extension/src/openvic-extension/utility/Utilities.hpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'extension/src/openvic-extension/utility/Utilities.hpp') diff --git a/extension/src/openvic-extension/utility/Utilities.hpp b/extension/src/openvic-extension/utility/Utilities.hpp index 15ff6b6..0cd9edc 100644 --- a/extension/src/openvic-extension/utility/Utilities.hpp +++ b/extension/src/openvic-extension/utility/Utilities.hpp @@ -33,9 +33,11 @@ namespace OpenVic::Utilities { return std_to_godot_string_name(static_cast(str)); } - godot::String int_to_formatted_string(int64_t val); + godot::String int_to_string_suffixed(int64_t val); - godot::String float_to_formatted_string(float val, int32_t decimal_places); + godot::String float_to_string_suffixed(float val); + + godot::String float_to_string_dp(float val, int32_t decimal_places); constexpr real_t to_real_t(std::floating_point auto val) { return static_cast(val); @@ -83,4 +85,4 @@ namespace OpenVic::Utilities { namespace literals { constexpr real_t operator""_real(long double val) { return to_real_t(val); } } -} \ No newline at end of file +} -- cgit v1.2.3-56-ga3b1