diff options
author | Silc Renew <tokage.it.lab@gmail.com> | 2022-07-28 17:31:23 +0900 |
---|---|---|
committer | Silc Renew <tokage.it.lab@gmail.com> | 2022-08-18 08:17:30 +0900 |
commit | 2c2e1a7736196caf6b1103901e12622c5181ccab (patch) | |
tree | a783c40984964d6e86715113ae267753c74df8f6 /scene/animation/animation_node_state_machine.h | |
parent | dbd15243621ec595742b18abc4c26f3cb2e00f3d (diff) |
added Curve in animation node transition for better control over cros…
Co-authored-by: jeronimo-schreyer <jeronimo.schreyer@gmail.com>
Diffstat (limited to 'scene/animation/animation_node_state_machine.h')
-rw-r--r-- | scene/animation/animation_node_state_machine.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/scene/animation/animation_node_state_machine.h b/scene/animation/animation_node_state_machine.h index ead914db7a..ab78b1afe8 100644 --- a/scene/animation/animation_node_state_machine.h +++ b/scene/animation/animation_node_state_machine.h @@ -49,7 +49,8 @@ private: bool auto_advance = false; StringName advance_condition; StringName advance_condition_name; - float xfade = 0.0; + float xfade_time = 0.0; + Ref<Curve> xfade_curve; bool disabled = false; int priority = 1; String advance_expression; @@ -82,6 +83,9 @@ public: void set_xfade_time(float p_xfade); float get_xfade_time() const; + void set_xfade_curve(const Ref<Curve> &p_curve); + Ref<Curve> get_xfade_curve() const; + void set_disabled(bool p_disabled); bool is_disabled() const; @@ -117,6 +121,7 @@ class AnimationNodeStateMachinePlayback : public Resource { StringName current; Transition current_transition; + Ref<Curve> current_curve; bool force_auto_advance = false; StringName fading_from; |