Sound stop

Hi everyone, is there any way to make a sound suddenly stop when you tap the screen.
Thx

@Klupa56 Looking thru the sound documentation, there doesn’t seem to be any way to stop sounds. Maybe you should look at the music function. That has a stop function.

When you call sound(), it returns a sound object. Just store that in a variable, i.e. mySound = sound(...)

Then, when you touch the screen, just call mySound:stop()

Edit: extremely small example

-- Sound Object

function setup()
    mySound = sound("Game Sounds One:1-2-3 Go")
end

function touched(touch)
    mySound:stop()
end

@dave1707 There’s a lot of stuff about sounds that are undocumented, actually. Here’s what I found: http://codea.io/talk/discussion/5310/hidden-sound-functions#latest

@SkyTheCoder Thanks. I now remember seeing that when you posted it the first time.

@SkyTheCoder could it get the functions which could manipulated Codea’s editor like this?

@firewolf I don’t understand what you mean. Nothing can change the editor.