diff options
author | Micky <micheledevita2@gmail.com> | 2022-11-20 12:29:50 +0100 |
---|---|---|
committer | Micky <micheledevita2@gmail.com> | 2022-11-20 12:29:50 +0100 |
commit | e791f4fce275247a66eb657ff7cc7be4ffd4d5bc (patch) | |
tree | 00b1015cdb150ca4277c47f665a630cbb73c0ca9 /editor | |
parent | 8aafcf9d2ae43e83636d60dbfd5f10e50fcdb324 (diff) |
Double precision of `String.split_floats`
Diffstat (limited to 'editor')
-rw-r--r-- | editor/editor_help.cpp | 2 | ||||
-rw-r--r-- | editor/plugins/script_text_editor.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/editor/editor_help.cpp b/editor/editor_help.cpp index 0a443ee645..636e076b1e 100644 --- a/editor/editor_help.cpp +++ b/editor/editor_help.cpp @@ -1363,7 +1363,7 @@ void EditorHelp::_update_doc() { if (constants[i].value.begins_with("Color(") && constants[i].value.ends_with(")")) { String stripped = constants[i].value.replace(" ", "").replace("Color(", "").replace(")", ""); - Vector<float> color = stripped.split_floats(","); + PackedFloat64Array color = stripped.split_floats(","); if (color.size() >= 3) { class_desc->push_color(Color(color[0], color[1], color[2])); _add_bulletpoint(); diff --git a/editor/plugins/script_text_editor.cpp b/editor/plugins/script_text_editor.cpp index 0d12d07aa7..4e66dc3d7e 100644 --- a/editor/plugins/script_text_editor.cpp +++ b/editor/plugins/script_text_editor.cpp @@ -1860,7 +1860,7 @@ void ScriptTextEditor::_text_edit_gui_input(const Ref<InputEvent> &ev) { if (valid) { color_args = line.substr(begin, end - begin); String stripped = color_args.replace(" ", "").replace("(", "").replace(")", ""); - Vector<float> color = stripped.split_floats(","); + PackedFloat64Array color = stripped.split_floats(","); if (color.size() > 2) { float alpha = color.size() > 3 ? color[3] : 1.0f; color_picker->set_pick_color(Color(color[0], color[1], color[2], alpha)); |