Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | TheWanderingShadow |
I am currently trying out the timer node to call a function, but at first glance it seems to be unable to activate a function that has an argument because I have to call the function by its name only.
func ready()
timer = Timer.new()
timer.set_wait_time(1)
timer.connect("timeout", self, "activate")
add_child(timer)
timer.start()
func activate(arg)
print(arg)
How can I use connect() in a way that lets me send an argument (a String in this case) to the function it calls?