Doing things to specific sounds.

This forum is currently in read-only mode.
0 favourites
From the Asset Store
75 explosion sound effects. Essential for many games, Explosions Sounds contains a mix of explosion and impact sounds.
  • I think it would be really useful if you could, with the sound plugin, just tell it to change frequency, volume or pan to "sound.wav" instead of seemingly having to do it to channels. Right now it seems a hassle to just change the volume of one sample that may play at the same time on the same channel as another sample.

    That's pretty much it. I would find it extremely useful, and I hate to bring up MMF again but that's how it works in it...

    EDIT: While I'm at it... it would be nice if the "play sound at object" didn't necessarily include volume, or have it seperate. I like it for its panning function, but sounds get quitier much too fast when you get away from the center of the listener position.

  • What if two "sound.wav"s are playing? Should it affect both, or one? If both, what if you wanted to control just one? If one, which one?

    I think the current system is very simple, just use the get last channel autoplayed expression after an Autoplay action, and set the parameters for that channel.

  • But wouldn't that do the same thing where it could affect two sounds. And mind you, the current use for it I would have would be for a character who has all the sounds played AT the character, with a channel associated with the character. That would affect multiple samples playing at once, no?

    It's overall a simpler approach too. About affecting two of the same samples, it did in MMF but the way I usually did things was to say to "stop" that specific sample before ever playing it again (can you stop specific samples now?).

    If I don't associate the character with a channel, does Construct make a new channel for every consecutive sample being played, for any object?

    Also, needing a new event to make the settings of a sample seems annoying. Maybe you play two samples in the same event, how does getting the last channel used work then?

    Questions, questions, questions?

    EDIT: About affecting one sample, if the setting are given right after the sample is played in the same event, does that not make it possible?

  • Playing around with adding sounds some more it seems really problematic. Attaching no samples to specific channels seems to place them all in the same one. I have a footstep sample and I made one foot in the run animation play the sound slightly faster, but this affects EVERY sample that plays if it plays at the same time or close to the foot sample.

    I imagined playing a sample outside of a specific channel would make it its own thing, hence why I requested the sample specific action like volume, frequency and stopping.

    Right now it seems really obnoxious and hard to get around.

  • every single audio library existing today works with channels.

    Only a single sample can be playing on one channel at any given time.

    That said, I could never get XAudio working with anything but autoplay for some reason

  • You're really overcomplicating this! It's very simple: use Autoplay for everything, and an action to set the parameters of the last autoplayed channel to control them.

    And mind you, the current use for it I would have would be for a character who has all the sounds played AT the character, with a channel associated with the character. That would affect multiple samples playing at once, no?

    No: you can only play one sound on one channel at a time. To achieve mixing (playing multiple sounds at once), you must play two simultaneous sounds on different channels. This is what autoplay is for - it picks a free channel and uses that to play the sound, and that channel number is what the 'get last channel autoplayed on' expression returns, so you can control every sound individually.

    [quote:2dmvivwn](can you stop specific samples now?).

    Yes, you have always been able to in XAudio2, just pass the channel number to stop.

    [quote:2dmvivwn]If I don't associate the character with a channel, does Construct make a new channel for every consecutive sample being played, for any object?

    As I said, autoplaying will assign a sound to a free channel automatically.

    [quote:2dmvivwn]Also, needing a new event to make the settings of a sample seems annoying. Maybe you play two samples in the same event, how does getting the last channel used work then?

    I don't see a problem here. You'd just do something like

    -> Autoplay "sound1.wav"

    -> Set channel <last channel autoplayed> volume to 90

    -> Autoplay "sound2.wav"

    -> Set channel <last channel autoplayed> volume to 80

    Voila, two independent volume sounds, all in one event.

    I think you're trying to control the specific channel on which every sound plays. That is unecessary. You should be taking advantage of autoplay.

  • Well, okay, thanks...

    But it still somehow affected the frequency of another sample playing at the same time...

    Also, stopping specific samples that may or may not be playing, what's the solution to that when the last channel set is probably not that specific one and I've used autoplay?

    Thanks for all the help!

    EDIT: I guess playing those on given channels, then.

  • Uhm, how do I actually place a resource sample on a given channel? I can't find any such action anywhere, only autplay resource, which puts it on a random, free channel.

    Maybe you can set a variable to the last channel used but that isn't really necessary, is it?

    EDIT: Sorry, found it. Let's see how many posts I make in this thread!

  • Is "Set channel XAudio2.LastChannel volume to (something)" supposed to work with positioned sounds? I couldn't get it to affect sounds played by autoplay file at position, or autoplay file at object. However, it does work perfectly with the non-positioned "autoplay file".

  • Playing at a position affects the volume so it's possible it locks it. Again, I'd love a feature where the volume is not affected by positioned sound, it only creates panning automatically. Like, a "restore volume" action that overrides positioned sounds.

  • you can always pan manually, leaving the volume untouched

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • A pitch adjustment would be really cool though...

    Making things like engine sounds that increase pitch as you speed up... things like that... really handy stuff.

    ~Sol

  • A pitch adjustment would be really cool though...

    Making things like engine sounds that increase pitch as you speed up... things like that... really handy stuff.

    ~Sol

    set frequency?

  • > A pitch adjustment would be really cool though...

    >

    > Making things like engine sounds that increase pitch as you speed up... things like that... really handy stuff.

    >

    > ~Sol

    >

    set frequency?

    Yeah that kinda makes it go all "squealy" doesn't it?

    Have you ever played with an audigy or x-fi sound card? Or even better the old SB Live, using the creative pitch changer? You can actually speed up and slow down sounds without changing the frequency... so the sound still sounds the "same" but faster or slower. It's kinda hard to explain if you haven't played around with it yourself.

    ~Sol

  • im going to attempt to do pitch shift/ and time stretch (what sol is talking about) fr my personal game engine

    if it works, ill release that part of it as a plugin

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