From 42032669238bdc807bc7b8f03fff87e6cb5847f1 Mon Sep 17 00:00:00 2001 From: Juan Linietsky Date: Sun, 14 Apr 2019 16:43:38 -0300 Subject: Add support for FPS snap in Animation Editor. --- editor/plugins/animation_player_editor_plugin.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'editor/plugins') diff --git a/editor/plugins/animation_player_editor_plugin.cpp b/editor/plugins/animation_player_editor_plugin.cpp index bbaf41e3cc..41f35c3bed 100644 --- a/editor/plugins/animation_player_editor_plugin.cpp +++ b/editor/plugins/animation_player_editor_plugin.cpp @@ -670,6 +670,7 @@ Dictionary AnimationPlayerEditor::get_state() const { if (EditorNode::get_singleton()->get_edited_scene() && is_visible_in_tree() && player) { d["player"] = EditorNode::get_singleton()->get_edited_scene()->get_path_to(player); d["animation"] = player->get_assigned_animation(); + d["track_editor_state"] = track_editor->get_state(); } return d; @@ -696,6 +697,10 @@ void AnimationPlayerEditor::set_state(const Dictionary &p_state) { _animation_edit(); } } + + if (p_state.has("track_editor_state")) { + track_editor->set_state(p_state["track_editor_state"]); + } } } -- cgit v1.2.3