mirror of
https://github.com/godotengine/godot.git
synced 2025-12-07 22:00:10 +00:00
Merge pull request #113140 from LanzaSchneider/fix-animation-mixer-invalid-cache-spam
Fix AnimationMixer error spam by respecting cache validity on invalid `root_node`
This commit is contained in:
commit
9c7bea6cda
1 changed files with 2 additions and 1 deletions
|
|
@ -660,6 +660,7 @@ bool AnimationMixer::_update_caches() {
|
|||
|
||||
Node *parent = get_node_or_null(root_node);
|
||||
if (!parent) {
|
||||
WARN_PRINT_ONCE(vformat("'%s' is an invalid root_node path, caches will not be built, please check the root_node assignment on: %s", root_node, get_path()));
|
||||
cache_valid = false;
|
||||
return false;
|
||||
}
|
||||
|
|
@ -1000,7 +1001,7 @@ bool AnimationMixer::_update_caches() {
|
|||
|
||||
void AnimationMixer::_process_animation(double p_delta, bool p_update_only) {
|
||||
_blend_init();
|
||||
if (_blend_pre_process(p_delta, track_count, track_map)) {
|
||||
if (cache_valid && _blend_pre_process(p_delta, track_count, track_map)) {
|
||||
_blend_capture(p_delta);
|
||||
_blend_calc_total_weight();
|
||||
_blend_process(p_delta, p_update_only);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue