Background music/sound effects

Messages are moved here (should anyone ever want to see them again) once they are no longer applicable to the current version (e.g. suggestions that have been implemented or bugs that have been fixed).

Moderator: George Gilbert

Forum rules
Please read the Forum rules and policies before posting. You may Image to help finance the hosting costs of this forum.
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Background music/sound effects

Post by Gambit37 »

What I'd like is the ability to specify a loopable sound file as a background track for each level, or even different parts of the same level. These kinds of things really add to the ambience.

Perhaps you could make a sub-set of functions that don't affect the dungeon, but affect world events or system settings. This way you could still use normal invisible pressure pads to activate sound effects, change background music, etc.
User avatar
beowuuf
Archmastiff
Posts: 20686
Joined: Sat Sep 16, 2000 2:00 pm
Location: Basingstoke, UK

Re: Background music/sound effects

Post by beowuuf »

If something in the dungeon can trigger a sound file being activated, how about also having the ability to trigger other files. Dungeon builders can have graphics or animations come up at key places. Picking up an important object, opening a main door, etc - or new endings for each dungeon, which has always been the drawback of DMuting DM/
Was unable to (permenantly) kill off ian_scho (Haynuus), Ameena, oh_brother (Westian), money (Falkor), raixel (Petal) and Lord_Bones (Aurek) in the DM D&D game Time's Champions!

CONGRATULATIONS TO THOSE WHO MADE THE GAME WHAT IT WAS - GREAT!
Francis
Novice
Posts: 16
Joined: Thu Jul 06, 2000 8:00 pm

Background music/sfx

Post by Francis »

Perhaps sounds could emanate from specific objects, like the running water of a fountain; with air vents, the footsteps of monsters in a different area could echo throughout a maze...
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Re: Background music/sfx

Post by Gambit37 »

Just been thinking about this again with the release of v0.16:

* Would it be possible to change SOUNDS so that they have a LOOPING parameter? For example, a designer might want one long sound effect to play when a door opens and for it NOT to loop. This would also benefit the ability to create AMBIENT sound effects...

* ... speaking of which, is this possible? I mean, is it possible to create an object that does nothing other than play an ambient sound (either controlled via triggers or as a permanent object). The difficulty at the moment is that all objects sound effects have a volume setting depending on how far away the player is. Generally, ambient sounds (such as wind) would want to play at a fixed volume so that it's heard consistently wherever you are. Obviously something like running water would need the a DISTANCE parameter. Perhaps you might consider adding this suport?

Something along these lines: SOUND_NEW_SFX_WIND mysound1.wav LOOP=(TRUE) DISTANCE=(5), where DISTANCE is the number of tiles away the effect can be heard (getting progressively quieter).
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Re: Background music/sfx

Post by Gambit37 »

Having messed around with various combinations of triggers and the like, it's not really possible to create sound effects and ambient sounds yet. I think that these would require a new trigger type, something like this:

FLOORITEM_SFX 2 2 2 ACTIVE SOUND=(MYSOUNDEFFECT) DISTANCE=(5)

These could be affected directly using other triggers, switching them from ACTIVE to INACTIVE to start and stop the sound. Perhaps a distance of -1 would mean the sound could be heard over the entire level. Couple this with my previous post and the dungeon designer will have loads of possibilities for creating ambience within the dungeon. This is the kind of the thing that will take RTC way above DMJava in terms of atmosphere and flexibility.
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

Was going to post this suggestion again, but found the original thread. I think ambient sounds would be very cool indeed, if used sparingly and wisely... what do you think of this suggestion George?
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

Bumping up in the hope this is added to 0.29....
User avatar
linflas
My other avatar is gay
Posts: 2445
Joined: Tue Nov 04, 2003 9:58 pm
Location: Lille, France
Contact:

Post by linflas »

bumping up too..
how about a music during intro (GG... presents... etc) and continuing during the beginning of the game ? additional intro.mp3 or ogg file, but not absolutely needed.
User avatar
PadTheMad
Lo Master
Posts: 420
Joined: Thu Jul 15, 2004 12:22 pm
Location: Doncaster, UK

Post by PadTheMad »

You can sort of do this in DM Java so it sounds (haha pun not intended :wink: ) possible.

Also, the slightly quirky DM port on the SNES had both music and ambient sound effects. The music was pretty cool and added to the atmosphere, partially making up for it's horrendous graphics and easier dungeon layout. (I guess back in the day the developers responsible thought console owners a lot more stupid than Amiga and Atari owners...)
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

Bumping up in the hope this is added to 0.29.... *I REALLY, REALLY WANT AMBIENT SOUNDS!!!* ;)
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

Any possibility of this at all? *bump*
User avatar
Lee
Artisan
Posts: 182
Joined: Wed Mar 16, 2005 8:09 pm
Location: Montréal
Contact:

Post by Lee »

I know I would make FULL use of something of this magnitude, excellent idea. I'd ask if there's any chance but there hasn't been any answer to it for 4 years lol :(
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

George tends to not answer queries he has no intention of implementing.... ;)

And four years???!!!!! :shock:
User avatar
Lee
Artisan
Posts: 182
Joined: Wed Mar 16, 2005 8:09 pm
Location: Montréal
Contact:

Post by Lee »

Yessiree it's been 4 years since the 1st post of this thread!

Hehe, I kinda figured as much about George. Oh well, great idea anyway :P

What about if we buy him a kebab though?
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

I've been experimenting a bit with using music and ambient sounds in the latest version of RTC using pressure pads that have the sounds applied as the 'trigger' sound.

Generally works well for short sounds and short musical 'stings'. But for longer stuff it's not really suitable as there's no way of selectively stopping a track that's already playing. And for ambient effects that requiring looping, it's a no-no.

I think these features would be fantastic:

1) A SFX trigger (as discussed at the top of the thread)
1) Ability to selectively stop a sound by it's name or some kind of internal ID
2) Ability to selectively faed in/out a sound by it's name or some kind of internal ID
3) Ability for RTC to respect sustaining loop meta data embedded in WAVs (so that the designer can make the wav loop and RTC doesn't need to do anything further with it) -- or if this is no good, to have a 'looping' parameter.
4) Ability to specify directional or non directional volume for a sound -- so that ambient loops would play at a fixed volume but static sounds such as a fountain trickling would get louder and quieter as the party move to and from the source.

As you're using DirectX for the sound layer, it should be pretty straightforward to add this kind of functionality in. I read up on some background info about DirectX sound and pretty much all the hardwork is done for you. You only need to call the relevant functions through the API.

I have some wonderful ideas for creating atmosphere in RTC scenarios but it's simply not possible at the moment. I realise that this is your personal project George and you're a very busy man, but it's incredibly disappointing to have had no discussion on this subject for FOUR years.

I have always wanted to produce a DM type game with much more atmosphere and ambience than was possible back in the day. Technology now allows me to do that, and I could use *any* engine out there to great effect - Source, Unreal, etc. But these FPS style engines, while stunning, don't have the feel of the old 'step' type games which is what I (and many others) still love about the genre. I could make the switch and put my energies into one of these engines and find some way of retaining the old-style gameplay. But I don't want to do that, I want to support RTC.

I have an inkling that one reason we don't hear from you about these possible new features is that you might be of the mind that you won't add anything new until we've proved that we can create something decent with the engine as it stands. That's a very fair point. It's just unfortunate that the decent things some of us want to produce really do require a few features that currently don't exist in RTC. A terrible Catch-22 that likely leaves both you and us frustrated.

Maybe that kebab might persuade you? ;)

EDIT: I mocked up some editor screens to show how they might be implemented. I know this is the easy bit. ;) Maybe it will inspire you?

Image

Image

Image

Image
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

I see you're up and about fixing things for 0.35, George. Do you have any comments on my above post at all?
User avatar
George Gilbert
Dungeon Master
Posts: 3022
Joined: Mon Sep 25, 2000 11:04 am
Location: London, England
Contact:

Post by George Gilbert »

I wondered how long it would take until someone bumped this post :lol:
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

So, no then... guess I have to wait another four years? :(
User avatar
George Gilbert
Dungeon Master
Posts: 3022
Joined: Mon Sep 25, 2000 11:04 am
Location: London, England
Contact:

Post by George Gilbert »

I didn't say that...
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

Hmmm... well, I guess *no* news is good news, right? ;)
User avatar
George Gilbert
Dungeon Master
Posts: 3022
Joined: Mon Sep 25, 2000 11:04 am
Location: London, England
Contact:

Post by George Gilbert »

Well, no news is certainly better than "no" news, that is news saying no.

This conversation could get quite surreal...
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

Indeed. So I'll be more direct. Do you think any of the above is a) workable and b) will-you-doable?
User avatar
George Gilbert
Dungeon Master
Posts: 3022
Joined: Mon Sep 25, 2000 11:04 am
Location: London, England
Contact:

Post by George Gilbert »

Taking your screen shots in order...

1) Directional-ness - no
2) Volume distance - no; change the vlolume of the source file instead!

FYI - volume in RTC is a function of both absolute distance but then also modified by walls / doors that are in the way etc. Changing the volume by any more parameters starts getting very messy!

3) Looping - should be OK (presuming there's a suitable DX API)
4) Stop / start controls - fine.
5) Fade - possibly (again depending on DX APIs)

Note that all of this would require a substantial re-write of all the sound code in RTC. In particular it would need to keep track of what is playing, volumes etc (at the moment it just hits play and forgets about it). For example, it has to cope with the party walking over a fade in pad then saving. When you re-load, it has to then find the right place in the WAV file, set the right volume and keep playing. It might all seem trivial but under the covers it's a big ugly mess!

So to answer your direct question (!), a) yes, it's all do-able, it's just a question of its complexity and the time available. b) some of it probably yes. First up would be the ambient and fixed point sounds (with optional looping) together with a stop pad. Anything else would be at a much lower priority...
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

1) Directional-ness - no
So spot effects such as a fountain trickling in the center of a room can't be done? This seems to contradict your very last point. ("First up would be the ambient and fixed point sounds"). If a sound has a fixed point in the dungeon, by extension, it *must* be directional. If you step right of it, the sound would come from the left speaker, etc.

Perhaps I need to explain better what I meant:

Directional: sound comes froma fixed point and as the party move towards/away from it, it gets louded/softer (like a fountain)
Non-directional: Sound can be heard throughout the level at the same continuous volume (like a low wind loop)
When you re-load, it has to then find the right place in the WAV file, set the right volume and keep playing
I think that's overkill -- just remembering what was playing and starting it again from the beginning would be more than fine.
First up would be the ambient and fixed point sounds (with optional looping) together with a stop pad.
I'd be pretty happy with that! :) Being able to start and stop some background ambience at the entrance/exit to each level would be cool... and fades aren't that important, that could be done to the files themselves using some sound software.

I had another thought. Maybe there should be some way of distinguishing sounds that are ambient and sounds that are music? And then giving some sort of sound control to the user so that if they turn off music, atmopsheric ambience will still play?

How many kebabs do you want?
User avatar
George Gilbert
Dungeon Master
Posts: 3022
Joined: Mon Sep 25, 2000 11:04 am
Location: London, England
Contact:

Post by George Gilbert »

Quote:
1) Directional-ness - no


So spot effects such as a fountain trickling in the center of a room can't be done? This seems to contradict your very last point. ("First up would be the ambient and fixed point sounds"). If a sound has a fixed point in the dungeon, by extension, it *must* be directional. If you step right of it, the sound would come from the left speaker, etc.

Perhaps I need to explain better what I meant:

Directional: sound comes froma fixed point and as the party move towards/away from it, it gets louded/softer (like a fountain)
Non-directional: Sound can be heard throughout the level at the same continuous volume (like a low wind loop)
Ahhhhh....I thought you meant by directional something like a sound can only be heard from the West of it etc - i.e. the sound is being directed in one direction....i.e. directional.

All sounds are already processed in surround sound (so a sound coming from the back left of your party will play out out the back left speaker louder than the others - if you've got that kind of kit in your computer) so a fountain playing louder / softer / left /right you'll get for free once there's code to specify the sound at all.
I had another thought. Maybe there should be some way of distinguishing sounds that are ambient and sounds that are music? And then giving some sort of sound control to the user so that if they turn off music, atmopsheric ambience will still play?
Interesting - could be a config option I suppose. Mind you I can't really think why someone would want one sort of background noise and not another.
How many kebabs do you want?
Depends on how many pints precede it :lol:
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

Ahhhhh....I thought you meant by directional something like a sound can only be heard from the West of it etc - i.e. the sound is being directed in one direction....i.e. directional.
Funny how it should have been that obvious! Apologies.
Interesting - could be a config option I suppose. Mind you I can't really think why someone would want one sort of background noise and not another.
Most modern games have a soundtrack that you can disable if you don't like it, but atmospheric ambience will be unaffected. I can imagine that some would want to switch music off.

As for pints, these days probably 3. Ten years ago it would have been 8 or 9....
User avatar
DragonsLover
Craftsman
Posts: 110
Joined: Sat Jun 14, 2003 12:37 am

Post by DragonsLover »

I'm interested to get background music. Why not using MIDIs too?
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

Any movement on this feature?
User avatar
Sophia
Concise and Honest
Posts: 4306
Joined: Thu Sep 12, 2002 9:50 pm
Location: Nowhere in particular
Contact:

Post by Sophia »

Gambit37 wrote:George tends to not answer queries he has no intention of implementing.... ;)
Ah the flaws of closed-source software! :wink:
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Post by Gambit37 »

Any progress on this for v0.35? Are you thinking about it at all GG?
Post Reply