Angband.oook.cz
Angband.oook.cz
AboutVariantsLadderForumCompetitionComicScreenshotsFunniesLinks

Go Back   Angband Forums > Angband > Vanilla

Reply
 
Thread Tools Display Modes
Old April 13, 2008, 15:47   #1
nurak
Rookie
 
Join Date: Apr 2008
Posts: 3
nurak is on a distinguished road
Unhappy Sound configuration

Hi,

I've just migrated from 3.0.6 on Windows to 3.0.9b on Mac OSX. Unfortunately, I can't seem to get my sound configuration to work. I've made some edits that worked fine on Windows, changing some of the sound around for my taste (first step, get rid of kill.wav)...No matter what, the game does not seem to read my sound.cfg file from before. I've tried converting it from DOS to Unix line endings but it doesn't seem to matter. From what I've gathered from the source code it belongs in lib/xtra/sound but I guess that's not correct. Anyone else have this problem?

Thanks,
Russ
nurak is offline   Reply With Quote
Old April 13, 2008, 22:35   #2
Lebannen
Apprentice
 
Join Date: Apr 2008
Posts: 61
Donated: $20
Lebannen is on a distinguished road
The sound files themselves are stored within the app package (select application in Finder, File -> Show Package Contents, then Contents/Resources/lib/xtra/sound/ ). I don't think there's a sound.cfg on the mac though - what kind of things does that allow? Reassigning sounds to different actions?

But having just tried sound on trunk, 3.0.9 and 3.0.8, I couldn't get sound to work at all on my Mac. Could you get anything to play at all?
Lebannen is offline   Reply With Quote
Old April 13, 2008, 23:41   #3
Dragonboneman
Adept
 
Join Date: Aug 2007
Posts: 182
Dragonboneman is on a distinguished road
Older Mac versions had sound which was completely different from the PC - I played V3.0.5 on an old iMac a few times and remember it had bits of music from the soundtrack to Excalibur, possibly an extract from Carl Orff's Carmina Burana, on the tombstone screen for instance. I liked that soundset better than the one that comes with the current PC version.
Dragonboneman is offline   Reply With Quote
Old April 14, 2008, 11:44   #4
nurak
Rookie
 
Join Date: Apr 2008
Posts: 3
nurak is on a distinguished road
The sounds are in lib/xtra/sound but there is no sound.cfg. However the sounds play using the default settings found in the baseline version of sound.cfg. For example, if I delete kill.wav, no sound is played when I kill something.
This leads me to believe that the sound.cfg information is there somewhere, but where??

The sound.cfg file does allow you to assign sounds to many more events than are set by default. For example, I had this line in my old one:
hit_hi_great = SOUND181.WAV
This plays a sound from MS Pinball (yes, MS Pinball...) when you get a *GREAT* hit. You can assign a sound to each level of hit, but the baseline does not so they all sound the same. I also put 5 different sounds in for the normal "hit" so it's not so monotonous. Little things like that have made my hours and hours of Angband just a bit more entertaining...
nurak is offline   Reply With Quote
Old May 13, 2008, 18:44   #5
Lebannen
Apprentice
 
Join Date: Apr 2008
Posts: 61
Donated: $20
Lebannen is on a distinguished road
Just to let you know, I'm poking at the mac sound code following your mention of it. By the look of it, there is no .cfg file controlling which sounds get played (although the code was written for one at one point!), while it's waiting on a nicer solution. The current solution relies on matching sounds by looking at the filenames - so to get your HIT_HI_GREAT sound, drop in a hit_hi_great.wav file into the directory and it'll get played!

I quite like the simplicity of this solution without resorting to .cfg files (the "mac-like" solution would be to use a .plist, and they're nice but fairly verbose...) so I'm thinking of extending it further to allow, in future, hit_hi_great.wav, hit_hi_great.mp3 and hit_hi_great1.wav type matching. This would give multiple sound format support, and randomly choose between all available files for a bit of variation. I'll try and land it by 3.1.0.
Lebannen is offline   Reply With Quote
Old May 14, 2008, 09:55   #6
nurak
Rookie
 
Join Date: Apr 2008
Posts: 3
nurak is on a distinguished road
Talking

Great news!!

Thanks for looking at that; sometimes I find navigating all of C's #defines and #ifdefs more daunting than the pits of Angband themselves...

The filename matching definitely sounds easier and cleaner than the .cfg file. The randomizing would be great too, taking care of my other complaint. Perhaps when your solution is in place all the event names can be listed in a text file (or online help) so the casual non-source-code-reading player can figure it out...

It would be especially good if there were some way to standardize this across platforms. My laptop is still Windows and Linux, for example. Formats like mp3 would be cool, but I don't know if there is a true cross-platform solution for it, one that could be safely (license-wise) bundled with the game...But sox (LGPL) supports most of the pre-mpeg formats and could be a good choice.

Anyway, thanks for the info, and I'll be looking forward to 3.1.0!

Cheers,
Russ
nurak is offline   Reply With Quote
Old May 14, 2008, 10:23   #7
takkaria
Veteran
 
takkaria's Avatar
 
Join Date: Apr 2007
Posts: 1,951
Donated: $40
takkaria is on a distinguished road
Quote:
Originally Posted by Lebannen View Post
Just to let you know, I'm poking at the mac sound code following your mention of it. By the look of it, there is no .cfg file controlling which sounds get played (although the code was written for one at one point!), while it's waiting on a nicer solution. The current solution relies on matching sounds by looking at the filenames - so to get your HIT_HI_GREAT sound, drop in a hit_hi_great.wav file into the directory and it'll get played!

I quite like the simplicity of this solution without resorting to .cfg files (the "mac-like" solution would be to use a .plist, and they're nice but fairly verbose...) so I'm thinking of extending it further to allow, in future, hit_hi_great.wav, hit_hi_great.mp3 and hit_hi_great1.wav type matching. This would give multiple sound format support, and randomly choose between all available files for a bit of variation. I'll try and land it by 3.1.0.
I would recommend that instead of doing that, you just use the already-existing code in snd-sdl.c for reading in the sound.cfg file. Making sound use different mechanisms per platform seems like a maintenance nightmare to me...
takkaria is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
No sound in new Vanilla versions Mondkalb Vanilla 1 October 3, 2007 08:38
Sound on Linux with X11 is it available. tuppe666 Vanilla 10 September 13, 2007 16:42


All times are GMT +1. The time now is 07:56.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.