More than 1 tag?

  • Hi,

    Can I add more than 1 tag when playing audio?

    The Idea is to be able to mute all (not preventing play) and have separate tags for different actions.

    Thanks.

    Tagged:

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • This is not possible. If you want to keep track of which sounds are playing, you need to save their tags in an array.

  • I think what OP is asking is can you assign 2 tags to the same audio.

    you can't do this either, but you can refer to the last played audio with leaving the tag blank like this:

    Start of Layout > Audio compression on tag "weapons"
    
    OnShoot > Play shoot.wav tag: "weapons"
    
    	// change pitch of last played shoot sound
    	Audio playbackspeed random(0.9,1.1) tag: ""
    
  • I think what OP is asking is can you assign 2 tags to the same audio.

    Yeah, that's what I meant. For example, if you want to play sounds with tags like "laugh:enemy", "scream:enemy" and "scream:player", and then mute all screams, you can't do this. You'll need to associate these custom tags with each sound using an array or something similar.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)