How to play sounds

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

Hey so I know I’ve been asking a lot of questions lately, but I’m new to Godot. I just watched a tutorial by GamesFromScratch about how to add sound effects. I created my sample library and now, when I put “play(‘shot’)” in GDscript it says the that the “play” command does not exist… Is there an alternative? (PS: I’m in 1.1)

Nothing wrong with asking questions. But why 1.1?

duke_meister | 2016-05-26 22:49

:bust_in_silhouette: Reply From: jospic
get_node("yourNodeSoundPlayer").play("shot")

-j

Worked a treat thanks!!

Exos9 | 2016-05-26 16:52