Implementing sound play function