Working with audio files in CoBlocks


#1

With CoBlocks, i can add images to a list and then, updating an index, make visible a single image, like in a slideshow. I want to play specific audio files related to each image; but in CoBlocks i cannot add audio files to a list and then reference to them, as i can do with images. I can make a script, but it would be very nice to be able to set everything in CoBlocks.
Any clue? thanks in advance!


#2

Hi @mariochiesa,

yes, sounds can currently not be stored in lists. I’ll send your feedback to our developers so that we can look into an easy way to make that possible :slight_smile:

As a workaround you could do an if-check for the index of the currently displayed image and play the sound like that.

Below you can find a template which uses only CoBlocks and a few functions to get the desired results. Please have a look. You can copy this space by pressing the remix button.