why no tween_complete signal is emit by method tween.interpolate_callback

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By alexzheng
:warning: Old Version Published before Godot 3 was released.

call interpolate_property will emit tween_complete when the tween completed.

But call tween.interpolate_callback, no signal is emit.

I just want to call a method after some seconds, and free the tween object after the method is called.

Of course, this may achieved by Timer.

Or is there any more simpler way to do this?

Thanks

code: _on_tween_complete will not call

func _on_tween_complete(obj, key, tween):
print(“free”, obj, key)
tween.queue_free()

func call_delay(delay, object, method, arg0=null,arg1=null,arg2=null,arg3=null,arg4=null):
var tween = Tween.new()
tween.interpolate_callback(object, delay, method, arg0, arg1, arg2, arg3, arg4)
add_child(tween)
tween.start()
tween.connect(“tween_complete”, self, “_on_tween_complete”, [tween])

This sounds like a bug, maybe you should report this so it can be fixed for 2.1.4

eons | 2017-06-14 17:39