Attention: Here be dragons
This is the latest
(unstable) version of this documentation, which may document features
not available in or compatible with released stable versions of Godot.
Checking the stable version of the documentation...
AnimationNodeAnimation
繼承: AnimationRootNode < AnimationNode < Resource < RefCounted < Object
AnimationNodeBlendTree 的輸入動畫節點。
說明
可加入 AnimationNodeBlendTree 的資源。僅透過 animation 作為單一輸出埠,供其他 AnimationNode 進行動畫混合之輸入使用。
教學
屬性
|
||
|
||
|
||
|
列舉
enum PlayMode: 🔗
PlayMode PLAY_MODE_FORWARD = 0
正向播放動畫。
PlayMode PLAY_MODE_BACKWARD = 1
反向播放動畫。
屬性說明
bool advance_on_start = false 🔗
若為 true,當收到自開頭播放動畫的請求時,第一幀僅進行處理但不渲染,播放將自下一幀開始。
另請參閱 AnimationPlayer.play() 的注意事項。
StringName animation = &"" 🔗
void set_animation(value: StringName)
StringName get_animation()
要輸出的動畫,必須是 AnimationTree.anim_player 所提供的動畫之一。
當 use_custom_timeline 為 true 時,會以此值覆寫原始 Animation 資源的迴圈設定。
注意: 若 Animation.loop_mode 未設為循環,則 Animation.track_set_interpolation_loop_wrap() 不會生效。若行為不如預期,建議複製該 Animation 資源並調整其迴圈設定。
決定動畫的播放方向。
當 use_custom_timeline 為 true 時,可偏移動畫的起始位置。
這對於在 3D 行走動畫中調整先踏出的腳十分有用。
若為 true,會縮放時間,使 timeline_length 所設定的長度成為一個循環。
這有助於對齊走路與跑步動畫的週期。
若為 false,則使用原始動畫長度。若你啟用 loop_mode 迴圈,動畫將於 timeline_length 內循環。
The length of the custom timeline.
If stretch_time_scale is true, scales the animation to this length.
bool use_custom_timeline = false 🔗
若為 true,此 AnimationNode 會輸出以調整部分參數後的 Animation 資源。