Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | Nick888 |
When i start my game, at the same time starts and the music.I have created a button that if someone press it ,i want the music stop and if press it again i want the music starts. If i send a signal from button to AudioStreamPlayer node ιs there a specific code to stop and play the music again?
I thought something like that in general:
func _on_Button_pressed():
get_tree().<= not get_tree().
pass
Thank you.
I thought something like that in general:
func _on_Button_pressed():
get_tree().playmusic= not get_tree().playmusic
pass
Nick888 | 2019-06-05 08:30