diff options
author | SaracenOne <SaracenOne@gmail.com> | 2022-04-20 11:36:54 +0100 |
---|---|---|
committer | K. S. Ernest (iFire) Lee <ernest.lee@chibifire.com> | 2022-06-28 09:26:13 -0700 |
commit | 75a8606b8335bb6e16b13909fa7f7ae09bed3882 (patch) | |
tree | 600cc82b3a37958b63abc2cc11dd17f3ae8c320f /doc/classes | |
parent | b863c40356b4b95192d1a1e2718db7d7aced4235 (diff) |
Add AnimationTree Advance Expressions
Allows specifying an expression as a condition for state machine transitions.
This gives much greater flexibility for creating complex state machines. By directly interfacing with the script code, it is possible to create complex animation advance condition for switching between states.
Ensure assigning AnimationTreeStateMachineTransition base expression node in editor is relative to current AnimationTree node.
Allow setting an expression base node on the AnimationTree itself.
Co-Authored-By: reduz <reduzio@gmail.com>
Diffstat (limited to 'doc/classes')
-rw-r--r-- | doc/classes/AnimationNodeStateMachineTransition.xml | 6 | ||||
-rw-r--r-- | doc/classes/AnimationTree.xml | 3 |
2 files changed, 9 insertions, 0 deletions
diff --git a/doc/classes/AnimationNodeStateMachineTransition.xml b/doc/classes/AnimationNodeStateMachineTransition.xml index 94e6a2f23d..206164d675 100644 --- a/doc/classes/AnimationNodeStateMachineTransition.xml +++ b/doc/classes/AnimationNodeStateMachineTransition.xml @@ -19,6 +19,12 @@ [/csharp] [/codeblocks] </member> + <member name="advance_expression" type="String" setter="set_advance_expression" getter="get_advance_expression" default=""""> + Use an expression as a condition for state machine transitions. It is possible to create complex animation advance conditions for switching between states and gives much greater flexibility for creating complex state machines by directly interfacing with the script code. + </member> + <member name="advance_expression_base_node" type="NodePath" setter="set_advance_expression_base_node" getter="get_advance_expression_base_node" default="NodePath("")"> + The path to the [Node] used to evaluate an [Expression] if one is not explictly specified internally. + </member> <member name="auto_advance" type="bool" setter="set_auto_advance" getter="has_auto_advance" default="false"> Turn on the transition automatically when this state is reached. This works best with [constant SWITCH_MODE_AT_END]. </member> diff --git a/doc/classes/AnimationTree.xml b/doc/classes/AnimationTree.xml index 67e64c6bee..ecac228a26 100644 --- a/doc/classes/AnimationTree.xml +++ b/doc/classes/AnimationTree.xml @@ -37,6 +37,9 @@ <member name="active" type="bool" setter="set_active" getter="is_active" default="false"> If [code]true[/code], the [AnimationTree] will be processing. </member> + <member name="advance_expression_base_node" type="NodePath" setter="set_advance_expression_base_node" getter="get_advance_expression_base_node" default="NodePath(".")"> + The path to the [Node] used to evaluate the AnimationNode [Expression] if one is not explictly specified internally. + </member> <member name="anim_player" type="NodePath" setter="set_animation_player" getter="get_animation_player" default="NodePath("")"> The path to the [AnimationPlayer] used for animating. </member> |