Aller au contenu

Photo

Playing music in combat


  • Veuillez vous connecter pour répondre
3 réponses à ce sujet

#1
FergusM

FergusM
  • Members
  • 460 messages
Okay, so I want to get some music playing when I start combat in my area. Problem is, I can't really find where this is controlled. I thought maybe something to do with 2DAs, but from poking around I didn't see anything that looked like 'specify the combat music for this area.' There doesn't seem to be any code for playing music in the area scripts.

I was looking through some old threads about this and I tried

        case EVENT_TYPE_COMBAT_INITIATED:
        {
            PlayMusic("BC_fade/combat"); //Also tried "music/BC_fade/combat"
        }
        case EVENT_TYPE_COMBAT_END:
        {
            StopMusic("BC_fade/combat");
        }

but that does not work.

#2
Challseus

Challseus
  • Members
  • 1 032 messages
Ah, music in Dragon Age, the bane of my existence... So, here's what I know:

* When looking at your area's properties, you'll see a section called Music Preset. You'll get values in the combo box, like Arl Eamon & Arl Eamon Blacksmith.

* If you look up those files under Sounds -> music -> Arl Eamon, you'll see some files, such as combat, Death, & main. All the other pieces of music follow this format, more or less.

* If you setup your area to use this music preset (utilizing the Music Volume settings), when combat beings, you'll hear the battle music. At least, I do anyway...

In short, it looks like the game assumes this specific format for your music. I've tried to emulate this with custom music, with no luck. See this thread for my own frustrations.

As a workaround, I've created one hell of a hack, by using sounds objects, instead of music for all my music needs. Hopefully, someone from Bioware can help clear this up at some point.

EDIT - I haven't had luck with PlayMusic() either. Someone (Craig?) said that the toolset should have shipped with a music editor or something, so you could find the right paths to all the music, and even preview it from within the toolset.

Modifié par Challseus, 28 février 2010 - 02:31 .


#3
FergusM

FergusM
  • Members
  • 460 messages
Hrm. That does get the battle music playing, but it plays the normal music as well. I might try dumping something in the override folder to make it not play the main music.

#4
Magic

Magic
  • Members
  • 187 messages
Does this work for you? Without "break", the EVENT_TYPE_COMBAT_INITIATED is executing the StopMusic() part as well.

        case EVENT_TYPE_COMBAT_INITIATED:
        {
            PlayMusic("BC_fade/combat"); //Also tried "music/BC_fade/combat"
            break;
        }
        case EVENT_TYPE_COMBAT_END:
        {
            StopMusic("BC_fade/combat");
            break;
        }