Merge pull request #20259 from marcelofg55/anim_call_err
Print an error when calling an invalid method on an Animation
This commit is contained in:
commit
4ebcbea1ce
1 changed files with 6 additions and 0 deletions
|
@ -549,6 +549,12 @@ void AnimationPlayer::_animation_process_animation(AnimationData *p_anim, float
|
||||||
int s = params.size();
|
int s = params.size();
|
||||||
|
|
||||||
ERR_CONTINUE(s > VARIANT_ARG_MAX);
|
ERR_CONTINUE(s > VARIANT_ARG_MAX);
|
||||||
|
#ifdef DEBUG_ENABLED
|
||||||
|
if (!nc->node->has_method(method)) {
|
||||||
|
ERR_PRINTS("Invalid method call '" + method + "'. '" + a->get_name() + "' at node '" + get_path() + "'.");
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
if (can_call) {
|
if (can_call) {
|
||||||
MessageQueue::get_singleton()->push_call(
|
MessageQueue::get_singleton()->push_call(
|
||||||
nc->node,
|
nc->node,
|
||||||
|
|
Loading…
Add table
Reference in a new issue