diff options
author | Juan Linietsky <reduzio@gmail.com> | 2018-06-21 18:08:11 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2018-06-21 18:08:11 -0300 |
commit | b80946ee0dbb7c28021c55d2623a35e89fc972f4 (patch) | |
tree | aae498f78f1fc7df6f05869ac2b92cf8aea92478 /scene/animation | |
parent | a0719533bdc4e99a24bd02886fc77a29d5d30dfc (diff) | |
download | redot-engine-b80946ee0dbb7c28021c55d2623a35e89fc972f4.tar.gz |
Fix crashes, ability to add blendpsace into blendtree, ability to delete with delete key
Diffstat (limited to 'scene/animation')
-rw-r--r-- | scene/animation/animation_graph_player.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/scene/animation/animation_graph_player.cpp b/scene/animation/animation_graph_player.cpp index ea41a20114..b8efecebe9 100644 --- a/scene/animation/animation_graph_player.cpp +++ b/scene/animation/animation_graph_player.cpp @@ -318,6 +318,9 @@ Vector2 AnimationNode::get_position() const { void AnimationNode::set_graph_player(AnimationGraphPlayer *p_player) { + if (player != NULL && p_player == NULL) { + emit_signal("removed_from_graph"); + } player = p_player; } @@ -377,6 +380,7 @@ void AnimationNode::_bind_methods() { BIND_VMETHOD(MethodInfo("process", PropertyInfo(Variant::REAL, "time"), PropertyInfo(Variant::BOOL, "seek"))); + ADD_SIGNAL(MethodInfo("removed_from_graph")); BIND_ENUM_CONSTANT(FILTER_IGNORE); BIND_ENUM_CONSTANT(FILTER_PASS); BIND_ENUM_CONSTANT(FILTER_STOP); |