Jump to content
The Dark Mod Forums

Sfx Overlap Problem


Ishtvan

Recommended Posts

I'm trying to get the SFX for an objective to be played, but it seems like only one thing can play "globally" at once, even though it might look like it's on two different channels because it's on two different entities. This means that if the ambient music is playing globally, and the "objective complete" sound cuts in, it will cut off the ambient music (and possibly leave it off).

 

Does this make sense? Maybe one way around this would just be to play the sound on the player, set the falloff settings such that it maintains constant volume within the distance from your feet to your ears (your origin is your feet so that's where the sound will play) and set it to omnidirectional (so it's not global, but it will seem that way).

Link to comment
Share on other sites

That sounds like the best solution to me, especially if (as we were talking about in another thread) the player needs to hear the "objective completed" sound while still hearing the background music. If it were left as a global and got cut off that would be an abrupt interruption in the ambient sounds.

 

It's a shame that the engine is limited like that, but thinking about it from a programmer's point of view I guess it makes sense. The global should only be whatever is in that world or map at the time and the local sounds would be played for local events. The "objective complete" or "objective failed" sounds shouldn't affect the rest of the world, only the player. Whereas, the ambient sounds are part of the global world.

 

Okay, I had to put my object oriented hat on for that one!

"Without music to decorate it, time is just a bunch of boring production deadlines or dates by which bills must be paid."- Frank Zappa

Link to comment
Share on other sites

Wait, we only have one global sound channel? This is bad. We can't make smooth transitions between two areas with global ambients like that! Or am I missing something?

 

Whereas, the ambient sounds are part of the global world.

That would be SFX, no? I always called sounds not created by the environment as ambient.

Link to comment
Share on other sites

Yeah I'm not sure how we could crossfade the ambients. We can still make physically placed sounds omnidirectional, and could conceivably have two ambient-spheres overlapping to crossfade. But the geometry is pretty restricted to that.

 

I could be wrong about this, I was just basing it on Dram's library map with an ambient, and I had put in the start mission sound to play on a globally on the worldspawn, but as soon as the ambient kicked in it cut off the start sound. There may be a way for mappers to set up ambients so they don't hog the channel, I'm not sure.

 

"Global" is just supposed to be a flag anyway, just meaning that the volume never falls off. It's not supposed to be a channel and I would have expected multiple globals to be able to play. It could be that something else is happening in that map example.

Link to comment
Share on other sites

There are some open source libraries for doing that, so we might be able to create it on the fly. But then, we don't have the source for the sound engine, so I'm not sure how we could do that when a sounds is in the middle of playing.

Gerhard

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recent Status Updates

    • Ansome

      Well then, it's been about a week since I released my first FM and I must say that I was very pleasantly surprised by its reception. I had expected half as much interest in my short little FM as I received and even less when it came to positive feedback, but I am glad that the aspects of my mission that I put the most heart into were often the most appreciated. It was also delightful to read plenty of honest criticism and helpful feedback, as I've already been given plenty of useful pointers on improving my brushwork, level design, and gameplay difficulty.
      I've gotten back into the groove of chipping away at my reading and game list, as well as the endless FM catalogue here, but I may very well try my hand at the 15th anniversary contest should it materialize. That is assuming my eyes are ready for a few more months of Dark Radiant's bright interface while burning the midnight oil, of course!
      · 4 replies
    • The Black Arrow

      Any of you heard Age of Wonders 4's OST?
      https://www.youtube.com/watch?v=Q0TcoMGq4iA
      I love how after all these years, Michiel van den Bos still conserves his "Melodic" spirit.
      · 0 replies
    • nbohr1more

      Moddb article is up:  https://www.moddb.com/mods/the-dark-mod/news/the-dark-mod-212-is-here
      · 3 replies
    • Petike the Taffer

      I've been gone for a while, but now I'm back, have a new desktop and I want to get back to making missions and playing missions. And doing other contributions. Waiting for my reset password for the wiki, but I'll take a look at it soon. Hello, all.
      · 4 replies
    • snatcher

      TDM Modpack 4.0 for The Dark Mod 2.12 released!
      · 1 reply
×
×
  • Create New...