diff options
author | Silc 'Tokage' Renew <tokage.it.lab@gmail.com> | 2022-01-27 11:52:39 +0900 |
---|---|---|
committer | Silc 'Tokage' Renew <tokage.it.lab@gmail.com> | 2022-01-27 12:42:46 +0900 |
commit | 1c0b163df5b49352391b9f797093d71e3da1dc23 (patch) | |
tree | 7d1e1a6c9179e1407c89ffb665786b5385e9af4b /editor | |
parent | 9df9dc77a396bcdfe362365e9511de80c1e94fc0 (diff) |
More time parameters change type float to double
Diffstat (limited to 'editor')
-rw-r--r-- | editor/plugins/animation_state_machine_editor.cpp | 6 | ||||
-rw-r--r-- | editor/plugins/animation_state_machine_editor.h | 8 |
2 files changed, 7 insertions, 7 deletions
diff --git a/editor/plugins/animation_state_machine_editor.cpp b/editor/plugins/animation_state_machine_editor.cpp index 94990636da..26ce6de0df 100644 --- a/editor/plugins/animation_state_machine_editor.cpp +++ b/editor/plugins/animation_state_machine_editor.cpp @@ -854,10 +854,10 @@ void AnimationNodeStateMachineEditor::_state_machine_pos_draw() { } to.y = from.y; - float len = MAX(0.0001, current_length); + double len = MAX(0.0001, current_length); - float pos = CLAMP(play_pos, 0, len); - float c = pos / len; + double pos = CLAMP(play_pos, 0, len); + double c = pos / len; Color fg = get_theme_color(SNAME("font_color"), SNAME("Label")); Color bg = fg; bg.a *= 0.3; diff --git a/editor/plugins/animation_state_machine_editor.h b/editor/plugins/animation_state_machine_editor.h index 8970e3e062..d948e05472 100644 --- a/editor/plugins/animation_state_machine_editor.h +++ b/editor/plugins/animation_state_machine_editor.h @@ -159,11 +159,11 @@ class AnimationNodeStateMachineEditor : public AnimationTreeNodeEditorPlugin { StringName last_blend_from_node; StringName last_current_node; Vector<StringName> last_travel_path; - float last_play_pos; - float play_pos; - float current_length; + double last_play_pos; + double play_pos; + double current_length; - float error_time; + double error_time; String error_text; EditorFileDialog *open_file; |