diff options
author | Silc Renew <tokage.it.lab@gmail.com> | 2023-01-31 02:12:31 +0900 |
---|---|---|
committer | Silc Renew <tokage.it.lab@gmail.com> | 2023-01-31 02:14:55 +0900 |
commit | a0c4f849e0abdbdb656c5e0e86c226ace3588555 (patch) | |
tree | 4193d3fd8f1348156050e248a3207c88e050f806 /scene/animation/animation_blend_space_1d.h | |
parent | 551f5191e5dbc1d1a43f99b13d5dbbf7f598dc58 (diff) |
Consistent with NodeBlendSpace1D option NodeBlendSpace2D
Co-authored-by: Skrapion <rick@firefang.com>
Diffstat (limited to 'scene/animation/animation_blend_space_1d.h')
-rw-r--r-- | scene/animation/animation_blend_space_1d.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/scene/animation/animation_blend_space_1d.h b/scene/animation/animation_blend_space_1d.h index af93783c0d..a1e9a7a764 100644 --- a/scene/animation/animation_blend_space_1d.h +++ b/scene/animation/animation_blend_space_1d.h @@ -36,6 +36,14 @@ class AnimationNodeBlendSpace1D : public AnimationRootNode { GDCLASS(AnimationNodeBlendSpace1D, AnimationRootNode); +public: + enum BlendMode { + BLEND_MODE_INTERPOLATED, + BLEND_MODE_DISCRETE, + BLEND_MODE_DISCRETE_CARRY, + }; + +protected: enum { MAX_BLEND_POINTS = 64 }; @@ -61,6 +69,10 @@ class AnimationNodeBlendSpace1D : public AnimationRootNode { void _tree_changed(); StringName blend_position = "blend_position"; + StringName closest = "closest"; + StringName length_internal = "length_internal"; + + BlendMode blend_mode = BLEND_MODE_INTERPOLATED; protected: bool sync = false; @@ -95,6 +107,9 @@ public: void set_value_label(const String &p_label); String get_value_label() const; + void set_blend_mode(BlendMode p_blend_mode); + BlendMode get_blend_mode() const; + void set_use_sync(bool p_sync); bool is_using_sync() const; @@ -107,4 +122,6 @@ public: ~AnimationNodeBlendSpace1D(); }; +VARIANT_ENUM_CAST(AnimationNodeBlendSpace1D::BlendMode) + #endif // ANIMATION_BLEND_SPACE_1D_H |